POST

Create Branch


Creates a branch. If a source branch is not provided, the branch will include a blank website.

If a source branch is not provided, the branch will include a blank website.

Important: Align the sourceType field with its corresponding source properties:

  • When sourceType is SOURCE_BRANCH, provide sourceBranchProperties.
  • When sourceType is SOURCE_TEMPLATE, provide sourceTemplateProperties.

Using UNKNOWN_SOURCE_TYPE or mismatched properties results in an ILLEGAL_SOURCE_TYPE error.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Manage Site Branches
Learn more about app permissions.
Endpoint
POST
https://www.wixapis.com/branches/v1/branches

Errors
404Not Found

There are 2 errors with this status code.

409Already Exists

There are 2 errors with this status code.

428Failed Precondition

There are 2 errors with this status code.

This method may also return standard errors. Learn more about standard Wix errors.

Event TriggersThis method triggers the following events:
Did this help?