{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/juzpost/json-schema/juzpost-group-page-schema.json",
  "title": "GroupPage",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/juzpost-accounts-api-openapi.yml#/components/schemas/GroupPage",
  "allOf": [
    {
      "$ref": "#/$defs/PageEnvelope"
    },
    {
      "type": "object",
      "description": "A page of channel groups.",
      "properties": {
        "data": {
          "type": "array",
          "description": "The groups in this page.",
          "items": {
            "$ref": "#/$defs/Group"
          }
        }
      }
    }
  ],
  "$defs": {
    "Group": {
      "type": "object",
      "description": "A channel group: a named bundle of social accounts you can schedule to by name.\n",
      "required": [
        "id",
        "name",
        "accountIds",
        "accountCount",
        "createdAt"
      ],
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid",
          "description": "The group id."
        },
        "name": {
          "type": "string",
          "description": "The group's name. This is the value `POST /schedule` accepts in its `group` field,\nmatched exactly.\n"
        },
        "accountIds": {
          "type": "array",
          "description": "Ids of the social accounts in this group, in no guaranteed order.",
          "items": {
            "type": "string",
            "format": "uuid",
            "description": "A social account id belonging to this group."
          }
        },
        "accountCount": {
          "type": "integer",
          "description": "How many accounts are in the group. The bulk scheduler rejects groups of more than\n10 with a `422`.\n"
        },
        "createdAt": {
          "type": "string",
          "format": "date-time",
          "description": "When the group was created."
        }
      }
    },
    "PageEnvelope": {
      "type": "object",
      "description": "Shared shape of every paginated response: a `data` array plus `pagination` state.\n",
      "required": [
        "data",
        "pagination"
      ],
      "properties": {
        "data": {
          "type": "array",
          "description": "The rows in this page, ordered by the requested sort and direction.",
          "items": {}
        },
        "pagination": {
          "$ref": "#/$defs/PaginationMeta"
        }
      }
    },
    "PaginationMeta": {
      "type": "object",
      "description": "Page state returned by every list operation. Keyset-based, so it stays correct while\nrows are being inserted, and it deliberately carries no total count.\n",
      "required": [
        "limit",
        "nextCursor",
        "hasMore"
      ],
      "properties": {
        "limit": {
          "type": "integer",
          "description": "The page size actually applied, after clamping to 1-100."
        },
        "nextCursor": {
          "type": [
            "string",
            "null"
          ],
          "description": "Pass this back as the `cursor` query parameter to fetch the next page. It is `null`\nwhen there is no next page.\n"
        },
        "hasMore": {
          "type": "boolean",
          "description": "True when at least one more page exists. Stop paginating when this is false rather\nthan when the data array is short.\n"
        }
      }
    }
  }
}