Skip to main content

setDefaultBankAccount

Requires permission payments:bank-account:update.

Makes a bank account the default for its currency and turns it on if it was off. The other accounts in the same currency lose the default flag. Requires permission to update bank accounts.

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

mutation SetDefaultBankAccount($id: ID!) {
setDefaultBankAccount(id: $id) {
id
accountNumber
branchCode
currencyCode
swiftCode
accountName
}
}

Variables:

{
"id": "id"
}

Response:

{
"data": {
"setDefaultBankAccount": {
"id": "id",
"accountNumber": "string",
"branchCode": "string",
"currencyCode": "string",
"swiftCode": "string",
"accountName": "string"
}
}
}
setDefaultBankAccount(
id: ID!
): BankAccount!

Arguments​

setDefaultBankAccount.id ● ID! non-null scalar​

The ID of the bank account.

Type​

BankAccount object​

A bank account the organization receives money into or pays from, in one currency.