Share via


Get Model Info - Get Model Info

Returns information about the AI model deployed. The method makes a REST API call to the /info route on the given endpoint. This method will only work when using Serverless API, Managed Compute, or Model . inference endpoint. Azure OpenAI endpoints don't support i.

GET https://{resource}.services.ai.azure.com/models/info?api-version=2024-05-01-preview

URI Parameters

Name In Required Type Description
resource
path True

string

The Azure AI Services resource name, for example 'my-resource'

api-version
query True

string

minLength: 1

The API version to use for this operation.

Responses

Name Type Description
200 OK

ModelInfo

The request has succeeded.

Other Status Codes

Azure.Core.Foundations.ErrorResponse

An unexpected error response.

Headers

x-ms-error-code: string

Security

api-key

Type: apiKey
In: header

OAuth2Auth

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/v2.0/authorize

Scopes

Name Description
https://cognitiveservices.azure.com/.default

Examples

maximum set model information
minimum set model information

maximum set model information

Sample request

GET https://{resource}.services.ai.azure.com/models/info?api-version=2024-05-01-preview

Sample response

{
  "model_name": "Phi-3.5-mini-instruct",
  "model_type": "chat-completion",
  "model_provider_name": "Microsoft"
}

minimum set model information

Sample request

GET https://{resource}.services.ai.azure.com/models/info?api-version=2024-05-01-preview

Sample response

{
  "model_name": "Phi-3.5-mini-instruct",
  "model_type": "chat-completion",
  "model_provider_name": "Microsoft"
}

Definitions

Name Description
Azure.Core.Foundations.Error

The error object.

Azure.Core.Foundations.ErrorResponse

A response containing error details.

Azure.Core.Foundations.InnerError

An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/microsoft/api-guidelines/blob/vNext/azure/Guidelines.md#handling-errors.

ModelInfo

Represents some basic information about the AI model.

ModelType

The type of AI model

Azure.Core.Foundations.Error

The error object.

Name Type Description
code

string

One of a server-defined set of error codes.

details

Azure.Core.Foundations.Error[]

An array of details about specific errors that led to this reported error.

innererror

Azure.Core.Foundations.InnerError

An object containing more specific information than the current object about the error.

message

string

A human-readable representation of the error.

target

string

The target of the error.

Azure.Core.Foundations.ErrorResponse

A response containing error details.

Name Type Description
error

Azure.Core.Foundations.Error

The error object.

Azure.Core.Foundations.InnerError

An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/microsoft/api-guidelines/blob/vNext/azure/Guidelines.md#handling-errors.

Name Type Description
code

string

One of a server-defined set of error codes.

innererror

Azure.Core.Foundations.InnerError

Inner error.

ModelInfo

Represents some basic information about the AI model.

Name Type Description
model_name

string

The name of the AI model. For example: Phi21

model_provider_name

string

The model provider name. For example: Microsoft

model_type

ModelType

The type of the AI model. A Unique identifier for the profile.

ModelType

The type of AI model

Value Description
chat-completion

A model capable of taking chat-formatted messages and generate responses

embeddings

A model capable of generating embeddings from a text