app/ └── https_endpoints/ ├── config.json └── data_api_config.json
Custom HTTPS Endpoint Configuration
Define the configurations for all of your app's custom HTTPS
endpoints as an array in https_endpoints/config.json.
[ { "route": "<Endpoint Route Name>", "http_method": "<HTTP method>", "function_name": "<Endpoint function name", "validation_method": "<Authorization scheme>", "secret_name": "<Validation Secret Name>", "respond_result": <boolean>, "fetch_custom_user_data": <boolean>, "create_user_on_auth": <boolean>, "disabled": <boolean> } ]
Field | Description |
|---|---|
routestring | The endpoint route. |
http_methodstring | The type of HTTP method that the
endpoint handles. Specify One of:
|
function_namestring | The name of the function associated with the endpoint. The function should use the endpoint function signature. |
validation_methodstring | The endpoint authorization scheme used to validate incoming requests. One of:
|
secret_namestring | The name of a secret that contains a string.
If |
respond_resultboolean | If If |
fetch_custom_user_databoolean | If If |
create_user_on_authboolean | If This setting is useful for apps that integrate with external authentication system through the Custom JWT authentication provider. If a request includes a valid JWT from the external system that doesn't correspond to a registered user, this creates a new user with the JWT as an identity. |
disabledboolean | Enables ( |
Data API Configuration
Define the configuration for your app's generated Data API
endpoints in https_endpoints/data_api_config.json.
{ "disabled": <boolean>, "versions": ["v1"], "return_type": "EJSON" | "JSON", "create_user_on_auth": <boolean>, "run_as_system": <boolean>, "run_as_user_id": "<User Account ID>", "run_as_user_id_script_source": "<Function Source Code>" }
Field | Description |
|---|---|
disabledboolean | If |
versionsstring[] | A list of Data API versions that your app supports. The list may include a subset of all possible versions but must list the versions in ascending order. You cannot enable a version other than the most recent version but any previously enabled versions listed here will continue to work. Available Versions:
|
return_typestring | The data format to use for data returned by endpoints in HTTPS response bodies. One of:
|
create_user_on_authboolean | If This setting is useful for apps that integrate with external authentication system through the Custom JWT authentication provider. If a request includes a valid JWT from the external system that doesn't correspond to a registered user, this creates a new user with the JWT as an identity. |
run_as_user_idstring | An application user's account ID. If defined, endpoints will always run as the specified user. Cannot be used with |
run_as_user_id_script_sourcestring | Stringified source code for a function that returns an application user's account ID. If defined, endpoints execute the function on every request and run as the user with the ID returned from the function. Cannot be used with |