Static IP guide
Making API requests with a static IP from a Node app on Deno Deploy
Deno Deploy spins up a fresh isolate for each request, often in whichever edge region is closest to the caller, so the outbound IP a request leaves from isn't something your code controls. Store your Fixie proxy URL as a Deno Deploy environment variable and point your HTTP client at it, and every request leaves from the same pair of addresses no matter which isolate or region handled it.
Recommended setup
Use Fixie HTTP/S proxy for HTTP and HTTPS requests to an API, webhook provider, or service that allowlists outbound IP addresses. Store the proxy value in FIXIE_URL, then configure Node.js to route outbound traffic through Fixie before connecting to API allowlisting.
Set up Fixie on Deno Deploy
Create a Fixie HTTP/S proxy in the Fixie dashboard. Copy the proxy value into Deno Deploy environment variables as FIXIE_URL, and copy the outbound IPs into the destination allowlist.
Implementation
The example below shows the core application-side change. Keep credentials in environment variables and avoid committing proxy, database, or API secrets.
Make an HTTP request through FIXIE_URL
Good to know
- From the terminal,
deno deploy env add FIXIE_URL "<proxy-url>" --secretsets it without the value ever appearing in the dashboard or CLI output. - Scope the variable to the Production context (and a separate one to Development, if you want preview deploys on a different proxy) — Build-context variables never reach your running code, so they're not useful for a proxy credential.
Allowlist and test the static IPs
- Open the Fixie dashboard and copy the outbound IP addresses for this proxy.
- Add both IPs to the API provider.
- Deploy the updated Node.js app on Deno Deploy.
- Run a small connection test before sending production traffic.
Related guides
- Making API requests with a static IP from a Node app on Heroku
- Making API requests with a static IP from a Node app on Vercel
- Making API requests with a static IP from a Node app on Render
- Making API requests with a static IP from a Node app on Fly.io
- Making API requests with a static IP from a Node app on Koyeb
- Making API requests with a static IP from a Node app on AWS Lambda
Related docs
Is this guide useful?