{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/github-enterprise/json-schema/github-enterprise-scim-user-list-schema.json",
  "title": "SCIM User List",
  "description": "SCIM User List",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/github-enterprise-scim-api-openapi.yml#/components/schemas/scim-user-list",
  "type": "object",
  "properties": {
    "schemas": {
      "description": "SCIM schema used.",
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "string"
      }
    },
    "totalResults": {
      "type": "integer"
    },
    "itemsPerPage": {
      "type": "integer"
    },
    "startIndex": {
      "type": "integer"
    },
    "Resources": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/scim-user"
      }
    }
  },
  "required": [
    "schemas",
    "totalResults",
    "itemsPerPage",
    "startIndex",
    "Resources"
  ],
  "$defs": {
    "scim-user": {
      "title": "SCIM /Users",
      "description": "SCIM /Users provisioning endpoints",
      "type": "object",
      "properties": {
        "schemas": {
          "description": "SCIM schema used.",
          "type": "array",
          "minItems": 1,
          "items": {
            "type": "string"
          }
        },
        "id": {
          "description": "Unique identifier of an external identity",
          "type": "string"
        },
        "externalId": {
          "description": "The ID of the User.",
          "type": [
            "string",
            "null"
          ]
        },
        "userName": {
          "description": "Configured by the admin. Could be an email, login, or username",
          "type": [
            "string",
            "null"
          ]
        },
        "profileUrl": {
          "description": "The URL of the linked GitHub user's profile.",
          "type": [
            "string",
            "null"
          ],
          "format": "uri"
        },
        "displayName": {
          "description": "The name of the user, suitable for display to end-users",
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "object",
          "properties": {
            "givenName": {
              "type": [
                "string",
                "null"
              ]
            },
            "familyName": {
              "type": [
                "string",
                "null"
              ]
            },
            "formatted": {
              "type": [
                "string",
                "null"
              ]
            }
          }
        },
        "emails": {
          "description": "user emails",
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "value": {
                "type": "string"
              },
              "primary": {
                "type": "boolean"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "value"
            ]
          }
        },
        "active": {
          "description": "The active status of the User.",
          "type": "boolean"
        },
        "meta": {
          "type": "object",
          "properties": {
            "resourceType": {
              "type": "string"
            },
            "created": {
              "type": "string",
              "format": "date-time"
            },
            "lastModified": {
              "type": "string",
              "format": "date-time"
            },
            "location": {
              "type": "string",
              "format": "uri"
            }
          }
        },
        "organization_id": {
          "description": "The ID of the organization.",
          "type": "integer"
        },
        "operations": {
          "description": "Set of operations to be performed",
          "type": "array",
          "minItems": 1,
          "items": {
            "properties": {
              "op": {
                "type": "string",
                "enum": [
                  "add",
                  "remove",
                  "replace"
                ]
              },
              "path": {
                "type": "string"
              },
              "value": {
                "oneOf": [
                  {
                    "type": "string"
                  },
                  {
                    "type": "object"
                  },
                  {
                    "type": "array",
                    "items": {}
                  }
                ]
              }
            },
            "required": [
              "op"
            ],
            "type": "object"
          }
        },
        "groups": {
          "description": "associated groups",
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "value": {
                "type": "string"
              },
              "display": {
                "type": "string"
              }
            }
          }
        },
        "roles": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "value": {
                "type": "string"
              },
              "primary": {
                "type": "boolean"
              },
              "type": {
                "type": "string"
              },
              "display": {
                "type": "string"
              }
            }
          }
        }
      },
      "required": [
        "id",
        "schemas",
        "emails",
        "active",
        "meta"
      ]
    }
  }
}