Skip to main content
Each script can have its own backend: JavaScript functions and data collections, hosted by DoglyTdc. You do not need a server.

How it works

1

Write the function

Create supabase/functions/<nome>.js with function handler(request) { ... }. You can start from a template.
2

Save to the main branch

A commit to the main branch deploys the backend automatically. You can also redeploy with POST /scripts/{script_id}/deploy or deploy_functions.
3

Call the function

From the script, through the API (POST /scripts/{script_id}/functions/{name}), or through AI (test_function).
During deployment, DoglyTdc checks each function’s syntax. A function with an error is marked as error and is not activated (if a working version existed before, it stays active). Functions deleted from the repository are removed.

The function

handler must be synchronous. Do not use async/await: doglytdc.* calls already wait for results themselves. An async function fails with “handler não pode ser async” (handler cannot be async).

The request object

The doglytdc object

Limits per execution

The function runs in an isolated sandbox: it has no access to networks, files, or databases beyond what the doglytdc object provides.

View the result

Each call is logged with its status, duration, and error (without the body). Logs retain the last 7 days. The function list (GET /scripts/{script_id}/functions) shows status, error, live_sha, last_run_at, and each function’s public address.