{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/certifyos/main/json-schema/certifyos-user-list-response-dto-schema.json",
  "title": "UserListResponseDto",
  "description": "Paginated list of users",
  "x-generated": "2026-10-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/certifyos-user-api-openapi.yml#/components/schemas/UserListResponseDto",
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/UserResponseDto"
      },
      "description": "List of users"
    },
    "totalCount": {
      "type": "integer",
      "format": "int64",
      "description": "Total number of users"
    },
    "links": {
      "$ref": "#/$defs/PageLinks",
      "type": "object",
      "description": "Pagination links"
    }
  },
  "$defs": {
    "OffsetDateTime": {
      "type": "string",
      "format": "date-time"
    },
    "PageLinks": {
      "type": "object",
      "description": "HATEOAS-style pagination links.",
      "properties": {
        "self": {
          "type": "string",
          "description": "Link to the current page."
        },
        "next": {
          "type": "string",
          "description": "Link to the next page; null on the last page."
        },
        "prev": {
          "type": "string",
          "description": "Link to the previous page; null on the first page."
        }
      }
    },
    "UserResponseDto": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "email": {
          "type": "string"
        },
        "firstName": {
          "type": "string"
        },
        "lastName": {
          "type": "string"
        },
        "tenantId": {
          "type": "string"
        },
        "createdAt": {
          "$ref": "#/$defs/OffsetDateTime"
        },
        "updatedAt": {
          "$ref": "#/$defs/OffsetDateTime"
        },
        "createdBy": {
          "type": "string"
        },
        "updatedBy": {
          "type": "string"
        }
      }
    }
  }
}