/AWS1/IF_AGW=>PUTINTEGRATION()¶
About PutIntegration¶
Sets up a method's integration.
Method Signature¶
METHODS /AWS1/IF_AGW~PUTINTEGRATION
IMPORTING
!IV_RESTAPIID TYPE /AWS1/AGWSTRING OPTIONAL
!IV_RESOURCEID TYPE /AWS1/AGWSTRING OPTIONAL
!IV_HTTPMETHOD TYPE /AWS1/AGWSTRING OPTIONAL
!IV_TYPE TYPE /AWS1/AGWINTEGRATIONTYPE OPTIONAL
!IV_INTEGRATIONHTTPMETHOD TYPE /AWS1/AGWSTRING OPTIONAL
!IV_URI TYPE /AWS1/AGWSTRING OPTIONAL
!IV_CONNECTIONTYPE TYPE /AWS1/AGWCONNECTIONTYPE OPTIONAL
!IV_CONNECTIONID TYPE /AWS1/AGWSTRING OPTIONAL
!IV_CREDENTIALS TYPE /AWS1/AGWSTRING OPTIONAL
!IT_REQUESTPARAMETERS TYPE /AWS1/CL_AGWMAPOFSTRTOSTR_W=>TT_MAPOFSTRINGTOSTRING OPTIONAL
!IT_REQUESTTEMPLATES TYPE /AWS1/CL_AGWMAPOFSTRTOSTR_W=>TT_MAPOFSTRINGTOSTRING OPTIONAL
!IV_PASSTHROUGHBEHAVIOR TYPE /AWS1/AGWSTRING OPTIONAL
!IV_CACHENAMESPACE TYPE /AWS1/AGWSTRING OPTIONAL
!IT_CACHEKEYPARAMETERS TYPE /AWS1/CL_AGWLISTOFSTRING_W=>TT_LISTOFSTRING OPTIONAL
!IV_CONTENTHANDLING TYPE /AWS1/AGWCONTENTHANDLINGSTRAG OPTIONAL
!IV_TIMEOUTINMILLIS TYPE /AWS1/AGWNULLABLEINTEGER OPTIONAL
!IO_TLSCONFIG TYPE REF TO /AWS1/CL_AGWTLSCONFIG OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_agwintegration
RAISING
/AWS1/CX_AGWBADREQUESTEX
/AWS1/CX_AGWCONFLICTEXCEPTION
/AWS1/CX_AGWLIMITEXCEEDEDEX
/AWS1/CX_AGWNOTFOUNDEXCEPTION
/AWS1/CX_AGWTOOMANYREQUESTSEX
/AWS1/CX_AGWUNAUTHORIZEDEX
/AWS1/CX_AGWCLIENTEXC
/AWS1/CX_AGWSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_restapiid TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
The string identifier of the associated RestApi.
iv_resourceid TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
Specifies a put integration request's resource ID.
iv_httpmethod TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
Specifies the HTTP method for the integration.
iv_type TYPE /AWS1/AGWINTEGRATIONTYPE /AWS1/AGWINTEGRATIONTYPE¶
Specifies a put integration input's type.
Optional arguments:¶
iv_integrationhttpmethod TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
The HTTP method for the integration.
iv_uri TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
Specifies Uniform Resource Identifier (URI) of the integration endpoint. For HTTP or
HTTP_PROXYintegrations, the URI must be a fully formed, encoded HTTP(S) URL according to the RFC-3986 specification, for either standard integration, whereconnectionTypeis notVPC_LINK, or private integration, whereconnectionTypeisVPC_LINK. For a private HTTP integration, the URI is not used for routing. ForAWSorAWS_PROXYintegrations, the URI is of the formarn:aws:apigateway:{region}:{subdomain.service|service}:path|action/{service_api}. Here, {Region} is the API Gateway region (e.g., us-east-1); {service} is the name of the integrated Amazon Web Services service (e.g., s3); and {subdomain} is a designated subdomain supported by certain Amazon Web Services service for fast host-name lookup. action can be used for an Amazon Web Services service action-based API, using an Action={name}&{p1}={v1}&p2={v2}... query string. The ensuing {service_api} refers to a supported action {name} plus any required input parameters. Alternatively, path can be used for an Amazon Web Services service path-based API. The ensuing service_api refers to the path to an Amazon Web Services service resource, including the region of the integrated Amazon Web Services service, if applicable. For example, for integration with the S3 API ofGetObject, theurican be eitherarn:aws:apigateway:us-west-2:s3:action/GetObject&Bucket={bucket}&Key={key}orarn:aws:apigateway:us-west-2:s3:path/{bucket}/{key}.
iv_connectiontype TYPE /AWS1/AGWCONNECTIONTYPE /AWS1/AGWCONNECTIONTYPE¶
The type of the network connection to the integration endpoint. The valid value is
INTERNETfor connections through the public routable internet orVPC_LINKfor private connections between API Gateway and a network load balancer in a VPC. The default value isINTERNET.
iv_connectionid TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
The ID of the VpcLink used for the integration. Specify this value only if you specify
VPC_LINKas the connection type.
iv_credentials TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
Specifies whether credentials are required for a put integration.
it_requestparameters TYPE /AWS1/CL_AGWMAPOFSTRTOSTR_W=>TT_MAPOFSTRINGTOSTRING TT_MAPOFSTRINGTOSTRING¶
A key-value map specifying request parameters that are passed from the method request to the back end. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the back end. The method request parameter value must match the pattern of
method.request.{location}.{name}, wherelocationisquerystring,path, orheaderandnamemust be a valid and unique method request parameter name.
it_requesttemplates TYPE /AWS1/CL_AGWMAPOFSTRTOSTR_W=>TT_MAPOFSTRINGTOSTRING TT_MAPOFSTRINGTOSTRING¶
Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value.
iv_passthroughbehavior TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the
requestTemplatesproperty on the Integration resource. There are three valid values:WHEN_NO_MATCH,WHEN_NO_TEMPLATES, andNEVER.
iv_cachenamespace TYPE /AWS1/AGWSTRING /AWS1/AGWSTRING¶
Specifies a group of related cached parameters. By default, API Gateway uses the resource ID as the
cacheNamespace. You can specify the samecacheNamespaceacross resources to return the same cached data for requests to different resources.
it_cachekeyparameters TYPE /AWS1/CL_AGWLISTOFSTRING_W=>TT_LISTOFSTRING TT_LISTOFSTRING¶
A list of request parameters whose values API Gateway caches. To be valid values for
cacheKeyParameters, these parameters must also be specified for MethodrequestParameters.
iv_contenthandling TYPE /AWS1/AGWCONTENTHANDLINGSTRAG /AWS1/AGWCONTENTHANDLINGSTRAG¶
Specifies how to handle request payload content type conversions. Supported values are
CONVERT_TO_BINARYandCONVERT_TO_TEXT, with the following behaviors:If this property is not defined, the request payload will be passed through from the method request to integration request without modification, provided that the
passthroughBehavioris configured to support payload pass-through.
iv_timeoutinmillis TYPE /AWS1/AGWNULLABLEINTEGER /AWS1/AGWNULLABLEINTEGER¶
Custom timeout between 50 and 29,000 milliseconds. The default value is 29,000 milliseconds or 29 seconds. You can increase the default value to longer than 29 seconds for Regional or private APIs only.
io_tlsconfig TYPE REF TO /AWS1/CL_AGWTLSCONFIG /AWS1/CL_AGWTLSCONFIG¶
tlsConfig
RETURNING¶
oo_output TYPE REF TO /aws1/cl_agwintegration /AWS1/CL_AGWINTEGRATION¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->putintegration(
io_tlsconfig = new /aws1/cl_agwtlsconfig( ABAP_TRUE )
it_cachekeyparameters = VALUE /aws1/cl_agwlistofstring_w=>tt_listofstring(
( new /aws1/cl_agwlistofstring_w( |string| ) )
)
it_requestparameters = VALUE /aws1/cl_agwmapofstrtostr_w=>tt_mapofstringtostring(
(
VALUE /aws1/cl_agwmapofstrtostr_w=>ts_mapofstringtostring_maprow(
key = |string|
value = new /aws1/cl_agwmapofstrtostr_w( |string| )
)
)
)
it_requesttemplates = VALUE /aws1/cl_agwmapofstrtostr_w=>tt_mapofstringtostring(
(
VALUE /aws1/cl_agwmapofstrtostr_w=>ts_mapofstringtostring_maprow(
key = |string|
value = new /aws1/cl_agwmapofstrtostr_w( |string| )
)
)
)
iv_cachenamespace = |string|
iv_connectionid = |string|
iv_connectiontype = |string|
iv_contenthandling = |string|
iv_credentials = |string|
iv_httpmethod = |string|
iv_integrationhttpmethod = |string|
iv_passthroughbehavior = |string|
iv_resourceid = |string|
iv_restapiid = |string|
iv_timeoutinmillis = 123
iv_type = |string|
iv_uri = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_integrationtype = lo_result->get_type( ).
lv_string = lo_result->get_httpmethod( ).
lv_string = lo_result->get_uri( ).
lv_connectiontype = lo_result->get_connectiontype( ).
lv_string = lo_result->get_connectionid( ).
lv_string = lo_result->get_credentials( ).
LOOP AT lo_result->get_requestparameters( ) into ls_row.
lv_key = ls_row-key.
lo_value = ls_row-value.
IF lo_value IS NOT INITIAL.
lv_string = lo_value->get_value( ).
ENDIF.
ENDLOOP.
LOOP AT lo_result->get_requesttemplates( ) into ls_row.
lv_key = ls_row-key.
lo_value = ls_row-value.
IF lo_value IS NOT INITIAL.
lv_string = lo_value->get_value( ).
ENDIF.
ENDLOOP.
lv_string = lo_result->get_passthroughbehavior( ).
lv_contenthandlingstrategy = lo_result->get_contenthandling( ).
lv_integer = lo_result->get_timeoutinmillis( ).
lv_string = lo_result->get_cachenamespace( ).
LOOP AT lo_result->get_cachekeyparameters( ) into lo_row_1.
lo_row_2 = lo_row_1.
IF lo_row_2 IS NOT INITIAL.
lv_string = lo_row_2->get_value( ).
ENDIF.
ENDLOOP.
LOOP AT lo_result->get_integrationresponses( ) into ls_row_3.
lv_key = ls_row_3-key.
lo_value_1 = ls_row_3-value.
IF lo_value_1 IS NOT INITIAL.
lv_statuscode = lo_value_1->get_statuscode( ).
lv_string = lo_value_1->get_selectionpattern( ).
LOOP AT lo_value_1->get_responseparameters( ) into ls_row.
lv_key = ls_row-key.
lo_value = ls_row-value.
IF lo_value IS NOT INITIAL.
lv_string = lo_value->get_value( ).
ENDIF.
ENDLOOP.
LOOP AT lo_value_1->get_responsetemplates( ) into ls_row.
lv_key = ls_row-key.
lo_value = ls_row-value.
IF lo_value IS NOT INITIAL.
lv_string = lo_value->get_value( ).
ENDIF.
ENDLOOP.
lv_contenthandlingstrategy = lo_value_1->get_contenthandling( ).
ENDIF.
ENDLOOP.
lo_tlsconfig = lo_result->get_tlsconfig( ).
IF lo_tlsconfig IS NOT INITIAL.
lv_boolean = lo_tlsconfig->get_insecureskipverification( ).
ENDIF.
ENDIF.