@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api Account API
@base https://cal-test.adyen.com/cal/services/Account/v6
@version 6
@auth ApiKey X-API-Key in header | Bearer basic
@endpoints 20
@toc checkAccountHolder(1), closeAccount(1), closeAccountHolder(1), closeStores(1), createAccount(1), createAccountHolder(1), deleteBankAccounts(1), deleteLegalArrangements(1), deletePayoutMethods(1), deleteShareholders(1), deleteSignatories(1), getAccountHolder(1), getTaxForm(1), getUploadedDocuments(1), suspendAccountHolder(1), unSuspendAccountHolder(1), updateAccount(1), updateAccountHolder(1), updateAccountHolderState(1), uploadDocument(1)

@group checkAccountHolder
@endpoint POST /checkAccountHolder
@desc Trigger verification
@required {accountHolderCode: str # The code of the account holder to verify., accountStateType: str(LimitedPayout/LimitedProcessing/LimitlessPayout/LimitlessProcessing/Payout/Processing) # The state required for the account holder. > Permitted values: `Processing`, `Payout`., tier: int(int32) # The tier required for the account holder.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","accountStateType":"Processing","tier":"2"}

@endgroup

@group closeAccount
@endpoint POST /closeAccount
@desc Close an account
@required {accountCode: str # The code of account to be closed.}
@returns(200) {accountCode: str, invalidFields: [map], pspReference: str, resultCode: str, status: str} # OK - the request has succeeded.
@returns(202) {accountCode: str, invalidFields: [map], pspReference: str, resultCode: str, status: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountCode":"CODE_OF_ACCOUNT"}

@endgroup

@group closeAccountHolder
@endpoint POST /closeAccountHolder
@desc Close an account holder
@required {accountHolderCode: str # The code of the Account Holder to be closed.}
@returns(200) {accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER"}

@endgroup

@group closeStores
@endpoint POST /closeStores
@desc Close stores
@required {accountHolderCode: str # The code of the account holder., stores: [str] # List of stores to be closed.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}

@endgroup

@group createAccount
@endpoint POST /createAccount
@desc Create an account
@required {accountHolderCode: str # The code of Account Holder under which to create the account.}
@optional {bankAccountUUID: str # The bankAccountUUID of the bank account held by the account holder to couple the account with. Scheduled payouts in currencies matching the currency of this bank account will be sent to this bank account. Payouts in different currencies will be sent to a matching bank account of the account holder., description: str # A description of the account, maximum 256 characters. You can use alphanumeric characters (A-Z, a-z, 0-9), white spaces, and underscores `_`., metadata: map # A set of key and value pairs for general use by the merchant. The keys do not have specific names and may be used for storing miscellaneous data as desired. > Note that during an update of metadata, the omission of existing key-value pairs will result in the deletion of those key-value pairs., payoutMethodCode: str # The payout method code held by the account holder to couple the account with. Scheduled card payouts will be sent using this payout method code., payoutSchedule: str(BIWEEKLY_ON_1ST_AND_15TH_AT_MIDNIGHT/DAILY/DAILY_AU/DAILY_EU/DAILY_SG/DAILY_US/HOLD/MONTHLY/WEEKLY/WEEKLY_MON_TO_FRI_AU/WEEKLY_MON_TO_FRI_EU/WEEKLY_MON_TO_FRI_US/WEEKLY_ON_TUE_FRI_MIDNIGHT/WEEKLY_SUN_TO_THU_AU/WEEKLY_SUN_TO_THU_US) # The payout schedule for the account.  Possible values: `DEFAULT`, `DAILY`, `DAILY_US`, `DAILY_EU`, `DAILY_AU`, `DAILY_SG`, `WEEKLY`, `WEEKLY_ON_TUE_FRI_MIDNIGHT`, `BIWEEKLY_ON_1ST_AND_15TH_AT_MIDNIGHT`, `MONTHLY`, `HOLD`. > `HOLD` prevents scheduled payouts, but you can still initiate payouts manually., payoutScheduleReason: str # The reason for the payout schedule choice. > This field is required when the `payoutSchedule` parameter is set to `HOLD`., payoutSpeed: str(INSTANT/SAME_DAY/STANDARD)=STANDARD # Speed at which payouts for this account are processed.  Possible values: `STANDARD` (default), `SAME_DAY`.}
@returns(200) {accountCode: str, accountHolderCode: str, bankAccountUUID: str, description: str, invalidFields: [map], metadata: map, payoutMethodCode: str, payoutSchedule: map{nextScheduledPayout: str(date-time), schedule: str}, payoutSpeed: str, pspReference: str, resultCode: str, status: str} # OK - the request has succeeded.
@returns(202) {accountCode: str, accountHolderCode: str, bankAccountUUID: str, description: str, invalidFields: [map], metadata: map, payoutMethodCode: str, payoutSchedule: map{nextScheduledPayout: str(date-time), schedule: str}, payoutSpeed: str, pspReference: str, resultCode: str, status: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER"}

@endgroup

@group createAccountHolder
@endpoint POST /createAccountHolder
@desc Create an account holder
@required {accountHolderCode: str # Your unique identifier for the prospective account holder. The length must be between three (3) and fifty (50) characters long. Only letters, digits, and hyphens (-) are allowed., accountHolderDetails: map{address!: map, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map, email: str, fullPhoneNumber: str, individualDetails: map, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map, principalBusinessAddress: map, storeDetails: [map], webAddress: str}, legalEntity: str(Business/Individual/NonProfit/Partnership/PublicCompany) # The legal entity type of the account holder. This determines the information that should be provided in the request.  Possible values: **Business**, **Individual**, or **NonProfit**.  * If set to **Business** or **NonProfit**, then `accountHolderDetails.businessDetails` must be provided, with at least one entry in the `accountHolderDetails.businessDetails.shareholders` list.  * If set to **Individual**, then `accountHolderDetails.individualDetails` must be provided.}
@optional {createDefaultAccount: bool # If set to **true**, an account with the default options is automatically created for the account holder. By default, this field is set to **true**., description: str # A description of the prospective account holder, maximum 256 characters. You can use alphanumeric characters (A-Z, a-z, 0-9), white spaces, and underscores `_`., primaryCurrency: str # The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes), with which the prospective account holder primarily deals., processingTier: int(int32) # The starting [processing tier](https://docs.adyen.com/classic-platforms/onboarding-and-verification/precheck-kyc-information) for the prospective account holder., verificationProfile: str # The identifier of the profile that applies to this entity.}
@returns(200) {accountCode: str, accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, description: str, invalidFields: [map], legalEntity: str, primaryCurrency: str, pspReference: str, resultCode: str, verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # OK - the request has succeeded.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"YOUR_UNIQUE_ACCOUNT_HOLDER_CODE","accountHolderDetails":{"address":{"country":"US"},"businessDetails":{"doingBusinessAs":"Real Good Restaurant","legalBusinessName":"Real Good Restaurant Inc.","shareholders":[{"shareholderType":"Controller","name":{"firstName":"John","lastName":"Carpenter"},"address":{"country":"NL"},"email":"testshareholder@email.com"}]},"email":"test@email.com","webAddress":"https://www.your-website.com"},"legalEntity":"Business"}

@endgroup

@group deleteBankAccounts
@endpoint POST /deleteBankAccounts
@desc Delete bank accounts
@required {accountHolderCode: str # The code of the Account Holder from which to delete the Bank Account(s)., bankAccountUUIDs: [str] # The code(s) of the Bank Accounts to be deleted.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","bankAccountUUIDs":["eeb6ed22-3bae-483c-83b9-bc2097a75d40"]}

@endgroup

@group deleteLegalArrangements
@endpoint POST /deleteLegalArrangements
@desc Delete legal arrangements
@required {accountHolderCode: str # The code of the account holder., legalArrangements: [map{legalArrangementCode!: str, legalArrangementEntityCodes: [str]}] # List of legal arrangements.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","legalArrangements":[{"legalArrangementCode":"cdf92f5a-a114-4ce6-8f19-c3f6ec83141c"}]}

@endgroup

@group deletePayoutMethods
@endpoint POST /deletePayoutMethods
@desc Delete payout methods
@required {accountHolderCode: str # The code of the account holder, from which to delete the payout methods., payoutMethodCodes: [str] # The codes of the payout methods to be deleted.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","payoutMethodCodes":["34b6ed22-3bae-483c-83b9-bc2097a75d40"]}

@endgroup

@group deleteShareholders
@endpoint POST /deleteShareholders
@desc Delete shareholders
@required {accountHolderCode: str # The code of the Account Holder from which to delete the Shareholders., shareholderCodes: [str] # The code(s) of the Shareholders to be deleted.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","shareholderCodes":["9188218c-576e-4cbe-8e86-72722f453920"]}

@endgroup

@group deleteSignatories
@endpoint POST /deleteSignatories
@desc Delete signatories
@required {accountHolderCode: str # The code of the account holder from which to delete the signatories., signatoryCodes: [str] # Array of codes of the signatories to be deleted.}
@returns(200) {invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}

@endgroup

@group getAccountHolder
@endpoint POST /getAccountHolder
@desc Get an account holder
@optional {accountCode: str # The code of the account of which to retrieve the details. > Required if no `accountHolderCode` is provided., accountHolderCode: str # The code of the account holder of which to retrieve the details. > Required if no `accountCode` is provided., showDetails: bool # True if the request should return the account holder details}
@returns(200) {accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, accounts: [map], description: str, invalidFields: [map], legalEntity: str, migrationData: map{accountHolderId: str, balancePlatform: str, migrated: bool, migratedAccounts: [map], migratedShareholders: [map], migratedStores: [map], migrationDate: str(date-time)}, primaryCurrency: str, pspReference: str, resultCode: str, systemUpToDateTime: str(date-time), verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # OK - the request has succeeded.
@returns(202) {accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, accounts: [map], description: str, invalidFields: [map], legalEntity: str, migrationData: map{accountHolderId: str, balancePlatform: str, migrated: bool, migratedAccounts: [map], migratedShareholders: [map], migratedStores: [map], migrationDate: str(date-time)}, primaryCurrency: str, pspReference: str, resultCode: str, systemUpToDateTime: str(date-time), verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountCode":"CODE_OF_ACCOUNT"}

@endgroup

@group getTaxForm
@endpoint POST /getTaxForm
@desc Get a tax form
@required {accountHolderCode: str # The account holder code you provided when you created the account holder., formType: str # Type of the requested tax form. For example, 1099-K., year: int(int32) # Applicable tax year in the YYYY format.}
@returns(200) {content: str(byte), contentType: str, invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","formType":"1099-K","year":2020}

@endgroup

@group getUploadedDocuments
@endpoint POST /getUploadedDocuments
@desc Get documents
@required {accountHolderCode: str # The code of the Account Holder for which to retrieve the documents.}
@optional {bankAccountUUID: str # The code of the Bank Account for which to retrieve the documents., shareholderCode: str # The code of the Shareholder for which to retrieve the documents.}
@returns(200) {documentDetails: [map], invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","bankAccountUUID":"EXAMPLE_UUID"}

@endgroup

@group suspendAccountHolder
@endpoint POST /suspendAccountHolder
@desc Suspend an account holder
@required {accountHolderCode: str # The code of the account holder to be suspended.}
@returns(200) {accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER"}

@endgroup

@group unSuspendAccountHolder
@endpoint POST /unSuspendAccountHolder
@desc Unsuspend an account holder
@required {accountHolderCode: str # The code of the account holder to be reinstated.}
@returns(200) {accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER"}

@endgroup

@group updateAccount
@endpoint POST /updateAccount
@desc Update an account
@required {accountCode: str # The code of the account to update.}
@optional {bankAccountUUID: str # The bankAccountUUID of the bank account held by the account holder to couple the account with. Scheduled payouts in currencies matching the currency of this bank account will be sent to this bank account. Payouts in different currencies will be sent to a matching bank account of the account holder., description: str # A description of the account, maximum 256 characters.You can use alphanumeric characters (A-Z, a-z, 0-9), white spaces, and underscores `_`., metadata: map # A set of key and value pairs for general use by the merchant. The keys do not have specific names and may be used for storing miscellaneous data as desired. > Note that during an update of metadata, the omission of existing key-value pairs will result in the deletion of those key-value pairs., payoutMethodCode: str # The payout method code held by the account holder to couple the account with. Scheduled card payouts will be sent using this payout method code., payoutSchedule: map{action: str, reason: str, schedule!: str}, payoutSpeed: str(INSTANT/SAME_DAY/STANDARD) # Speed at which payouts for this account are processed.  Possible values: `STANDARD` (default), `SAME_DAY`.}
@returns(200) {accountCode: str, bankAccountUUID: str, description: str, invalidFields: [map], metadata: map, payoutMethodCode: str, payoutSchedule: map{nextScheduledPayout: str(date-time), schedule: str}, payoutSpeed: str, pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {accountCode: str, bankAccountUUID: str, description: str, invalidFields: [map], metadata: map, payoutMethodCode: str, payoutSchedule: map{nextScheduledPayout: str(date-time), schedule: str}, payoutSpeed: str, pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountCode":"CODE_OF_ACCOUNT","payoutSchedule":{"schedule":"WEEKLY","action":"CLOSE"}}

@endgroup

@group updateAccountHolder
@endpoint POST /updateAccountHolder
@desc Update an account holder
@required {accountHolderCode: str # The code of the Account Holder to be updated.}
@optional {accountHolderDetails: map{address!: map, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map, email: str, fullPhoneNumber: str, individualDetails: map, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map, principalBusinessAddress: map, storeDetails: [map], webAddress: str}, description: str # A description of the account holder, maximum 256 characters. You can use alphanumeric characters (A-Z, a-z, 0-9), white spaces, and underscores `_`., legalEntity: str(Business/Individual/NonProfit/Partnership/PublicCompany) # The legal entity type of the account holder. This determines the information that should be provided in the request.  Possible values: **Business**, **Individual**, or **NonProfit**.  * If set to **Business** or **NonProfit**, then `accountHolderDetails.businessDetails` must be provided, with at least one entry in the `accountHolderDetails.businessDetails.shareholders` list.  * If set to **Individual**, then `accountHolderDetails.individualDetails` must be provided., primaryCurrency: str # The primary three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes), to which the account holder should be updated., processingTier: int(int32) # The processing tier to which the Account Holder should be updated. >The processing tier can not be lowered through this request.  >Required if accountHolderDetails are not provided., verificationProfile: str # The identifier of the profile that applies to this entity.}
@returns(200) {accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, description: str, invalidFields: [map], legalEntity: str, primaryCurrency: str, pspReference: str, resultCode: str, verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # OK - the request has succeeded.
@returns(202) {accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, description: str, invalidFields: [map], legalEntity: str, primaryCurrency: str, pspReference: str, resultCode: str, verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"YOUR_UNIQUE_ACCOUNT_HOLDER_CODE","accountHolderDetails":{"businessDetails":{"shareholders":[{"shareholderType":"Controller","name":{"firstName":"Shelly","lastName":"Eller"},"address":{"city":"San Francisco","country":"US","houseNumberOrName":"274","postalCode":"94107","stateOrProvince":"CA","street":"Brannan"},"email":"testshareholder2@email.com","personalData":{"dateOfBirth":"1970-01-01","documentData":[{"number":"1234567890","type":"ID"}]}}],"taxId":"123456789"},"email":"test@email.com","fullPhoneNumber":"+14154890281","webAddress":"http://www.accountholderwebsite.com"}}

@endgroup

@group updateAccountHolderState
@endpoint POST /updateAccountHolderState
@desc Update payout or processing state
@required {accountHolderCode: str # The code of the Account Holder on which to update the state., disable: bool # If true, disable the requested state.  If false, enable the requested state., stateType: str(LimitedPayout/LimitedProcessing/LimitlessPayout/LimitlessProcessing/Payout/Processing) # The state to be updated. >Permitted values are: `Processing`, `Payout`}
@optional {reason: str # The reason that the state is being updated. >Required if the state is being disabled.}
@returns(200) {accountHolderCode: str, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # OK - the request has succeeded.
@returns(202) {accountHolderCode: str, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, invalidFields: [map], pspReference: str, resultCode: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","disable":true,"reason":"test reason payout","stateType":"Payout"}

@endgroup

@group uploadDocument
@endpoint POST /uploadDocument
@desc Upload a document
@required {documentContent: str(byte) # The content of the document, in Base64-encoded string format.  To learn about document requirements, refer to [Verification checks](https://docs.adyen.com/classic-platforms/verification-checks)., documentDetail: map{accountHolderCode: str, bankAccountUUID: str, description: str, documentType!: str, filename: str, legalArrangementCode: str, legalArrangementEntityCode: str, shareholderCode: str, signatoryCode: str}}
@returns(200) {accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, description: str, invalidFields: [map], legalEntity: str, primaryCurrency: str, pspReference: str, resultCode: str, verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # OK - the request has succeeded.
@returns(202) {accountHolderCode: str, accountHolderDetails: map{address: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, bankAccountDetails: [map], bankAggregatorDataReference: str, businessDetails: map{doingBusinessAs: str, legalBusinessName: str, listedUltimateParentCompany: [map], registrationNumber: str, shareholders: [map], signatories: [map], stockExchange: str, stockNumber: str, stockTicker: str, taxId: str}, email: str, fullPhoneNumber: str, individualDetails: map{name: map{firstName: str, gender: str, infix: str, lastName: str}, personalData: map{dateOfBirth: str, documentData: [map], nationality: str}}, lastReviewDate: str, legalArrangements: [map], merchantCategoryCode: str, metadata: map, payoutMethods: [map], phoneNumber: map{phoneCountryCode: str, phoneNumber: str, phoneType: str}, principalBusinessAddress: map{city: str, country: str, houseNumberOrName: str, postalCode: str, stateOrProvince: str, street: str}, storeDetails: [map], webAddress: str}, accountHolderStatus: map{events: [map], payoutState: map{allowPayout: bool, disableReason: str, disabled: bool, notAllowedReason: str, payoutLimit: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, processingState: map{disableReason: str, disabled: bool, processedFrom: map{currency: str, value: int(int64)}, processedTo: map{currency: str, value: int(int64)}, tierNumber: int(int32)}, status: str, statusReason: str}, description: str, invalidFields: [map], legalEntity: str, primaryCurrency: str, pspReference: str, resultCode: str, verification: map{accountHolder: map{checks: [map]}, legalArrangements: [map], legalArrangementsEntities: [map], payoutMethods: [map], shareholders: [map], signatories: [map], ultimateParentCompany: [map]}, verificationProfile: str} # Accepted - the request has been accepted for processing, but the processing has not been completed.
@errors {400: Bad Request - a problem reading or understanding the request., 401: Unauthorized - authentication required., 403: Forbidden - insufficient permissions to process the request., 422: Unprocessable Entity - a request validation error., 500: Internal Server Error - the server could not process the request.}
@example_request {"documentContent":"dGVzdCBkb2N1bWVudCBjb250ZW50","documentDetail":{"accountHolderCode":"CODE_OF_ACCOUNT_HOLDER","documentType":"PASSPORT","filename":"passport.png","description":"test passport description"}}

@endgroup

@end
