Reference

Commit files

Writes and deletes files, as one commit. All changes land, or none. Changes that match what is already there are skipped.

POST
/namespaces/{namespace}/branches/{branch}/commits

Authorization

bearer
headerAuthorizationBearer <token>

Path Parameters

namespace*string

A namespace of your organization, such as prod/app, or <org>:<namespace> for a public namespace of another one. Encode / as %2F.

branch*string

A branch, such as main or agents/fix-1. Encode / as %2F.

Request Body

application/json
  1. body
message*string
Length1 <= length <= 10000
changes*array<>
Itemsitems <= 10000

Response Body

Nothing changed, so no commit was made.

application/json
  1. response
head*string

The branch's head after the call.

changed*boolean

False when every change matched what was already there. Then no commit is made and head is the current one.

Example Request
curl -X POST 'https://example.com/v1/namespaces/string/branches/string/commits' \  -H 'Content-Type: application/json' \  -d '{  "message": "string",  "changes": [    {      "path": "string"    }  ]}'
Example Response
{  "head": "string",  "changed": true}