Welcome‎ > ‎Version 2‎ > ‎Publisher Api (Read/Write)‎ > ‎Data Structures‎ > ‎

Order Voucher

Data Structure holding voucher information about an order.

Fields:
  redemptionUrl - If the voucher is redeemable through and external url it will be listed here
  voucherUrl - If the voucher needs to be printed, it can be printed from this url. The publisher will need to map this url structure to call Voucher.

Sample XML Responses:
<voucher>
    <redemptionUrl i:nil="true"/>
    <voucherUrl>
http://deals.mywebsite.com/voucher?SecretKey=JNZnzeylec%2bg%2f67fjw41z64ApiioSNfy&amp;Code=F-1EE-00-75C</voucherUrl>
</voucher>

<voucher>
    <redemptionUrl>http://redemption.mywebsite.com/code=F-1EE-00-75C</redemptionUrl>
    <voucherUrl i:nil="true" />
</voucher>



Sample JSON Response:
{
    "vouchers": {
        "redemptionUrl": null,
        "voucherUrl": "
http:\/\/deals.mywebsite.com\/voucher?SecretKey=JNZnzeylec%2bg%2f67fjw41z64ApiioSNfy&amp;Code=F-1EE-00-75C"
    }
}

{
    "vouchers": {
        "redemptionUrl": "
http:\/\/redemption.mywebsite.com\/?code=F-1EE-00-75C",
        "voucherUrl": null
    }
}

Comments