---
title: "Delete Earning Rule"
method: DELETE
path: "/v1/loyalties/{campaignId}/earning-rules/{earningRuleId}"
tags: ["Loyalties"]
---

# Delete Earning Rule

`DELETE /v1/loyalties/{campaignId}/earning-rules/{earningRuleId}`

## Request

- Base URL: `https://api.voucherify.io`
- URL: `https://api.voucherify.io/v1/loyalties/{campaignId}/earning-rules/{earningRuleId}`
- Auth: one of:
  - API key in header `X-App-Id` and API key in header `X-App-Token`
  - OAuth 2
    - Implicit: `https://api.voucherify.io/v1/oauth/token`
    - Scopes: `api`, `loyalties`

This method deletes an earning rule for a specific loyalty campaign.

## Response `204`

Returns no content if deletion is successful.

## Other responses

- `404`: Returns an error indicating that the loyalty campaign or earning rule with given ID was not found.

---

[API](https://skmtc.dev/voucherifyio/apis/voucherify-api-async-actions.md) - [All operations](https://skmtc.dev/voucherifyio/apis/voucherify-api-async-actions/llms.txt) - [OpenAPI document](https://skmtc.dev/voucherifyio/apis/voucherify-api-async-actions/revisions/4982266e0494?raw)
