# Search Account Overdraft

This API endpoint allows users to search for existing account overdraft information by passing the overdraft `id` to the request query. It retrieves details related to account overdrafts, including current status, limits, and fee amounts. The search operation provides users with the necessary information to manage account overdrafts and make informed decisions.

<mark style="color:blue;">`GET`</mark> `/api/AccountOverdraft/v1/Search`<br>

The `status` value for overdraft is: Inactive = 1, Active = 2, Disabled = 3, Pending = 4, Expired = 5

**Headers**

| Name                                            | Value                |
| ----------------------------------------------- | -------------------- |
| Content-Type<mark style="color:red;">\*</mark>  | `application/json`   |
| Authorization<mark style="color:red;">\*</mark> | `Bearer <token>`     |
| Request-Reference                               | `{unique-reference}` |

**Query Parameter**

<table><thead><tr><th width="185">Name</th><th width="173">Data Type (length)</th><th width="104" data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td><code>accountName</code></td><td>string</td><td>true</td><td>The customer's account overdraft name</td></tr></tbody></table>

Here is an example request and response with a sample payload sent to the endpoint in Curl format.

<details>

<summary>Sample Request</summary>

```json
curl --location -g '{{baseurl}}/api/AccountOverdraft/v1/Search?AccountNumber=1000002993&AccountName=Test&ProductCode=001&OverdraftStatus=2&SecurityType=2&StartDate=2022-01-01&EndDate=2022-03-20&PageNumber=1&PageSize=10&SortColumn=DateCreated&Direction=asc' \
--header 'Authorization: bearer {token}' \
--header 'request-reference: {unique_reference}' \
--header 'Content-Type: application/json' \
--data ''
```

</details>

<details>

<summary>Respose: <code>200</code></summary>

```json
{
  "status": true,
  "message": "string",
  "data": {
    "data": [
      {
        "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
        "accountNumber": "string",
        "accountName": "string",
        "productName": "string",
        "limit": 0,
        "tenure": 0,
        "dateCreated": "2023-01-29T15:00:25.475Z",
        "commencementDate": "2023-01-29T15:00:25.475Z",
        "maturityDate": "2023-01-29T15:00:25.475Z",
        "useDefaultFee": true,
        "feeCodes": [
          {
            "feeCode": "string"
          }
        ],
        "feeAmount": 0,
        "useDefaultInterest": true,
        "interestCode": "string",
        "interestAmount": 0,
        "securityPledged": true,
        "securityType": "string",
        "securityValuation": 0,
        "description": "string",
        "initiator": "string",
        "guarantorName": "string",
        "guarantorPhoneNumber": "string",
        "status": "string",
        "ledgerBalance": "string",
        "availableBalance": "string",
        "withdrawableBalance": "string"
      }
    ],
    "recordCount": 0
  }
}
```

</details>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.udara360.io/udara360-docs-1/overdrafts-and-loans/markdown/search-account-overdraft.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
