> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

# ExecuteReleasePublication

# Package: containersProjects

# Namespace: ContainersProjects

# Method link: https://dev.wix.com/docs/api-reference/mobile/containers-app/containers-projects/project-v1/execute-release-publication.md

## Permission Scopes:
Manage AppSmith Projects: SCOPE.CONTAINERS.PROJECTS

## Introduction

Publishes the version of a prepared publication, so it becomes the live version every user of
the app gets.

Call this only after the user approved the publication returned by Prepare Release Publication.
Specify its `digest`. If another version went live after it was prepared, the call fails with
`LIVE_RELEASE_CHANGED` and nothing changes: prepare again and ask the user again.

A publication is published at most once. Repeating the call returns the same result, so a call
that timed out can be repeated safely. While another call is publishing the same publication, or
shortly after a call whose outcome is unknown, the call returns `status: PUBLISHING` and changes
nothing: call it again a little later.

---

## REST API

### Schema

```
 Method: executeReleasePublication
 Description: Publishes the version of a prepared publication, so it becomes the live version every user of the app gets.  Call this only after the user approved the publication returned by Prepare Release Publication. Specify its `digest`. If another version went live after it was prepared, the call fails with `LIVE_RELEASE_CHANGED` and nothing changes: prepare again and ask the user again.  A publication is published at most once. Repeating the call returns the same result, so a call that timed out can be repeated safely. While another call is publishing the same publication, or shortly after a call whose outcome is unknown, the call returns `status: PUBLISHING` and changes nothing: call it again a little later.
 URL: https://www.wixapis.com/containers/projects/v1/projects/{projectId}/release-publications/{publicationId}/execute
 Method: POST
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  requestKey, digest, approvalMethod
 Method parameters: 
   param name: approvalMethod | type: AppPlanApprovalMethod   | required: true 
      - enum:
           AGENT_RELAYED_CHAT_CONFIRMATION - The user approved the plan (or the publication) in a chat with the agent, and the agent relays
it. The approval can't be verified, so it's accepted only from the site owner.
   param name: digest | type: digest | description: `digest` of the publication the user approved. | required: true | validation: maxLength 64
   param name: requestKey | type: requestKey | description: Stable key for this execution, created by the caller. | required: true | validation: maxLength 100
 Return type: ExecuteReleasePublicationResponse
  - name: publication | type: ReleasePublication | description: The publication after the call. `status` is `PUBLISHED`, or `PUBLISHING` while it is being published.  
     - name: id | type: string | description: Publication GUID.  | validation: format GUID
     - name: projectId | type: string | description: GUID of the project.  | validation: format GUID
     - name: releaseId | type: string | description: GUID of the release to publish.  | validation: maxLength 200
     - name: releaseLabel | type: string | description: Label of the release to publish, when it has one.  | validation: maxLength 500
     - name: currentLiveReleaseId | type: string | description: GUID of the release that was live when the publication was prepared. Not returned when the app had no live version.  | validation: maxLength 200
     - name: effect | type: ReleasePublicationEffect | description: What publishing changes.  
         - enum:
         -     MAKE_LIVE: The release becomes the live version, which every user of the app gets.
         -     ALREADY_LIVE: The release is already the live version. Publishing changes nothing.
     - name: digest | type: string | description: Digest of the publication. Specify it when you call [Execute Release Publication](https://dev.wix.com/docs/api-reference/mobile/containers-app/containers-projects/project-v1/execute-release-publication.md).  | validation: maxLength 64
     - name: expiresDate | type: string | description: Date and time the publication expires if it isn't executed, 1 hour after it's prepared.  | read-only: true | validation: format date-time
     - name: status | type: ReleasePublicationStatus | description: Publication status.  
         - enum:
         -     PREPARED: Prepared and waiting for the user's approval. Nothing changed yet.
         -     PUBLISHED: The release is the live version.
         -     PUBLISHING: The release is being published. Call Execute Release Publication again to get the outcome.
     - name: liveReleaseId | type: string | description: GUID of the live release after the publication. Returned when `status` is `PUBLISHED`.  | validation: maxLength 200
     - name: createdDate | type: string | description: Date and time the publication was prepared.  | read-only: true | validation: format date-time
     - name: updatedDate | type: string | description: Date and time the publication was last updated.  | read-only: true | validation: format date-time

 Possible Errors:
   HTTP Code: 403 | Status Code: PERMISSION_DENIED | Application Code: APPROVAL_NOT_ACCEPTED | Description: The approval method isn't accepted from the current user. `AGENT_RELAYED_CHAT_CONFIRMATION` is accepted only from the site owner.
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: RELEASE_NOT_FOUND | Description: Couldn't find the release in the project's app anymore. Nothing was changed.
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: RELEASE_PUBLICATION_NOT_FOUND | Description: Couldn't find the release publication for the current user, site and project.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: RELEASE_FORCED_PAST_ERRORS | Description: The release was saved even though its checks failed, so it can't be published by a site user. Nothing was changed.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: LIVE_RELEASE_CHANGED | Description: Another version went live after the publication was prepared. Nothing was changed.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: RELEASE_PUBLICATION_EXPIRED | Description: The publication expired before it was published. A publication expires 1 hour after it's prepared. Prepare it again.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: RELEASE_PUBLICATION_CHANGED | Description: `digest` isn't the digest of the prepared publication. Show the prepared publication and ask again.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: FEATURE_UNAVAILABLE | Description: Publishing isn't available for this site.


```

### Examples

### Execute Release Publication
Publishes the version that the site owner approved, so every user of the app gets it.

```curl
curl -X POST \
'https://www.wixapis.com/containers/projects/v1/projects/6b2e9d4a-1c7f-4a35-8e0b-5d3f7a9c2e18/release-publications/d4f8a2c6-3e9b-4a17-b5c0-8e1d6f4a9b23/execute' \
-H 'Authorization: <AUTH>' \
-H 'Content-Type: application/json' \
-d '{
  "requestKey": "f1b6d3a8-7c2e-4d95-a0f4-2e8c5b9d1a67",
  "digest": "a7c3e9f1b5d2084e6c1a9f3b7d5e2c8a4f0b6d9e3c7a1f5b8d2e4c6a0f9b3d7e",
  "approvalMethod": "AGENT_RELAYED_CHAT_CONFIRMATION"
}'
```

---

## JavaScript SDK

### Schema

```
 Method: wixClientAdmin.containers.projects.executeReleasePublication(identifiers, requestKey, options)
 Description: Publishes the version of a prepared publication, so it becomes the live version every user of the app gets.  Call this only after the user approved the publication returned by Prepare Release Publication. Specify its `digest`. If another version went live after it was prepared, the call fails with `LIVE_RELEASE_CHANGED` and nothing changes: prepare again and ask the user again.  A publication is published at most once. Repeating the call returns the same result, so a call that timed out can be repeated safely. While another call is publishing the same publication, or shortly after a call whose outcome is unknown, the call returns `status: PUBLISHING` and changes nothing: call it again a little later.
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  identifiers.projectId, identifiers.publicationId, requestKey, options.digest, options.approvalMethod, identifiers, options
 Method parameters: 
   param name: identifiers | type: ExecuteReleasePublicationIdentifiers  none | required: true 
        - name: projectId | type: string | description: GUID of the project. | required: true | validation: format GUID
        - name: publicationId | type: string | description: GUID of the prepared publication. | required: true | validation: format GUID
   param name: options | type: ExecuteReleasePublicationOptions  none | required: true 
        - name: digest | type: string | description: `digest` of the publication the user approved. | required: true | validation: maxLength 64
        - name: approvalMethod | type: AppPlanApprovalMethod | description: How the user approved the publication. | required: true 
             - enum:
             -     AGENT_RELAYED_CHAT_CONFIRMATION: The user approved the plan (or the publication) in a chat with the agent, and the agent relays it. The approval can't be verified, so it's accepted only from the site owner.
   param name: requestKey | type: string | description: Stable key for this execution, created by the caller. | required: true | validation: maxLength 100
 Return type: PROMISE<ExecuteReleasePublicationResponse>
  - name: publication | type: ReleasePublication | description: The publication after the call. `status` is `PUBLISHED`, or `PUBLISHING` while it is being published.  
     - name: _id | type: string | description: Publication GUID.  | validation: format GUID
     - name: projectId | type: string | description: GUID of the project.  | validation: format GUID
     - name: releaseId | type: string | description: GUID of the release to publish.  | validation: maxLength 200
     - name: releaseLabel | type: string | description: Label of the release to publish, when it has one.  | validation: maxLength 500
     - name: currentLiveReleaseId | type: string | description: GUID of the release that was live when the publication was prepared. Not returned when the app had no live version.  | validation: maxLength 200
     - name: effect | type: ReleasePublicationEffect | description: What publishing changes.  
         - enum:
         -     MAKE_LIVE: The release becomes the live version, which every user of the app gets.
         -     ALREADY_LIVE: The release is already the live version. Publishing changes nothing.
     - name: digest | type: string | description: Digest of the publication. Specify it when you call [Execute Release Publication](https://dev.wix.com/docs/api-reference/mobile/containers-app/containers-projects/project-v1/execute-release-publication.md).  | validation: maxLength 64
     - name: expiresDate | type: Date | description: Date and time the publication expires if it isn't executed, 1 hour after it's prepared.  | read-only: true 
     - name: status | type: ReleasePublicationStatus | description: Publication status.  
         - enum:
         -     PREPARED: Prepared and waiting for the user's approval. Nothing changed yet.
         -     PUBLISHED: The release is the live version.
         -     PUBLISHING: The release is being published. Call Execute Release Publication again to get the outcome.
     - name: liveReleaseId | type: string | description: GUID of the live release after the publication. Returned when `status` is `PUBLISHED`.  | validation: maxLength 200
     - name: _createdDate | type: Date | description: Date and time the publication was prepared.  | read-only: true 
     - name: _updatedDate | type: Date | description: Date and time the publication was last updated.  | read-only: true 

 Possible Errors:
   HTTP Code: 403 | Status Code: PERMISSION_DENIED | Application Code: APPROVAL_NOT_ACCEPTED | Description: The approval method isn't accepted from the current user. `AGENT_RELAYED_CHAT_CONFIRMATION` is accepted only from the site owner.
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: RELEASE_NOT_FOUND | Description: Couldn't find the release in the project's app anymore. Nothing was changed.
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: RELEASE_PUBLICATION_NOT_FOUND | Description: Couldn't find the release publication for the current user, site and project.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: RELEASE_FORCED_PAST_ERRORS | Description: The release was saved even though its checks failed, so it can't be published by a site user. Nothing was changed.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: LIVE_RELEASE_CHANGED | Description: Another version went live after the publication was prepared. Nothing was changed.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: RELEASE_PUBLICATION_EXPIRED | Description: The publication expired before it was published. A publication expires 1 hour after it's prepared. Prepare it again.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: RELEASE_PUBLICATION_CHANGED | Description: `digest` isn't the digest of the prepared publication. Show the prepared publication and ask again.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: FEATURE_UNAVAILABLE | Description: Publishing isn't available for this site.


```

### Examples

### Publish a version of an app
Publishes the version that the site owner approved, so every user of the app gets it.

```javascript
import { projects } from "@wix/containers";

async function executeReleasePublication() {
  const response = await projects.executeReleasePublication(
    {
      projectId: "6b2e9d4a-1c7f-4a35-8e0b-5d3f7a9c2e18",
      publicationId: "d4f8a2c6-3e9b-4a17-b5c0-8e1d6f4a9b23",
    },
    "f1b6d3a8-7c2e-4d95-a0f4-2e8c5b9d1a67",
    {
      digest: "a7c3e9f1b5d2084e6c1a9f3b7d5e2c8a4f0b6d9e3c7a1f5b8d2e4c6a0f9b3d7e",
      approvalMethod: "AGENT_RELAYED_CHAT_CONFIRMATION",
    },
  );
}

/* Promise resolves to:
 * {
 *   "publication": {
 *     "_id": "d4f8a2c6-3e9b-4a17-b5c0-8e1d6f4a9b23",
 *     "projectId": "6b2e9d4a-1c7f-4a35-8e0b-5d3f7a9c2e18",
 *     "releaseId": "rel-7a2d9e4c1b6f",
 *     "releaseLabel": "New menu colors",
 *     "currentLiveReleaseId": "rel-3c8f1a6e9d2b",
 *     "effect": "MAKE_LIVE",
 *     "digest": "a7c3e9f1b5d2084e6c1a9f3b7d5e2c8a4f0b6d9e3c7a1f5b8d2e4c6a0f9b3d7e",
 *     "expiresDate": "2026-11-09T12:25:00.000Z",
 *     "status": "PUBLISHED",
 *     "liveReleaseId": "rel-7a2d9e4c1b6f",
 *     "_createdDate": "2026-11-09T11:25:00.000Z",
 *     "_updatedDate": "2026-11-09T11:26:12.000Z"
 *   }
 * }
 */

```

### executeReleasePublication (self-managed)
Self-managed SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md).

```javascript
import { createClient } from '@wix/sdk';
import { projects } from '@wix/containers';
// Import the auth strategy for the relevant access type
// Import the relevant host module if needed

const myWixClient = createClient ({
  modules: { projects },
  // Include the auth strategy and host as relevant
});


async function executeReleasePublication(identifiers,requestKey,options) {
  const response = await myWixClient.projects.executeReleasePublication(identifiers,requestKey,options);
};
```

---