> ## Documentation Index
> Fetch the complete documentation index at: https://docs.propaga.mx/llms.txt
> Use this file to discover all available pages before exploring further.

# Search multiple transactions by batch

> Gets the information of multiple transactions in a single request, using Propaga IDs and/or your own `wholesalerTransactionId`

Use this endpoint to look up several transactions at once, for example to sync their statuses with your system. You can search by Propaga's `transactionId`, by your `wholesalerTransactionId` (`externalIds`), or by both in the same request.

Only transactions that belong to the wholesaler of the `Authorization` token are returned. Any ID that does not match one of your transactions is listed in `notFound`, so you don't have to compare the lists yourself.

> [!NOTE]
>
> You can send up to **100** IDs in `transactionIds` and up to **100** IDs in `externalIds` per request. At least one of the two lists must have an ID. Repeated IDs are only searched once.

```bash Request theme={null}
curl --location --request POST 'https://staging-api.propaga.io/v1/transaction/batch/search' \
--header 'Authorization: <your_awesome_token>' \
--header 'Content-Type: application/json' \
--data '{
    "transactionIds": [
        "c4da2e20-4565-4ca7-8335-769eea1eaf70",
        "0f6b1c7e-9d3a-4f4b-8a51-2b7c9e1d4a10"
    ],
    "externalIds": [
        "TRAN-3245",
        "TRAN-9999"
    ]
}'
```

```json Response theme={null}
{
    "transactions": [
        {
            "transactionId": "c4da2e20-4565-4ca7-8335-769eea1eaf70",
            "cornerStoreId": "22de359b-4743-4067-b389-1a128928dca5",
            "userId": "3030cb59-5238-441b-9064-51bad8c39816",
            "transactionStatus": "on-hold",
            "wholesalerTransactionId": "TRAN-3245",
            "movementDate": "2024-04-26T19:26:40.112Z",
            "totalAmount": 1462.4,
            "wholesalerFees": 0,
            "interests": 43.87,
            "IVAAmount": 7.02,
            "totalAmountWithInterests": 1513.29,
            "paymentDate": "2024-05-11T19:26:40.101Z",
            "deliveryDate": null,
            "products": [
                {
                    "id": "8ae071b7-8e44-4e8b-ac20-c5ed2d5d2476",
                    "externalSKU": "123",
                    "name": "Detergente Roma",
                    "quantity": 1,
                    "createdAt": "2024-04-26T20:26:40.664Z",
                    "updatedAt": "2024-04-26T20:26:40.664Z"
                }
            ],
            "metadata": {},
            "wholesaler": "<wholesaler_name>"
        }
    ],
    "notFound": {
        "transactionIds": ["0f6b1c7e-9d3a-4f4b-8a51-2b7c9e1d4a10"],
        "externalIds": ["TRAN-9999"]
    }
}
```

## Body

**transactionIds** `string[]`

Propaga's transaction IDs (UUID v4). Max 100.

**externalIds** `string[]`

Your transaction IDs, the ones you sent as `wholesalerTransactionId` when you created the transactions. Max 100.

## Response

**transactions** `array`

Transactions found, sorted from the most recent to the oldest. Each item has the same format as [Get transaction information by id](https://docs.propaga.mx/api-reference/transaction/get-transaction.md).

If one of your `externalIds` matches more than one transaction (for example, a cancelled one and a new one created with the same ID), all of them are returned.

**properties**

**transactionId** `string`

Propaga's transaction id

**cornerStoreId** `string`

Propaga's corner store id

**userId** `string`

Propaga's user id of the corner store

**transactionStatus** `string`

Current status for the transaction: `pending-verification`, `on-hold`, `delivery`, `paid`, `expired`, `cancel`, `rejected` or `in-dispute`

**wholesalerTransactionId** `string`

Wholesaler's transaction ID

**movementDate** `string`

Date and time of the creation of the transaction

**totalAmount** `number`

Total amount of the transaction

**wholesalerFees** `number`

Wholesaler fees amount

**interests** `number`

Interests amount

**IVAAmount** `number`

IVA amount

**totalAmountWithInterests** `number`

Total amount with interests

**paymentDate** `string`

Date and time of limit payment date

**deliveryDate** `string`

Date and time the order was delivered, `null` if it has not been delivered

**products** `array`

List of products in the transaction

**metadata** `json`

Any metadata saved for the transaction

**wholesaler** `string`

Wholesaler's name

**currency** `string`

Currency of the transaction. Only returned when it is not `MXN`

**notFound** `object`

IDs from the request that did not match any of your transactions

**properties**

**transactionIds** `string[]`

Propaga's transaction IDs that were not found

**externalIds** `string[]`

Your transaction IDs that were not found

## Error codes

```json No IDs sent (400) theme={null}
{
    "errorCode": "SEARCH_PARAMETERS_NOT_FOUND",
    "errorMessage": "Search parameters not found"
}
```

```json Invalid request (400) theme={null}
{
    "statusCode": 400,
    "message": [
        "transactionIds must contain no more than 100 elements",
        "each value in transactionIds must be a UUID"
    ],
    "error": "Bad Request"
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.