---
title: "POST /v1/git-repos"
method: POST
path: "/v1/git-repos"
tags: ["git-repos"]
---

# POST /v1/git-repos

`POST /v1/git-repos`

Upsert a git repository information for a project.

## Request body

- object
  - `projectId` string, required
  - `remoteUrl` string, required
  - `branch` string, required
  - `branchType` union, required
    - 'PRODUCTION'
    - 'DEVELOPMENT'
  - `sshPrivateKey` string, required
  - `slug` string, required

## Response `201`

Default Response

- object
  - `id` string, required
  - `created` string, required
  - `updated` string, required
  - `remoteUrl` string, required
  - `branch` string, required
  - `branchType` union, required
    - 'PRODUCTION'
    - 'DEVELOPMENT'
  - `projectId` string, required
  - `slug` string, required

## Changes

- **2024-12-31** `3c05b427e5b5` — 1 info
  - endpoint added
- **2024-01-08** `888e937e184a` — 1 breaking
  - api path removed without deprecation
- **2024-01-06** `90a314e00bf4` — 1 info
  - endpoint added
- **2023-12-03** `7b0cc60eed56` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/activeboxes/apis/activeboxes-documentation/changes/v1/git-repos/post.md)

---

[API](https://skmtc.dev/activeboxes/apis/activeboxes-documentation.md) · [All operations](https://skmtc.dev/activeboxes/apis/activeboxes-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/activeboxes/activeboxes-documentation/revisions/12c564515962/schema)
