---
title: "Deploy Cf Worker"
method: POST
path: "/api/admin/deploy-cf-worker"
tags: ["admin"]
---

# Deploy Cf Worker

`POST /api/admin/deploy-cf-worker`

## Request

- Base URL: `https://api.equity-rank.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.equity-rank.com/api/admin/deploy-cf-worker`
- Auth: HTTP bearer

Upload backend/static/og-prerender.js to Cloudflare Workers.

Reads CLOUDFLARE_API_TOKEN from Railway env vars and uses the CF REST API
directly — no wrangler CLI or Node.js required.

Routes (equity-rank.com/*) are NOT modified — they persist from the initial
`wrangler deploy --env production` setup. This endpoint only replaces the
script content.

Returns deploy status dict:
  {ok, worker_name, script_size, deployed_at, account_id}
On failure: {ok: False, error: str, details?: str}

## Response `200`

Successful Response

- object

---

[API](https://skmtc.dev/equity-rank/apis/equity-rank-api.md) · [All operations](https://skmtc.dev/equity-rank/apis/equity-rank-api/llms.txt) · [OpenAPI document](https://skmtc.dev/equity-rank/apis/equity-rank-api/revisions/c2f2463fee33?raw)
