Share via

Foundry endpoint not working

Carlos Albarran 0 Reputation points
2026-04-07T00:49:00.2733333+00:00

Hello:

I activated the following foundry endpoint:

https://REDACTED.openai.azure.com/openai/deployments/Kimi-K2.5/chat/completions?api-version=2024-02-01

https://ai.azure.com/nextgen/r/[RESOURCE_ID_REMOVED]

However, I am getting the following error. What is missing? I activated everything... kindly asking for your help.

{"error":{"code":"404","message": "Resource not found"}}

Note: PII Redacted at support side.

Azure Machine Learning

1 answer

Sort by: Most helpful
  1. Manas Mohanty 16,190 Reputation points Microsoft External Staff Moderator
    2026-04-14T10:06:21.9733333+00:00

    Hi Carlos Albarran,

    Endpoint syntax does not seem to be correct.

    I just tested below code copied from deployment/code with Owner (Sub inherited)/Azure AI user (RG inherited) and it is working for me.

    User's image

    from openai import OpenAI
    
    endpoint = "https://<pleaserefereploymentcode>.openai.azure.com/openai/v1/" deployment_name = "Kimi-K2.5"
    api_key = "<your-api-key>"
    
    client = OpenAI(
        base_url=endpoint,
        api_key=api_key
    )
    
    completion = client.chat.completions.create(
        model=deployment_name,
        messages=[
            {
                "role": "user",
                "content": "What is the capital of France?",
            }
        ],
    )
    
    print(completion.choices[0].message)
    
    
    

    Output

     ChatCompletionMessage(content='The capital of France is **Paris**.', refusal=None, role='assistant', annotations=None, audio=None, function_call=None, tool_calls=None, reasoning_content='The user is asking a very simple factual question: "What is the capital of France?" This is a straightforward question with a clear, unambiguous answer. The capital of France is Paris.\n\n I should provide a direct, concise answer. I don\'t need to overcomplicate this with unnecessary details unless the user asks for more information, but a brief, friendly confirmation is appropriate.\n\n Answer: Paris.')
    
    
    

    Attached screenshot for reference

    User's image

    Note:

    Found a discrepancy in endpoint syntax creation though. Created a feedback item and checking with PG team internally on it.

    Please copy the code suggested in deployment as workaround

    
    endpoint = "https://<project-name>-resource.openai.azure.com/openai/v1/
    
    
    

    Please let us know the proposed approach helps address the issue

    Thank you.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.