Skip to the page

Guides · Integrations

OpenAPI & no-code tools

Let Postman, Retool, n8n, Zapier or a custom GPT call your deployed queries through the OpenAPI document every project serves.

In the schema
—

What you’ll build#

You will connect third-party tools directly to your project, including API clients like Postman and Bruno, internal-tool builders like Retool and Appsmith, workflow automations in n8n, Zapier or Make, and custom GPT actions. Each tool calls your deployed queries over HTTPS with its own scoped service key under the same schema access policies as your app.

Live OpenAPI specification

Every branch compiles deployed queries into a live OpenAPI spec on demand.

You don’t maintain hand-written Swagger YAML or a wrapper API. Pushing a new query updates the branch’s OpenAPI specification immediately.

Before you start#

Write a deployed query for each operation the external tool needs. The leading # comment line of each query file becomes the operation’s summary in the OpenAPI document and UI picker.

dbschema/queries/openTickets.edgeql
# List open tickets and their linked GitHub issuesselect Ticket { id, title, issue }filter not .is_resolvedorder by .titlelimit <int64>$limit
dbschema/queries/resolveTicket.edgeql
# Mark a ticket resolvedupdate Ticketfilter .id = <uuid>$ticketset { is_resolved := true }

Fetch the OpenAPI specification#

Fetch GET /openapi.json from the branch URL with any valid bearer credential to inspect or import the generated specification.

Terminal
curl https://support.napalmdata.com/openapi.json \  -H "Authorization: Bearer $NAPALM_KEY" \  -o openapi.json
One operation per query
Each deployed query appears as POST /query/{name} using the query name as operationId, alongside JSON Schemas compiled from your schema types.
Always current
Napalm generates the document directly from the active query catalog at request time. Push a new query and re-fetch /openapi.json to see the new operation immediately.
Vendor extensions
x-napalm-is-write flags mutations, and x-napalm-action flags gatekeeper queries attached to external or hosted handlers.
Bearer auth
The specification declares HTTP bearer authentication, accepting either a service key or an end-user session token.

For typed clients in your own codebase, napalm generate compiles the same catalog into SDKs across eight languages. See SDKs.

Issue a scoped service key#

Before sharing credentials with a third-party platform, isolate its access and lock the branch surface.

Per-tool service key

Dedicated keys isolate each integration for independent auditing and instant revocation.

Deployed-query lockdown

Disabling passthrough confines every caller to your reviewed query catalog.

External tool clients

Retool, n8n, Zapier and Postman import the spec and invoke typed endpoints.

Push your query catalog, create a dedicated service key, disable ad-hoc statement passthrough and audit the key’s row reach.

Terminal
napalm queries push support # Issue a dedicated service key (omit --read-only when the tool needs write access)napalm keys create support --label retool --read-only # Restrict every caller to deployed queries and block ad-hoc EdgeQL statementsnapalm endpoint support --passthrough none # Audit how many rows the key can read or write before sharing the keynapalm keys reach support <key-id>
One key per tool
Label each key for its target integration. Revoking a leaked key via napalm keys revoke leaves every other tool running.
Read-only by default
Dashboards only need read access, and Napalm rejects every mutation from a --read-only key.
Deployed queries only
Under --passthrough none, callers can invoke only deployed POST /query/{name} endpoints and ad-hoc EdgeQL requests fail.
Access policies enforced
Service-key calls run under your schema’s access rules and return only permitted rows.

Make a sample call#

Invoke any operation in the document by posting a JSON variables object to POST /query/{name}.

Request · curl
curl https://support.napalmdata.com/query/openTickets \  -H "Authorization: Bearer $NAPALM_KEY" \  -H "Content-Type: application/json" \  -d '{ "variables": { "limit": 20 } }'
Response
{  "data": [    { "id": "8f2c1e64-0b7a-4f4e-9d2b-3a6c5e1f7d90", "title": "Export fails on large files", "issue": "acme/app#412" }  ]}

The request body carries variables, and successful responses return matching rows in data. Errors return a stable code, and query_failed responses include the underlying EdgeQL exception type.

A read-only key calling resolveTicket
{  "error": {    "code": "query_failed",    "type": "DisabledCapabilityError"  }}
Dry-run previews
Pass "is_dry_run": true alongside variables to execute the mutation under caller policies, inspect the resulting row diffs and roll back the transaction.
Read your own writes
Responses return a Napalm-Bookmark header. Echoing that header on the next request guarantees the read observes your write on any replica. See Running queries.

Configure external tools#

Import openapi.json or point an HTTP step at your branch URL, attaching the tool’s service key as a bearer header.

ToolQuery setupAuthentication
Postman, Insomnia, BrunoImport openapi.json to generate a saved request collection.AuthenticationConfigure Bearer Token auth at the collection level.
Retool, AppsmithAdd the branch URL as a REST API or OpenAPI resource to list every deployed query by name.AuthenticationAttach an Authorization: Bearer … header on the resource.
n8nAdd an HTTP Request node per call using POST, the query URL and a JSON variables body.AuthenticationStore the bearer header in an n8n Header Auth credential.
Zapier, MakeUse Webhooks by Zapier (Custom Request) or Make’s HTTP module.AuthenticationPass the Authorization header on the action step.
Custom GPTsImport openapi.json as the GPT Action schema so the model selects operations by summary.AuthenticationSelect API Key auth configured as Bearer.

Trigger automations on row changes#

The setups above call into Napalm from an external tool. To trigger an external workflow whenever a row commits, declare a notify event on the type (such as notify ticket_changed after insert, update;) and subscribe the automation tool’s catch-hook URL with a read-only service key.

Terminal
# Restrict outbound webhooks on this branch to hooks.zapier.comnapalm webhooks hosts support --add hooks.zapier.com # Deliver changed ticket rows filtered by a read-only service keynapalm webhooks add support https://hooks.zapier.com/hooks/catch/<your-hook> \  --event ticket_changed --key <key-id>
Payload
A JSON batch of changed rows visible to the attached service key, each carrying type, op, id and fields. Notifications & webhooks documents every field.
Signature check
Every delivery carries an HMAC-SHA256 signature in Napalm-Signature. Platforms that expose raw request bytes should verify the signature. Platforms that parse JSON automatically should treat the webhook as a wake-up signal and fetch current rows via POST /query/{name} using a scoped key.
Downstream failures
Most no-code tools acknowledge incoming webhooks immediately before running subsequent workflow steps, so Napalm records the delivery as complete on receipt. Monitor the automation tool’s own run history for downstream step errors.
Requirements
Row-carrying webhooks require cluster change-log storage (napalm storage enable <cluster> log) and --passthrough keys so Napalm can read rows under the service key.

When you need delivery retries controlled by your own handler code, see Email, Slack & push and Queues & streams.

Check the setup#

  1. Inspect the OpenAPI spec

    Confirm GET /openapi.json lists /query/openTickets and /query/resolveTicket along with their summaries, and sets x-napalm-is-write only on resolveTicket.

  2. Run a read query from your tool

    Invoke openTickets and confirm permitted rows return inside data.

  3. Verify read-only enforcement

    Call resolveTicket using your --read-only key and confirm Napalm returns 400 query_failed (DisabledCapabilityError) without modifying the ticket.

  4. Verify ad-hoc lockdown

    Send an ad-hoc EdgeQL query body to POST /query and confirm Napalm responds with 403 deployed_query_required.

Type a word or two to search every docs page.