Functions

Roll back to a previous deployment

Changed on

Re-deploy a previous version by copying its source, dependencies, and runtime pin onto the function's draft, then deploying. Returns immediately with a deployment ID — poll GET /v1/functions/deployments/{deploymentId} until status is active or failed. Secrets are not rolled back.

post/v1/functions/{functionId}/rollback

Request

  • Base URL
    https://api.zavu.dev
  • URL
    https://api.zavu.dev/v1/functions/{functionId}/rollback
  • Auth
    HTTP bearer

Path parameters

functionIdstring required

Zavu Function ID.

Request body

deploymentIdstring required

ID of the deployment to roll back to.

Response

Rollback deployment queued.

rolledBackToVersioninteger
previousDraftobject nullable

The draft that was replaced, so a UI can offer to restore it.

Example response

{
  "deployment": {
    "id": "fnd_abc123"
  }
}

Changes