The connector only reads data. It never creates orders, payment links or charges in your Unbox store.
Configuring Unbox Pay as a Source
In the Sources tab, click on the “Add source” button located on the top right of your screen. Then, select the Unbox Pay option from the list of connectors. Click Next and you’ll be prompted to add your access.1. Add account access
The connector uses the Unbox Partner API. Its credentials are not generated in the Unbox panel: ask your Unbox contact (or Unbox support at ola@unbox.com.br) for access to the Partner API for your store. Unbox provides an API key and a username and password of a partner account linked to your store. The following configurations are available:-
API Key: The Partner API key (sent as
x-api-key) provided by Unbox. - Username: The username of the partner account of your store.
- Password: The password of that partner account.
- Start Date: (Optional) The earliest order creation date to extract. Leave it empty to extract every order of your store.
- Lookback Days: (Optional, default 30) On every sync, the orders created in this many days before the last synced order are read again. Unbox only lets the connector search orders by creation date, so this is how payments confirmed later (boleto, Pix) are updated. Orders whose payment is still open are also re-read on every sync, for up to 90 days, until their payment is confirmed, canceled or expires.
- Refunds Lookback Days: (Optional, default 180) On every sync, the orders created in this many days back (from today) whose payment was refunded, charged back or canceled are read again, even when they are older than the Lookback Days window. This keeps a payment reversed months after the order up to date, so a receivable already marked as received can be reopened. Set it to 0 to turn it off; the maximum is 730.
2. Select streams
Choose which data streams you want to sync. For faster extractions, select only the streams that are relevant to your analysis. You can select entire groups of streams or pick specific ones.Tip: The stream can be found more easily by typing its name.Select the streams and click Next.
3. Configure data streams
Customize how you want your data to appear in your catalog. Select the desired layer where the data will be placed, a folder to organize it inside the layer, a name for each table (which will effectively contain the fetched data) and the type of sync.- Layer: choose between the existing layers on your catalog. This is where you will find your new extracted tables as the extraction runs successfully.
- Folder: a folder can be created inside the selected layer to group all tables being created from this new data source.
- Table name: we suggest a name, but feel free to customize it. You have the option to add a prefix to all tables at once and make this process faster!
- Sync Type: you can choose between INCREMENTAL and FULL_TABLE.
- Incremental: every time the extraction happens, we’ll get only the new data, which is good if, for example, you want to keep every record ever fetched.
- Full table: every time the extraction happens, we’ll get the current state of the data, which is good if, for example, you don’t want to have deleted data in your catalog.
4. Configure data source
Describe your data source for easy identification within your organization, not exceeding 140 characters. To define your Trigger, consider how often you want data to be extracted from this source. This decision usually depends on how frequently you need the new table data updated (every day, once a week, or only at specific times). Optionally, you can define some additional settings:- Configure Delta Log Retention and determine for how long we should store old states of this table as it gets updated. Read more about this resource here.
- Determine when to execute an Additional Full Sync. This will complement the incremental data extractions, ensuring that your data is completely synchronized with your source every once in a while. A periodic full sync also picks up refunds and chargebacks older than the Refunds Lookback Days. On a full sync (and on the first sync) the connector reads every order before loading anything, so if the sync fails midway your tables keep their previous data instead of being replaced by a partial copy.
5. Check your new source
You can view your new source on the Sources page. If needed, manually trigger the source extraction by clicking on the arrow button. Once executed, your data will appear in your Catalog.Streams and Fields
Available streams
The table below lists every stream, its slug (the exact identifier to pass when creating the source via API) and a short description.Fields by stream
Orders
Orders
One row per order, updated incrementally by its creation date (see Lookback Days).Identification and status:
id- Internal identifier of the orderreference_id- Public order number shown to the buyerstatus- Order status (CANCELED,COMPLETED,FAILED,PENDING,PROCESSING,REFUNDED)source- Channel of the order (STOREFRONT,CART_TEMPLATE,PAYMENT_LINK)created_at- When the order was created, UTC (incremental key)updated_at- When the order was last updated, UTC
email- E-mail entered on the orderbuyer_name,buyer_tax_payer_id,buyer_is_company- Name and CPF or CNPJ of the buyer, from the billing address of the payment (or the delivery address)account_id,account_name,account_email,account_external_id- Buyer’s account in the store, when the order is linked to one
total- Total charged for the orderitem_total,discount_total,total_savings,fulfillment_total,tax_total,surcharge_total,total_without_discounts- Order totalsinstallment_amount,interest,total_before_interest- Installment details, when the order was paid in installmentscurrency- Currency (for example,BRL)
payments_count- Number of payments of the orderpayment_status- Current status of the most recent paymentpayment_method- Method of the most recent payment (unboxpay_credit,unboxpay_boleto,unboxpay_pix)payment_transaction_id- Transaction id of the most recent paymentpaid_at- First moment a payment of the order was confirmed (PAIDorCAPTURED), UTCpaid_amount- Sum of the payments currentlyPAIDorCAPTURED
invoice_issued,sent_to_erp,sent_to_lp,sold_to_company,is_boleto_paid- Invoice, ERP, logistics and boleto flagsdispatched,delivered,problem_delivering,shipping_label_pending,shipping_label_failed- Delivery flags
payment_link_id,payment_link_reference_id,payment_link_external_id,payment_link_title- Payment link that originated the orderrecurring_order_id,recurring_order_cycle_id,recurring_order_frequency_id,generated_new_recurring_order- Subscription that generated the ordercart_id- Cart the order came fromtotal_item_quantity- Sum of item quantities
payments- Payments as returned by Unbox, with status history and billing addressdiscounts,fulfillment_groups,invoices,shop_sales,surcharges,notes- Other details of the order
Order Payments
Order Payments
One row per payment of an order.
order_id,payment_id- Order and payment (together they identify the row); joinorder_idtoorders.idorder_reference_id,order_status,order_created_at- Order number, status and creation date (incremental key)transaction_id- Transaction id at Unbox Pay, to match the Unbox Pay statementamount,currency- Gross amount charged to the buyer, including installment interestmethod_name,method_display_name,method_plugin_name,display_name,processor,mode- Payment method detailsstatus,status_at,status_created_by,status_triggered_by- Current status and when it was reachedpaid_at- First moment the payment was confirmed (PAIDorCAPTURED), UTCauthorized_at,canceled_at,refunded_at,charged_back_at,expired_at,failed_at- First moment the payment reached each status, UTCstatus_history- Every status change as JSON textcard_brand,is_captured,is_authorization_canceled,capture_error_code,capture_error_message,risk_level,took_loss_on_sale- Card and anti-fraud detailsbilling_full_name,billing_tax_payer_id,billing_is_commercial,billing_phone,billing_city,billing_region,billing_postal- Payer from the billing addressorder_total,order_installment_amount,order_interest- Order amountscreated_at- When the payment was created, UTC
Order Items
Order Items
One row per item of an order.
order_id,fulfillment_group_id,item_id- Order, delivery group and item (together they identify the row)order_reference_id,order_created_at- Order number and creation date (incremental key)title,variant_title,option_title- Product, variant and option titlesproduct_id,product_variant_id,product_erp_code,variant_erp_code,product_slug,product_type,product_vendor- Product identifiersquantity,price,original_price,subtotal,tax,currency- Quantity and amountsstatus,cancel_reason- Item statusis_recurring,is_discounted_bonus_item,is_taxable,tax_code- Item flagsattributes- Item attributes as JSON textadded_at,created_at,updated_at- Item dates, UTC
Payment Links
Payment Links
One row per payment link. Read in full on every sync.
id,reference_id,external_id- Identifiers of the link (external_idis the id your system gave the link)type,title,description,status,is_sold_out,is_expired- Link detailsorders_count- Number of orders placed through the linktotal_amount,currency,shipping_value,fulfillment_type,payment_method- Amounts and payment settingsbuyer_types,usage_limit,expiration_date- Restrictions of the linkblock_payment_method_change,block_apply_discount_code,block_apply_shop_sale- Checkout restrictionsitems- Items of the link as JSON textcreated_at,updated_at,created_by,updated_by- Audit fields
Subscriptions
Subscriptions
One row per subscription. Read in full on every sync.
id,reference_id- Identifiers of the subscription; orders it generates carryidinorders.recurring_order_idcustomer_account_id,unbox_pay_customer_id- Customer of the subscriptionstatus,status_at,status_triggered_by,status_history- Status (ACTIVE,CANCELED,PAUSED,ERROR) and its historyfrequency_id,frequency_title,frequency_periodicity,frequency_interval- Frequencypricing_policy_type,pricing_policy_value- Price policy of the cyclescycle_count,skip_next_cycle,last_cycle_date,next_cycle_date- Cyclesdiscount_id,discount_code- Discount of the subscriptiontotal_amount,currency- Estimate of the next cycle amount (the amount actually charged is on the generated order)items- Items of each new cycle as JSON textcreated_at,updated_at- Dates, UTC
Implementation Notes
Data Quality Considerations
- Amounts are the gross amounts charged to the buyer. Unbox Pay fees, net amounts and release dates are not available through the API.
paid_atcomes from the payment status history: the first time the payment reachedPAIDorCAPTURED. It is the date the buyer paid, not the date the money is credited to your bank account.- Refunds, chargebacks and cancellations are picked up for orders created in the last Refunds Lookback Days (180 by default). Older ones need a full sync.
order_payments.payment_idandorder_items.item_idare the ids Unbox gives each payment and item. If Unbox ever omits one, the payment’s transaction id is used, and otherwise the position in the order (<order id>:<position>).- If an older order with an open payment can no longer be read from Unbox, it stops being refreshed and the sync log shows a warning.
API Limits & Performance
- Orders are read in pages of 50 (smaller pages when Unbox is slow), in 15-day periods. The first sync of a store with a long history takes longer; later syncs only read the lookback window plus the orders with an open payment.
- Unbox does not publish its rate limit. The connector makes at most about 4 requests per second and waits when Unbox asks it to slow down.