Skip to content

Enable API Key

POST/web/v1/workspaces/{workspaceId}/api-keys/{keyId}/enableJWT

Re-enables a previously disabled API key, restoring its ability to authenticate API requests.

Authentication

Auth Chain: WEB Chain — requires Authorization: Bearer <jwt> Requires workspace OWNER role. These headers are injected by the system (frontend does nothing): X-PORTAL-ACCESS-CODE (Nginx), X-Request-Id (Gateway)

Request Parameters

NameTypeRequiredInDescription
workspaceIdstringYespathWorkspace business ID
keyIdstringYespathAPI key business ID

Success Response

No Content200
{
  "version": "1.3.0",
  "timestamp": 1709337600000,
  "success": true,
  "code": "2000",
  "message": "SUCCESS",
  "data": null
}

Error Responses

Unauthorized401
{
  "success": false,
  "code": "4010",
  "message": "Invalid or expired token"
}
Forbidden — not workspace owner403
{
  "success": false,
  "code": "4030",
  "message": "Only workspace owner can manage API keys"
}

Notes

  • Only previously disabled keys can be enabled. Enabling an already active key has no effect.
  • Only workspace OWNERs can enable API keys.

Internal Documentation