order.payment.pending

Last modified October 11, 2017

A server webhook fired when an order has been processed but payment from the buyer has not yet been completed (for example, when a buyer selects wire transfer as their payment method or buys using a purchase order).

About Webhook Expansion

When webhook expansion is enabled, order.payment.pending will include the entire customer account object, rather than just the account ID.

Contents of Event Payload

Name Type Description
order string internal order ID
id string internal order ID
reference string customer-facing order reference
buyerReference string for purchase order transactions, the optional purchase order number entered by the buyer
completed Boolean "true" for a completed order; always false for order.payment.pending
changed Integer date of the most recent update to the order record, in milliseconds
changedValue Integer date of the most recent update to the order record, in milliseconds (backward compatibility)
changedInSeconds integer date of the most recent update to the order record, in seconds
changedDisplay string date of the most recent update to the order record, formatted for display based on the language in which the order was processed
language string two-character ISO code for the order language
live Boolean "false" for a test order
currency string three-character ISO code for the order currency
payoutCurrency string three-character ISO code for the currency in which your disbursement will be made
invoiceUrl string URL of the customer-facing invoice for this order
account string (expansion disabled)
object (expansion enabled)
FastSpring-generated customer account ID (expansion disabled)
details of the customer account (expansion enabled)
account.id string FastSpring-generated customer account ID
account.account string FastSpring-generated customer account ID
account.contact object customer's contact details
account.contact.first string customer's first name
account.contact.last string customer's last name
account.contact.email string customer's email address
account.contact.company string customer's company name
account.contact.phone string customer's telephone number
account.language string two-character ISO code for the language associated with the customer's account
account.country string two-character ISO code for the country associated with the customer's account
account.lookup object multiple-field object containing lookup IDs for the customer account (e.g. for use with the /accounts endpoint of the FastSpring API)
account.lookup.global string external customer account ID, generated by FastSpring
account.lookup.custom string optional custom account ID specified via the /accounts endpoint of the FastSpring API (not shown in examples below)
account.url string url for the Store's default account management page
total number order total in the transaction's currency
totalDisplay string order total, formatted for display in the transaction's currency
totalInPayoutCurrency number order total in the currency of your FastSpring disbursements
totalInPayoutCurrencyDisplay string order total, formatted for display in the currency of your FastSpring disbursements
tax number amount of tax
taxDisplay string amount of tax, formatted for display in the transaction's currency
taxInPayoutCurrency number amount of tax in the currency of your FastSpring disbursements
taxInPayoutCurrencyDisplay string amount of tax, formatted for display in the currency of your FastSpring disbursements
subtotal number order subtotal in the transaction's currency
subtotalDisplay string order subtotal, formatted for display in the transaction's currency
subtotalInPayoutCurrency number order subtotal in the currency of your FastSpring disbursements
subtotalInPayoutCurrencyDisplay string order subtotal, formatted for display in the currency of your FastSpring disbursements
discount number total discount applied to the order in the transaction's currency
discountDisplay string total discount applied to the order, formatted for display in the transaction's currency
discountInPayoutCurrency number total discount applied to the order, in the currency of your FastSpring disbursements
discountInPayoutCurrencyDisplay string total discount applied to the order, formatted for display in the currency of your FastSpring disbursements
discountWithTax number discount amount including tax
discountWithTaxDisplay string discount amount including tax, formatted for display in the transaction's currency
discountWithTaxInPayoutCurrency number discount amount including tax, in the currency of your FastSpring disbursements
discountWithTaxInPayoutCurrencyDisplay string discount amount including tax, formatted for display in the currency of your FastSpring disbursements
payment object details about the transaction's payment method used for the purchase; blank for order.payment.pending since payment has not yet been made
reason string reason why the payment is pending (e.g. "wireTransfer", "purchaseOrder")
customer object details about the customer
customer.first string customer's first name
customer.last string customer's last name
customer.email string customer's email address
customer.company string customer's company name
customer.phone string customer's telephone number
address object details about the customer address associated with this order
address.city string name of the city in the address
address.addressLine1 string first address line (for physical shipments or when Force physical address collection for all orders is enabled for the Storefront)
address.addressLine2 string second, optional address line (for physical shipments or when Force physical address collection for all orders is enabled for the Storefront)
address.regionCode string two-character ISO code for the state of the address (present for U.S. addresses only)
address.regionDisplay string state or region of the address, formatted for display
address.region string state or region of the address (backward compatibility)
address.postalCode string postal code of the address
address.country string country of the address
address.display string concatenated string of address information, formatted for display
notes array optional internal order notes entered via Dashboard
items array products included in the order, one object per product
items.product string product path / product ID
items.quantity integer quantity of the current product in this transaction
items.display string customer-facing Display name of the product
items.sku string optional internal SKU ID (e.g. your part number) for the current product
items.subtotal number subtotal for the current product, in the transaction's currency
items.subtotalDisplay string subtotal for the current product, formatted for display in the transaction's currency
items.subtotalInPayoutCurrency number subtotal for the current product, in the currency of your FastSpring disbursements
items.subtotalInPayoutCurrencyDisplay string subtotal for the current product, formatted for display in the currency of your FastSpring disbursements
items.attributes object multiple-field object containing optional product-level attributes for the current product
items.discount number amount of any discount applied to the current product
items.discountDisplay string amount of any discount applied to the current product, formatted for display in the transaction's currency
items.discountInPayoutCurrency number amount of any discount applied to the current product, in the currency of your FastSpring disbursements
items.discountInPayoutCurrencyDisplay string amount of any discount applied to the current product, formatted for display in the currency of your FastSpring disbursements
items.subscription string ID of the subscription associated with the current product; blank for order.payment.pending because the subscription has not yet been created
items.fulfillments object multiple-field object containing details of fulfillment actions associated with the current product (filelicense, or instructions)
items.fulfillments.<fulfillment ID> array identifier for the current fulfillment action (other than instructions); array consists of fulfillment attributes
items.fulfillments.<fulfillment ID>.license string (when "type" = "license") license key associated with the current fulfillment action
items.fulfillments.<fulfillment ID>.display string

name of the current fulfillment action:

when "type" = "license", "License Key"
when "type" = "file", <download file name>

items.fulfillments.<fulfillment ID>.size integer (when "type" = "file") size of the download file, in bytes
items.fulfillments.<fulfillment ID>.file string (when "type" = "file") order-specific URL for the product download associated with this fulfillment action
items.fulfillments.<fulfillment ID>.type string "license" or "file"
items.fulfillments.instructions string contents of the Post Order Instructions field for the current product
coupons array list of coupon IDs applied to the order (currently, only one coupon can be applied to an order)


Examples

Example 1 - Webhook Expansion Disabled

order.payment.pending webhook example (webhook expansion disabled)
{  
   "order":"yAgkCUQyRCuPNuT44gd6vg",
   "id":"yAgkCUQyRCuPNuT44gd6vg",
   "reference":"FUR170210-3172-46119",
   "buyerReference":null,
   "completed":false,
   "changed":1486744538094,
   "changedValue":1486744538094,
   "changedInSeconds":1486744538,
   "changedDisplay":"10/02/17",
   "language":"en",
   "live":true,
   "currency":"GBP",
   "payoutCurrency":"USD",
   "invoiceUrl":"https://furiousfalcon.onfastspring.com/account/order/FUR170210-3172-46119/invoice",
   "account":"uKj7izONRfanVwBL9eiG_A",
   "total":4.95,
   "totalDisplay":"£4.95",
   "totalInPayoutCurrency":5.99,
   "totalInPayoutCurrencyDisplay":"USD 5.99",
   "tax":0.83,
   "taxDisplay":"£0.83",
   "taxInPayoutCurrency":1.0,
   "taxInPayoutCurrencyDisplay":"USD 1.00",
   "subtotal":4.12,
   "subtotalDisplay":"£4.12",
   "subtotalInPayoutCurrency":4.98,
   "subtotalInPayoutCurrencyDisplay":"USD 4.98",
   "discount":0.0,
   "discountDisplay":"£0.00",
   "discountInPayoutCurrency":0.0,
   "discountInPayoutCurrencyDisplay":"USD 0.00",
   "discountWithTax":0.0,
   "discountWithTaxDisplay":"£0.00",
   "discountWithTaxInPayoutCurrency":0.0,
   "discountWithTaxInPayoutCurrencyDisplay":"USD 0.00",
   "payment":{
   },
   "reason":"wireTransfer",
   "customer":{  
      "first":"Leeroy",
      "last":"Jenkins",
      "email":"ne1@all.com",
      "company":null,
      "phone":null
   },
   "address":{  
      "country":"GB",
      "display":"GB"
   },
   "notes":[  
   ],
   "items":[  
      {  
         "product":"eggs",
         "quantity":1,
         "display":"Eggs",
         "sku":"falcon1",
         "subtotal":4.12,
         "subtotalDisplay":"£4.12",
         "subtotalInPayoutCurrency":4.98,
         "subtotalInPayoutCurrencyDisplay":"USD 4.98",
         "discount":0.0,
         "discountDisplay":"£0.00",
         "discountInPayoutCurrency":0.0,
         "discountInPayoutCurrencyDisplay":"USD 0.00",
         "fulfillments":{  
            "instructions":"<p>Thank you for purchasing <em>Eggs</em>. To register, please launch the trial version and select <strong>Help</strong> | <strong>Register Eggs</strong>. Then, copy and paste the license key below into the <strong>License Key</strong> field and click <strong>Submit</strong>.</p><p>Your Eggs license key is:<br/></p>"
         }
      }
   ]
}


Example 2 - Webhook Expansion Enabled

order.payment.pending webhook example (webhook expansion enabled)
{  
   "order":"P_cvYBiNSOq3WeOwbZPgJw",
   "id":"P_cvYBiNSOq3WeOwbZPgJw",
   "reference":"FUR170828-4256-68119",
   "buyerReference":null,
   "completed":false,
   "changed":1503935908496,
   "changedValue":1503935908496,
   "changedInSeconds":1503935908,
   "changedDisplay":"8/28/17",
   "language":"en",
   "live":true,
   "currency":"EUR",
   "payoutCurrency":"USD",
   "invoiceUrl":"https://furiousfalcon.onfastspring.com/account/order/FUR170828-4256-68119/invoice",
   "account":{  
      "id":"N8FjcSWcQNeYCc-suM1O8g",
      "account":"N8FjcSWcQNeYCc-suM1O8g",
      "contact":{  
         "first":"Leeroy",
         "last":"Jenkins",
         "email":"ne1@all.com",
         "company":"Chicken Danger, Inc.",
         "phone":null
      },
      "language":"en",
      "country":"DE",
      "lookup":{  
         "global":"TVWhu0iwQhKJyuhpT_2yMw"
      },
      "url":"https://furiousfalcon.onfastspring.com/account"
   },
   "total":10.95,
   "totalDisplay":"€10.95",
   "totalInPayoutCurrency":12.63,
   "totalInPayoutCurrencyDisplay":"USD 12.63",
   "tax":1.75,
   "taxDisplay":"€1.75",
   "taxInPayoutCurrency":2.02,
   "taxInPayoutCurrencyDisplay":"USD 2.02",
   "subtotal":9.2,
   "subtotalDisplay":"€9.20",
   "subtotalInPayoutCurrency":10.61,
   "subtotalInPayoutCurrencyDisplay":"USD 10.61",
   "discount":0.0,
   "discountDisplay":"€0.00",
   "discountInPayoutCurrency":0.0,
   "discountInPayoutCurrencyDisplay":"USD 0.00",
   "discountWithTax":0.0,
   "discountWithTaxDisplay":"€0.00",
   "discountWithTaxInPayoutCurrency":0.0,
   "discountWithTaxInPayoutCurrencyDisplay":"USD 0.00",
   "payment":{  

   },
   "reason":"wireTransfer",
   "customer":{  
      "first":"Leeroy",
      "last":"Jenkins",
      "email":"ne1@all.com",
      "company":"Chicken Danger, Inc.",
      "phone":null
   },
   "address":{  
      "country":"DE",
      "display":"DE"
   },
   "notes":[  

   ],
   "items":[  
      {  
         "product":"falcon",
         "quantity":1,
         "display":"Furious Falcon",
         "sku":"falcon6abc123",
         "subtotal":9.2,
         "subtotalDisplay":"€9.20",
         "subtotalInPayoutCurrency":10.61,
         "subtotalInPayoutCurrencyDisplay":"USD 10.61",
         "discount":0.0,
         "discountDisplay":"€0.00",
         "discountInPayoutCurrency":0.0,
         "discountInPayoutCurrencyDisplay":"USD 0.00",
         "fulfillments":{  
            "instructions":"<p>Thank you for purchasing <em>Falcon</em>. To register, please launch the trial version and select <strong>Help</strong> | <strong>Register Falcon</strong>. Then, copy and paste the license key above into the <strong>License Key</strong> field and click <strong>Submit</strong>.</p>"
         }
      }
   ]
}