---
title: "Get encrypted bank details"
method: GET
path: "/bank_account_details/{customer_bank_account_id}"
tags: ["Bank Account Detail"]
---

# Get encrypted bank details

`GET /bank_account_details/{customer_bank_account_id}`

## Request

- Base URL: `https://api.gocardless.com`
- URL: `https://api.gocardless.com/bank_account_details/{customer_bank_account_id}`
- Auth: HTTP bearer

Returns bank account details in the flattened JSON Web Encryption format described in RFC 7516.

You must specify a `Gc-Key-Id` header when using this endpoint. See [Public Key Setup](https://docs.gocardless.com/docs/gc-embed/bank-details-access#public-key-setup) for more details.

<p class="restricted-notice"><strong>Restricted</strong>: This endpoint is restricted to organisations with the Encrypted Bank Details Access upgrade</p>

<p class="notice"><strong>Note</strong>: See our [Security Requirements](https://docs.gocardless.com/docs/api-reference/security-requirements) before using this feature</p>

## Path parameters

- `customer_bank_account_id` string, required

## Headers

- `GoCardless-Version` string, required

## Response `200`

Successful response

- BankAccountDetailSingleResourceResponse
  - `bank_account_details` BankAccountDetail: Retrieve bank account details in JWE encrypted format
    - `protected` string: Base64 URL encoded JWE header values, containing the following keys: - `alg`: the asymmetric encryption type used to encrypt symmetric key, e.g: `RSA-OAEP`. - `enc`: the content encryption type, e.g: `A256GCM`. - `kid`: the ID of an RSA-2048 public key, from your JWKS, used to encrypt the AES key.
    - `encrypted_key` string: Base64 URL encoded symmetric content encryption key, encrypted with the asymmetric key from your JWKS.
    - `iv` string: Base64 URL encoded initialization vector, used during content encryption.
    - `ciphertext` string: Base64 URL encoded encrypted payload, in this case bank details.
    - `tag` string: Base64 URL encoded authentication tag, used to verify payload integrity during decryption.

## Other responses

- `400`: Bad Request
- `401`: Unauthorised
- `404`: Not found
- `422`: Validation Error
- `500`: Internal Error

---

[API](https://skmtc.dev/gocardless/apis/gocardless-api.md) - [All operations](https://skmtc.dev/gocardless/apis/gocardless-api/llms.txt) - [OpenAPI document](https://skmtc.dev/gocardless/apis/gocardless-api/revisions/4dd3dae45364?raw)
