---
title: "Create creates a repo"
method: POST
path: "/api/v1/repositories"
tags: ["RepositoryService"]
---

# Create creates a repo

`POST /api/v1/repositories`

## Request body

- V1alpha1Repository
  - `connectionState` V1alpha1ConnectionState
    - `attemptedAt` V1Time — Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers. +protobuf.options.marshal=false +protobuf.as=Timestamp +protobuf.options.(gogoproto.goproto_stringer)=false
      - `nanos` integer — Non-negative fractions of a second at nanosecond resolution. Negative second values with fractions must still have non-negative nanos values that count forward in time. Must be from 0 to 999,999,999 inclusive. This field may be limited in precision depending on context.
      - `seconds` string, int64 — Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.
    - `message` string
    - `status` string
  - `enableLfs` boolean
  - `insecure` boolean
  - `insecureIgnoreHostKey` boolean
  - `password` string
  - `repo` string
  - `sshPrivateKey` string
  - `tlsClientCertData` string
  - `tlsClientCertKey` string
  - `username` string

## Response `200`

(empty)

- V1alpha1Repository
  - `connectionState` V1alpha1ConnectionState
    - `attemptedAt` V1Time — Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers. +protobuf.options.marshal=false +protobuf.as=Timestamp +protobuf.options.(gogoproto.goproto_stringer)=false
      - `nanos` integer — Non-negative fractions of a second at nanosecond resolution. Negative second values with fractions must still have non-negative nanos values that count forward in time. Must be from 0 to 999,999,999 inclusive. This field may be limited in precision depending on context.
      - `seconds` string, int64 — Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.
    - `message` string
    - `status` string
  - `enableLfs` boolean
  - `insecure` boolean
  - `insecureIgnoreHostKey` boolean
  - `password` string
  - `repo` string
  - `sshPrivateKey` string
  - `tlsClientCertData` string
  - `tlsClientCertKey` string
  - `username` string

---

[API](https://skmtc.net/devtron-labs/apis/consolidate-services.md) · [All operations](https://skmtc.net/devtron-labs/apis/consolidate-services/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/devtron-labs/consolidate-services/versions/778bfc291d1e/schema)
