{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/riveterhq-com/json-schema/riveterhq-com-account-schema.json",
  "title": "Account",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/riveterhq-com-account-api-openapi.yml#/components/schemas/Account",
  "type": "object",
  "properties": {
    "uuid": {
      "type": "string",
      "format": "uuid",
      "description": "Unique identifier for the account"
    },
    "name": {
      "type": "string",
      "description": "Account name"
    },
    "plan": {
      "type": "string",
      "enum": [
        "free",
        "starter",
        "advanced",
        "pro",
        "enterprise"
      ],
      "description": "Current billing plan"
    },
    "credit": {
      "$ref": "#/$defs/Credit"
    }
  },
  "required": [
    "uuid",
    "name",
    "plan",
    "credit"
  ],
  "$defs": {
    "Credit": {
      "type": "object",
      "properties": {
        "count": {
          "type": "integer",
          "description": "Current credit count"
        },
        "max": {
          "type": "integer",
          "description": "Maximum credits available"
        },
        "balance": {
          "type": "integer",
          "description": "Remaining credit balance"
        }
      },
      "required": [
        "count",
        "max",
        "balance"
      ]
    }
  }
}