# GetBatchSearchDetail

Returns the batch search details using ID.

`GET /trading-partners/batch-searches/{id}`

**API:** Avalara E-Invoicing API
**Tag:** Trading Partners
**API Version:** 1.2
**Base URL:** https://api.sbx.avalara.com/einvoicing
**Authentication:** Bearer token

Source: https://developer.avalara.com/products/e-invoicing/api/v1.2/methods/Trading%20Partners/GetBatchSearchDetail/

## Description

This endpoint returns detailed information for a specific batch search using the provided ID. It is useful for tracking the status and progress of a previously initiated batch search operation.

## Parameters

| Name | Type | In | Required | Description |
|---|---|---|---|---|
| `avalara-version` | string | header | Yes | The HTTP Header meant to specify the version of the API intended to be used. |
| `id` | string | path | Yes | The ID of the batch search that was submitted earlier. |
| `X-Avalara-Client` | string | header | No | You can freely use any text you wish for this value. This feature can help you diagnose and solve problems with your software. The header can be treated like a "Fingerprint". |
| `X-Correlation-ID` | string | header | No | The caller can use this as an identifier to use as a correlation id to trace the call. |

## Responses

| Status | Description | Schema |
|---|---|---|
| 200 | The batch search details for a given ID. | `BatchSearch` |
| 401 | Unauthorized | `BatchSearchListResponse` |
| 403 | Forbidden | `ErrorResponse` |
| 404 | Report not found | `ErrorResponse` |
| 500 | Internal server error | `ErrorResponse` |

### 200 Response: `BatchSearch`

Represents a single batch search operation

| Property | Type | Required | Description |
|---|---|---|---|
| `id` | string | No | ID of the batch search |
| `name` | string | No | Name of the batch report |
| `createdBy` | string | No | Email of the user who created the batch search |
| `created` | string | No | Timestamp when the batch search was created |
| `lastModified` | string | No | Timestamp when the batch search was created |
| `status` | string | No | Status of the batch search Values: `Accepted`, `Running`, `Completed`, `Failed`. |
| `error` | ErrorResponse | No |  |

## Example Request

```bash
curl -X GET "https://api.sbx.avalara.com/einvoicing/trading-partners/batch-searches/{id}" \
  -H "Authorization: Basic <credentials>" \
  -H "Accept: application/json"
```