Skip to content

Square: Get Bank Account By V1 Id

Square bankAccounts.getBankAccountByV1Id: arguments, response, policy and SDK examples.

← Bank accounts operations · Get started

Operation square.getbankaccountbyv1id

Provider route: GET /v2/bank-accounts/by-v1-id/{v1_bank_account_id}. Alter supplies the connection’s credentials and routing.

Install @alter-ai/sdk @alter-ai/square with npm, or alter-sdk-square with pip. Supply your connected customer’s grant ID and the arguments described below.

import { App } from "@alter-ai/sdk";
import { SquareIntegration } from "@alter-ai/square";
async function execute(input: Parameters<SquareIntegration["bankAccounts"]["getBankAccountByV1Id"]>[0]) {
const app = new App({ apiKey: process.env.ALTER_API_KEY! });
try {
const provider = new SquareIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! });
const call = await provider.bankAccounts.getBankAccountByV1Id(input);
const result = await call.wait();
return result.bodyJson();
} finally {
await app.close();
}
}
import os
from alter_sdk import App
from alter_sdk_square import SquareIntegration
async def execute(arguments):
async with App(api_key=os.environ["ALTER_API_KEY"]) as app:
provider = SquareIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]})
call = await provider.bank_accounts.get_bank_account_by_v1_id(arguments)
result = await call.wait()
return result.body_json()
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: not allowed
pathobjectRequired within parentAdditional keys: not allowed
path.v1_bank_account_idstringRequired within parent

Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.

FieldTypePresenceDescription and constraints
$ModelRootExpand Get Bank Account By V1 Id — response body

Referenced models: Get Bank Account By V1 Id — response body

1 more schema is linked from the tables above, on the schema pages.

Get Bank Account By V1 Id — response body
FieldTypePresenceDescription and constraints
$objectRootResponse object returned by GetBankAccountByV1Id.
bank_accountModelOptionalExpand Get Bank Account — response body — bank account
The requested `BankAccount` object.
errorsarrayOptionalInformation on errors encountered during the request.
errors[]ModelEach itemExpand Get Shift — response body — errors item

Referenced models: Get Bank Account — response body — bank account, Get Shift — response body — errors item

Get Bank Account — response body — bank account
FieldTypePresenceDescription and constraints
$objectRootRepresents a bank account. For more information about
linking a bank account to a Square account, see
[Bank Accounts API](https://developer.squareup.com/docs/bank-accounts-api).
account_number_suffixstringRequired within parentThe last few digits of the account number.
Minimum length: 1
account_typestringRequired within parentIndicates the financial purpose of the bank account.
The financial purpose of the associated bank account.
See [BankAccountType](#type-bankaccounttype) for possible values
Known values: CHECKING, SAVINGS, INVESTMENT, OTHER, BUSINESS_CHECKING
bank_nameJSONOptional
bank_name (anyOf 1)stringAlternativeRead only. Name of actual financial institution.
For example "Bank of America".
Maximum length: 100
bank_name (anyOf 2)nullAlternative
countryModelRequired within parentExpand Create Location — response body — location country
The ISO 3166 Alpha-2 country code where the bank account is based.
See [Country](#type-country) for possible values
creditablebooleanRequired within parentIndicates whether it is possible for Square to send money to this bank account.
currencyModelRequired within parentExpand Create Location — response body — location currency
The 3-character ISO 4217 currency code indicating the operating
currency of the bank account. For example, the currency code for US dollars
is `USD`.
See [Currency](#type-currency) for possible values
customer_idstringOptionalThe ID of the customer who owns the bank account
Read only: true
debit_mandate_reference_idJSONOptional
debit_mandate_reference_id (anyOf 1)stringAlternativeReference identifier that will be displayed to UK bank account owners
when collecting direct debit authorization. Only required for UK bank accounts.
debit_mandate_reference_id (anyOf 2)nullAlternative
debitablebooleanRequired within parentIndicates whether it is possible for Square to take money from this
bank account.
fingerprintJSONOptional
fingerprint (anyOf 1)stringAlternativeA Square-assigned, unique identifier for the bank account based on the
account information. The account fingerprint can be used to compare account
entries and determine if the they represent the same real-world bank account.
fingerprint (anyOf 2)nullAlternative
holder_namestringRequired within parentName of the account holder. This name must match the name
on the targeted bank account record.
Minimum length: 1
idstringRequired within parentThe unique, Square-issued identifier for the bank account.
Maximum length: 30
Minimum length: 1
location_idJSONOptional
location_id (anyOf 1)stringAlternativeThe location to which the bank account belongs.
location_id (anyOf 2)nullAlternative
primary_bank_identification_numberstringRequired within parentPrimary identifier for the bank. For more information, see
[Bank Accounts API](https://developer.squareup.com/docs/bank-accounts-api).
Maximum length: 40
reference_idJSONOptional
reference_id (anyOf 1)stringAlternativeClient-provided identifier for linking the banking account to an entity
in a third-party system (for example, a bank account number or a user identifier).
reference_id (anyOf 2)nullAlternative
secondary_bank_identification_numberJSONOptional
secondary_bank_identification_number (anyOf 1)stringAlternativeSecondary identifier for the bank. For more information, see
[Bank Accounts API](https://developer.squareup.com/docs/bank-accounts-api).
Maximum length: 40
secondary_bank_identification_number (anyOf 2)nullAlternative
statusstringRequired within parentIndicates the current verification status of a `BankAccount` object.
Read-only. The current verification status of this BankAccount object.
See [BankAccountStatus](#type-bankaccountstatus) for possible values
Known values: VERIFICATION_IN_PROGRESS, VERIFIED, DISABLED
versionJSONOptional
version (anyOf 1)integerAlternativeThe current version of the `BankAccount`.
version (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$

Referenced models: Create Location — response body — location country, Create Location — response body — location currency

Get Shift — response body — errors item
FieldTypePresenceDescription and constraints
$objectRootRepresents an error encountered during a request to the Connect API.

See [Handling errors](https://developer.squareup.com/docs/build-basics/handling-errors) for more information.
categorystringRequired within parentIndicates which high-level category of error has occurred during a
request to the Connect API.
The high-level category for the error.
See [ErrorCategory](#type-errorcategory) for possible values
Known values: API_ERROR, AUTHENTICATION_ERROR, INVALID_REQUEST_ERROR, RATE_LIMIT_ERROR, PAYMENT_METHOD_ERROR, REFUND_ERROR, MERCHANT_SUBSCRIPTION_ERROR, EXTERNAL_VENDOR_ERROR
codeModelRequired within parentExpand Get Shift — response body — errors item code
The specific code of the error.
See [ErrorCode](#type-errorcode) for possible values
detailstringOptionalA human-readable description of the error for debugging purposes.
fieldstringOptionalThe name of the field provided in the original request (if any) that
the error pertains to.

Referenced models: Get Shift — response body — errors item code

Create Location — response body — location country
FieldTypePresenceDescription and constraints
$stringRootIndicates the country associated with another entity, such as a business.
Values are in [ISO 3166-1-alpha-2 format](http://www.iso.org/iso/home/standards/country_codes.htm).
Known values: ZZ, AD, AE, AF, AG, AI, AL, AM, AO, AQ, AR, AS, AT, AU, AW, AX, AZ, BA, BB, BD, BE, BF, BG, BH, BI, BJ, BL, BM, BN, BO, BQ, BR, BS, BT, BV, BW, BY, BZ, CA, CC, CD, CF, CG, CH, CI, CK, CL, CM, CN, CO, CR, CU, CV, CW, CX, CY, CZ, DE, DJ, DK, DM, DO, DZ, EC, EE, EG, EH, ER, ES, ET, FI, FJ, FK, FM, FO, FR, GA, GB, GD, GE, GF, GG, GH, GI, GL, GM, GN, GP, GQ, GR, GS, GT, GU, GW, GY, HK, HM, HN, HR, HT, HU, ID, IE, IL, IM, IN, IO, IQ, IR, IS, IT, JE, JM, JO, JP, KE, KG, KH, KI, KM, KN, KP, KR, KW, KY, KZ, LA, LB, LC, LI, LK, LR, LS, LT, LU, LV, LY, MA, MC, MD, ME, MF, MG, MH, MK, ML, MM, MN, MO, MP, MQ, MR, MS, MT, MU, MV, MW, MX, MY, MZ, NA, NC, NE, NF, NG, NI, NL, NO, NP, NR, NU, NZ, OM, PA, PE, PF, PG, PH, PK, PL, PM, PN, PR, PS, PT, PW, PY, QA, RE, RO, RS, RU, RW, SA, SB, SC, SD, SE, SG, SH, SI, SJ, SK, SL, SM, SN, SO, SR, SS, ST, SV, SX, SY, SZ, TC, TD, TF, TG, TH, TJ, TK, TL, TM, TN, TO, TR, TT, TV, TW, TZ, UA, UG, UM, US, UY, UZ, VA, VC, VE, VG, VI, VN, VU, WF, WS, YE, YT, ZA, ZM, ZW
Create Location — response body — location currency
FieldTypePresenceDescription and constraints
$stringRootIndicates the associated currency for an amount of money. Values correspond
to [ISO 4217](https://wikipedia.org/wiki/ISO_4217).
Known values: UNKNOWN_CURRENCY, AED, AFN, ALL, AMD, ANG, AOA, ARS, AUD, AWG, AZN, BAM, BBD, BDT, BGN, BHD, BIF, BMD, BND, BOB, BOV, BRL, BSD, BTN, BWP, BYR, BZD, CAD, CDF, CHE, CHF, CHW, CLF, CLP, CNY, COP, COU, CRC, CUC, CUP, CVE, CZK, DJF, DKK, DOP, DZD, EGP, ERN, ETB, EUR, FJD, FKP, GBP, GEL, GHS, GIP, GMD, GNF, GTQ, GYD, HKD, HNL, HRK, HTG, HUF, IDR, ILS, INR, IQD, IRR, ISK, JMD, JOD, JPY, KES, KGS, KHR, KMF, KPW, KRW, KWD, KYD, KZT, LAK, LBP, LKR, LRD, LSL, LTL, LVL, LYD, MAD, MDL, MGA, MKD, MMK, MNT, MOP, MRO, MUR, MVR, MWK, MXN, MXV, MYR, MZN, NAD, NGN, NIO, NOK, NPR, NZD, OMR, PAB, PEN, PGK, PHP, PKR, PLN, PYG, QAR, RON, RSD, RUB, RWF, SAR, SBD, SCR, SDG, SEK, SGD, SHP, SLL, SLE, SOS, SRD, SSP, STD, SVC, SYP, SZL, THB, TJS, TMT, TND, TOP, TRY, TTD, TWD, TZS, UAH, UGX, USD, USN, USS, UYI, UYU, UZS, VEF, VND, VUV, WST, XAF, XAG, XAU, XBA, XBB, XBC, XBD, XCD, XDR, XOF, XPD, XPF, XPT, XTS, XXX, YER, ZAR, ZMK, ZMW, BTC, XUS

SDK function policy ID: square.getbankaccountbyv1id. Catalog operation: GetBankAccountByV1Id. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.

Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.

Required provider scopes: ["BANK_ACCOUNTS_READ"]

Pinned headers: {"Square-Version": "2026-11-18"}

Official provider source

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand how our website, product, and documentation are used.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

Advertising

Shares visits and sign-ups with Meta, Reddit, and X so we can measure which of our ads work.

You can change these choices at any time from Cookie settings.