public class InvokeEndpointRequest extends AmazonWebServiceRequest implements java.io.Serializable
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.
Constructor and Description |
---|
InvokeEndpointRequest() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getAccept()
The desired MIME type of the inference in the response.
|
java.nio.ByteBuffer |
getBody()
Provides input data, in the format specified in the
ContentType request header. |
java.lang.String |
getContentType()
The MIME type of the input data in the request body.
|
java.lang.String |
getCustomAttributes()
|
java.lang.String |
getEndpointName()
The name of the endpoint that you specified when you created the endpoint
using the CreateEndpoint API.
|
int |
hashCode() |
void |
setAccept(java.lang.String accept)
The desired MIME type of the inference in the response.
|
void |
setBody(java.nio.ByteBuffer body)
Provides input data, in the format specified in the
ContentType request header. |
void |
setContentType(java.lang.String contentType)
The MIME type of the input data in the request body.
|
void |
setCustomAttributes(java.lang.String customAttributes)
|
void |
setEndpointName(java.lang.String endpointName)
The name of the endpoint that you specified when you created the endpoint
using the CreateEndpoint API.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
InvokeEndpointRequest |
withAccept(java.lang.String accept)
The desired MIME type of the inference in the response.
|
InvokeEndpointRequest |
withBody(java.nio.ByteBuffer body)
Provides input data, in the format specified in the
ContentType request header. |
InvokeEndpointRequest |
withContentType(java.lang.String contentType)
The MIME type of the input data in the request body.
|
InvokeEndpointRequest |
withCustomAttributes(java.lang.String customAttributes)
|
InvokeEndpointRequest |
withEndpointName(java.lang.String endpointName)
The name of the endpoint that you specified when you created the endpoint
using the CreateEndpoint API.
|
clone, getCloneRoot, getCloneSource, getGeneralProgressListener, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, withGeneralProgressListener, withRequestMetricCollector
public java.lang.String getEndpointName()
The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.
Constraints:
Length: - 63
Pattern: ^[a-zA-Z0-9](-*[a-zA-Z0-9])*
The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.
public void setEndpointName(java.lang.String endpointName)
The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.
Constraints:
Length: - 63
Pattern: ^[a-zA-Z0-9](-*[a-zA-Z0-9])*
endpointName
- The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.
public InvokeEndpointRequest withEndpointName(java.lang.String endpointName)
The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 63
Pattern: ^[a-zA-Z0-9](-*[a-zA-Z0-9])*
endpointName
- The name of the endpoint that you specified when you created the endpoint using the CreateEndpoint API.
public java.nio.ByteBuffer getBody()
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.
Constraints:
Length: - 5242880
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.
public void setBody(java.nio.ByteBuffer body)
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.
Constraints:
Length: - 5242880
body
-
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.
public InvokeEndpointRequest withBody(java.nio.ByteBuffer body)
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.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 5242880
body
-
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.
public java.lang.String getContentType()
The MIME type of the input data in the request body.
Constraints:
Length: - 1024
The MIME type of the input data in the request body.
public void setContentType(java.lang.String contentType)
The MIME type of the input data in the request body.
Constraints:
Length: - 1024
contentType
- The MIME type of the input data in the request body.
public InvokeEndpointRequest withContentType(java.lang.String contentType)
The MIME type of the input data in the request body.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 1024
contentType
- The MIME type of the input data in the request body.
public java.lang.String getAccept()
The desired MIME type of the inference in the response.
Constraints:
Length: - 1024
The desired MIME type of the inference in the response.
public void setAccept(java.lang.String accept)
The desired MIME type of the inference in the response.
Constraints:
Length: - 1024
accept
- The desired MIME type of the inference in the response.
public InvokeEndpointRequest withAccept(java.lang.String accept)
The desired MIME type of the inference in the response.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 1024
accept
- The desired MIME type of the inference in the response.
public java.lang.String getCustomAttributes()
Constraints:
Length: - 1024
public void setCustomAttributes(java.lang.String customAttributes)
Constraints:
Length: - 1024
customAttributes
- public InvokeEndpointRequest withCustomAttributes(java.lang.String customAttributes)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 1024
customAttributes
- public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Copyright © 2018 Amazon Web Services, Inc. All Rights Reserved.