{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/metricool/json-schema/metricool-json-ok-list-response-agency-end-client-dto-schema.json",
  "title": "JsonOkListResponseAgencyEndClientDto",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/metricool-agency-end-clients-api-service-api-openapi.yml#/components/schemas/JsonOkListResponseAgencyEndClientDto",
  "type": "object",
  "properties": {
    "metadata": {
      "type": "object"
    },
    "page": {
      "$ref": "#/$defs/JsonPaging"
    },
    "data": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/AgencyEndClientDto"
      }
    }
  },
  "$defs": {
    "AgencyEndClientBrandDto": {
      "required": [
        "brandId",
        "enabled",
        "roleId"
      ],
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int64"
        },
        "agencyId": {
          "type": "integer",
          "format": "int32"
        },
        "endClientId": {
          "type": "integer",
          "format": "int32"
        },
        "brandId": {
          "type": "integer",
          "format": "int32"
        },
        "email": {
          "type": "string"
        },
        "enabled": {
          "type": "boolean"
        },
        "roleId": {
          "type": "integer",
          "format": "int64"
        },
        "brandName": {
          "type": "string"
        },
        "roleName": {
          "type": "string"
        }
      }
    },
    "AgencyEndClientDto": {
      "required": [
        "agencyId",
        "assignments",
        "id",
        "username"
      ],
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int32"
        },
        "agencyId": {
          "type": "integer",
          "format": "int32"
        },
        "username": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "lastname": {
          "type": "string"
        },
        "email": {
          "type": "string"
        },
        "language": {
          "type": "string"
        },
        "timezone": {
          "type": "string"
        },
        "enabled": {
          "type": "boolean"
        },
        "lastInvitationDate": {
          "$ref": "#/$defs/DateTimeInfo"
        },
        "profilePicture": {
          "type": "string",
          "description": "Absolute URL of the client's profile picture. Omitted when the client has none; the UI then renders the client's initials."
        },
        "assignments": {
          "minItems": 1,
          "type": "array",
          "items": {
            "$ref": "#/$defs/AgencyEndClientBrandDto"
          }
        }
      }
    },
    "DateTimeInfo": {
      "required": [
        "dateTime"
      ],
      "type": "object",
      "properties": {
        "dateTime": {
          "type": "string",
          "description": "Local Date-time represented with a certain timezone "
        },
        "timezone": {
          "type": "string",
          "description": "Timezone applied to the datetime"
        }
      }
    },
    "JsonPaging": {
      "type": "object",
      "properties": {
        "next": {
          "type": "string"
        }
      }
    }
  }
}