---
title: "Comment on an issue"
---

> 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/{number}/comments`

## Authentication

Requires one of the following:

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

## Path parameters

- `addIssueComment.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}$`
- `addIssueComment.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}$`
- `addIssueComment.path.number` (integer, required)
  - min 1

## Header parameters

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

## Request body

_Required._

- `addIssueComment.body` (string, required)
  - minLength 1; maxLength 65536

## Example request

```json
{
  "body": "string"
}
```

## Code samples

### cURL

```curl
curl --request POST \
  --url https://app.gitpando.com/v1/monorepos/string/string/issues/1/comments \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "body": "string"
}
'
```

### TypeScript

```typescript
const url = 'https://app.gitpando.com/v1/monorepos/string/string/issues/1/comments';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json', Authorization: 'Bearer <token>'},
  body: JSON.stringify({body: JSON.stringify('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/1/comments"

payload = { "body": "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 comment.

### 201

Added.

#### Example

```json
{
  "id": "string",
  "body": "string",
  "body_version": 0,
  "author": "string",
  "machine": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reactions": [
    {
      "content": "+1",
      "count": 0,
      "by": [
        "string"
      ]
    }
  ]
}
```

- `addIssueComment.response.201.id` (string, required)
- `addIssueComment.response.201.body` (string | null, required) — Null only in a live event, over 16 KB: read it with getIssueComment.
- `addIssueComment.response.201.body_version` (integer, required)
- `addIssueComment.response.201.author` (string, required)
- `addIssueComment.response.201.machine` (string | null, required) — The machine that wrote it.
- `addIssueComment.response.201.created_at` (string, required)
  - format `date-time`
- `addIssueComment.response.201.updated_at` (string, required)
  - format `date-time`
- `addIssueComment.response.201.reactions` (array<object>, required) — Those given at least once, in GitHub's order.
  - `addIssueComment.response.201.reactions.content` (string, required)
    - one of `"+1"`, `"-1"`, `"laugh"`, `"hooray"`, `"confused"`, `"heart"`, `"rocket"`, `"eyes"`
  - `addIssueComment.response.201.reactions.count` (integer, required)
  - `addIssueComment.response.201.reactions.by` (array<string>, required) — Logins

### 404

An error

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "paths": [
      "string"
    ],
    "checks": {
      "sha": "string",
      "state": "success",
      "required": [
        "string"
      ],
      "checks_unknown": "string",
      "missing": [
        "string"
      ],
      "statuses": [
        {
          "sha": "string",
          "context": "string",
          "state": "pending",
          "target_url": "string",
          "description": "string",
          "creator": "string",
          "app": "string",
          "created_at": "2019-08-24T14:15:22Z"
        }
      ]
    }
  }
}
```

- `addIssueComment.response.404.error` (object, required)
  - `addIssueComment.response.404.error.code` (string, required)
  - `addIssueComment.response.404.error.message` (string, required)
  - `addIssueComment.response.404.error.paths` (array<string>, optional)
  - `addIssueComment.response.404.error.checks` (object, optional) — GitHub's combined status, plus the required contexts and which are missing.
    - `addIssueComment.response.404.error.checks.sha` (string | null, required)
    - `addIssueComment.response.404.error.checks.state` (string, required) — `success` when the merge gate passes; `missing` when a required context has not reported; `unknown` while the required checks are (an unforced merge is refused).
      - one of `"success"`, `"pending"`, `"failure"`, `"error"`, `"missing"`, `"unknown"`
    - `addIssueComment.response.404.error.checks.required` (array | null, required) — Null while unknown.
    - `addIssueComment.response.404.error.checks.checks_unknown` (string | null, required) — Why the required checks are unknown, in plain words: "Pando couldn't read this monorepo's required checks; try again", or "pando.toml line 3: expected comma or end of structure; fix it on main, or merge with force". Null otherwise.
    - `addIssueComment.response.404.error.checks.statuses` (array<object>, required) — The latest status per context.
      - `addIssueComment.response.404.error.checks.statuses.sha` (string, required)
      - `addIssueComment.response.404.error.checks.statuses.context` (string, required)
      - `addIssueComment.response.404.error.checks.statuses.state` (string, required)
        - one of `"pending"`, `"success"`, `"failure"`, `"error"`
      - `addIssueComment.response.404.error.checks.statuses.created_at` (string, required)
        - format `date-time`
      - `addIssueComment.response.404.error.checks.statuses.target_url` (string | null, optional)
      - `addIssueComment.response.404.error.checks.statuses.description` (string | null, optional)
      - `addIssueComment.response.404.error.checks.statuses.creator` (string, optional) — The member who posted it (a login); `app:<slug>` for a status posted with a status token or by a CI integration; `hook:<hook id>` for a status token from a web hook with no app.
      - `addIssueComment.response.404.error.checks.statuses.app` (string | null, optional) — The CI service that reported it (`buildkite`, `github-actions`, ...), stamped by Pando from a status token or a CI integration, never from the body or `target_url`. Null when a member posted it with their own credential. The web shows the service's mark for a slug it knows.
    - `addIssueComment.response.404.error.checks.missing` (array<string>, optional)

### 413

`too_large`.


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