Search

Index

Revindex Storefront

Voucher

Last updated on 2023-01-27 6 mins. to read

A Voucher is a payment method often used as gift certificate, gift card, store credit, etc..

DeleteVoucher

This service is used to delete a Voucher object.

Request Parameters

Node Required Data Type Description
voucherID Yes Integer The object identifier.

 

Return Data

None


GetVoucher

This service is used to query the Voucher object.

Request Parameters

Node Required Data Type Description
voucherID Yes Integer The object identifier.

 

Return Data

Node Data Type Description
voucher XML  
  adminNotes String Administrator notes not shown to customer.
  amount Decimal The remaining balance in the voucher.
  assignedUserID Integer The voucher may be assigned to a user.
  code String The unique code to redeem the voucher.
  createDate DateTime  
  initialAmount Decimal The initial starting amount when the voucher was created.
  issueDate DateTime The date when the voucher was first created.
  portalID Integer  
  salesOrderDetailID Integer The corresponding sales order detail object identifier if this voucher was generate from the order.
  status Integer The status of the voucher. Inactive = 1, Active = 2, Hold = 3, Cancelled = 4
  updateDate DateTime  
  voucherDefinitionID Integer The object identifier of the voucher definition.
  voucherID Integer The object identifier.

 


GetVoucherByCode

This service is used to query the Voucher object.

Request Parameters

Node Required Data Type Description
code Yes String The voucher code.

 

Return Data

Same data structure as GetVoucher service return data.


GetVouchers

This service is used to query all the Voucher objects.

Request Parameters

Node Required Data Type Description
count No Boolean Specify if return data should include total number of records found.
skip No Integer The number of records to skip over for paging purposes.
take No Integer The number of records to return for paging purposes.

 

Return Data

Node Data Type Description
totalCount Integer Number of records found.
vouchers XML Container node
  voucher XML Zero or more Voucher nodes with same data structure as GetVoucher service return data.

 


GetVouchersByVoucherDefinition

This service is used to query all the Voucher objects.

Request Parameters

Node Required Data Type Description
count No Boolean Specify if return data should include total number of records found.
skip No Integer The number of records to skip over for paging purposes.
take No Integer The number of records to return for paging purposes.
voucherDefinitionID Yes Integer The VoucherDefinition object identifier.

 

Return Data

Node Data Type Description
totalCount Integer Number of records found.
vouchers XML Container node
  voucher XML Zero or more Voucher nodes with same data structure as GetVoucher service return data.

 


InsertVoucher

This service is used to create a new Voucher object.

Request Parameters

Node Required Data Type Description
adminNotes No String Administrator notes not shown to customer.
amount Yes Decimal The remaining balance in the voucher.
assignedUserID No Integer The voucher may be assigned to a user.
code Yes String The unique code to redeem the voucher.
maxRedemption No Integer Max number of times the voucher can be redeemed.
salesOrderDetailID No Integer The corresponding sales order detail object identifier if this voucher was generate from the order.
status Yes Integer The status of the voucher. Inactive = 1, Active = 2, Hold = 3, Cancelled = 4
voucherDefinitionID Yes Integer The object identifier of the voucher definition.

 

Return Data

Same as GetVoucher service return data.


UpdateVoucher

This service is used to update a Voucher object.

Request Parameters

Node Required Data Type Description
adminNotes No String Administrator notes not shown to customer.
amount Yes Decimal The remaining balance in the voucher.
assignedUserID No Integer The voucher may be assigned to a user.
code Yes String The unique code to redeem the voucher.
maxRedemption No Integer Max number of times the voucher can be redeemed.
salesOrderDetailID No Integer The corresponding sales order detail object identifier if this voucher was generate from the order.
status Yes Integer The status of the voucher. Inactive = 1, Active = 2, Hold = 3, Cancelled = 4
voucherDefinitionID Yes Integer The object identifier of the voucher definition.
voucherID Yes Integer The object identifier.

 

Return Data

Same as GetVoucher service return data.

Comments


Powered by Revindex Wiki