/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { template class AmazonWebServiceResult; namespace SageMakerRuntime { namespace Model { class AWS_SAGEMAKERRUNTIME_API InvokeEndpointResult { public: InvokeEndpointResult(); //We have to define these because Microsoft doesn't auto generate them InvokeEndpointResult(InvokeEndpointResult&&); InvokeEndpointResult& operator=(InvokeEndpointResult&&); //we delete these because Microsoft doesn't handle move generation correctly //and we therefore don't trust them to get it right here either. InvokeEndpointResult(const InvokeEndpointResult&) = delete; InvokeEndpointResult& operator=(const InvokeEndpointResult&) = delete; InvokeEndpointResult(Aws::AmazonWebServiceResult&& result); InvokeEndpointResult& operator=(Aws::AmazonWebServiceResult&& result); /** *

Includes the inference provided by the model.

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

*/ inline Aws::IOStream& GetBody() { return m_body.GetUnderlyingStream(); } /** *

Includes the inference provided by the model.

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

*/ inline void ReplaceBody(Aws::IOStream* body) { m_body = Aws::Utils::Stream::ResponseStream(body); } /** *

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

*/ inline const Aws::String& GetContentType() const{ return m_contentType; } /** *

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

*/ inline void SetContentType(const Aws::String& value) { m_contentType = value; } /** *

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

*/ inline void SetContentType(Aws::String&& value) { m_contentType = std::move(value); } /** *

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

*/ inline void SetContentType(const char* value) { m_contentType.assign(value); } /** *

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

*/ inline InvokeEndpointResult& WithContentType(const Aws::String& value) { SetContentType(value); return *this;} /** *

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

*/ inline InvokeEndpointResult& WithContentType(Aws::String&& value) { SetContentType(std::move(value)); return *this;} /** *

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

*/ inline InvokeEndpointResult& WithContentType(const char* value) { SetContentType(value); return *this;} /** *

Identifies the production variant that was invoked.

*/ inline const Aws::String& GetInvokedProductionVariant() const{ return m_invokedProductionVariant; } /** *

Identifies the production variant that was invoked.

*/ inline void SetInvokedProductionVariant(const Aws::String& value) { m_invokedProductionVariant = value; } /** *

Identifies the production variant that was invoked.

*/ inline void SetInvokedProductionVariant(Aws::String&& value) { m_invokedProductionVariant = std::move(value); } /** *

Identifies the production variant that was invoked.

*/ inline void SetInvokedProductionVariant(const char* value) { m_invokedProductionVariant.assign(value); } /** *

Identifies the production variant that was invoked.

*/ inline InvokeEndpointResult& WithInvokedProductionVariant(const Aws::String& value) { SetInvokedProductionVariant(value); return *this;} /** *

Identifies the production variant that was invoked.

*/ inline InvokeEndpointResult& WithInvokedProductionVariant(Aws::String&& value) { SetInvokedProductionVariant(std::move(value)); return *this;} /** *

Identifies the production variant that was invoked.

*/ inline InvokeEndpointResult& WithInvokedProductionVariant(const char* value) { SetInvokedProductionVariant(value); return *this;} /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline const Aws::String& GetCustomAttributes() const{ return m_customAttributes; } /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline void SetCustomAttributes(const Aws::String& value) { m_customAttributes = value; } /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline void SetCustomAttributes(Aws::String&& value) { m_customAttributes = std::move(value); } /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline void SetCustomAttributes(const char* value) { m_customAttributes.assign(value); } /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline InvokeEndpointResult& WithCustomAttributes(const Aws::String& value) { SetCustomAttributes(value); return *this;} /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline InvokeEndpointResult& WithCustomAttributes(Aws::String&& value) { SetCustomAttributes(std::move(value)); return *this;} /** *

Provides additional information in the response about the inference returned * by a model hosted at an Amazon SageMaker endpoint. The information is an opaque * value that is forwarded verbatim. You could use this value, for example, to * return an ID received in the CustomAttributes header of a request * or other metadata that a service endpoint was programmed to produce. The value * must consist of no more than 1024 visible US-ASCII characters as specified in Section 3.3.6. Field * Value Components of the Hypertext Transfer Protocol (HTTP/1.1). If the * customer wants the custom attribute returned, the model must set the custom * attribute to be included on the way back.

This feature is currently * supported in the AWS SDKs but not in the Amazon SageMaker Python SDK.

*/ inline InvokeEndpointResult& WithCustomAttributes(const char* value) { SetCustomAttributes(value); return *this;} private: Aws::Utils::Stream::ResponseStream m_body; Aws::String m_contentType; Aws::String m_invokedProductionVariant; Aws::String m_customAttributes; }; } // namespace Model } // namespace SageMakerRuntime } // namespace Aws