Get a voucher detail
get
/crmRestApi/resources/11.13.18.05/loyVouchers/{VoucherNumber}
Request
Path Parameters
-
VoucherNumber(required): string
The alternative way to identify a voucher. The UI shows the voucher number, but the VoucherNumber attribute is used in the URI to update a voucher record using the resource. The VoucherNumber attribute can also be used as parameter for the validateVoucherFinder finder. There is no default value, dependency, or limitation associated with this attribute.
Query Parameters
-
dependency: string
This parameter specifies dependencies which are fields that are set before and rolled back after generating the response. Generally they are used to preview the effects of an attribute change. The fields specified in this parameter are always set in the resource instance in question. When a child resource collection is requested and the parameter is set, the fields will be set in the parent resource instance before generating the resource collection payload. The value of this query parameter is a set of dependency fields. Example: dependency=ProductId=2
Format: <attr1>=<val1>,<attr2>=<value2> -
expand: string
When this parameter is provided, the specified children are included in the resource payload (instead of just a link). The value of this query parameter is "all" or "". More than one child can be specified using comma as a separator. Example: ?expand=Employees,Localizations. Nested children can also be provided following the format "Child.NestedChild" (Example: ?expand=Employees.Managers). If a nested child is provided (Example: Employees.Managers), the missing children will be processed implicitly. For example, "?expand=Employees.Managers" is the same as "?expand=Employees,Employees.Managers" (which will expand Employees and Managers).
-
fields: string
This parameter filters the resource fields. Only the specified fields are returned, which means that if no fields are specified, no fields are returned (useful to get only the links). If an indirect child resource is provided (Example: Employees.Managers), the missing children will be processed implicitly. For example, "?fields=Employees.Managers:Empname" is the same as "?fields=;Employees:;Employees.Managers:Empname" (which will only return the "Empname" field for Managers). the value of this query parameter is a list of resource fields. The attribute can be a direct (Example: Employees) or indirect (Example: Employees.Managers) child. It cannot be combined with expand query parameter. If both are provided, only fields will be considered.
Format: ?fields=Attribute1,Attribute2
Format for fields in child resource: ?fields=Accessor1:Attribute1,Attribute2 -
links: string
This parameter can be used to show only certain links while accessing a singular resource or a resource collection. The parameter value format is a comma-separated list of : <link_relation>
Example:
self,canonical -
onlyData: boolean
The resource item payload will be filtered in order to contain only data (no links section, for example).
Header Parameters
-
Metadata-Context:
If the REST API supports runtime customizations, the shape of the service may change during runtime. The REST client may isolate itself from these changes or choose to interact with the latest version of the API by specifying this header. For example: Metadata-Context:sandbox="TrackEmployeeFeature".
-
REST-Framework-Version:
The protocol version between a REST client and service. If the client does not specify this header in the request the server will pick a default version for the API.
There's no request body for this operation.
Back to TopResponse
Supported Media Types
- application/json
Default Response
The following table describes the default response for this task.
Headers
-
Metadata-Context:
If the REST API supports runtime customizations, the shape of the service may change during runtime. The REST client may isolate itself from these changes or choose to interact with the latest version of the API by specifying this header. For example: Metadata-Context:sandbox="TrackEmployeeFeature".
-
REST-Framework-Version:
The protocol version between a REST client and service. If the client does not specify this header in the request the server will pick a default version for the API.
Root Schema : loyVouchers-item-response
Type:
Show Source
object-
ActionNote: string
Title:
Action NoteMaximum Length:1000The attribute indicates additional information pertaining to a voucher action for which the voucher was created. There is no default value or limitation associated with this attribute. -
ActivityDate: string
The date used by Oracle Loyalty Cloud to fetch a valid voucher for a given activity date. The ActivityDate attribute is a parameter used in the availableVoucherFinder and validateVoucherFinder finders. There is no default value, dependency, or limitation associated with this attribute.
-
Basis: string
Title:
Voucher Basis MeaningRead Only:trueMaximum Length:80The list of value meaning for the Basis code. There is no default value or limitation associated with this attribute. -
BasisCode: string
Title:
Voucher BasisMaximum Length:30The accepted values are ORA_VOUC_BASIS_ACC, ORA_TXORA_VOUC_BASIS_TIER, and so on. There is no default value, dependency, or limitation associated with this attribute. -
ConsumedTransactionNumber: string
Title:
Redeemed Transaction NumberMaximum Length:30The transaction number that used this voucher.There is no default value, dependency, or limitation associated with this attribute. -
CreatedBy: string
Title:
Created ByRead Only:trueMaximum Length:64The user that creates the voucher record. Oracle Loyalty Cloud populates this value when the loyalty administrator creates the voucher in the Oracle Loyalty Cloud UI. There is no default value, dependency, or limitation associated with this attribute. -
CreationDate: string
(date-time)
Title:
Creation DateRead Only:trueThe date when the voucher record is created. Oracle Loyalty Cloud sets this date value when the loyalty administrator creates the voucher in the Oracle Loyalty Cloud UI. There is no default value, dependency, or limitation associated with this attribute. -
CurcyExchDt: string
(date)
Title:
Currency Exchange DateThe currency exchange date associated with the voucher. There is no default value, dependency, or limitation associated with this attribute. -
CurrencyAmount: number
Title:
Voucher Discount ValueThe currency amount signifies the voucher amount associated with the voucher of type absolute value voucher. This attribute is required for vouchers of type absolute value voucher. There is no default value, dependency, nor limitation associated with this attribute. -
CurrencyCode: string
Title:
Currency CodeMaximum Length:15The currency code associated with the voucher. There is no default value, dependency, or limitation associated with this attribute. -
Description: string
Title:
TypeRead Only:trueMaximum Length:240The attribute provides the product description for the voucher, which is displayed on the Loyalty Voucher page in the UI. Oracle Loyalty Cloud assigns the ProdId attribute value with the identifier of the product when the user inputs the product description. There is no default value, dependency, or limitation associated with this attribute. -
DiscountValue: string
Read Only:
trueThe voucher discount value. If the VchrBasisCode attribute of a voucher is set to Percentage, the value of discount must be a positive integer. This value is provided as an input value from a user when creating the voucher. There is no default value or limitation associated with this attribute. -
ExpirationDt: string
(date-time)
Title:
Expiration DateThe expiration date of the voucher. Oracle Loyalty Cloud generates this attribute value when it assigns a voucher action or the attribute value can be provided as an input when creating a voucher using the resource. There is no default value, dependency, or limitation associated with this attribute. -
InvOrgId: integer
(int64)
Title:
Inventory Organization IDThe unique identifier of the organization that provides the inventory when the user is redeeming the vouchers. There is no default value, dependency, or limitation associated with this attribute. -
LastUpdateDate: string
(date-time)
Title:
Change DateRead Only:trueThe date when the voucher record is updated. Oracle Loyalty Cloud sets this date value when the loyalty administrator updates the voucher card in the Oracle Loyalty Cloud UI. There is no default value, dependency, or limitation associated with this attribute. -
LastUpdatedBy: string
Title:
Changed ByRead Only:trueMaximum Length:64The user that updates the voucher record. Oracle Loyalty Cloud populates this value when the loyalty administrator updates the voucher in the Oracle Loyalty Cloud UI. There is no default value, dependency, or limitation associated with this attribute. -
links: array
Links
Title:
LinksThe link relations associated with the resource instance. -
LoyMemVchrId: integer
(int64)
Title:
Voucher IDThe primary key identifier which signifies a unique value for a generated voucher record. There is no default value, dependency, nor limitation associated with this attribute. -
MemberId: integer
(int64)
Title:
Member IDThe primary key of the member to whom the voucher is assigned. There is no default value, dependency, or limitation associated with this attribute. -
MemberNumber: string
Title:
Member NumberThe member number of the loyaltyMember attribute to whom the voucher is assigned. The MemberNumber attribute is used when assigning a voucher or creating a voucher using the resource. The MemberNumber attribute is also used as a parameter in the availableVoucherFinder finder. There is no default value or dependency associated with this attribute. -
Name: string
Title:
PromotionRead Only:trueMaximum Length:50The attribute indicates the name of the promotion for which the voucher was created. There is no default value, dependency, or limitation associated with this attribute. -
OrganizationCode: string
Title:
Organization CodeMaximum Length:18The organization code associated with the member voucher. There is no default value, dependency, or limitation associated with this attribute. -
OriginalVoucherNumber: string
Title:
Original Voucher NumberMaximum Length:30The original voucher number associated with the voucher. There is no default value, dependency, or limitation associated with this attribute. -
PrConId: integer
(int64)
Title:
Primary Contact IDRead Only:trueThe attribute indicates the Primary contact identifier of the member for whom the voucher was created. There is no default value, dependency, or limitation associated with this attribute. -
ProductNumber: string
Title:
Product NumberThe identifier of the product for an existing voucher which is used to specify the product information. There is no default value, dependency, or limitation associated with this attribute. -
PromotionNumber: string
Title:
Promotion NumberMaximum Length:30The promotion number that was applied to the transaction during transaction processing and created this voucher. There is no default value, dependency, or limitation associated with this attribute. -
Quantity: number
Title:
QuantityDefault Value:1The attribute provides details of how many vouchers are assigned. There is no default value, dependency, nor limitation associated with this attribute. -
StatusCode: string
Title:
StatusMaximum Length:30Default Value:ORA_VOUC_STATUS_AVLBLThe attribute indicates the status of the voucher. The accepted values are ORA_VOUC_STATUS_AVLBL, ORA_VOUC_STATUS_USED, ORA_VOUC_STATUS_CANC, and so on. The VoucherStatus attribute can be changed from Available to Used only through a PATCH request. There is no default value, dependency, or limitation associated with this attribute. -
StatusMeaning: string
Title:
Voucher Status MeaningRead Only:trueMaximum Length:80The voucher status meaning, which shows the voucher status as follows: Available, Expired, Used, and so on. There is no default value, dependency, nor limitation associated with this attribute. -
TxnId: integer
(int64)
Title:
Transaction IDRead Only:trueThe transaction Identifier which has led to the assignment of loyalty vouchers due to transaction processing. There is no default value or limitation associated with this attribute. -
TxnItemId: integer
(int64)
Title:
Transaction Item IDThe transaction item identifier which signifies the transaction identifier assigned while processing the transaction. There is no default value, dependency, nor limitation associated with this attribute. -
TxnNum: string
Title:
Transaction NumberRead Only:trueMaximum Length:30The transaction number associated with the voucher. This attribute is automatically generated by Oracle Loyalty Cloud when a voucher gets assigned as an outcome of transaction processing. There is no default value, dependency, or limitation associated with this attribute. -
UsedDt: string
(date-time)
Title:
Used DateThe date when a valid voucher that is available is changed to the Used status. This date gets assigned when the voucher status is changed from Available to Used through a PATCH request. There is no default value, dependency, or limitation associated with this attribute. -
validFlag: boolean
The date when a valid voucher that is available is changed to the Used status. This date gets assigned when the voucher status is changed from Available to Used through a PATCH request. There is no default value, dependency, or limitation associated with this attribute.
-
VchrBasis: string
Title:
Discount Type MeaningRead Only:trueMaximum Length:80The list of values meaning for the Voucher Basis code. There is no default value, dependency, nor limitation associated with this attribute. -
VchrBasisCode: string
Title:
Discount TypeMaximum Length:30The attribute indicates the discount type that the voucher offers. Accepted values are ORA_VOUC_BASIS_ABSOLUTE or ORA_VOUC_BASIS_PERCENTAGE. It is provided as input from a user when creating the voucher. There is no default value, dependency, or limitation associated with this attribute. -
VoucherDiscountValue: number
Title:
Voucher Discount ValueThe voucher discount value. If the DiscountType attribute of a voucher is set to Percentage, then the value of the discount must be a positive integer. This value is provided as an input value from a user when creating the voucher. There is no default value or limitation associated with this attribute. -
VoucherEffectiveStartDt: string
(date)
Title:
Start DateThe date when the voucher is in effect. This date is assigned during an Assign Voucher action or when the voucher is created using the resource. There is no default value, dependency, or limitation associated with this attribute. -
VoucherNumber: string
Title:
Voucher NumberMaximum Length:30The alternative way to identify a voucher. The UI shows the voucher number, but the VoucherNumber attribute is used in the URI to update a voucher record using the resource. The VoucherNumber attribute can also be used as parameter for the validateVoucherFinder finder. There is no default value, dependency, or limitation associated with this attribute.
Nested Schema : Links
Type:
arrayTitle:
LinksThe link relations associated with the resource instance.
Show Source
Nested Schema : link
Type:
Show Source
object-
href: string
Title:
hyperlink referenceThe URI to the related resource. -
kind: string
Title:
kindAllowed Values:[ "collection", "item", "describe", "other" ]The kind of the related resource. -
name: string
Title:
nameThe name of the link to the related resource. -
properties: object
properties
-
rel: string
Title:
relationAllowed Values:[ "self", "lov", "parent", "canonical", "child", "enclosure", "action", "custom" ]The name of the relation to the resource instance. Example: self.
Nested Schema : properties
Type:
Show Source
object-
changeIndicator: string
Change indicator or the ETag value of the resource instance.
Links
- BasisCodeLookupPVO
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DORA_LOY_MEM_VOUC_BASIS
The lookups resource is used to view standard lookup codes. - finder:
- MemberVO2
-
Operation: /crmRestApi/resources/11.13.18.05/loyMembersParameters:
- finder:
MemNumSearch%3BMemberNumber%3D{MemberNumber}
Member Data Object for Loyalty Member Service - finder:
- SalesCatalogProductProgPVO1
-
Operation: /crmRestApi/resources/11.13.18.05/productsParameters:
- finder:
ProductList
The product resource is used to view, create, or modify a product. A product is an item that an organization or company intends to sell. - finder:
- SatusCodeLookupPVO
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DORA_LOY_MEM_VOUC_STATUS%2CBindLookupCode%3D{StatusCode}
The lookups resource is used to view standard lookup codes. - finder:
- VoucherBasisLookupPVO
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DORA_LOY_MEM_VOUC_DISCOUNT_TYPE%2CBindLookupCode%3D{BasisCode}
The lookups resource is used to view standard lookup codes. - finder:
Examples
This example shows how to retrieve a specific voucher.
Use GET with the following URI syntax to retrieve voucher number 300100129316575:
https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575Example of Response Header
cache-control -no-cache, no-store, must-revalidate
connection -Keep-Alive
content-encoding -gzip
content-language -en
content-length -823
content-type -application/vnd.oracle.adf.resourceitem+json
date -Thu, 23 Aug 2018 18:31:49 GMT
etag -"ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000178"
keep-alive -timeout=61, max=100
link - <https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575>;rel="self";kind="item";name="loyVouchers"
location -
rest-framework-version -1
server -Oracle-HTTP-Server
vary -User-Agent
x-content-type-options -nosniff
x-oracle-dms-ecid -005T1tsrf_OEoIILIqL6if0001wh0000d9Example of Response Body
{
"MemberNumber" : "300100129316529",
"VoucherNumber" : "300100129316575",
"BasisCode" : "ORA_VOUC_BASIS_RED",
"ConsumedTxnId" : 0,
"CurrencyAmount" : 0,
"VoucherEffectiveStartDt" : "2018-08-04",
"VoucherDiscountValue" : 10,
"ExpirationDt" : "2018-10-01T23:59:59+00:00",
"LoyMemVchrId" : 300100129316575,
"MemberId" : 300100129316528,
"Quantity" : 1,
"TxnId" : 0,
"StatusCode" : "ORA_VOUC_STATUS_AVLBL",
"TxnItemId" : 0,
"UsedDt" : null,
"VchrBasisCode" : "ORA_VOUC_BASIS_PERCENTAGE",
"Description" : "One Night Free Hotel Room",
"InvOrgId" : 204,
"DiscountValue" : null,
"ActionNote" : "Assign Absolute",
"ActivityDate" : null,
"validFlag" : "true",
"Name" : "XYZ Hotels Voucher",
"PrConId" : 300100129316530,
"ProductNumber" : "CRMITEM-AS54888-00182745",
"links" : [ {
"rel" : "self",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575",
"name" : "loyVouchers",
"kind" : "item",
"properties" : {
"changeIndicator" : "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000178"
}
}, {
"rel" : "canonical",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575",
"name" : "loyVouchers",
"kind" : "item"
}, {
"rel" : "lov",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575/lov/BasisCodeLookupPVO",
"name" : "BasisCodeLookupPVO",
"kind" : "collection"
}, {
"rel" : "lov",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575/lov/SalesCatalogProductProgPVO1",
"name" : "SalesCatalogProductProgPVO1",
"kind" : "collection"
}, {
"rel" : "lov",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575/lov/SatusCodeLookupPVO",
"name" : "SatusCodeLookupPVO",
"kind" : "collection"
}, {
"rel" : "lov",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575/lov/VoucherBasisLookupPVO",
"name" : "VoucherBasisLookupPVO",
"kind" : "collection"
}, {
"rel" : "lov",
"href" : "https://example.com:port/crmRestApi/resources/11.13.18.05/loyVouchers/300100129316575/lov/MemberVO2",
"name" : "MemberVO2",
"kind" : "collection"
} ]
}