Share via


Custom Models - Get Copy Result

Obtain current status and the result of a custom model copy operation.

GET {endpoint}/formrecognizer/v2.1/custom/models/{modelId}/copyResults/{resultId}

URI Parameters

Name In Required Type Description
endpoint
path True

string

Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus2.api.cognitive.microsoft.com).

modelId
path True

string (uuid)

Model identifier.

resultId
path True

string (uuid)

Copy operation result identifier.

Request Header

Name Required Type Description
Ocp-Apim-Subscription-Key True

string

Responses

Name Type Description
200 OK

CopyOperationResult

Success

Other Status Codes

ErrorResponse

Response entity accompanying non-successful responses containing additional details about the error.

Security

Ocp-Apim-Subscription-Key

Type: apiKey
In: header

Examples

Get copy custom model result
Get copy custom model result with failures

Get copy custom model result

Sample request

GET {endpoint}/formrecognizer/v2.1/custom/models/f973e3c1-1148-43bb-bea8-49d0603ab3a8/copyResults/3b1e6c5b-e113-4114-ab6b-ce65dfe8050f

Sample response

{
  "status": "succeeded",
  "createdDateTime": "2020-01-01T00:00:00Z",
  "lastUpdatedDateTime": "2020-01-01T00:01:00Z",
  "copyResult": {
    "modelId": "f973e3c1-1148-43bb-bea8-49d0603ab3a8",
    "errors": []
  }
}

Get copy custom model result with failures

Sample request

GET {endpoint}/formrecognizer/v2.1/custom/models/f973e3c1-1148-43bb-bea8-49d0603ab3a8/copyResults/3b1e6c5b-e113-4114-ab6b-ce65dfe8050f

Sample response

{
  "status": "failed",
  "createdDateTime": "2020-01-01T00:00:00Z",
  "lastUpdatedDateTime": "2020-01-01T00:01:00Z",
  "copyResult": {
    "modelId": "f973e3c1-1148-43bb-bea8-49d0603ab3a8",
    "errors": [
      {
        "code": "ResourceResolverError",
        "message": "{ErrorMessage}"
      }
    ]
  }
}

Definitions

Name Description
CopyOperationResult

Status and result of the queued copy operation.

CopyResult

Custom model copy result.

ErrorInformation
ErrorResponse
OperationStatus

Status of the queued operation.

CopyOperationResult

Status and result of the queued copy operation.

Name Type Description
copyResult

CopyResult

Results of the copy operation.

createdDateTime

string (date-time)

Date and time (UTC) when the copy operation was submitted.

lastUpdatedDateTime

string (date-time)

Date and time (UTC) when the status was last updated.

status

OperationStatus

Operation status.

CopyResult

Custom model copy result.

Name Type Description
errors

ErrorInformation[]

Errors returned during the copy operation.

modelId

string (uuid)

Identifier of the target model.

ErrorInformation

Name Type Description
code

string

message

string

ErrorResponse

Name Type Description
error

ErrorInformation

OperationStatus

Status of the queued operation.

Value Description
notStarted
running
succeeded
failed