voucherifyio / voucherify-nodejs-sdk

[Deprecated] Node.js SDK for Voucherify - coupons, vouchers, promo codes
http://www.voucherify.io
MIT License
27 stars 16 forks source link

How can I send track id when I use redeem method #104

Closed zoriiz closed 4 years ago

zoriiz commented 5 years ago

I try to use redeem method and add track id as a param without customer.

client.redemptions.redeem(code, { track_id: 'string' })

and I got this error

{ code: 400, message: 'Invalid RedemptionContext', details: 'Unrecognized property \'tracking_id\'', key: 'invalid_redemption_context', toString: [Function] }

Any idea?

frakti commented 4 years ago

Sorry for late response @zoriiz. You can find it in README:

client.redemptions.redeem(code, {customer: {source_id: 'string'}})