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

# Get a local receipt by hash.

` GET /v1/receipts/{receipt_hash} `

Get a local receipt by hash.

## Servers

- ` http://127.0.0.1:8831 ` — Default local host-agent listener.

## Authentication

The operation accepts these alternatives. Schemes within one alternative are required together.

### Alternative 1

- ` SetupBearer `: ` http `

  - HTTP scheme: ` bearer `

  - Setup token before operator configuration, or an authenticated operator session outside this spec.

## Parameters

### ` receipt_hash ` (path, required)

- ` value `: type ` string `

  - minLength: ` 32 `

  - maxLength: ` 256 `

## Responses

### ` 200 ` — Matching receipt.

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` receipt `

  - ` receipt `: type ` object `

    - ` receipt_hash `: type ` string `

    - ` receipt `: type ` object `

    - ` submitted_at `: type ` string `; format ` date-time `

    - ` control_plane_url `: type ` string `

    - ` batch_id `: type ` string `

    - ` created_at `: type ` string `; format ` date-time `

### ` default ` — B3IQ-native problem response.

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` error `

  - ` error `: type ` object `

    - Required fields: ` status `, ` title `, ` detail `

    - ` status `: type ` integer `

    - ` title `: type ` string `

    - ` detail `: type ` string `

    - ` code `: type ` string ` — Stable B3IQ code when present. See docs/error-codes.md.

## Request examples

### cURL

```curl
curl -X GET 'http://127.0.0.1:8831/v1/receipts/string' \
  -H 'Authorization: Bearer YOUR_API_TOKEN'
```

### JavaScript

```javascript
const response = await fetch('http://127.0.0.1:8831/v1/receipts/string', {
  method: 'GET',
  headers: {
      "Authorization": "Bearer YOUR_API_TOKEN"
  }
});

const data = await response.json();
console.log(data);
```

### Python

```python
import requests

headers = {
    'Authorization': 'Bearer YOUR_API_TOKEN'
}

response = requests.get('http://127.0.0.1:8831/v1/receipts/string', headers=headers)
print(response.json())
```