GET

Get Loyalty Earning Rule


Retrieves a specified non-automated earning rule.

To retrieve both automated and non-automated earning rules, use List Earning Rules.

Permissions
Manage Loyalty
Read Loyalty
Learn more about app permissions.
Endpoint
GET
https://www.wixapis.com/_api/loyalty-earning-rules/v1/earning-rules/{id}

Path Params
idstringRequired

ID of the earning rule to retrieve.

Response Object
earningRuleEarningRule

Retrieved earning rule.

Get earning rule
Request
cURL
curl -X GET \ 'https://www.wixapis.com/loyalty-earning-rules/v1/earning-rules/eeb9ff42-b24f-4a68-8491-21507508f3f5' \ -H 'Authorization: <AUTH>' \ -H 'Content-Type: application/json'
Response
JSON
{ "earningRule": { "id": "eeb9ff42-b24f-4a68-8491-21507508f3f5", "sourceAppId": "553c79f3-5625-4f38-b14b-ef7c0d1e87df", "triggerAppId": "1380b703-ce81-ff05-f115-39571d94dfcd", "triggerActivityType": "stores/OrderPaid", "title": "Purchase a product", "conversionRate": { "moneyAmount": 1, "points": 20, "configs": [ { "moneyAmount": 1, "points": 20 } ] }, "status": "ACTIVE", "revision": "1", "createdDate": "2024-09-16T12:12:16.833Z", "updatedDate": "2024-09-16T12:12:16.833Z", "metadata": { "canBeDeleted": true } } }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?