Fields
Needs FFL orders: Read and write, a permission of FFL Checkout stores. An FFL order is one fact about one of your orders: the dealer the buyer chose, and later whether the transfer happened. Your own system keeps the order.
| Field | Type | Rule |
|---|---|---|
| refrequired | string | Your own order number, kept as sent: the number you complete and read the order by. Up to 64 letters, digits, dots, underscores, colons and hyphens, starting with a letter or a digit. A WooCommerce order key (it starts wc_) is refused: it is the secret that opens a guest's order page. |
| dealer_license_numberoptional | string | The licence number of the dealer the buyer chose, in any form, up to 32 characters: the license_number or license_key from GET /dealers/search. |
| dealer_snapshotoptional | object | What the buyer saw of the dealer: business_name (up to 255 characters), address (512) and expires (32). Anything else is dropped, so no buyer data is kept. |
| optionoptional | string | dealer, the default: the buyer chose a dealer. deferred: the buyer will name one later. |
- The first report answers
201and is announced asffl_selection.captured. - Safe to repeat. The same
refagain answers200: the dealer is refreshed (the buyer may have changed it before the order settled), the status is kept, and nothing is announced again. - A dealer the registry does not know is recorded all the same, with
dealer_resolvedfalse. - Then report the transfer with POST /ffl-orders/{ref}/complete, which puts the dealer on file with your store.
What it answers
data is the order, the shape the three FFL order endpoints answer with:
| Field | Meaning |
|---|---|
| ref | Your order number as you sent it, or, for an order your FFL Monkey checkout plugin reported, the reference it made (wc- and 32 hex characters). |
| status | captured: reported. completed: the transfer happened. More values may be added. |
| option | dealer or deferred, as reported. |
| dealer_license_number | As you sent it, or null. |
| dealer_license_key | The licence without its expiry group, the same across renewals; null when no number was sent or it could not be read. |
| dealer_resolved | Whether the licence number named a dealer in FFL Monkey's registry when the order was reported. |
| dealer_snapshot | What the buyer saw of the dealer, below. Always its three fields, null where nothing was sent. |
| captured_at | When the order was first reported. |
| completed_at | When the transfer was reported, or null. |
| canceled_at | When the order was cancelled, or null. |
dealer_snapshot | Meaning |
|---|---|
| business_name | The dealer's name, as shown to the buyer. |
| address | The dealer's address, as shown. |
| expires | The dealer's licence expiry, as shown. |
Returns
- 201Reported: the order, in
data. - 200Reported already: the order, its dealer refreshed.
- 422validation_failed: a
refthat is not an order number, a WooCommerce order key, or a field that broke a rule.
This endpoint can also answer 401 invalid_api_key, 403 license_not_active, 403 product_not_included, 403 insufficient_scope and 429 rate_limited.