Create a new branch

POST /docs/{doc_id_or_slug}/branches

Create an empty new branch.

Path parameters

  • doc_id_or_slug string Required

    UUID or slug of a documentation which can be seen in the Automatic Deployment settings page of your documentation

application/json

Body

The branch creation request object

  • name string Required

    The name of the branch.


    Please note that the branch name is used in your documentation public URL

Responses

  • 201 application/json

    Documentation branch successfully created

    Hide response attributes Show response attributes object
    • name string

      Unique id of the branch.

    • slug string

      Slug of the branch used in public documentation URL

    • is_default boolean

      Whether the branch is the default one or not.

      Default value is false.

  • Branch already exists

  • Invalid branch creation request

POST /docs/{doc_id_or_slug}/branches
curl \
 -X POST https://bump.sh/api/v1/docs/{doc_id_or_slug}/branches \
 -H "Authorization: Token $ACCESS_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"name":"my-branch"}'
Request examples
{
  "name": "my-branch"
}
Response examples (201)
{
  "name": "3ef8f52f-9056-4113-840e-2f7183b90e06",
  "slug": "my-branch",
  "is_default": false
}