---
updatedAt: 2025-11-25T03:45:54.000Z
agentTools:
  projectIndex: https://docs.getorbital.com/llms.txt
---

# 3. Invoice API: Accept Fiat with Stablecoin Conversion

```shell Invoice API
{
   "externalId": "Invoice-003",
   "currency": "USDT",
   "mainCurrency": "TRX",
   "targetAmount": "100",
   "targetCurrency": "USD",
   "firstName": "John",
   "lastName": "Doe",
   "dateOfBirth": "1990-01-23",
   "identificationType": "customerId",
   "customerId": "UniqueCustomerIDfromMerchant"
}

```

```json Response Example
{
    "status": "success",
    "data": {
        "status": "initiated",
        "type": "deposit",
        "subType": "invoice",
        "id": "3684dda9-a4ab-46ad-9fe8-ab75b960b722",
        "sourceCurrency": "USDT",
        "sourceAmount": "100.04",
        "targetCurrency": "USD",
        "targetAmount": "100",
        "mainCurrency": "TRX",
        "merchantId": "SB-010318",
        "invoiceCreated": "2025-11-11T12:14:55.000Z",
        "invoiceExpires": "2025-11-11T13:14:55.000Z",
        "address": "TTdS476RtbX14Wn5Jei6TuDB3D1dHBwsCM",
        "addressId": "6a768763-2c52-4c95-9741-bafc8439adaf",
        "redirectUrl": null,
        "rates": [
            {
                "ticker": "USD_USDT",
                "amount": "100",
                "price": "100.030009",
                "rate": "1.00030009"
            }
        ],
        "fees": [],
        "mode": "lenient",
        "firstName": "John",
        "lastName": "Doe",
        "identificationType": "customerId",
        "dateOfBirth": "1990-01-23",
        "customerId": "UniqueCustomerIDfromMerchant",
        "personType": "naturalPerson"
    },
    "message": "Invoice payment created successfully."
}

```

# A merchant is collecting 100 USD for a service and instructs the customer to pay the equivalent amount using the USDT stablecoin.

<!-- shell@ -->

**What happens:**

- Merchant creates an invoice specifying the Target Currency (USD) and Target Amount (100).
- API calculates the required crypto equivalent based on the current rate (e.g., 100 USD is approximately 100.04 USDT).
- Customer receives payment instructions for the calculated crypto amount (100.04 USDT).
- Customer pays the required crypto amount.
- Merchant is credited the exact 100 USD in their account.