---
title: "Draft a Jira issue from an item"
description: "The AI draft of an issue (summary, description, issue type, priority, assignee, due date, labels) from an item on a page (slug with block, offset or…"
canonical_url: https://docs.markdrop.in/api/jira/draft-a-jira-issue-from-an-item
last_updated: 2026-11-06
site: "Markdrop Docs"
index: https://docs.markdrop.in/llms.txt
---

# Draft a Jira issue from an item

`POST https://api.markdrop.in/api/v1/jira/draft`

The AI draft of an issue (summary, description, issue type, priority, assignee, due date, labels) from an item on a page (`slug` with `block`, `offset` or `selection`) or a Team line (`fact_id`), with the projects, issue types, priorities and people to pick from. Creates nothing. When AI can't run, the draft is the item as written (`ai: false`, `note` says why). Needs your own Atlassian connection (409 otherwise).

- **Authentication:** API token required: `Authorization: Bearer mdk_…`.
- **Rate limit:** 30 per minute per IP address.
- **Guide:** [Jira](https://docs.markdrop.in/integrations/jira)

## Request body

`application/json`, required.

- `slug` (string): Matches `^[A-Za-z0-9_-]{1,64}$`.
- `block` (string): Matches `^b-[0-9A-Za-z_-]{1,40}$`.
- `offset` (integer): From 0 to 5,000,000.
- `selection` (string): Up to 5,000 characters.
- `fact_id` (string): Matches `^[0-9a-f]{24}$`.
- `project` (string): Up to 20 characters.

## Responses

- `200`: OK.
- `401`: No token, or the token is revoked or mistyped.
- `422`: The request didn't validate. `detail` lists each problem, with where it is (`loc`) and why (`msg`).
- `429`: Too many requests from your IP address. Wait the seconds in `Retry-After`.

## Examples

**curl**

```bash
curl -X POST https://api.markdrop.in/api/v1/jira/draft \
  -H "Authorization: Bearer $MARKDROP_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'
```

**JavaScript**

```javascript
const res = await fetch("https://api.markdrop.in/api/v1/jira/draft", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.MARKDROP_TOKEN}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({}),
});
const data = await res.json();
```

**Python**

```python
import os

import requests

r = requests.post(
    "https://api.markdrop.in/api/v1/jira/draft",
    headers={"Authorization": f"Bearer {os.environ['MARKDROP_TOKEN']}"},
    json={},
)
r.raise_for_status()
print(r.json())
```
