# com.atiproto.item

> Published by [atiproto.com](https://lexicon.garden/identity/did:plc:4x5dcv6u4wlkjcssto7f22nu)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:4x5dcv6u4wlkjcssto7f22nu/com.atiproto.item)
- [Documentation](https://lexicon.garden/lexicon/did:plc:4x5dcv6u4wlkjcssto7f22nu/com.atiproto.item/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:4x5dcv6u4wlkjcssto7f22nu/com.atiproto.item/examples)

## Definitions

### `com.atiproto.item`

**Type**: `record`

A record representing a item given by one user to another

**Key**: `any`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `amount` | `integer` | Yes | Tip amount in cents (0 when recipient allows zero items) |
| `status` | `string` | Yes | Tip status |
| `message` | `string` | No | Optional message (max 500 chars) |
| `subject` | `string` (did) | No | DID of the user receiving the item |
| `currency` | `string` | Yes | ISO 4217 currency code |
| `createdAt` | `string` (datetime) | Yes | Creation timestamp |
| `recordUri` | `string` (at-uri) | No | AT-URI of specific record being tipped |
| `completedAt` | `string` (datetime) | No | Completion timestamp |

### `com.atiproto.item#view`

**Type**: `object`

View of a item record for use in API responses

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `uri` | `string` (at-uri) | Yes | AT-URI of the item record |
| `amount` | `integer` | Yes | Tip amount in cents (0 when recipient allows zero items) |
| `status` | `string` | Yes | Tip status |
| `message` | `string` | No | Optional message (max 500 chars) |
| `subject` | `string` (did) | No | DID of the user receiving the item |
| `currency` | `string` | Yes | ISO 4217 currency code |
| `createdAt` | `string` (datetime) | Yes | Creation timestamp |
| `recordUri` | `string` (at-uri) | No | AT-URI of specific record being tipped |
| `completedAt` | `string` (datetime) | No | Completion timestamp |

## Raw Schema

```json
{
  "id": "com.atiproto.item",
  "defs": {
    "main": {
      "key": "any",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "amount",
          "currency",
          "status",
          "createdAt"
        ],
        "properties": {
          "amount": {
            "type": "integer",
            "minimum": 0,
            "description": "Tip amount in cents (0 when recipient allows zero items)"
          },
          "status": {
            "enum": [
              "pending",
              "authorized",
              "completed",
              "failed",
              "refunded"
            ],
            "type": "string",
            "maxLength": 64,
            "description": "Tip status"
          },
          "message": {
            "type": "string",
            "maxLength": 5000,
            "description": "Optional message (max 500 chars)",
            "maxGraphemes": 500
          },
          "subject": {
            "type": "string",
            "format": "did",
            "description": "DID of the user receiving the item"
          },
          "currency": {
            "type": "string",
            "maxLength": 3,
            "description": "ISO 4217 currency code"
          },
          "createdAt": {
            "type": "string",
            "format": "datetime",
            "description": "Creation timestamp"
          },
          "recordUri": {
            "type": "string",
            "format": "at-uri",
            "description": "AT-URI of specific record being tipped"
          },
          "completedAt": {
            "type": "string",
            "format": "datetime",
            "description": "Completion timestamp"
          }
        }
      },
      "description": "A record representing a item given by one user to another"
    },
    "view": {
      "type": "object",
      "required": [
        "uri",
        "amount",
        "currency",
        "status",
        "createdAt"
      ],
      "properties": {
        "uri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of the item record"
        },
        "amount": {
          "type": "integer",
          "minimum": 0,
          "description": "Tip amount in cents (0 when recipient allows zero items)"
        },
        "status": {
          "enum": [
            "pending",
            "authorized",
            "completed",
            "failed",
            "refunded"
          ],
          "type": "string",
          "maxLength": 64,
          "description": "Tip status"
        },
        "message": {
          "type": "string",
          "maxLength": 5000,
          "description": "Optional message (max 500 chars)",
          "maxGraphemes": 500
        },
        "subject": {
          "type": "string",
          "format": "did",
          "description": "DID of the user receiving the item"
        },
        "currency": {
          "type": "string",
          "maxLength": 3,
          "description": "ISO 4217 currency code"
        },
        "createdAt": {
          "type": "string",
          "format": "datetime",
          "description": "Creation timestamp"
        },
        "recordUri": {
          "type": "string",
          "format": "at-uri",
          "description": "AT-URI of specific record being tipped"
        },
        "completedAt": {
          "type": "string",
          "format": "datetime",
          "description": "Completion timestamp"
        }
      },
      "description": "View of a item record for use in API responses"
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
