Rotate a proxy's credential

POST
/v1/{namespace}/proxies/{proxy}/rotate-secret

Replaces the proxy's credential. Needs ns:update. The old credential stops working at once, so update the web proxy right after.

Authorization

headerAuthorizationBearer <token>

A personal or service access token, sent as Authorization: Bearer <token>. See access tokens.

Path Parameters

namespace*string

The namespace id.

proxy*string

The proxy id.

Response Body

The proxy and its new credential.

application/json
  1. response

A proxy and its credential.

proxy*

The proxy.

secret*string

The proxy's credential, starting with prx-. Returned only on create and rotate; store it now.

curl -X POST 'https://eu-sov-1.bytesafecloud.eu/v1/my-namespace-id/proxies/proxy-01kya2b7m3q8xz5n0hdr4wcv6t/rotate-secret'
{  "proxy": {    "id": "proxy-01kya2b7m3q8xz5n0hdr4wcv6t",    "name": "Zscaler, Stockholm office",    "description": "Office egress",    "firewalls": [      "npm-main"    ],    "userHeader": "plain",    "userHeaderName": "X-Authenticated-User",    "trust": "shared",    "caCertificatePem": "-----BEGIN CERTIFICATE-----\nMIIBszCCAVmgAwIBAgIQ...\n-----END CERTIFICATE-----\n",    "caFingerprint": "97ebbd4919033a7226e1c8b7f7fde3a4c2b1e0f9d8c7b6a5f4e3d2c1b0a99887",    "caExpiresAt": "2028-11-04T09:30:00Z",    "secretRotatedAt": "2026-11-05T10:12:00Z",    "createdAt": "2026-11-05T09:30:00Z",    "updatedAt": "2026-11-05T10:12:00Z"  },  "secret": "prx-Xq7kP2mLr9TzW4vB8nC3dF6hJ1sA5eG0"}