/AWS1/CL_APY=>EVALUATECODE()
¶
About EvaluateCode¶
Evaluates the given code and returns the response. The code definition requirements depend on the specified
runtime. For APPSYNC_JS
runtimes, the code defines the request and response functions. The request
function takes the incoming request after a GraphQL operation is parsed and converts it into a request
configuration for the selected data source operation. The response function interprets responses from the data
source and maps it to the shape of the GraphQL field output type.
Method Signature¶
IMPORTING¶
Required arguments:¶
IO_RUNTIME
TYPE REF TO /AWS1/CL_APYAPPSYNCRUNTIME
/AWS1/CL_APYAPPSYNCRUNTIME
¶
The runtime to be used when evaluating the code. Currently, only the
APPSYNC_JS
runtime is supported.
IV_CODE
TYPE /AWS1/APYCODE
/AWS1/APYCODE
¶
The code definition to be evaluated. Note that
code
andruntime
are both required for this action. Theruntime
value must beAPPSYNC_JS
.
IV_CONTEXT
TYPE /AWS1/APYCONTEXT
/AWS1/APYCONTEXT
¶
The map that holds all of the contextual information for your resolver invocation. A
context
is required for this action.
Optional arguments:¶
IV_FUNCTION
TYPE /AWS1/APYSTRING
/AWS1/APYSTRING
¶
The function within the code to be evaluated. If provided, the valid values are
request
andresponse
.