GitButler Logo

Projects

Operations about projects

GET
/projects

Get Projects

Return all projects

/projects

Query Parameters

sincestring

Only projects updated since this date

Format: "date-time"

beforestring

Only projects updated before this date

Format: "date-time"

limitinteger

Limit the number of projects returned

Default: 50Format: "int32"
curl -X GET "https://app.gitbutler.com/api/projects?since=2019-08-24T14%3A15%3A22Z&before=2019-08-24T14%3A15%3A22Z&limit=50"

Return all projects

{
  "slug": "string",
  "owner": "string",
  "parent_project": {
    "slug": "string",
    "owner": "string",
    "parent_project": {},
    "name": "string",
    "description": "string",
    "repository_id": "string",
    "code_repository_id": "string",
    "active_reviews_count": 0,
    "created_at": "string",
    "updated_at": "string"
  },
  "name": "string",
  "description": "string",
  "repository_id": "string",
  "code_repository_id": "string",
  "active_reviews_count": 0,
  "created_at": "string",
  "updated_at": "string"
}

POST
/projects

Post Projects

Create a project

/projects

Request Body

application/jsonRequired

name
Required
string

Project name

slugstring

Project slug

descriptionstring

Project description

directorystring

Project directory name

curl -X POST "https://app.gitbutler.com/api/projects" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "string",
    "slug": "string",
    "description": "string",
    "directory": "string"
  }'

Create a project

{
  "slug": "string",
  "owner": "string",
  "parent_project": {
    "slug": "string",
    "owner": "string",
    "parent_project": {},
    "name": "string",
    "description": "string",
    "repository_id": "string",
    "code_repository_id": "string",
    "active_reviews_count": 0,
    "created_at": "string",
    "updated_at": "string"
  },
  "name": "string",
  "description": "string",
  "repository_id": "string",
  "code_repository_id": "string",
  "active_reviews_count": 0,
  "created_at": "string",
  "updated_at": "string"
}

GET
/projects/{repo_id}

Get Projects Repo Id

Return one project

/projects/{repo_id}

Path Parameters

repo_id
Required
string

Repository ID

curl -X GET "https://app.gitbutler.com/api/projects/string"

Return one project

{
  "slug": "string",
  "owner": "string",
  "parent_project": {
    "slug": "string",
    "owner": "string",
    "parent_project": {},
    "name": "string",
    "description": "string",
    "repository_id": "string",
    "code_repository_id": "string",
    "active_reviews_count": 0,
    "created_at": "string",
    "updated_at": "string"
  },
  "name": "string",
  "description": "string",
  "repository_id": "string",
  "code_repository_id": "string",
  "active_reviews_count": 0,
  "created_at": "string",
  "updated_at": "string"
}

DELETE
/projects/{repo_id}

Delete Projects Repo Id

Delete a project

/projects/{repo_id}

Path Parameters

repo_id
Required
string

Repository ID

curl -X DELETE "https://app.gitbutler.com/api/projects/string"

Delete a project

PUT
/projects/{repo_id}

Put Projects Repo Id

Update a project

/projects/{repo_id}

Request Body

application/jsonRequired

slugstring

Project slug

namestring

Project name

descriptionstring

Project description

share_levelstring

Share level (public or private)

Path Parameters

repo_id
Required
integer

Format: "int32"
curl -X PUT "https://app.gitbutler.com/api/projects/0" \
  -H "Content-Type: application/json" \
  -d '{
    "slug": "string",
    "name": "string",
    "description": "string",
    "share_level": "string"
  }'

Update a project

{
  "slug": "string",
  "owner": "string",
  "parent_project": {
    "slug": "string",
    "owner": "string",
    "parent_project": {},
    "name": "string",
    "description": "string",
    "repository_id": "string",
    "code_repository_id": "string",
    "active_reviews_count": 0,
    "created_at": "string",
    "updated_at": "string"
  },
  "name": "string",
  "description": "string",
  "repository_id": "string",
  "code_repository_id": "string",
  "active_reviews_count": 0,
  "created_at": "string",
  "updated_at": "string"
}

GET
/projects/lookup/{owner}/{slug}

Get Projects Lookup Owner Slug

Get a repository_id from a user and project slug pair

/projects/lookup/{owner}/{slug}

Path Parameters

owner
Required
string

Owner of the project

slug
Required
string

Slug of the project

curl -X GET "https://app.gitbutler.com/api/projects/lookup/string/string"

Get a repository_id from a user and project slug pair

POST
/projects/{repo_id}/connect

Post Projects Repo Id Connect

Connect a project to an organization

/projects/{repo_id}/connect

Request Body

application/jsonRequired

organization_slug
Required
string

Organization Slug

project_slugstring

Project Slug (if connecting to an existing org project)

Path Parameters

repo_id
Required
string

User Repository ID to connect

curl -X POST "https://app.gitbutler.com/api/projects/string/connect" \
  -H "Content-Type: application/json" \
  -d '{
    "organization_slug": "string",
    "project_slug": "string"
  }'

Connect a project to an organization

{
  "slug": "string",
  "owner": "string",
  "parent_project": {
    "slug": "string",
    "owner": "string",
    "parent_project": {},
    "name": "string",
    "description": "string",
    "repository_id": "string",
    "code_repository_id": "string",
    "active_reviews_count": 0,
    "created_at": "string",
    "updated_at": "string"
  },
  "name": "string",
  "description": "string",
  "repository_id": "string",
  "code_repository_id": "string",
  "active_reviews_count": 0,
  "created_at": "string",
  "updated_at": "string"
}

POST
/projects/{repo_id}/disconnect

Post Projects Repo Id Disconnect

Disconnect a project from an organization

/projects/{repo_id}/disconnect

Path Parameters

repo_id
Required
string

User Repository ID to disconnect

curl -X POST "https://app.gitbutler.com/api/projects/string/disconnect"

Disconnect a project from an organization