---
title: "Open an issue"
description: "`link`: branches to link at once (`pando worktree add --issue`). Send\nan `Idempotency-Key`: a retry with the same key answers the first\nissue (200, `Pando-Replayed: true`).\n"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.gitpando.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Pando API › issues

`POST /v1/monorepos/{owner}/{monorepo}/issues`

`link`: branches to link at once (`pando worktree add --issue`). Send
an `Idempotency-Key`: a retry with the same key answers the first
issue (200, `Pando-Replayed: true`).

## Authentication

Requires one of the following:

- `credential`, http, header `Authorization`
- `session`, apiKey, in cookie

## Path parameters

- `createIssue.path.owner` (string, required) — The monorepo's owner, a namespace (a person's login or an organization). Matched without case.
  - pattern `^[a-z0-9](?:[a-z0-9]|-(?=[a-z0-9])){0,38}$`
- `createIssue.path.monorepo` (string, required) — The monorepo's name within its owner (or an old name). Matched without case.
  - pattern `^[a-z0-9](?:[a-z0-9._]|-(?!-)){0,38}$`

## Header parameters

- `createIssue.header.Idempotency-Key` (string, optional)
  - maxLength 64

## Request body

_Required._

- `createIssue.title` (string, required)
  - minLength 1; maxLength 256
- `createIssue.body` (string, optional)
  - maxLength 65536
- `createIssue.labels` (array<string>, optional)
- `createIssue.assignees` (array<string>, optional)
- `createIssue.project` (string | null, optional) — A repo's name.
- `createIssue.link` (array<object>, optional)
  - `createIssue.link.repo` (string, required) — A repo's name.
  - `createIssue.link.branch` (string, required)

## Example request

```json
{
  "title": "string",
  "body": "string",
  "labels": [
    "string"
  ],
  "assignees": [
    "string"
  ],
  "project": "string",
  "link": [
    {
      "repo": "string",
      "branch": "string"
    }
  ]
}
```

## Code samples

### cURL

```curl
curl --request POST \
  --url https://app.gitpando.com/v1/monorepos/string/string/issues \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "string",
  "body": "string",
  "labels": [
    "string"
  ],
  "assignees": [
    "string"
  ],
  "project": "string",
  "link": [
    {
      "repo": "string",
      "branch": "string"
    }
  ]
}
'
```

### TypeScript

```typescript
const url = 'https://app.gitpando.com/v1/monorepos/string/string/issues';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json', Authorization: 'Bearer <token>'},
  body: JSON.stringify({
    title: 'string',
    body: JSON.stringify('string'),
    labels: ['string'],
    assignees: ['string'],
    project: 'string',
    link: [{repo: 'string', branch: 'string'}]
  })
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://app.gitpando.com/v1/monorepos/string/string/issues"

payload = {
    "title": "string",
    "body": "string",
    "labels": ["string"],
    "assignees": ["string"],
    "project": "string",
    "link": [
        {
            "repo": "string",
            "branch": "string"
        }
    ]
}
headers = {
    "Content-Type": "application/json",
    "Authorization": "Bearer <token>"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 200

A retry with the same Idempotency-Key: the first issue (`Pando-Replayed: true`).

#### Example

```json
{
  "number": 0,
  "title": "string",
  "state": "open",
  "state_reason": "completed",
  "project": "string",
  "project_path": "string",
  "labels": [
    {
      "name": "string",
      "color": "gray",
      "description": "string"
    }
  ],
  "assignees": [
    "string"
  ],
  "author": "string",
  "comments": 0,
  "tasks": {
    "done": 0,
    "total": 0
  },
  "linked_branches": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "closed_at": "2019-08-24T14:15:22Z",
  "closed_by": "string",
  "closed_by_merge": {
    "repo": "string",
    "repo_path": "string",
    "branch": "string",
    "merge_commit": "string"
  },
  "body": "string",
  "body_version": 0,
  "machine": "string",
  "links": [
    {
      "repo": "string",
      "repo_path": "string",
      "branch": "string",
      "sources": [
        "link"
      ],
      "sha": "string",
      "linked_by": "string",
      "branch_state": "open",
      "merged_at": "2019-08-24T14:15:22Z",
      "closed_issue": true
    }
  ],
  "participants": [
    "string"
  ],
  "reactions": [
    {
      "content": "+1",
      "count": 0,
      "by": [
        "string"
      ]
    }
  ]
}
```

- `createIssue.response.200.number` (integer, required)
- `createIssue.response.200.title` (string, required)
- `createIssue.response.200.state` (string, required)
  - one of `"open"`, `"closed"`
- `createIssue.response.200.state_reason` (string | null, required)
  - one of `"completed"`, `"not_planned"`, `null`
- `createIssue.response.200.project` (string | null, required) — A repo's name; null for the monorepo as a whole.
- `createIssue.response.200.project_path` (string | null, required)
- `createIssue.response.200.labels` (array<object>, required)
  - `createIssue.response.200.labels.name` (string, required) — 1 to 50 characters, unique ignoring case.
  - `createIssue.response.200.labels.color` (string, required) — Each theme sets the eight from its own tokens (no red, so a label never reads as a failure).
    - one of `"gray"`, `"orange"`, `"yellow"`, `"green"`, `"teal"`, `"blue"`, `"purple"`, `"pink"`
  - `createIssue.response.200.labels.description` (string | null, required)
- `createIssue.response.200.assignees` (array<string>, required)
- `createIssue.response.200.author` (string, required)
- `createIssue.response.200.comments` (integer, required)
- `createIssue.response.200.tasks` (object | null, required) — `- [ ]` and `- [x]` lines in the body; null without a task list.
  - `createIssue.response.200.tasks.done` (integer, optional)
  - `createIssue.response.200.tasks.total` (integer, optional)
- `createIssue.response.200.linked_branches` (integer, required)
- `createIssue.response.200.created_at` (string, required)
  - format `date-time`
- `createIssue.response.200.updated_at` (string, required)
  - format `date-time`
- `createIssue.response.200.closed_at` (string | null, required)
  - format `date-time`
- `createIssue.response.200.closed_by` (string | null, required)
- `createIssue.response.200.closed_by_merge` (one of, required)
  - one of: [IssueMerge](/api/schemas/IssueMerge/), `null`
- `createIssue.response.200.body` (string, required)
- `createIssue.response.200.body_version` (integer, required) — Goes up by one on every body edit.
- `createIssue.response.200.machine` (string | null, required) — The machine that opened it.
- `createIssue.response.200.links` (array<object>, required)
  - `createIssue.response.200.links.repo` (string, required)
  - `createIssue.response.200.links.repo_path` (string, required)
  - `createIssue.response.200.links.branch` (string, required)
  - `createIssue.response.200.links.sources` (array<string>, required)
    - one of `"link"`, `"title"`, `"commit"`
  - `createIssue.response.200.links.sha` (string | null, required) — `commit`: the newest commit on the branch naming the issue.
  - `createIssue.response.200.links.linked_by` (string | null, required) — `link`: who linked it.
  - `createIssue.response.200.links.branch_state` (string, required)
    - one of `"open"`, `"ready"`, `"conflicts"`, `"failing"`, `"merged"`, `"deleted"`
  - `createIssue.response.200.links.merged_at` (string | null, required)
    - format `date-time`
  - `createIssue.response.200.links.closed_issue` (boolean, required) — This branch's merge closed the issue.
- `createIssue.response.200.participants` (array<string>, required)
- `createIssue.response.200.reactions` (array<object>, required) — Those given at least once, in GitHub's order.
  - `createIssue.response.200.reactions.content` (string, required)
    - one of `"+1"`, `"-1"`, `"laugh"`, `"hooray"`, `"confused"`, `"heart"`, `"rocket"`, `"eyes"`
  - `createIssue.response.200.reactions.count` (integer, required)
  - `createIssue.response.200.reactions.by` (array<string>, required) — Logins

### 201

Opened.

#### Example

```json
{
  "number": 0,
  "title": "string",
  "state": "open",
  "state_reason": "completed",
  "project": "string",
  "project_path": "string",
  "labels": [
    {
      "name": "string",
      "color": "gray",
      "description": "string"
    }
  ],
  "assignees": [
    "string"
  ],
  "author": "string",
  "comments": 0,
  "tasks": {
    "done": 0,
    "total": 0
  },
  "linked_branches": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "closed_at": "2019-08-24T14:15:22Z",
  "closed_by": "string",
  "closed_by_merge": {
    "repo": "string",
    "repo_path": "string",
    "branch": "string",
    "merge_commit": "string"
  },
  "body": "string",
  "body_version": 0,
  "machine": "string",
  "links": [
    {
      "repo": "string",
      "repo_path": "string",
      "branch": "string",
      "sources": [
        "link"
      ],
      "sha": "string",
      "linked_by": "string",
      "branch_state": "open",
      "merged_at": "2019-08-24T14:15:22Z",
      "closed_issue": true
    }
  ],
  "participants": [
    "string"
  ],
  "reactions": [
    {
      "content": "+1",
      "count": 0,
      "by": [
        "string"
      ]
    }
  ]
}
```

- `createIssue.response.201.number` (integer, required)
- `createIssue.response.201.title` (string, required)
- `createIssue.response.201.state` (string, required)
  - one of `"open"`, `"closed"`
- `createIssue.response.201.state_reason` (string | null, required)
  - one of `"completed"`, `"not_planned"`, `null`
- `createIssue.response.201.project` (string | null, required) — A repo's name; null for the monorepo as a whole.
- `createIssue.response.201.project_path` (string | null, required)
- `createIssue.response.201.labels` (array<object>, required)
  - `createIssue.response.201.labels.name` (string, required) — 1 to 50 characters, unique ignoring case.
  - `createIssue.response.201.labels.color` (string, required) — Each theme sets the eight from its own tokens (no red, so a label never reads as a failure).
    - one of `"gray"`, `"orange"`, `"yellow"`, `"green"`, `"teal"`, `"blue"`, `"purple"`, `"pink"`
  - `createIssue.response.201.labels.description` (string | null, required)
- `createIssue.response.201.assignees` (array<string>, required)
- `createIssue.response.201.author` (string, required)
- `createIssue.response.201.comments` (integer, required)
- `createIssue.response.201.tasks` (object | null, required) — `- [ ]` and `- [x]` lines in the body; null without a task list.
  - `createIssue.response.201.tasks.done` (integer, optional)
  - `createIssue.response.201.tasks.total` (integer, optional)
- `createIssue.response.201.linked_branches` (integer, required)
- `createIssue.response.201.created_at` (string, required)
  - format `date-time`
- `createIssue.response.201.updated_at` (string, required)
  - format `date-time`
- `createIssue.response.201.closed_at` (string | null, required)
  - format `date-time`
- `createIssue.response.201.closed_by` (string | null, required)
- `createIssue.response.201.closed_by_merge` (one of, required)
  - one of: [IssueMerge](/api/schemas/IssueMerge/), `null`
- `createIssue.response.201.body` (string, required)
- `createIssue.response.201.body_version` (integer, required) — Goes up by one on every body edit.
- `createIssue.response.201.machine` (string | null, required) — The machine that opened it.
- `createIssue.response.201.links` (array<object>, required)
  - `createIssue.response.201.links.repo` (string, required)
  - `createIssue.response.201.links.repo_path` (string, required)
  - `createIssue.response.201.links.branch` (string, required)
  - `createIssue.response.201.links.sources` (array<string>, required)
    - one of `"link"`, `"title"`, `"commit"`
  - `createIssue.response.201.links.sha` (string | null, required) — `commit`: the newest commit on the branch naming the issue.
  - `createIssue.response.201.links.linked_by` (string | null, required) — `link`: who linked it.
  - `createIssue.response.201.links.branch_state` (string, required)
    - one of `"open"`, `"ready"`, `"conflicts"`, `"failing"`, `"merged"`, `"deleted"`
  - `createIssue.response.201.links.merged_at` (string | null, required)
    - format `date-time`
  - `createIssue.response.201.links.closed_issue` (boolean, required) — This branch's merge closed the issue.
- `createIssue.response.201.participants` (array<string>, required)
- `createIssue.response.201.reactions` (array<object>, required) — Those given at least once, in GitHub's order.
  - `createIssue.response.201.reactions.content` (string, required)
    - one of `"+1"`, `"-1"`, `"laugh"`, `"hooray"`, `"confused"`, `"heart"`, `"rocket"`, `"eyes"`
  - `createIssue.response.201.reactions.count` (integer, required)
  - `createIssue.response.201.reactions.by` (array<string>, required) — Logins

### 400

`bad_request` (a title, an unknown label or project, a branch that does not exist) or `not_a_member` (an assignee).

### 413

`too_large`: a body over 65,536 characters.


Source: https://docs.gitpando.com/api/issues/createIssue/index.md
