---
title: "Mint a short-lived single-thread stream URL capability"
---

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

Path: Shiba public API › threads

`POST /threads/{threadId}/stream-tickets`

## Authentication

Requires one of the following:

- `bearerAuth`, http, header `Authorization`, format `API key`
- `cookieAuth`, apiKey, in cookie

## Path parameters

- `threadId` (`createThreadStreamTicket.path.threadId`; string, required) — Thread identifier

## Code samples

### cURL

```bash
curl --request POST \
  --url '<base-url>/api/v1/threads/<threadId>/stream-tickets' \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = '<base-url>/api/v1/threads/<threadId>/stream-tickets';
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};

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

### Python

```python
import requests

url = "<base-url>/api/v1/threads/<threadId>/stream-tickets"

headers = {"Authorization": "Bearer <token>"}

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

print(response.text)
```

## Responses

### 200

Stream ticket

### 401

Unauthorized

#### Example

```json
{
  "ok": false,
  "error": "string",
  "detail": "string",
  "code": "string"
}
```

- `error` (`createThreadStreamTicket.response.401.error`; string, required)
- `ok` (`createThreadStreamTicket.response.401.ok`; boolean, optional)
- `detail` (`createThreadStreamTicket.response.401.detail`; string, optional)
- `code` (`createThreadStreamTicket.response.401.code`; string, optional)


Source: https://tryshiba.dev/reference/api/threads/createThreadStreamTicket/index.md
