Automated Order Export

From Whirlwind eCommerce Wiki
Revision as of 18:43, 18 December 2009 by Root (Talk | contribs)

Jump to: navigation, search

Description

The Automated Order Export provides a method to export order data in an XML format.

Syntax

https://yourdomain/index.php?fa=ORDER.orderExportToXML&emailAddress=x&password=y

Paramaters

  • emailAddress STR OPTIONAL (REQUIRED if the calling application does not support sessions)
the email address of a valid administrator or order manager account in the system. If not passed, the system will attempt to validate based on the current logged in session.
  • password STR OPTIONAL (REQUIRED if the calling application does not support sessions)
the password for the above emailAddress account.
  • startTime DATETIME OPTIONAL
will filter out orders that completed before the startTime. Format: YYYY-MM-DD HH:MM:SS
  • endTime DATETIME OPTIONAL
will filter out orders that completed after the endTime. Format: YYYY-MM-DD HH:MM:SS
  • orderNumber INT-LIST OPTIONAL
will only return orders with orderNumbers that are in this list. Example: 1234,23456,78901
  • onlyNotSent BIT OPTIONAL
will return only orders that have not been marked as sent to the POS (point of sale) system. Set to value of "1" to use filter.
  • markAsSent BIT OPTIONAL
will mark all orders that are returned as sent to the POS (point of sale) system. Set to value of "1" to mark as sent.
  • overrideSSLrequirement BIT OPTIONAL
By default, this tool will only return orders if requested over a secure (SSL) connection. For testing purposes, this can be turned off by setting overrideSSLrequirement to "1". DO NOT use this parameter in production systems!!!!

Example Output

Returns Complete XML Document for all orders that qualify.

<?xml version="1.0" encoding="UTF-8"?>
<orders> 
	<order> 
		<orderId>553</orderId> 
		<orderNumber>10661</orderNumber> 
		<order_createDate>2009-12-10 16:09:31</order_createDate> 
		<order_modDate>2009-12-11 09:31:52</order_modDate> 
		<order_completeDate>2009-12-11 10:26:06</order_completeDate> 
		<order_cancelDate></order_cancelDate> 
		<order_accountUserId>7</order_accountUserId> 
		<order_notes></order_notes> 
		<HTTP_REFERER>http://silkflowers.whirlwindtechnology.com/index.php?fa=ORDER.checkoutConfirmation</HTTP_REFERER> 
		<ENTRY_URL>/index.php?fa=ORDER.process</ENTRY_URL> 
		<IP_ADDRESS>98.100.93.242</IP_ADDRESS> 
		<sent2POS></sent2POS> 
		<sourceCode></sourceCode> 
		<campaign_trackingId>0</campaign_trackingId> 
		<grandTotal>1405.00</grandTotal> 
		<user_userId>7</user_userId> 
		<user_firstName>Chris</user_firstName> 
		<user_lastName>Ziter</user_lastName> 
		<user_emailAddress>chris@eightbyeight.com</user_emailAddress> 
		<ship_addresses> 
			<ship_address> 
				<ship_addressId>1118</ship_addressId> 
				<ship_firstName>Christopher</ship_firstName> 
				<ship_lastName>Ziter</ship_lastName> 
				<ship_street1>8378 Frane Lane</ship_street1> 
				<ship_street2></ship_street2> 
				<ship_city>Cincinnati</ship_city> 
				<ship_state>OH</ship_state> 
				<ship_zipCode>45236</ship_zipCode> 
				<ship_country></ship_country> 
				<ship_phone1>8888888888</ship_phone1> 
				<ship_phone2></ship_phone2> 
				<ship_phone3></ship_phone3> 
				<ship_fax></ship_fax> 
				<ship_emailAddress>chris@essexgreen.com</ship_emailAddress> 
				<ship_instructions></ship_instructions> 
				<ship_shipType></ship_shipType> 
				<ship_shipTypeCode></ship_shipTypeCode> 
				<ship_shipAmount>0.00</ship_shipAmount> 
				<ship_taxAmount></ship_taxAmount> 
				<ship_company></ship_company> 
				<ship_title></ship_title> 
				<items> 
					<item> 
						<itemId>328</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>271</item_productId> 
						<item_productName>Silk Hydrangea & Lily Bouquet</item_productName> 
						<item_productNumber>FLC492-MS</item_productNumber> 
						<item_pricePer>149.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>FLC492-MS</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
					<item> 
						<itemId>330</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>265</item_productId> 
						<item_productName>Grand Impression Silk Floral</item_productName> 
						<item_productNumber>FLC459-WH</item_productNumber> 
						<item_pricePer>595.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>FLC459-WH</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
					<item> 
						<itemId>335</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>472</item_productId> 
						<item_productName>Cypress Bonsai Tree</item_productName> 
						<item_productNumber>TTB120-GR</item_productNumber> 
						<item_pricePer>75.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>TTB120-GR</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
					<item> 
						<itemId>339</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>270</item_productId> 
						<item_productName>Bird Of Paradise Silk Arrangement</item_productName> 
						<item_productNumber>FLC482-OR</item_productNumber> 
						<item_pricePer>169.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>FLC482-OR</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
				</items> 
			</ship_address> 
			<ship_address> 
				<ship_addressId>1125</ship_addressId> 
				<ship_firstName>Christopher</ship_firstName> 
				<ship_lastName>Ziter</ship_lastName> 
				<ship_street1>8378 Frane Lane</ship_street1> 
				<ship_street2></ship_street2> 
				<ship_city>Cincinnati</ship_city> 
				<ship_state>OH</ship_state> 
				<ship_zipCode>45236</ship_zipCode> 
				<ship_country></ship_country> 
				<ship_phone1>8888888888</ship_phone1> 
				<ship_phone2></ship_phone2> 
				<ship_phone3></ship_phone3> 
				<ship_fax></ship_fax> 
				<ship_emailAddress>chris@essexgreen.com</ship_emailAddress> 
				<ship_instructions></ship_instructions> 
				<ship_shipType></ship_shipType> 
				<ship_shipTypeCode></ship_shipTypeCode> 
				<ship_shipAmount></ship_shipAmount> 
				<ship_taxAmount></ship_taxAmount> 
				<ship_company></ship_company> 
				<ship_title></ship_title> 
				<items> 
					<item> 
						<itemId>336</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>48</item_productId> 
						<item_productName>16" Fiberglass Ribbed Square Container</item_productName> 
						<item_productNumber>CTD126-MT</item_productNumber> 
						<item_pricePer>89.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>CTD126-MT</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
					<item> 
						<itemId>337</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>17</item_productId> 
						<item_productName>Large Smilax Container Planting</item_productName> 
						<item_productNumber>BPX105-LG</item_productNumber> 
						<item_pricePer>59.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>BPX105-LG</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
					<item> 
						<itemId>338</itemId> 
						<item_quantity>1</item_quantity> 
						<item_productId>398</item_productId> 
						<item_productName>Deluxe Ficus Tree - 8ft</item_productName> 
						<item_productNumber>TRA100-08</item_productNumber> 
						<item_pricePer>319.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>TRA100-08</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
				</items> 
			</ship_address> 
		</ship_addresses> 
		<bill_addresses> 
			<bill_address> 
				<bill_addressId>1119</bill_addressId> 
				<bill_firstName>Christopher</bill_firstName> 
				<bill_lastName>Ziter</bill_lastName> 
				<bill_street1>8378 Frane Lane</bill_street1> 
				<bill_street2></bill_street2> 
				<bill_city>Cincinnati</bill_city> 
				<bill_state>OH</bill_state> 
				<bill_zipCode>45236</bill_zipCode> 
				<bill_country></bill_country> 
				<bill_phone1>8888888888</bill_phone1> 
				<bill_phone2></bill_phone2> 
				<bill_phone3></bill_phone3> 
				<bill_fax></bill_fax> 
				<bill_emailAddress>chris@essexgreen.com</bill_emailAddress> 
				<bill_instructions></bill_instructions> 
				<bill_shipType></bill_shipType> 
				<bill_shipTypeCode></bill_shipTypeCode> 
				<bill_shipAmount></bill_shipAmount> 
				<bill_taxAmount></bill_taxAmount> 
				<bill_company></bill_company> 
				<bill_title></bill_title> 
				<payments> 
					<payment> 
						<pay_paymentId>553</pay_paymentId> 
						<pay_accountNumber>11111111111111111111</pay_accountNumber> 
						<pay_expDate>2009-12-31</pay_expDate> 
						<pay_authNumber></pay_authNumber> 
						<pay_cancelDate></pay_cancelDate> 
						<pay_manualPayment></pay_manualPayment> 
						<pay_processDate></pay_processDate> 
						<pay_amount>1405.00</pay_amount> 
						<pay_payType>MC</pay_payType> 
						<pay_cvv>434</pay_cvv> 
						<pay_paymentGateway></pay_paymentGateway> 
						<pay_isAuthorized></pay_isAuthorized> 
						<pay_transactionId></pay_transactionId> 
						<pay_AVSResponseCode></pay_AVSResponseCode> 
						<pay_transType></pay_transType> 
					</payment> 
				</payments> 
			</bill_address> 
		</bill_addresses> 
		<discounts> 
			<discount> 
				<disc_discountId>167</disc_discountId> 
				<disc_prod_discountId>7</disc_prod_discountId> 
				<disc_discountCode>tiertest</disc_discountCode> 
				<disc_description>$50 off at $200</disc_description> 
				<disc_amount>50.00</disc_amount> 
				<disc_itemId>0</disc_itemId> 
			</discount> 
		</discounts> 
	</order> 
	<order> 
		<orderId>566</orderId> 
		<orderNumber>19961</orderNumber> 
		<order_createDate>2009-12-14 18:45:35</order_createDate> 
		<order_modDate>2009-12-15 13:40:02</order_modDate> 
		<order_completeDate>2009-12-15 13:43:57</order_completeDate> 
		<order_cancelDate></order_cancelDate> 
		<order_accountUserId>10</order_accountUserId> 
		<order_notes></order_notes> 
		<HTTP_REFERER></HTTP_REFERER> 
		<ENTRY_URL>/index.php?</ENTRY_URL> 
		<IP_ADDRESS>67.248.17.9</IP_ADDRESS> 
		<sent2POS></sent2POS> 
		<sourceCode></sourceCode> 
		<campaign_trackingId>0</campaign_trackingId> 
		<grandTotal>88.00</grandTotal> 
		<user_userId>10</user_userId> 
		<user_firstName>rick</user_firstName> 
		<user_lastName>sherwood</user_lastName> 
		<user_emailAddress>rjswood@nycap.rr.com</user_emailAddress> 
		<ship_addresses> 
			<ship_address> 
				<ship_addressId>1147</ship_addressId> 
				<ship_firstName>rick</ship_firstName> 
				<ship_lastName>sherwood</ship_lastName> 
				<ship_street1>3 Catallo Drive</ship_street1> 
				<ship_street2></ship_street2> 
				<ship_city>waterford</ship_city> 
				<ship_state>NY</ship_state> 
				<ship_zipCode>12188</ship_zipCode> 
				<ship_country></ship_country> 
				<ship_phone1>518-237-8355</ship_phone1> 
				<ship_phone2></ship_phone2> 
				<ship_phone3></ship_phone3> 
				<ship_fax></ship_fax> 
				<ship_emailAddress>rjswood@nycap.rr.com</ship_emailAddress> 
				<ship_instructions></ship_instructions> 
				<ship_shipType></ship_shipType> 
				<ship_shipTypeCode></ship_shipTypeCode> 
				<ship_shipAmount>0.00</ship_shipAmount> 
				<ship_taxAmount></ship_taxAmount> 
				<ship_company></ship_company> 
				<ship_title></ship_title> 
				<items> 
					<item> 
						<itemId>342</itemId> 
						<item_quantity>2</item_quantity> 
						<item_productId>527</item_productId> 
						<item_productName>Rubrum Lily & Viburnum Accent</item_productName> 
						<item_productNumber>FLA519-MS</item_productNumber> 
						<item_pricePer>49.00</item_pricePer> 
						<item_cartDescription></item_cartDescription> 
						<item_isTaxable>1</item_isTaxable> 
						<item_shippingSurcharge>0.00</item_shippingSurcharge> 
						<item_deliveryDate></item_deliveryDate> 
						<item_sku>FLA519-MS</item_sku> 
						<item_weight>0.000</item_weight> 
						<item_itemLayout_complete></item_itemLayout_complete> 
						<item_itemLayout_configurable>0</item_itemLayout_configurable> 
						<item_itemLayout_dataString></item_itemLayout_dataString> 
					</item> 
				</items> 
			</ship_address> 
		</ship_addresses> 
		<bill_addresses> 
			<bill_address> 
				<bill_addressId>1148</bill_addressId> 
				<bill_firstName>rick</bill_firstName> 
				<bill_lastName>sherwood</bill_lastName> 
				<bill_street1>3 Catallo Drive</bill_street1> 
				<bill_street2></bill_street2> 
				<bill_city>waterford</bill_city> 
				<bill_state>NY</bill_state> 
				<bill_zipCode>12188</bill_zipCode> 
				<bill_country></bill_country> 
				<bill_phone1>518-237-8355</bill_phone1> 
				<bill_phone2></bill_phone2> 
				<bill_phone3></bill_phone3> 
				<bill_fax></bill_fax> 
				<bill_emailAddress>rjswood@nycap.rr.com</bill_emailAddress> 
				<bill_instructions></bill_instructions> 
				<bill_shipType></bill_shipType> 
				<bill_shipTypeCode></bill_shipTypeCode> 
				<bill_shipAmount></bill_shipAmount> 
				<bill_taxAmount></bill_taxAmount> 
				<bill_company></bill_company> 
				<bill_title></bill_title> 
				<payments> 
					<payment> 
						<pay_paymentId>566</pay_paymentId> 
						<pay_accountNumber>3333-4444-5555-6666</pay_accountNumber> 
						<pay_expDate>2009-12-31</pay_expDate> 
						<pay_authNumber></pay_authNumber> 
						<pay_cancelDate></pay_cancelDate> 
						<pay_manualPayment></pay_manualPayment> 
						<pay_processDate></pay_processDate> 
						<pay_amount>88.00</pay_amount> 
						<pay_payType>AE</pay_payType> 
						<pay_cvv>452</pay_cvv> 
						<pay_paymentGateway></pay_paymentGateway> 
						<pay_isAuthorized></pay_isAuthorized> 
						<pay_transactionId></pay_transactionId> 
						<pay_AVSResponseCode></pay_AVSResponseCode> 
						<pay_transType></pay_transType> 
					</payment> 
				</payments> 
			</bill_address> 
		</bill_addresses> 
		<discounts> 
			<discount> 
				<disc_discountId>170</disc_discountId> 
				<disc_prod_discountId>5</disc_prod_discountId> 
				<disc_discountCode>tiertest</disc_discountCode> 
				<disc_description>$10 off your order</disc_description> 
				<disc_amount>10.00</disc_amount> 
				<disc_itemId>0</disc_itemId> 
			</discount> 
		</discounts> 
	</order> 
</orders>
<!-- total proc time: 0.43181800842285 -->


Example Calls

returns all orders in the system

https://yourdomain/index.php?fa=ORDER.orderExportToXML&emailAddress=x&password=y

returns only orders that have not been marked as sent to the POS, also marks orders as sent that are returned

https://yourdomain/index.php?fa=ORDER.orderExportToXML&emailAddress=x&password=y&onlyNotSent=1&markAsSent=1

returns only orders with orderNumber 1,2,3 or 4

https://yourdomain/index.php?fa=ORDER.orderExportToXML&emailAddress=x&password=y&orderNumber=1,2,3,4

returns only orders before Dec 1, 2008

https://yourdomain/index.php?fa=ORDER.orderExportToXML&emailAddress=x&password=y&startTime=2008-12-01