P

Protected Modal Web Functions / Servers

REST discovered

Details
URL
https://<deployment-host>.modal.run
Docs
https://modal.com/docs/guide/webhook-proxy-auth
Authentication
Modal Proxy Token pair (key + token) for protected web functions Modal-Key: <credential> + Modal Proxy Token pair (key + token) for protected web functions Modal-Secret: <credential> discovered
Modal Proxy Token pair (key + token) for protected web functions compound

Create a Proxy Token for your workspace from the Proxy Tokens page linked in the Proxy Tokens guide. Use the issued key-and-token pair when calling web functions configured with requires_proxy_auth=True. The docs distinguish these from API tokens and note they cannot be interchanged.

Modal API token pair (token ID + token secret) compound discovered Get key ↗
$ modal curl

Create credentials either with the CLI or in the dashboard. Easiest paths: run modal token new from an authenticated browser session, or create a service user from the workspace Service Users guide via the service user tokens page. Modal exposes the pair as MODAL_TOKEN_ID and MODAL_TOKEN_SECRET; you can store them with modal token set or export those environment variables directly.