{ "version":"2.0", "metadata":{ "apiVersion":"2017-05-13", "endpointPrefix":"runtime.sagemaker", "jsonVersion":"1.1", "protocol":"rest-json", "serviceFullName":"Amazon SageMaker Runtime", "serviceId":"SageMaker Runtime", "signatureVersion":"v4", "signingName":"sagemaker", "uid":"runtime.sagemaker-2017-05-13" }, "operations":{ "InvokeEndpoint":{ "name":"InvokeEndpoint", "http":{ "method":"POST", "requestUri":"/endpoints/{EndpointName}/invocations" }, "input":{"shape":"InvokeEndpointInput"}, "output":{"shape":"InvokeEndpointOutput"}, "errors":[ {"shape":"InternalFailure"}, {"shape":"ServiceUnavailable"}, {"shape":"ValidationError"}, {"shape":"ModelError"} ], "documentation":"

After you deploy a model into production using Amazon SageMaker hosting services, your client applications use this API to get inferences from the model hosted at the specified endpoint.

For an overview of Amazon SageMaker, see How It Works.

Amazon SageMaker strips all POST headers except those supported by the API. Amazon SageMaker might add additional headers. You should not rely on the behavior of headers outside those enumerated in the request syntax.

Cals to InvokeEndpoint are authenticated by using AWS Signature Version 4. For information, see Authenticating Requests (AWS Signature Version 4) in the Amazon S3 API Reference.

Endpoints are scoped to an individual account, and are not public. The URL does not contain the account ID, but Amazon SageMaker determines the account ID from the authentication token that is supplied by the caller.

" } }, "shapes":{ "BodyBlob":{ "type":"blob", "max":5242880, "sensitive":true }, "CustomAttributesHeader":{ "type":"string", "max":1024, "sensitive":true }, "EndpointName":{ "type":"string", "max":63, "pattern":"^[a-zA-Z0-9](-*[a-zA-Z0-9])*" }, "Header":{ "type":"string", "max":1024 }, "InternalFailure":{ "type":"structure", "members":{ "Message":{"shape":"Message"} }, "documentation":"

An internal failure occurred.

", "error":{"httpStatusCode":500}, "exception":true, "fault":true, "synthetic":true }, "InvokeEndpointInput":{ "type":"structure", "required":[ "EndpointName", "Body" ], "members":{ "EndpointName":{ "shape":"EndpointName", "documentation":"

The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.

", "location":"uri", "locationName":"EndpointName" }, "Body":{ "shape":"BodyBlob", "documentation":"

Provides input data, in the format specified in the ContentType request header. Amazon SageMaker passes all of the data in the body to the model.

For information about the format of the request body, see Common Data Formats—Inference.

" }, "ContentType":{ "shape":"Header", "documentation":"

The MIME type of the input data in the request body.

", "location":"header", "locationName":"Content-Type" }, "Accept":{ "shape":"Header", "documentation":"

The desired MIME type of the inference in the response.

", "location":"header", "locationName":"Accept" }, "CustomAttributes":{ "shape":"CustomAttributesHeader", "documentation":"

", "location":"header", "locationName":"X-Amzn-SageMaker-Custom-Attributes" } }, "payload":"Body" }, "InvokeEndpointOutput":{ "type":"structure", "required":["Body"], "members":{ "Body":{ "shape":"BodyBlob", "documentation":"

Includes the inference provided by the model.

For information about the format of the response body, see Common Data Formats—Inference.

" }, "ContentType":{ "shape":"Header", "documentation":"

The MIME type of the inference returned in the response body.

", "location":"header", "locationName":"Content-Type" }, "InvokedProductionVariant":{ "shape":"Header", "documentation":"

Identifies the production variant that was invoked.

", "location":"header", "locationName":"x-Amzn-Invoked-Production-Variant" }, "CustomAttributes":{ "shape":"CustomAttributesHeader", "documentation":"

", "location":"header", "locationName":"X-Amzn-SageMaker-Custom-Attributes" } }, "payload":"Body" }, "LogStreamArn":{"type":"string"}, "Message":{ "type":"string", "max":2048 }, "ModelError":{ "type":"structure", "members":{ "Message":{"shape":"Message"}, "OriginalStatusCode":{ "shape":"StatusCode", "documentation":"

Original status code.

" }, "OriginalMessage":{ "shape":"Message", "documentation":"

Original message.

" }, "LogStreamArn":{ "shape":"LogStreamArn", "documentation":"

The Amazon Resource Name (ARN) of the log stream.

" } }, "documentation":"

Model (owned by the customer in the container) returned an error 500.

", "error":{"httpStatusCode":424}, "exception":true }, "ServiceUnavailable":{ "type":"structure", "members":{ "Message":{"shape":"Message"} }, "documentation":"

The service is unavailable. Try your call again.

", "error":{"httpStatusCode":503}, "exception":true, "fault":true, "synthetic":true }, "StatusCode":{"type":"integer"}, "ValidationError":{ "type":"structure", "members":{ "Message":{"shape":"Message"} }, "documentation":"

Inspect your request and try again.

", "error":{"httpStatusCode":400}, "exception":true, "synthetic":true } }, "documentation":"

The Amazon SageMaker runtime API.

" }