Receipt resource

This resource allows you to retrieve details of a processed order that would usually be shown on a receipt, or an merchant order view.

By default if you process any order through a POST request to the Checkout resource, an Order response for the processed order will be returned.

In future you can retrieve receipt details for any order by simply submitting a GET request with the order number to this resource.

Example

If the order number was ORD003413, submitting a GET request to https://www.mydomain.nz/API/V3/Receipt/ORD003413 will retrieve XML similar to that below:

<ResultSet session="5ybb8je8aM8QNRy" xmlns="http://www.zeald.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.zeald.com https://mydomain.nz/API/V3/Receipt.xsd">
    <Receipt href="https://mydomain.nz/API/V3/Receipt/ORD003413" id="Ecommerce::Receipt::ORD003413">
        <order_number>ORD003413</order_number>
        <order_id>20070111230730595</order_id>
        <status>Pending</status>
        <when>2020-07-01 11:13:11</when>

        <!-- The current user / primary contact / person placing the order -->
        <user>
            <fname>Peter</fname>
            <lname>Janson</lname>
            <company>Janson Ltd</company>

            <!-- Country code for the user -->
            <country>NZ</country>
            <address1>PO Box 901-188</address>
            <address2>Mt Eden</address2>
            <city>Auckland</city>
            <post_code>0442</post_code>
            <phone>021 411 1111</phone>
            <email>peter.janson@janson.co.nz</email>
        </user>

        <!--
            A recipient node is completely optional and will only be returned if
            the order had a delivery address explicity submitted

            This current example indicates the order should be delivered to the
            same person, but with a different physical address.

            Note: we don't collect an email address for the recipient.
        -->
        <recipient>
            <fname>Peter</fname>
            <lname>Janson</lname>
            <company>Janson Ltd</company>
            <country>NZ</country>
            <address1>12 Perrington Close</address>
            <address2>Mt Eden</address2>
            <city>Auckland</city>
            <post_code>8383</post_code>
            <phone>021 411 1111</phone>
        </recipient>

        <!--
            A supported payment method code. The code `internal` means the system
            expects payment to be handled either manually, or by the app placing
            the order.
        -->
        <payment>Direct Credit</payment>
        <payment_instructions>Bank:
Account Name:
Account Number:

In the 'Particulars' field type in the order number:
In the 'Payee Code' field type your surname.
Leave the 'Reference' field blank.</payment_instructions>

        <!--
            Optional notes against the order. Depending on how the website is
            configured, on some websites this is a 'Gift note'.
        -->
        <notes>Please deliver it around the side of the house to the back door.</notes>

        <!-- additional data fields stored against this order -->
        <additional>

        </additional>

        <orderline>
            <code>ORD0002095-1</code>
            <description>Foo Product 1</description>
            <options>Sizes:</options>
            <price>576.00</price>
            <price_formatted>$576.00</price_formatted>
            <discount>
                <amount>100.00</amount>
                <amount_formatted>NZ $100.00</amount_formatted>
                <description>promotion</description>
                <original_amount>676.00</original_amount>
                <original_amount_formatted>NZ $676.00</original_amount_formatted>
                <percentage>15</percentage>
            </discount>
            <quantity>1</quantity>
            <sku>04514</sku>
            <status>pending</status>
            <subtotal>576.00</subtotal>
            <subtotal_formatted>$576.00</subtotal_formatted>
            <update_date>2021-01-21 10:29:06</update_date>

            <!-- if an option was selected, a selected_option node for each option group -->
            <selected_option>
                <group>Size</group>
                <group_label>Size</group_label>
                <label>small</label>
                <value>small</value>
            </selected_option>
        </orderline>

        <!--
            Any discounts applied against the order. There are generally two types
            of discount that may apply against the whole order:
              - `ENTIRE_ORDER` - a discounts that applies to the whole order, but
                not the shipping. In this case the discount has been removed for the
                total value of the orderlines, prior to the subtotal being stored.
                i.e. the subtotal is *inclusive* of this discount.
              - `TOTAL_COST` - applies to against the total of the order including
                the shipping. In this case the discount is not included in the subtotal
                as it applies after the subtotal & shipping have been combined.
                i.e. the subtotal is *exclusive* of this discount.
         -->
        <discount>
            <type>TOTAL_COST</type>
            <source>coupon</source>
            <code>mycouponcode</code>
            <amount>7.50</amount>
            <amount_formatted>$7.50</amount_formatted>
        </discount>

        <!-- delivery method used & cost -->
        <delivery>
            <amount>5.50</amount>
            <amount_formatted>NZ $5.50</amount_formatted>
            <description>NZ Wide Delivery</description>
            <mode>NZWideDelivery</mode>
        </delivery>

        <tax_number>12345</tax_number>
        <tax_number_label>GST</tax_number_label>

        <!-- receipt page -->
        <link>http://localhost:8097/gem-fashion2-dev/receipt/x_order/%403FCBDE971F310090858D7EFF1D4019140BE7C6DDAC05F8B653F90D1CA5702C945F2A04DB1C76AD60288B28C4E23675D8.html</link>

        <!-- subtotal - total of the order lines, less any customer discounts -->
        <subtotal>52.00</subtotal>
        <subtotal_formatted>$52.00</subtotal_formatted>

        <!-- if this site has sales tax configured, the amount of tax -->
        <tax>7.80</tax>
        <tax_formatted>$7.80</tax_formatted>

        <!-- total cost of the order including all costs -->
        <total>81.80</total>
        <total_formatted>$81.80</total_formatted>
    <Receipt>
</ResultSet>

Updating an order

To update an order, please use the Data API Order resource.