{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/githunt-ai/json-schema/githunt-ai-claim-response-schema.json",
  "title": "ClaimResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/githunt-ai-lists-api-openapi.yml#/components/schemas/ClaimResponse",
  "type": "object",
  "properties": {
    "success": {
      "type": "boolean",
      "const": true
    },
    "data": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string"
        },
        "claimed": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Logins this run now holds until `claim_expires_at`."
        },
        "unavailable": {
          "type": "array",
          "description": "Logins another run holds, or that are already `seen`.",
          "items": {
            "type": "object",
            "properties": {
              "login": {
                "type": "string"
              },
              "state": {
                "type": "string",
                "enum": [
                  "seen",
                  "claimed"
                ]
              },
              "claim_expires_at": {
                "type": [
                  "string",
                  "null"
                ]
              }
            }
          }
        },
        "claim_expires_at": {
          "type": "string",
          "format": "date-time"
        }
      }
    },
    "meta": {
      "$ref": "#/$defs/Meta"
    }
  },
  "$defs": {
    "Meta": {
      "type": "object",
      "description": "Envelope metadata. `quota.cost` is 0 on endpoints that debit no credits.",
      "properties": {
        "requestId": {
          "type": "string"
        },
        "quota": {
          "$ref": "#/$defs/Quota"
        }
      }
    },
    "Quota": {
      "type": "object",
      "properties": {
        "used": {
          "type": "integer"
        },
        "limit": {
          "type": "integer",
          "description": "-1 means unlimited"
        },
        "month": {
          "type": "string"
        },
        "cost": {
          "type": "integer",
          "description": "Credits this request debited (search: 1, get user: 1, evidence report: 3 when a report is returned and 0 while pending, analyze profile: 3, list operations: 0). `used` already reflects this charge."
        },
        "rollover": {
          "type": "integer",
          "description": "Unused credits banked from the previous month and available on top of `limit` this month (`remaining` = limit + rollover - used). Only present on the Team plan, capped at one extra month's allowance (so at most 2x the allowance is usable in a month)."
        }
      }
    }
  }
}