Welcome‎ > ‎Version 3‎ > ‎Publisher Api‎ > ‎Methods‎ > ‎1 - Offer Related‎ > ‎

Get Voucher Preview

Will get a preview of a voucher based on the offer id.  Useful for double checking how the voucher will be displayed once running.  This call is never cached so be aware when building preview pages that the links will come from pub admin to preview.

Method: GET /api/v3/publisher/voucher/preview
Authentication: oauth
Required QueryString Value
SecretKey The secret key for the voucher.

  base response fields
  voucher - The voucher object.

Sample Request:

GET http://api.groupcommerce.com/api/v3/publisher/voucher/preview?secretKey=xBKC03CcbQk%3d

Authorization: OAuth oauth_signature="LepaX%2bTrehK43VJQpTvuJwTJBSQ%3d", oauth_nonce="4941263", oauth_timestamp="1320815673", oauth_consumer_key="eeb6b959-b854-4ad1-b563-e801c83cf81d", oauth_signature_method="HMAC-SHA1", oauth_version="1.0"

Sample JSON Response:

    "errors": [],
    "lastPublished": "/Date(1319851251455)/",
    "success": true,
    "version": "3",
    "voucher": {
see voucher */

Sample XML Response:

<getVoucherPreviewResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
        <!-- see voucher -->