BackendHTTP APIFunctions

Get a function's source code

Requires an API key with the environment:functions:read scope. Learn more about API key scopes.

Returns the TypeScript source code of a function for a given integration.

GET
/integrations/{uniqueKey}/functions/{name}/code

Returns the TypeScript source code of a function for a given integration. Requires an API key with the environment:functions:read scope.

Authorization

bearerAuth
headerAuthorizationBearer <token>

An Environment API key from your Tenklo environment, or an Account API key for account-level endpoints.

Path Parameters

uniqueKey*string

The integration ID (unique_key) that you created in Tenklo.

name*string

The name of the function.

Query Parameters

type?string

The function type. Required to disambiguate when multiple functions share the same name.

Value in"sync""action""on-event"

Response Body

Successfully returned the function source code

application/json
  1. response
type*string

The function type.

Value in"sync""action""on-event"
code*string

The TypeScript source code of the function.

Example Request
curl -X GET 'https://api.tenklo.dev/integrations/string/functions/string/code'
Example Response
{  "type": "sync",  "code": "string"}