net.anisota.chronicle.inventory

anisota.net

Documentation

Item record in the player's inventory. rkey is the item ID. Updated via putRecord when quantities change.

main record

Item record in the player's inventory. rkey is the item ID. Updated via putRecord when quantities change.

Record Key any Any valid record key

Properties

consumable boolean Optional

Whether this item is consumed on use (quantity decreases)

createdAt string datetime Required

When the item was first acquired

itemId string Required

Unique identifier for the item

maxLength: 100 bytes
itemName string Optional

Display name of the item

maxLength: 200 bytes
itemType string Optional

Item category: power, camera, light, supplies, field, lore

maxLength: 50 bytes
metadata unknown Optional

Additional item-specific data (stats, attributes, etc.)

quantity integer Required

Current quantity in inventory

minimum: 0
rarity string Optional

Rarity level of the item

Allowed: veryCommon, common, uncommon, rare, veryRare, epic, legendary
source string Optional

How the item was acquired

Allowed: quest, trade, crafted, found, purchased, expedition, starter
updatedAt string datetime Optional

When the record was last updated

View raw schema
{
  "key": "any",
  "type": "record",
  "record": {
    "type": "object",
    "required": [
      "itemId",
      "quantity",
      "signature",
      "createdAt"
    ],
    "properties": {
      "itemId": {
        "type": "string",
        "maxLength": 100,
        "description": "Unique identifier for the item"
      },
      "rarity": {
        "enum": [
          "veryCommon",
          "common",
          "uncommon",
          "rare",
          "veryRare",
          "epic",
          "legendary"
        ],
        "type": "string",
        "description": "Rarity level of the item"
      },
      "source": {
        "enum": [
          "quest",
          "trade",
          "crafted",
          "found",
          "purchased",
          "expedition",
          "starter"
        ],
        "type": "string",
        "description": "How the item was acquired"
      },
      "itemName": {
        "type": "string",
        "maxLength": 200,
        "description": "Display name of the item"
      },
      "itemType": {
        "type": "string",
        "maxLength": 50,
        "description": "Item category: power, camera, light, supplies, field, lore"
      },
      "metadata": {
        "type": "unknown",
        "description": "Additional item-specific data (stats, attributes, etc.)"
      },
      "quantity": {
        "type": "integer",
        "minimum": 0,
        "description": "Current quantity in inventory"
      },
      "createdAt": {
        "type": "string",
        "format": "datetime",
        "description": "When the item was first acquired"
      },
      "signature": {
        "ref": "#chronicleSignature",
        "type": "ref"
      },
      "updatedAt": {
        "type": "string",
        "format": "datetime",
        "description": "When the record was last updated"
      },
      "consumable": {
        "type": "boolean",
        "description": "Whether this item is consumed on use (quantity decreases)"
      }
    }
  },
  "description": "Item record in the player's inventory. rkey is the item ID. Updated via putRecord when quantities change."
}
chronicleSignature object

ES256 cryptographic signature proving record authenticity

Properties

alg string Required

Signing algorithm (ES256)

kid string Required

Key identifier for the signing key

nonce string Required

Unique random nonce to prevent replay

sig string Required

Base64-encoded ES256 signature

signedAt string datetime Required

When the record was signed

version integer Required

Signature schema version

View raw schema
{
  "type": "object",
  "required": [
    "sig",
    "alg",
    "kid",
    "signedAt",
    "nonce",
    "version"
  ],
  "properties": {
    "alg": {
      "type": "string",
      "description": "Signing algorithm (ES256)"
    },
    "kid": {
      "type": "string",
      "description": "Key identifier for the signing key"
    },
    "sig": {
      "type": "string",
      "description": "Base64-encoded ES256 signature"
    },
    "nonce": {
      "type": "string",
      "description": "Unique random nonce to prevent replay"
    },
    "version": {
      "type": "integer",
      "description": "Signature schema version"
    },
    "signedAt": {
      "type": "string",
      "format": "datetime",
      "description": "When the record was signed"
    }
  },
  "description": "ES256 cryptographic signature proving record authenticity"
}

Lexicon Garden

@