Skip to content

Convert a Quote to an Order

The customer accepted a quote. This recipe covers what happens next: order creation, payment processing, entitlement creation, and how to verify the entire chain completed.

Prerequisites

  • A quote exists with status accepted (the customer accepted it in the portal).
  • The Organization's billing entity and Stripe account are configured.
  • The WooCommerce product(s) in the quote have an Entitlement Class assigned.

Steps

Part A: Verify order creation

Step 1. Go to MIDDAG Account > Quotes and open the accepted quote.

Step 2. Check the Linked Order field. When a customer accepts a quote, the system automatically creates a WooCommerce order from the quote's line items.

Step 3. If the Linked Order field shows an order number, click it to open the WooCommerce order. Verify:

  • Order items match the quote's line items.
  • The order is associated with the correct Organization.
  • The billing entity metadata is set (middag_br or middag_global).

Step 4. If no order was created, check MIDDAG Account > Logs for errors during the quote-to-order conversion. Common causes:

  • Product no longer exists or was moved to trash.
  • WooCommerce failed to create the order (stock, permissions, or plugin conflict).

To create the order manually: go to WooCommerce > Orders > Add Order, add the same line items, link it to the quote via the MIDDAG Account metadata box, and set the correct billing entity.

Part B: Payment processing

Step 5. After order creation, the customer is redirected to the payment page in the portal. Available payment methods depend on the billing entity:

EntityMethods available
MIDDAG BRCredit card (Stripe), Pix (Banco Inter), Boleto (Banco Inter)
MIDDAG GLOBALCredit card (Stripe)

Step 6. The customer completes payment. Confirmation arrives via webhook:

  • Credit card: Stripe fires payment_intent.succeeded.
  • Pix: Banco Inter fires a callback within 30 minutes of the QR code scan.
  • Boleto: Banco Inter fires a callback when the boleto is paid (up to 3 business days).

Step 7. To monitor payment status, go to WooCommerce > Orders and check the order status:

  • pending -- payment not yet received.
  • processing or completed -- payment confirmed.
  • failed -- payment attempt failed. Customer may retry.

Part C: Verify entitlement creation

Step 8. Once payment is confirmed, the system provisions the entitlement automatically. Go to MIDDAG Account > Entitlements.

Step 9. Search for the Organization or the order number. An entitlement should appear with:

  • Status: active.
  • Class matching the product(s) in the order.
  • Linked order pointing to the WooCommerce order.

Step 10. If the quote contained products from different Entitlement Classes, one entitlement is created per distinct class.

Part D: Verify the full chain

Step 11. Confirm the quote status progressed through the expected transitions:

draft -> sent -> viewed -> accepted -> paid -> fulfilled

Step 12. Confirm downstream resources exist based on the entitlement class. See Grant Access After Purchase, Part C, for detailed verification steps per class.

Step 13. If using HubSpot, check that the deal status in HubSpot was updated to reflect the accepted and paid quote. The sync happens automatically via webhook.

Expected result

  • The quote transitioned from accepted through paid to fulfilled.
  • A WooCommerce order was created and paid.
  • An entitlement with status active exists, with downstream resources provisioned.
  • HubSpot deal status is synced (if HubSpot integration is active).
  • The customer can see their new entitlement in the portal.

Further reading