/v1/workspaces/{workspace_id}/configs/{config_id}/environments/{environment_id}/sdk-keys/secondaryAuthEnd the grace period
Revokes the secondary key now instead of at its `expires_at`. SDK servers still using it get 404 within about 5 seconds. Recorded in the history (`sdk_key.grace_ended`) and the workspace audit log.
Path parameters
config_id*string · uuidId of the config.
environment_id*string · uuidId of an environment of the same project.
workspace_id*string · uuidId of the workspace.
Response · 200 The masked keys left (the primary key).
data*arrayThe primary key, then the secondary key while a grace period runs.
Example
Request
DELETE https://api.flags.productcraft.co/v1/workspaces/{workspace_id}/configs/{config_id}/environments/{environment_id}/sdk-keys/secondary
Authorization: Bearer YOUR_TOKENResponse
{
"data": [
{
"slot": {},
"key_prefix": "pcf_sdk_4fQx",
"last4": "k9Zt",
"created_at": "2026-01-01T00:00:00.000Z",
"expires_at": "2026-01-01T00:00:00.000Z"
}
]
}