pointRedemptionRule
query
An access token is required to call this API. Refer to Authorization for more information about how to obtain the token.
Get a paginated list of active point redemption rules within the store.
Arguments
Returns elements following the specified cursor. The
first argument must also be specified when using this argument.Returns elements preceding the specified cursor. The
last argument must also be specified when using this argument.Returns the first n elements in the list.
Returns the last n elements in the list.
Whether to reverse the order of the list.
● true: reverse
● false: do not reverse
Default value: false
The applicable channel for point redemption rules. If this argument is omitted, rules for the
ONLINE_STORE channel are returned by default.Return
A list of edges, containing the nodes and their corresponding cursors.
Pagination information for the current page.
A flattened list of nodes.
Status and error codes
For detailed information about common codes, see Status and error codes.
Example
Get a list of point redemption rules
Code
query {
pointRedemptionRule(first:1) {
edges{
cursor
node{
id
name
customisedDescription
icon
allowRevokeRedemption
point {
cashbackPoint
cashbackAmount
couponCodePoint
couponCodePercentage
couponPoint
couponAmount
freeShippingPoint
freeProductPoint
freeProductId }
pointsAutoDeduct
disablePointsRefund
ruleType
cashbackbenefitsUsageThreshold{
minPurchaseAmountEnabled
minPurchaseAmount
minPointsEnabled
minPoints
maxPointsEnabled
maxPoints
maxDeductAmountEnabled
maxDeductAmount }
benefitRedemptionCondition{
benefitRedemptionConditionType
minPurchaseAmountValue
minItemQuantityValue }
couponUsageScope
productsApplicableType
autoStackLimit
codeStackLimit
channel
allowRevokeRedemption
specificCategoryIds
expiryRule
specificProductIds
redemptionLimit{
type
period
count}
}
}
pageInfo{
hasNextPage
hasPreviousPage
endCursor
startCursor}
}
}
Response
{
"data": {
"pointRedemptionRule": {
"edges": [
{
"node": {
"redemptionLimit": {
"count": 5,
"period": 30,
"type": "LIMITED"
},
"specificCategoryIds": [],
"disablePointsRefund": null,
"expiryRule": 30,
"point": {
"couponCodePoint": null,
"couponPoint": null,
"freeProductId": "gid://shopline/Product/******************51381124",
"freeShippingPoint": null,
"cashbackAmount": null,
"couponAmount": null,
"freeProductPoint": 11,
"cashbackPoint": null,
"couponCodePercentage": null
},
"ruleType": "FREE_PRODUCT",
"cashbackbenefitsUsageThreshold": {
"maxPointsEnabled": false,
"minPoints": null,
"minPointsEnabled": false,
"minPurchaseAmount": null,
"minPurchaseAmountEnabled": false,
"maxDeductAmount": null,
"maxDeductAmountEnabled": false,
"maxPoints": null
},
"channel": "ONLINE_STORE",
"id": "gid://shopline/Membership/PRI*************552879",
"specificProductIds": [],
"allowRevokeRedemption": false,
"autoStackLimit": true,
"benefitRedemptionCondition": null,
"codeStackLimit": true,
"icon": "https://img.myshopline.com/image/member/*********4596/**********************2595c901ad.png?w=846&h=372",
"couponUsageScope": "FOR_ALL",
"customisedDescription": "desc",
"name": "free",
"pointsAutoDeduct": null,
"productsApplicableType": "ALL"
},
"cursor": "4C04ED4B4B70D849A6EDE3DF4AFAD2872B0AB19E47EF82F37DC4C3F337AD1FC6"
}
],
"pageInfo": {
"endCursor": "4C04ED4B4B70D849A6EDE3DF4AFAD2872B0AB19E47EF82F37DC4C3F337AD1FC6",
"hasNextPage": true,
"hasPreviousPage": false,
"startCursor": "4C04ED4B4B70D849A6EDE3DF4AFAD2872B0AB19E47EF82F37DC4C3F337AD1FC6"
}
}
},
"extensions": {
"cost": {
"actualQueryCost": 11,
"requestedQueryCost": 11,
"throttleStatus": {
"currentlyAvailable": 99989,
"maximumAvailable": 100000,
"restoreRate": 100000
}
}
}
}
Was this article helpful to you?