v1
latestOpenAPI 3.1.02026-08-04170116.0 KBData In
Create Order Record
Ingest order data into Triple Whale for Custom Sales Platforms. This endpoint allows users to upload detailed order information, including customer details, product information, transaction totals, discounts, refunds, and shipping details.
post/data-in/orders
Request body
Example request
{
"shop": "madisonbraids.myshopify.com",
"order_id": "order_12345",
"platform": "magento",
"platform_account_id": "shop_account_123",
"created_at": "2022-06-15T19:26:30.000Z",
"currency": "USD",
"customer": {
"id": "customer_123",
"email": "customer@example.com",
"phone": "+1234567890",
"first_name": "John",
"last_name": "Doe"
},
"custom_expenses": 25,
"is_new_customer": true,
"discount_codes": [
{
"code": "BLACKFRIDAY",
"amount": 15.5,
"type": "percentage"
}
],
"line_items": [
{
"id": "line_item_1",
"name": "Line Item 1",
"price": 20,
"quantity": 2,
"product_id": "product_123",
"product_name": "T-shirt",
"variant_id": "variant_456",
"variant_name": "Red T-shirt (Large)",
"sku": "sku_123"
}
],
"name": "Order #12345",
"payment_gateway_names": [
"paypal"
],
"refunds": [
{
"refund_id": "refund_1",
"refunded_at": "2024-11-29T11:00:00Z",
"line_items": [
{
"id": "line_item_1",
"line_item_id": "line_item_1",
"quantity": 1,
"product_id": "product_123",
"variant_id": "variant_456",
"price": 20,
"currency": "USD"
}
],
"total_refund": 40,
"total_tax_refund": 3,
"total_shipping_refund": 5,
"tags": [
"damaged_item"
]
}
],
"shipping_address": {
"address_1": "123 Main Street",
"address_2": "Apt 4B",
"zip": "10001",
"city": "New York",
"country": "USA",
"country_code": "US",
"province_code": "NY"
},
"shipping_lines": [
{
"shipping_discounted_price": 5,
"shipping_price": 10,
"source": "standard_shipping",
"title": "Standard Shipping"
}
],
"shipping_price": 15,
"shipping_costs": 15,
"source_name": "web",
"subscription_id": "sub_12345",
"tags": [
"holiday_sale",
"staff_order"
],
"order_revenue": 150.75,
"total_discounts": 15.5,
"taxes": 8.25,
"status": "completed",
"updated_at": "2024-11-29T10:00:00Z"
}Response
Order record successfully received.
Example response
{
"success": true,
"message": "Order received"
}