---
title: "POST /apps/{appId}/branches"
method: POST
path: "/apps/{appId}/branches"
---

# POST /apps/{appId}/branches

`POST /apps/{appId}/branches`

Creates a new branch for an Amplify app.

## Path parameters

- `appId` string, required

## Request body

- object
  - `branchName` string, required — The name for the branch.
  - `description` string — The description for the branch.
  - `stage` 'PRODUCTION' | 'BETA' | 'DEVELOPMENT' | 'EXPERIMENTAL' | 'PULL_REQUEST' — Describes the current stage for the branch.
  - `framework` string — The framework for the branch.
  - `enableNotification` boolean — Enables notifications for the branch.
  - `enableAutoBuild` boolean — Enables auto building for the branch.
  - `environmentVariables` object — The environment variables for the branch.
  - `basicAuthCredentials` string, password — The basic authorization credentials for the branch. You must base64-encode the authorization credentials and provide them in the format <code>user:password</code>.
  - `enableBasicAuth` boolean — Enables basic authorization for the branch.
  - `enablePerformanceMode` boolean — <p>Enables performance mode for the branch.</p> <p>Performance mode optimizes for faster hosting performance by keeping content cached at the edge for a longer interval. When performance mode is enabled, hosting configuration or code changes can take up to 10 minutes to roll out. </p>
  - `tags` object — The tag for the branch.
  - `buildSpec` string, password — The build specification (build spec) file for an Amplify app build.
  - `ttl` string — The content Time to Live (TTL) for the website in seconds.
  - `displayName` string — The display name for a branch. This is used as the default domain prefix.
  - `enablePullRequestPreview` boolean — Enables pull request previews for this branch.
  - `pullRequestEnvironmentName` string — The Amplify environment name for the pull request.
  - `backendEnvironmentArn` string — The Amazon Resource Name (ARN) for a backend environment that is part of an Amplify app.

## Response `200`

Success

- CreateBranchResult — The result structure for create branch request.
  - `branch` object, required — Describes the branch for an Amplify app, which maps to a third-party repository branch.
    - `branchArn` string, required — The Amazon Resource Name (ARN) for a branch that is part of an Amplify app.
    - `branchName` string, required — The name for the branch that is part of an Amplify app.
    - `description` string, required — The description for the branch that is part of an Amplify app.
    - `tags` object — The tag for the branch of an Amplify app.
    - `stage` 'PRODUCTION' | 'BETA' | 'DEVELOPMENT' | 'EXPERIMENTAL' | 'PULL_REQUEST', required — The current stage for the branch that is part of an Amplify app.
    - `displayName` string, required — The display name for the branch. This is used as the default domain prefix.
    - `enableNotification` boolean, required — Enables notifications for a branch that is part of an Amplify app.
    - `createTime` string, date-time, required — The creation date and time for a branch that is part of an Amplify app.
    - `updateTime` string, date-time, required — The last updated date and time for a branch that is part of an Amplify app.
    - `environmentVariables` object, required — The environment variables specific to a branch of an Amplify app.
    - `enableAutoBuild` boolean, required — Enables auto-building on push for a branch of an Amplify app.
    - `customDomains` CustomDomain[], required — The custom domains for a branch of an Amplify app.
    - `framework` string, required — The framework for a branch of an Amplify app.
    - `activeJobId` string, required — The ID of the active job for a branch of an Amplify app.
    - `totalNumberOfJobs` string, required — The total number of jobs that are part of an Amplify app.
    - `enableBasicAuth` boolean, required — Enables basic authorization for a branch of an Amplify app.
    - `enablePerformanceMode` boolean — <p>Enables performance mode for the branch.</p> <p>Performance mode optimizes for faster hosting performance by keeping content cached at the edge for a longer interval. When performance mode is enabled, hosting configuration or code changes can take up to 10 minutes to roll out. </p>
    - `thumbnailUrl` string — The thumbnail URL for the branch of an Amplify app.
    - `basicAuthCredentials` string, password — The basic authorization credentials for a branch of an Amplify app. You must base64-encode the authorization credentials and provide them in the format <code>user:password</code>.
    - `buildSpec` string, password — The build specification (build spec) content for the branch of an Amplify app.
    - `ttl` string, required — The content Time to Live (TTL) for the website in seconds.
    - `associatedResources` AssociatedResource[] — A list of custom resources that are linked to this branch.
    - `enablePullRequestPreview` boolean, required — Enables pull request previews for the branch.
    - `pullRequestEnvironmentName` string — The Amplify environment name for the pull request.
    - `destinationBranch` string — The destination branch if the branch is a pull request branch.
    - `sourceBranch` string — The source branch if the branch is a pull request branch.
    - `backendEnvironmentArn` string — The Amazon Resource Name (ARN) for a backend environment that is part of an Amplify app.

## Other responses

- `480` — BadRequestException
- `481` — UnauthorizedException
- `482` — NotFoundException
- `483` — InternalFailureException
- `484` — LimitExceededException
- `485` — DependentServiceFailureException

---

[API](https://skmtc.net/aws/apis/amplify.md) · [All operations](https://skmtc.net/aws/apis/amplify/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/amplify/revisions/573daadbd119/schema)
