{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/rutter/json-schema/rutter-verify-auth-response-schema.json",
  "title": "VerifyAuthResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/rutter-auth-api-openapi.yml#/components/schemas/VerifyAuthResponse",
  "type": "object",
  "properties": {
    "expires_at": {
      "type": [
        "number",
        "null"
      ],
      "description": "When the presented credential expires, as a Unix timestamp in seconds."
    },
    "requests_per_window": {
      "type": "number",
      "description": "The maximum number of requests the presented credential may make per rate-limit window."
    },
    "window_seconds": {
      "type": "number",
      "description": "The length of the rate-limit window, in seconds. `requests_per_window` is meaningless without it."
    },
    "scopes": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "connections:read",
          "logs:read",
          "jobs:read",
          "accounting:read",
          "commerce:read"
        ]
      },
      "description": "The scopes granted to the presented credential."
    },
    "organization": {
      "$ref": "#/$defs/VerifyAuthOrganization"
    }
  },
  "required": [
    "expires_at",
    "requests_per_window",
    "window_seconds",
    "scopes",
    "organization"
  ],
  "$defs": {
    "VerifyAuthOrganization": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "The Rutter organization id."
        },
        "client_id": {
          "type": "string",
          "description": "The organization's client ID."
        },
        "name": {
          "type": "string",
          "description": "The organization's name."
        }
      },
      "required": [
        "id",
        "client_id",
        "name"
      ],
      "description": "Organization details the credential belongs to."
    }
  }
}