Skip to main content
Lambda

Invoking Functions

Call Invoke with:

FieldValue
Function NameThe function name or ARN. Add :alias or :version to call a specific alias or version, for example GrantReward:live.
Invocation TypeRequestResponse waits for the function and returns its response. Event starts the function and returns right away, without a response. DryRun only checks that you are allowed to call it. Not set means RequestResponse.
Log TypeTail returns the last 4 KB of the function's log in Log Result, base64-encoded.
Client ContextOptional base64-encoded JSON that the function gets as context.
BodyThe event that the function gets, as JSON.

For example, with this body:

{ "playerId": "Player1", "reward": "gold_chest" }

the function gets event.playerId and event.reward in Node.js, or event["playerId"] in Python.

The result​

FieldDescription
Status Code200 for RequestResponse, 202 for Event, 204 for DryRun.
PayloadWhat the function returned, usually JSON. Parse it with a JSON plugin or Unreal's JSON Blueprint Utilities.
Function ErrorUnhandled if the function threw an error. The node still reports Success, so check this field. The error is in Payload.
Log ResultThe log, if Log Type is Tail.
Executed VersionThe version of the function that ran.