Collapse Menu
Classic Docs
Order Page Config, Design and Page Flow
Advanced Features
Subscriptions and Saasy
Contact Support

XML Example Format

This article provides information about XML Example Format

 

Content for Order Notification and Order Item Notification

<order xmlns:c="http://xml.fastspring.com/template/core">
  <date>#{order.statusChange.format("yyyy-MM-dd'T'HH:mm:ssZ")}</date>
  <reference>#{order.id}</reference>
  <test>#{order.isTest}</test>
  <ip>#{order.originIp}</ip>
  <referrer>#{order.referrer}</referrer>
  <currency>#{order.currency}</currency>
  <tax>#{order.tax.textValue}</tax>
  <total>#{order.total.textValue}</total>
  <subtotal>#{order.subTotal.textValue}</subtotal>
  
  <purchaser>
    <fname>#{order.customer.firstName}</fname>
    <lname>#{order.customer.lastName}</lname>
    <company>#{order.customer.companyName}</company>
    <phone>#{order.customer.phone}</phone>
    <email>#{order.customer.email}</email>
    <country>#{order.address.country}</country>
    <region>#{order.address.region}</region>
    <address1>#{order.address.address1}</address1>
    <address2>#{order.address.address2}</address2>
    <city>#{order.address.city}</city>
    <postal>#{order.address.postalCode}</postal>
  </purchaser>
  
  <items>
    <c:repeat var="item" value="#{order.allItems}">
      <item>
      <product>#{item.productName}</product>
      <quantity>#{item.quantity}</quantity>
      <subtotal>#{item.priceTotal.textValue}</subtotal>
      <licenses>
        <c:repeat var="fulfill" value="#{item.allFulfillment}">
          <c:if test="#{fulfill.isLicense}">
            <license>
              <name>#{fulfill.licenseName}</name>
              <data xml:space="preserve">#{fulfill.licenses.list}</data>
            </license>
          </c:if>
        </c:repeat>
      </licenses>
      </item>
    </c:repeat>
  </items>
</order>

Content for Subscription Activated Notification, Subscription Changed Notification, Subscription Deactivated Notification, and Subscription Payment Failed Notification

<subscription xmlns:c="http://xml.fastspring.com/template/core">
 <begindate>#{subscription.beginDate.format("yyyy-MM-dd'T'HH:mm:ssZ")}</begindate>
 <name>##{subscription.productName}</name>
 <enddate>#{subscription.endDate.format("yyyy-MM-dd'T'HH:mm:ssZ")}</enddate>
 <test>#{subscription.isTest}</test>
 <path>#{subscription.productPath}</path>
 <quantity>#{subscription.quantity}</quantity>
 <reference>#{subscription.reference}</reference>
 <referrer>#{subscription.referrer}</referrer>
 <status>#{subscription.status}</status>
 <tags>#{subscription.tagString}</tags>
 <price>#{subscription.totalPrice}</price>
 <customerurl>#{subscription.url.detail}</customerurl>
 <customer>
  <fname>#{subscription.notify.firstName}</fname>
  <lname>#{subscription.notify.lastName}</lname>
  <company>#{subscription.notify.companyName}</company>
  <phone>#{subscription.notify.phone}</phone>
  <email>#{subscription.notify.email}</email>
 </customer>
</subscription>