{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/envestnet/json-schema/envestnet-payment-account-holder-response-schema.json",
  "title": "PaymentAccountHolderResponse",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/envestnet-payment-processor-api-openapi.yml#/components/schemas/PaymentAccountHolderResponse",
  "type": "object",
  "properties": {
    "account": {
      "type": "array",
      "readOnly": true,
      "items": {
        "$ref": "#/$defs/PaymentAccountHolder"
      }
    }
  },
  "$defs": {
    "AccountAddress": {
      "title": "AccountAddress",
      "type": "object",
      "properties": {
        "zip": {
          "type": "string"
        },
        "country": {
          "type": "string"
        },
        "address3": {
          "type": "string"
        },
        "address2": {
          "type": "string"
        },
        "city": {
          "type": "string"
        },
        "sourceType": {
          "type": "string"
        },
        "address1": {
          "type": "string"
        },
        "street": {
          "type": "string"
        },
        "state": {
          "type": "string"
        },
        "type": {
          "type": "string",
          "enum": [
            "HOME",
            "BUSINESS",
            "POBOX",
            "RETAIL",
            "OFFICE",
            "SMALL_BUSINESS",
            "COMMUNICATION",
            "PERMANENT",
            "STATEMENT_ADDRESS",
            "PAYMENT",
            "PAYOFF",
            "UNKNOWN"
          ]
        }
      }
    },
    "AccountHolderData": {
      "title": "AccountHolderData",
      "type": "object",
      "properties": {
        "identifier": {
          "type": "array",
          "description": "Identifiers of the account holder.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "items": {
            "$ref": "#/$defs/Identifier"
          }
        },
        "gender": {
          "type": "string",
          "description": "Identifiers of the account holder.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true
        },
        "ownership": {
          "type": "string",
          "description": "Indicates the ownership of the account.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "enum": [
            "PRIMARY",
            "SECONDARY",
            "CUSTODIAN",
            "OTHERS",
            "POWER_OF_ATTORNEY",
            "TRUSTEE",
            "JOINT_OWNER",
            "BENEFICIARY",
            "AAS",
            "BUSINESS",
            "DBA",
            "TRUST"
          ]
        },
        "name": {
          "$ref": "#/$defs/Name"
        }
      }
    },
    "AccountProfileDetail": {
      "title": "AccountProfileDetail",
      "type": "object",
      "properties": {
        "identifier": {
          "type": "array",
          "description": "Identifiers available in the profile page of the account.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "items": {
            "$ref": "#/$defs/Identifier"
          }
        },
        "address": {
          "type": "array",
          "description": "Address available in the profile page of the account.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "items": {
            "$ref": "#/$defs/AccountAddress"
          }
        },
        "phoneNumber": {
          "type": "array",
          "description": "Phone number available in the profile page of the account.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "items": {
            "$ref": "#/$defs/PhoneNumber"
          }
        },
        "email": {
          "type": "array",
          "description": "Email Id available in the profile page of the account.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "items": {
            "$ref": "#/$defs/Email"
          }
        }
      }
    },
    "Email": {
      "title": "Email",
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "readOnly": true,
          "enum": [
            "PRIMARY",
            "SECONDARY",
            "PERSONAL",
            "WORK",
            "OTHERS"
          ]
        },
        "value": {
          "type": "string",
          "readOnly": true
        }
      }
    },
    "Identifier": {
      "title": "Identifier",
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "Type of Identifier",
          "readOnly": true,
          "enum": [
            "NIE",
            "DNI",
            "EIN",
            "BN",
            "AADHAR",
            "NIN",
            "NRIC"
          ]
        },
        "value": {
          "type": "string",
          "description": "Value of the identifier",
          "readOnly": true
        }
      }
    },
    "Name": {
      "title": "Name",
      "type": "object",
      "properties": {
        "middle": {
          "type": "string"
        },
        "last": {
          "type": "string"
        },
        "fullName": {
          "type": "string"
        },
        "first": {
          "type": "string"
        }
      }
    },
    "PaymentAccountHolder": {
      "title": "PaymentAccountHolder",
      "type": "object",
      "properties": {
        "accountStatus": {
          "type": "string",
          "description": "The status of the account that is updated by the user through an application or an API.</li><ul><li><b>ACTIVE:</b> All the added aggregated accounts status will be made \"ACTIVE\" by default.</li><li><b>TO_BE_CLOSED:</b> If the aggregated accounts are not found or closed in the data provider site, Yodlee system marks the status as TO_BE_CLOSED.</li><li><b>INACTIVE:</b> Users can update the status as INACTIVE to stop updating and to stop considering the account in other services.</li><li><b>CLOSED:</b> Users can update the status as CLOSED, if the account is closed with the provider.</li></ul><b>Endpoints</b>:<ul><li>GET /partner/paymentProcessor/account</li><li>GET /partner/paymentProcessor/account/balance</li><li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "enum": [
            "ACTIVE",
            "INACTIVE",
            "TO_BE_CLOSED",
            "CLOSED",
            "DELETED"
          ]
        },
        "lastUpdated": {
          "type": "string",
          "description": "The date time the account information was last retrieved from the provider site and updated in the Yodlee system.<br><b>Endpoints</b>:<ul><li>GET /partner/paymentProcessor/account</li><li>GET /partner/paymentProcessor/account/balance</li><li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true
        },
        "accountName": {
          "type": "string",
          "description": "The account name as it appears at the site.<br><b>Endpoints</b>:<ul><li>GET /partner/paymentProcessor/account</li><li>GET /partner/paymentProcessor/account/balance</li><li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true
        },
        "accountType": {
          "type": "string",
          "description": "The type of account that is aggregated, i.e., savings, checking, charge, etc. The account type is derived based on the attributes of the account. <br><b>Endpoints</b>:<ul><li>GET /partner/paymentProcessor/account</li><li>GET /partner/paymentProcessor/account/balance</li><li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true
        },
        "profile": {
          "$ref": "#/$defs/AccountProfileDetail"
        },
        "holder": {
          "type": "array",
          "description": "Holder details of the account.<br><b>Endpoints</b>:<li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "readOnly": true,
          "items": {
            "$ref": "#/$defs/AccountHolderData"
          }
        },
        "id": {
          "type": "integer",
          "description": "The primary key of the account resource and the unique identifier for the account.<br><br><b>Endpoints</b>:<ul><li>GET /partner/paymentProcessor/account</li><li>GET /partner/paymentProcessor/account/balance</li><li>GET /partner/paymentProcessor/account/holder</li></ul>",
          "format": "int64",
          "readOnly": true
        }
      }
    },
    "PhoneNumber": {
      "title": "PhoneNumber",
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "type of phone number",
          "readOnly": true,
          "enum": [
            "HOME",
            "WORK",
            "LANDLINE",
            "MOBILE"
          ]
        },
        "value": {
          "type": "string",
          "description": "Phone Number",
          "readOnly": true
        }
      }
    }
  }
}