> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.paywithatoa.co.uk/llms.txt
> Use this file to discover all available pages before exploring further.

# Fetch Account Details

> Retrieve account details via the Atoa Bank Feed API, request parameters, response schema and code samples in cURL, Python, JavaScript, PHP, Go and Java.

Use this to fetch basic information about a linked bank account.

### Authorization

Bearer `<token>`

**Request Body Schema**

<ParamField path="accountId" type="string" required>
  ID of the user's bank account. This can be obtained from the redirect URL
  after account linking or by using the [Fetch All Accounts API
  Reference](/api-reference/AccountInitiationServices/fetch-all-accounts)
  endpoint.

  Refer:- [Accounts](/accounts)
</ParamField>

**Response**

<ResponseField name="accountId" type="string">
  The ID of the user's bank account from the bank.
</ResponseField>

<ResponseField name="bankName" type="string">
  The name of the bank associated with the account. Useful for display purposes
  or internal logging.
</ResponseField>

<ResponseField name="accountNumber" type="string">
  The bank account number for which the user has provided consent.
</ResponseField>

<ResponseField name="sortCode" type="string">
  The sort code linked to the bank account.
</ResponseField>

<ResponseExample>
  ```json 200 theme={null}
  {
    "accountId": "7d4c6e07-78e6-4ad4-8b08-7ac183a5e750",
    "bankName": "mock-sandbox-v1",
    "accountNumber": "50978130",
    "sortCode": "726908"
  }
  ```

  ```json 401 theme={null}
  {
    "name": "UNAUTHORIZED",
    "message": "Unauthorized",
    "status": 401,
    "errors": "[]"
  }
  ```

  ```json 404 theme={null}
  {
    "name": "NOT FOUND",
    "message": "Consent not found",
    "status": 404,
    "errors": "[]"
  }
  ```
</ResponseExample>
