0.0.4 • Published 3 years ago

@one-view/voucher-wallet-types v0.0.4

Weekly downloads
-
License
-
Repository
-
Last release
3 years ago

FORMAT: 1A HOST: https://api-pandacare.foodpanda.com/voucher-wallet

voucher-wallet

Voucher wallet plugin

Voucher Wallet /v1/customers/{geid}/{customerId}/wallet

Get voucher wallet

  • Parameters
    • geid (string, required, FP_SG) - global entity id
    • customerId (string, required) - customer ID

Get voucher wallet GET

  • Request

    • Headers

        Authorization: bearer token
        X-Contact-Id: case-id
  • Response 200 (application/json)

    • Attributes (Vouchers)
  • Response 403 (application/json)

    • Attributes (Error)
  • Response 404 (application/json)

    • Attributes (Error)
  • Response 500 (application/json)

    • Attributes (Error)

Voucher /v1/vouchers/{geid}/{voucherCode}

Get voucher by code

  • Parameters
    • geid (string, required, FP_SG) - global entity id
    • voucherCode (string, required) - voucher code

Get single voucher by code GET

  • Request

    • Headers

        Authorization: bearer token
        X-Contact-Id: case-id
  • Response 200 (application/json)

    • Attributes (Voucher)
  • Response 403 (application/json)

    • Attributes (Error)
  • Response 404 (application/json)

    • Attributes (Error)
  • Response 500 (application/json)

    • Attributes (Error)

Data Structures

int32 (number)

int64 (number)

error_object (object)

  • status (string)
  • title (string)

Error (object)

Vouchers

  • list (arrayVoucher, required, fixed-type)

Voucher

  • code : vmdMlZ8 (string) - voucher code
  • name : happy new year (string) - voucher name
  • description : for user activation (string) - voucher description
  • expiry : 1619667165 (string) - timestamp formatted date
  • minimumOrder : $10.00 (string) minimum order amount
  • value : $20.00 (string) voucher value
  • status (VoucherStatus)
  • attributes (arrayVoucherAttribute, fixed-type)

VoucherStatus (enum)

  • APPLICABLE
  • NOT_APPLICABLE
  • EXPIRED
  • USED

VoucherAttribute

  • label : code (string, required) - voucher label
  • value (object) - actual voucher value
  • displayValue : vmdMlZ8 (string, required) - voucher value
  • isRestricted : true (boolean, required) - is the value restricted to be copied