Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding Models to Typespec for CLU #24376

Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ using Azure.Core.Traits;
})
namespace Azure.AI.Language.Conversations;

alias ErrorResponse = Azure.Core.Foundations.ErrorResponse;
model ErrorResponse is Azure.Core.Foundations.ErrorResponse;

@doc("An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses.")
model InnerErrorModel extends Record<unknown> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -323,6 +323,55 @@
"modelAsString": true
}
},
"Azure.Core.Foundations.Error": {
heaths marked this conversation as resolved.
Show resolved Hide resolved
"type": "object",
"properties": {
"code": {
"type": "string",
"description": "One of a server-defined set of error codes."
},
"message": {
"type": "string",
"description": "A human-readable representation of the error."
},
"target": {
"type": "string",
"description": "The target of the error."
},
"details": {
"type": "array",
"items": {
"$ref": "#/definitions/Azure.Core.Foundations.Error"
},
"x-ms-identifiers": [],
"description": "An array of details about specific errors that led to this reported error.",
"x-typespec-name": "Azure.Core.Foundations.Error[]"
},
"innererror": {
"$ref": "#/definitions/Azure.Core.Foundations.InnerError",
"description": "An object containing more specific information than the current object about the error."
}
},
"description": "The error object.",
"required": [
"code",
"message"
]
},
"Azure.Core.Foundations.InnerError": {
"type": "object",
"properties": {
"code": {
"type": "string",
"description": "One of a server-defined set of error codes."
},
"innererror": {
"$ref": "#/definitions/Azure.Core.Foundations.InnerError",
"description": "Inner error."
}
},
"description": "An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses."
},
"BaseExtraInformation": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -820,6 +869,19 @@
"modelAsString": true
}
},
"ErrorResponse": {
"type": "object",
"properties": {
"error": {
"$ref": "#/definitions/Azure.Core.Foundations.Error",
"description": "The error object."
}
},
"description": "A response containing error details.",
"required": [
"error"
]
},
"InformationResolution": {
"type": "object",
"properties": {
Expand Down