> For the complete documentation index, see [llms.txt](https://docs.serverlessapigateway.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.serverlessapigateway.com/reader-guides/quickstart-first-proxy/quickstart-supabase-passwordless.md).

# Quickstart: Supabase Passwordless API

Use Supabase OTP flows when your product needs passwordless auth routes behind one Worker gateway. This guide covers both the auth request and verify endpoints. If your app already uses Supabase Auth, this is the fastest path to edge-managed passwordless login.

**Last reviewed:** 2026-03-06

## When to use this

Use these quickstart guides when you are setting up Serverless API Gateway for the first time or adding a new integration pattern. Each guide walks through one isolated concern so you can deploy incrementally instead of configuring everything at once.

## Key concepts

* Every quickstart produces a deployable `wrangler.toml` and JSON config pair -- you can run `wrangler deploy` at the end of each guide.
* Guides are ordered from simplest (health endpoint) to most complex (Auth0/Supabase passwordless), so earlier guides serve as prerequisites for later ones.
* Config can come from a local file, Cloudflare KV, or the `SAG_API_CONFIG_JSON` environment variable -- choose based on your deploy workflow.
* All guides use the same JSON config schema, so patterns you learn in one guide transfer directly to others.

## Repo-grounded example

```json
{
  "authorizer": {
    "type": "supabase",
    "jwt_secret": "$env.SUPABASE_JWT_SECRET",
    "issuer": "https://project.supabase.co/auth/v1",
    "audience": "authenticated"
  },
  "paths": [
    {
      "method": "POST",
      "path": "/api/v1/supabase/auth",
      "integration": { "type": "supabase_passwordless_auth" }
    },
    {
      "method": "POST",
      "path": "/api/v1/supabase/verify",
      "integration": { "type": "supabase_passwordless_verify" }
    }
  ]
}
```

This snippet configures the Supabase authorizer with the project JWT secret, issuer, and audience. The two paths use `supabase_passwordless_auth` and `supabase_passwordless_verify` integration types to handle OTP send and verify flows.

## Troubleshooting

* If `wrangler deploy` fails with a config error, validate your JSON against the schema file (`api-config.schema.json`) before investigating further.
* If the health endpoint returns 404, confirm that your `wrangler.toml` points to the correct main entrypoint and that the config file is being loaded.
* If JWT or Auth0 routes return 500, check that all required environment variables and secrets are set in your Cloudflare dashboard or `.dev.vars` file.
* Use `wrangler tail` to stream live logs from the deployed worker and see the exact error message the gateway produces.

## Related docs

* [introduction](/getting-started/introduction.md)
* [overview](/configuration/overview.md)
* [gateway troubleshooting matrix](/troubleshooting/wrangler-deploy-guide/gateway-troubleshooting-matrix.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.serverlessapigateway.com/reader-guides/quickstart-first-proxy/quickstart-supabase-passwordless.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
