{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/stackit/main/json-schema/stackit-list-members-response-schema.json",
  "title": "ListMembersResponse",
  "x-generated": "2026-10-18",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/stackit-authorization-openapi.yml#/components/schemas/ListMembersResponse",
  "properties": {
    "members": {
      "items": {
        "$ref": "#/$defs/Member"
      },
      "title": "The list of members who should be added to this resource",
      "type": "array"
    },
    "resourceId": {
      "pattern": "^([a-zA-Z0-9/_|\\-=+@.]{1,})$",
      "title": "The ID of the resource, where the members should be updated",
      "type": "string"
    },
    "resourceType": {
      "pattern": "^[a-z](?:-?[a-z]){1,63}$",
      "title": "Resource type",
      "type": "string"
    }
  },
  "required": [
    "resourceId",
    "resourceType",
    "members"
  ],
  "type": "object",
  "$defs": {
    "Member": {
      "properties": {
        "role": {
          "pattern": "^[a-z](?:[-.]?[a-z]){1,63}$",
          "title": "A valid role defined for the resource.",
          "type": "string"
        },
        "subject": {
          "maxLength": 255,
          "minLength": 1,
          "title": "Identifier of user, service account, client or user group. Usually email address or name in case of clients.",
          "type": "string"
        }
      },
      "required": [
        "subject",
        "role"
      ],
      "type": "object"
    }
  }
}