Ppolarapi
Home/Gateway proxy
Sign in โ†—
POLARAPI GATEWAY / UNIVERSAL PROXY

Put your upstream
behind one route.

Create explicit HTTPS upstream routes, issue one PolarAPI key, and call it through the Cloudflare gateway at https://1.polarapi.us.ci.

i
Available gateway feature

This release provides configured transparent proxy routes, hashed PolarAPI keys, encrypted upstream header credentials, per-route request limits, and request metadata logs. Visual clusters, normalized unified APIs, and multiple projects/environments are not yet available.

01 / QUICKSTART

Three steps to a proxied request

  1. Configure encryptionSet the Cloudflare Worker secret CREDENTIAL_ENCRYPTION_KEY. Configure it with Wrangler secrets; keep it out of frontend environment variables and source control.
  2. Create a routeSign in at https://polarapi.us.ci, then use Proxy endpoints to enter a slug, method, public HTTPS origin, upstream path, credential mode (Bearer token, custom header, or none), timeout, and requests-per-minute limit.
  3. Create an API keyIssue a key with the endpoints:execute scope; the same key works for all routes in your personal workspace. Copy it immediately; it is shown only once. The registry stores only a SHA-256 hash.
02 / CONFIGURATION

Define an explicit upstream mapping

Example route: slug profile, method GET, origin https://api.example.com, upstream path /v2/profile. A request to /v1/profile/42?expand=plan is forwarded to the configured origin/path with the suffix and query string preserved.

Optional upstream authentication is entered per route in the route form, encrypted at rest using AES-GCM, and injected only into the upstream request. The PolarAPI caller's Bearer key is never forwarded as the upstream authorization credential.

03 / CLIENT REQUEST

Call the gateway

curl --request GET \
  'https://1.polarapi.us.ci/v1/profile/42?expand=plan' \
  --header 'Authorization: Bearer <POLARAPI_API_KEY>' \
  --header 'Accept: application/json'

Use the endpoint's configured HTTP method, or select ANY to allow common methods on a route. POST, PUT, PATCH, and DELETE request bodies are forwarded without JSON-specific rewriting. The configured upstream response status, body stream, and relevant headers are returned transparently.

Responses include X-Request-ID, X-PolarAPI-Upstream-Status, and rate-limit headers. Use the request ID to locate metadata in the signed-in request stream.

04 / PROXY BEHAVIOR

Transparent where possible

  • Preserves the configured method, incoming query string, request body bytes (up to 1 MiB), upstream status, and response streaming.
  • Forwards ordinary request headers while stripping the caller's PolarAPI authorization, cookies, host, hop-by-hop headers, and spoofed forwarding headers.
  • Does not follow upstream redirects. It preserves the upstream redirect response without issuing an unconfigured destination request.
  • Route timeout is configurable from 1 to 30 seconds; per-route limit is configurable up to 30 requests per minute, subject to the 15/minute per-key and 500/day per-user caps.
  • Up to 200 recent metadata records are retained for at most seven days. Request and response bodies, PolarAPI keys, and upstream secrets are not logged.
05 / SECURITY & ERRORS

Protected by explicit configuration

  • Only a configured route can be called; this is not an open proxy. Requests require a valid active PolarAPI key with endpoints:execute.
  • Upstreams must be HTTPS on the standard port. IP literals, localhost, private-suffix hostnames, and common metadata hosts are rejected.
  • Invalid/revoked keys return 401; missing scopes return 403; rate limits return 429; upstream timeouts return 504; connection errors return 502.
  • Current Single Singal access is rechecked at most once per 60-second cache window. Confirmed revocation disables account sessions and API access; temporary provider errors return 503.

Configure SINGAL_API_KEY, SINGAL_WEBHOOK_SECRET, and CREDENTIAL_ENCRYPTION_KEY as Cloudflare Worker secrets before production use. Static-header API keys are supported, but OAuth, service accounts and provider-specific signing are not. Do not put a PolarAPI key in public browser code. This release does not implement provider-specific unified adapters, cluster orchestration, binary upload limits above 1 MiB, or a custom private-network allowlist.

Open PolarAPI workspace โ†—
POLARAPI GATEWAY ยท PROXY CONTRACT