Functions
Defining a Function within a Service
[api.functions.function-id]
# The function name is required
name = "myfunction"
# The `http` param defines an HTTP API entry for the function
# `verb` is an HTTP verb such as GET or POST
# Path parameters are denoted inside curly braces "{}"
http = { verb = "GET", path = "/path/maybe/with/{parameter}" }
# The authorizer id refers to an authorizer defined in the same service
authorizer_id = "<id>"
# The timeout in seconds after which the function is terminated, regardless of whether it has completed.
timeout_seconds = 3
# The size of the function in MB. AWS Lambda scales the CPU allocation with this value.
size_mb = 512[api.authorizers.my-auth]
type = "iam"
[api.functions.my-func]
authorizer_id = "my-auth"HTTP Functions
Last updated