Search Orders

Search for all Orders placed through your application given certain filter critera.

This endpoint will only return completed orders by default (no carts). However it is possible to use this endpoint as a "Search Carts" endpoint by combining two parameters. If you wish to include IN_PROGRESS orders AKA carts you can set the exclude_in_progress query param to false.

If you want to use order search to only search for IN_PROGRESS orders, that is to say, searching for carts, you can include the the following query in your search body: {"bag_status": "IN_PROGRESS"}. You must still set exclude_in_progress to false in this case.

Search Orders

post
Query parameters
pageinteger · int32OptionalDefault: 1
sizeinteger · int32OptionalDefault: 20
extendedbooleanOptionalDefault: false
exclude_in_progressbooleanOptionalDefault: true
includestringOptional
Header parameters
X-Violet-TokenstringRequired
X-Violet-App-SecretstringRequired
X-Violet-App-Idinteger · int32Required
Body

Order Search Request

user_idinteger · int64Optional

User ID

order_idinteger · int64Optional

Order ID

referral_idstringOptional

Referral ID

bag_idinteger · int64Optional

Bag ID

bag_statusstring · enumOptional

Bag Status

Possible values:
merchant_idinteger · int32Optional

Merchant ID

before_datestring · date-timeOptionalDeprecated

Use date_created:max.

after_datestring · date-timeOptionalDeprecated

Use date_created:min.

app_order_idstringOptional

Order ID in the Channels System

customer_namestringOptional

Full customer name to search by - case insensitive.

customer_emailstringOptional

Customer email to search by - case insensitive.

sku_namestringOptional

Name of an Sku present in the order - case insensitive.

totalinteger · int32Optional

Exact total to search.

statusstring · enumOptional

Order status to search.

Possible values:
sort_bystringOptional

Order property to sort by in camel case.

sort_directionstringOptional

Direction to sort results by.

date_last_modified:minstring · date-timeOptional

Only include orders modified after this date.

Pattern: yyyy-MM-dd'T'HH:mm:ssZ
date_last_modified:maxstring · date-timeOptional

Only include orders modified before this date.

Pattern: yyyy-MM-dd'T'HH:mm:ssZ
date_created:minstring · date-timeOptional

Only include orders created after this date.

Pattern: yyyy-MM-dd'T'HH:mm:ssZ
date_created:maxstring · date-timeOptional

Only include orders created before this date.

Pattern: yyyy-MM-dd'T'HH:mm:ssZ
date_submitted:minstring · date-timeOptional

Only include orders submitted after this date.

Pattern: yyyy-MM-dd'T'HH:mm:ssZ
date_submitted:maxstring · date-timeOptional

Only include orders submitted before this date.

Pattern: yyyy-MM-dd'T'HH:mm:ssZ
Responses
default
default response
application/json
post
POST /v1/orders/search HTTP/1.1
Host: sandbox-api.violet.io
X-Violet-Token: text
X-Violet-App-Secret: text
X-Violet-App-Id: 1
Content-Type: application/json
Accept: */*
Content-Length: 554

{
  "user_id": 1,
  "order_id": 1,
  "referral_id": "text",
  "bag_id": 1,
  "bag_status": "IN_PROGRESS",
  "merchant_id": 1,
  "app_order_id": "text",
  "customer_name": "text",
  "customer_email": "text",
  "sku_name": "text",
  "total": 1,
  "status": "IN_PROGRESS",
  "sort_by": "text",
  "sort_direction": "text",
  "date_last_modified:min": "2025-07-10T03:24:16.582Z",
  "date_last_modified:max": "2025-07-10T03:24:16.582Z",
  "date_created:min": "2025-07-10T03:24:16.582Z",
  "date_created:max": "2025-07-10T03:24:16.582Z",
  "date_submitted:min": "2025-07-10T03:24:16.582Z",
  "date_submitted:max": "2025-07-10T03:24:16.582Z"
}
default

default response

{
  "content": [
    {
      "id": 1,
      "errors": [
        {
          "id": 1,
          "order_id": 1,
          "bag_id": 1,
          "entity_id": "text",
          "entity_type": "ORDER",
          "type": "EXTERNAL_CREATE_CART",
          "message": "text",
          "date_created": "2025-07-10T03:24:16.582Z",
          "platform": "OTHER"
        }
      ],
      "app_id": 1,
      "developer_id": 1,
      "customer": {
        "first_name": "text",
        "last_name": "text",
        "email": "text",
        "shipping_address": {
          "name": "text",
          "city": "text",
          "state": "text",
          "country": "text",
          "postal_code": "text",
          "phone": "text",
          "type": "SHIPPING",
          "email": "text",
          "address_1": "text",
          "address_2": "text",
          "first_name": "text",
          "last_name": "text"
        },
        "billing_address": {
          "name": "text",
          "city": "text",
          "state": "text",
          "country": "text",
          "postal_code": "text",
          "phone": "text",
          "type": "SHIPPING",
          "email": "text",
          "address_1": "text",
          "address_2": "text",
          "first_name": "text",
          "last_name": "text"
        },
        "same_address": false,
        "name": "text"
      },
      "bags": [
        {
          "id": 1,
          "order_id": 1,
          "merchant_id": 1,
          "app_id": 1,
          "external_id": "text",
          "external_reference_id": "text",
          "status": "IN_PROGRESS",
          "fulfillment_status": "PROCESSING",
          "financial_status": "UNPAID",
          "dispute_status": "UNDISPUTED",
          "skus": [
            {
              "id": 1,
              "offer_id": 1,
              "merchant_id": 1,
              "app_id": 1,
              "sku_id": 1,
              "external_id": "text",
              "name": "text",
              "brand": "text",
              "thumbnail": "text",
              "quantity": 1,
              "price": 1,
              "weight": 1,
              "height": 1,
              "width": 1,
              "length": 1,
              "available": true,
              "status": "IN_PROGRESS",
              "product_type": "PHYSICAL",
              "custom": true,
              "custom_properties": [
                {
                  "name": "engraving",
                  "value": "Happy Birthday!"
                }
              ],
              "quantity_fulfilled": 1,
              "rates": [
                {
                  "order_sku_id": 1,
                  "amount": 1,
                  "rate": 1,
                  "type": "TAX",
                  "name": "text",
                  "decimal_rate": 1,
                  "dollar_amount": 1
                }
              ],
              "line_price": 1
            }
          ],
          "shipping_method": {
            "type": "CALCULATED",
            "Carrier": "OTHER",
            "label": "text",
            "price": 1,
            "custom": true,
            "min_subtotal": 1,
            "max_subtotal": 1,
            "min_weight": 1,
            "max_weight": 1,
            "external_id": "text",
            "id": 1,
            "shipping_method_id": "text",
            "bag_id": 1,
            "merchant_id": 1
          },
          "taxes": [
            {
              "order_id": 1,
              "merchant_id": 1,
              "skus": [
                "text"
              ],
              "state": "text",
              "postal_code": "text",
              "rate": 1,
              "amount": 1,
              "description": "text"
            }
          ],
          "sub_total": 1,
          "shipping_total": 1,
          "tax_total": 1,
          "discount_total": 1,
          "total": 1,
          "taxes_included": false,
          "external_checkout": true,
          "commission_rate": 1,
          "date_created": "2025-07-10T03:24:16.582Z",
          "date_last_modified": "2025-07-10T03:24:16.582Z",
          "date_last_consolidated": "2025-07-10T03:24:16.582Z",
          "date_submitted": "2025-07-10T03:24:16.582Z",
          "remorse_period_ends": "2025-07-10T03:24:16.582Z",
          "currency": "text",
          "external_currency": "text",
          "currency_exchange_rate": 1,
          "channel": "APP",
          "app_order_id": "text",
          "platform": "OTHER",
          "fulfillments": [
            {
              "id": 1,
              "bag_id": 1,
              "external_id": "text",
              "carrier": "OTHER",
              "raw_carrier": "text",
              "status": "PENDING",
              "carrier_status": "PENDING",
              "tracking_number": "text",
              "tracking_url": "text",
              "skus": [
                {
                  "id": 1,
                  "fulfillment_id": 1,
                  "order_sku_id": 1,
                  "quantity_fulfilled": 1
                }
              ]
            }
          ],
          "discounts": [
            {
              "id": 1,
              "bag_id": 1,
              "status": "PENDING",
              "type": "CODE",
              "value_type": "AMOUNT",
              "target_type": "ORDER",
              "code": "text",
              "external_id": "text",
              "amount": 1,
              "percentage": 1,
              "amount_total": 1,
              "date_created": "2025-07-10T03:24:16.582Z",
              "date_last_modified": "2025-07-10T03:24:16.582Z",
              "email": "text"
            }
          ],
          "wallet_based_checkout": false,
          "app_name": "text",
          "bag_id": 1,
          "bag_status": "IN_PROGRESS",
          "merchant_name": "text"
        }
      ],
      "shipping_address": {
        "name": "text",
        "city": "text",
        "state": "text",
        "country": "text",
        "postal_code": "text",
        "phone": "text",
        "type": "SHIPPING",
        "email": "text",
        "address_1": "text",
        "address_2": "text",
        "first_name": "text",
        "last_name": "text"
      },
      "billing_address": {
        "name": "text",
        "city": "text",
        "state": "text",
        "country": "text",
        "postal_code": "text",
        "phone": "text",
        "type": "SHIPPING",
        "email": "text",
        "address_1": "text",
        "address_2": "text",
        "first_name": "text",
        "last_name": "text"
      },
      "payment_method": {
        "brand": "text",
        "last_four": "text",
        "exp_month": 1,
        "exp_year": 1,
        "cardholder_name": "text",
        "payment_method_id": 1,
        "default": true
      },
      "sub_total": 0,
      "shipping_total": 0,
      "tax_total": 0,
      "discount_total": 0,
      "total": 0,
      "app_customer_id": "text",
      "app_order_id": "text",
      "status": "IN_PROGRESS",
      "is_guest": true,
      "date_created": "2025-07-10T03:24:16.582Z",
      "date_last_modified": "2025-07-10T03:24:16.582Z",
      "date_submitted": "2025-07-10T03:24:16.582Z",
      "priced": false,
      "wallet_based_checkout": false,
      "currency": "USD",
      "referral_id": "text",
      "currency_symbol": "text",
      "app_name": "text",
      "stripe_key": "text",
      "payment_intent_client_secret": "text",
      "payment_transactions": [
        {
          "id": 1,
          "order_id": 1,
          "payment_provider": "text",
          "payment_provider_transaction_id": "text",
          "payment_method_id": 1,
          "payment_provider_payment_method_id": "text",
          "payment_intent_client_secret": "text",
          "amount": 1,
          "currency": "text",
          "capture_status": "PROCESSING",
          "capture_method": "AUTOMATIC",
          "transfer_status": "SENT",
          "transfer_method": "AUTOMATIC",
          "metadata": {
            "ANY_ADDITIONAL_PROPERTY": {}
          },
          "related_bags": [
            "text"
          ],
          "related_refunds": [
            "text"
          ],
          "errors": [
            {
              "id": 1,
              "error_code": 1,
              "error_message": "text",
              "resolved": true,
              "date_resolved": "2025-07-10T03:24:16.582Z",
              "date_created": "2025-07-10T03:24:16.582Z",
              "payment_transaction_id": 1
            }
          ],
          "date_created": "2025-07-10T03:24:16.582Z",
          "date_last_modified": "2025-07-10T03:24:16.582Z",
          "status": "PROCESSING"
        }
      ],
      "order_id": 1,
      "guest": true,
      "order_status": "IN_PROGRESS",
      "intent_based_checkout": true
    }
  ],
  "last": true,
  "total_pages": 1,
  "total_elements": 1,
  "first": true,
  "number_of_elements": 1,
  "size": 1,
  "number": 1,
  "empty": true,
  "next_page_cursor": "text",
  "pageable": {
    "page_number": 1,
    "page_size": 1,
    "sort": {
      "unsorted": true,
      "sorted": true,
      "empty": true
    },
    "offset": 1,
    "paged": true,
    "unpaged": true
  },
  "sort": {
    "unsorted": true,
    "sorted": true,
    "empty": true
  }
}

Last updated

Was this helpful?