> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.solvimon.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.solvimon.com/_mcp/server.

# Deactivate a coupon

POST https://test.api.solvimon.com/v{version}/coupons/{resourceIdOrReference}/deactivate

Requires the COUPON.UPDATE permission.

Reference: https://docs.solvimon.com/api-docs/configuration-api/coupons/post-coupons-by-resource-id-or-reference-deactivate

## Authentication

- `X-API-KEY` header (required) — API Key authentication via header
- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Servers

- `https://test.api.solvimon.com` (The TEST environment for our API, default)
- `https://api.solvimon.com` (The live environment for our API)

## Request

### Path parameters

- `version` (string, required, default: 1) — version
- `resourceIdOrReference` (string, required, default: ) — The ID or reference of the resource.

### Headers

- `x-platform-id` (string, optional) — Platform ID.

## Response

### 200

OK

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `name` (string, optional)
- `reference` (string, optional)
- `description` (string, optional, nullable)
- `status` (enum, optional, nullable)
  - Allowed values: `DRAFT`, `ACTIVE`, `INACTIVE`, `DEPRECATED`, `ARCHIVED`
- `discount` (CouponDiscount, optional)
- `duration` (CouponDuration, optional)
- `limited_to` (CouponLimitedTo, optional)
- `start_at` (string, optional, nullable)
- `end_at` (string, optional, nullable)
- `maximum_redemptions` (integer, optional, nullable)
- `number_of_redemptions` (integer, optional, nullable)
- `created_at` (string, optional, nullable)
- `updated_at` (string, optional, nullable)

## Errors

### 400 Bad Request Error

Bad Request

- `type` (enum, required)
  - Allowed values: `API_ERROR`, `INVALID_REQUEST`
- `code` (enum, required)
  - Allowed values: `RESOURCE_NOT_FOUND`, `RESOURCES_NOT_FOUND`, `UNABLE_TO_PROCESS_INSTRUCTIONS`, `BAD_REQUEST`, `UNSUPPORTED_MEDIA_TYPE`, `RESOURCE_ALREADY_EXISTS`, `CUSTOM_FIELD_VALUE_ALREADY_EXISTS`, `COULD_NOT_CREATE_RESOURCE`, `COULD_NOT_UPDATE_RESOURCE`, `COULD_NOT_DELETE_RESOURCE`, `MISSING_VERSION`, `UNSUPPORTED_VERSION`, `UNAUTHORISED`, `CUSTOMER_NOT_FOUND`, `PLATFORM_NOT_FOUND`, `PRICING_PLAN_NOT_FOUND`, `PRODUCT_NOT_FOUND`, `PRODUCT_ITEM_NOT_FOUND`, `PRICING_NOT_FOUND`, `PRICING_ITEM_NOT_FOUND`, `USER_NOT_FOUND`, `METER_NOT_FOUND`, `METER_VALUE_NOT_FOUND`, `METER_PROPERTY_NOT_FOUND`, `PRICING_ITEM_SUMMARIES_NOT_FOUND`, `MISSING_ID`, `INVALID_ID`, `MISSING_REFERENCE`, `MISSING_FIELD`, `INVALID_FIELD`, `INVALID_OPERATION`, `INTERNAL_ERROR`, `USER_NOT_ALLOWED`, `IDEMPOTENCY_CHECK_FAILED`, `INVALID_REQUEST`
- `message` (string, required)
- `field` (string, optional, nullable)
- `resource_id` (string, optional, nullable)
- `resource_type` (enum, optional, nullable)
  - Allowed values: `CUSTOMER`, `CUSTOM_FIELD`, `PLATFORM`, `PLATFORM_UPTODATE`, `METER`, `METER_VALUE`, `METER_PROPERTY`, `METER_PROPERTY_VARIABLE`, `METER_VALUE_CALCULATION`, `INGEST_DATA`, `METER_DATA`, `CHARGE_DATA`, `PERSIST_DATA`, `ADJUSTMENT_DATA`, `PRODUCT_CATEGORY`, `PRODUCT`, `PRODUCT_ITEM`, `PRICING`, `PRICING_GROUP`, `PRICING_ITEM`, `PRICING_ITEM_CONFIG`, `PRICING_PLAN_SUBSCRIPTION`, `PRICING_PLAN_SUBSCRIPTION_GROUP`, `PRICING_PLAN_SCHEDULE`, `SEAT_ASSIGNMENT`, `SHIPPING_ADDRESS`, `PRICING_PLAN`, `PRICING_PLAN_VERSION`, `PRICING_PLAN_GROUP`, `QUOTE`, `QUOTE_VERSION`, `QUOTE_TEMPLATE`, `QUOTE_VERSION_SUMMARY`, `API_KEY`, `USER`, `ROLE`, `PROXY_USER`, `EXTERNAL_CREDENTIALS`, `TOKEN`, `INVOICE`, `E_INVOICE`, `PDF`, `BILLING_ENTITY`, `FEATURE`, `MEMBERSHIP`, `PAYMENT`, `PAYMENT_ACCEPTOR`, `PAYMENT_METHOD`, `PAYMENT_METHOD_OPTIONS`, `PAYMENT_SCHEDULE`, `PAYMENT_REQUEST`, `INTEGRATION`, `WEBHOOK`, `WEBHOOK_EVENT`, `FILE`, `FILE_PROCESSING_SETTINGS`, `TEAM`, `DOWNLOAD_URL`, `CSV_REPORT`, `REPORT`, `REPORT_GENERATE_REQUEST`, `REPORT_CONFIGURATION`, `REPORT_SUBSCRIPTION`, `REPORT_DEFINITION`, `ACCOUNT_GROUP`, `ENTITY`, `EVENT_TRACE`, `EVENT_TRACE_LINK`, `PRICING_CATEGORY`, `CONTACT`, `ALERT_RULE`, `ALERT`, `USAGE_LIMIT`, `AUDIT_RECORD`, `PORTAL_URL`, `AUTHENTICATION_PROVIDER`, `REPROCESS`, `APPROVAL_POLICY`, `APPROVAL_REQUEST`, `BULK_ACTION`, `COUPON`, `PROMOTION_CODE`, `WALLET`, `WALLET_TYPE`, `WALLET_GRANT`, `AUTO_TOPUP_CONFIG`, `WORKFLOW`, `WORKFLOW_TRIGGER`, `WORKFLOW_ACTION`, `WORKFLOW_ACTION_EXECUTION`, `CREDIT_TYPE`, `SIGNATURE_REQUEST`, `ATTACHMENT`, `DOCUMENT`, `EXCHANGE_RATE`

### 401 Unauthorized Error

Unauthorized

- `type` (enum, required)
  - Allowed values: `API_ERROR`, `INVALID_REQUEST`
- `code` (enum, required)
  - Allowed values: `RESOURCE_NOT_FOUND`, `RESOURCES_NOT_FOUND`, `UNABLE_TO_PROCESS_INSTRUCTIONS`, `BAD_REQUEST`, `UNSUPPORTED_MEDIA_TYPE`, `RESOURCE_ALREADY_EXISTS`, `CUSTOM_FIELD_VALUE_ALREADY_EXISTS`, `COULD_NOT_CREATE_RESOURCE`, `COULD_NOT_UPDATE_RESOURCE`, `COULD_NOT_DELETE_RESOURCE`, `MISSING_VERSION`, `UNSUPPORTED_VERSION`, `UNAUTHORISED`, `CUSTOMER_NOT_FOUND`, `PLATFORM_NOT_FOUND`, `PRICING_PLAN_NOT_FOUND`, `PRODUCT_NOT_FOUND`, `PRODUCT_ITEM_NOT_FOUND`, `PRICING_NOT_FOUND`, `PRICING_ITEM_NOT_FOUND`, `USER_NOT_FOUND`, `METER_NOT_FOUND`, `METER_VALUE_NOT_FOUND`, `METER_PROPERTY_NOT_FOUND`, `PRICING_ITEM_SUMMARIES_NOT_FOUND`, `MISSING_ID`, `INVALID_ID`, `MISSING_REFERENCE`, `MISSING_FIELD`, `INVALID_FIELD`, `INVALID_OPERATION`, `INTERNAL_ERROR`, `USER_NOT_ALLOWED`, `IDEMPOTENCY_CHECK_FAILED`, `INVALID_REQUEST`
- `message` (string, required)
- `field` (string, optional, nullable)
- `resource_id` (string, optional, nullable)
- `resource_type` (enum, optional, nullable)
  - Allowed values: `CUSTOMER`, `CUSTOM_FIELD`, `PLATFORM`, `PLATFORM_UPTODATE`, `METER`, `METER_VALUE`, `METER_PROPERTY`, `METER_PROPERTY_VARIABLE`, `METER_VALUE_CALCULATION`, `INGEST_DATA`, `METER_DATA`, `CHARGE_DATA`, `PERSIST_DATA`, `ADJUSTMENT_DATA`, `PRODUCT_CATEGORY`, `PRODUCT`, `PRODUCT_ITEM`, `PRICING`, `PRICING_GROUP`, `PRICING_ITEM`, `PRICING_ITEM_CONFIG`, `PRICING_PLAN_SUBSCRIPTION`, `PRICING_PLAN_SUBSCRIPTION_GROUP`, `PRICING_PLAN_SCHEDULE`, `SEAT_ASSIGNMENT`, `SHIPPING_ADDRESS`, `PRICING_PLAN`, `PRICING_PLAN_VERSION`, `PRICING_PLAN_GROUP`, `QUOTE`, `QUOTE_VERSION`, `QUOTE_TEMPLATE`, `QUOTE_VERSION_SUMMARY`, `API_KEY`, `USER`, `ROLE`, `PROXY_USER`, `EXTERNAL_CREDENTIALS`, `TOKEN`, `INVOICE`, `E_INVOICE`, `PDF`, `BILLING_ENTITY`, `FEATURE`, `MEMBERSHIP`, `PAYMENT`, `PAYMENT_ACCEPTOR`, `PAYMENT_METHOD`, `PAYMENT_METHOD_OPTIONS`, `PAYMENT_SCHEDULE`, `PAYMENT_REQUEST`, `INTEGRATION`, `WEBHOOK`, `WEBHOOK_EVENT`, `FILE`, `FILE_PROCESSING_SETTINGS`, `TEAM`, `DOWNLOAD_URL`, `CSV_REPORT`, `REPORT`, `REPORT_GENERATE_REQUEST`, `REPORT_CONFIGURATION`, `REPORT_SUBSCRIPTION`, `REPORT_DEFINITION`, `ACCOUNT_GROUP`, `ENTITY`, `EVENT_TRACE`, `EVENT_TRACE_LINK`, `PRICING_CATEGORY`, `CONTACT`, `ALERT_RULE`, `ALERT`, `USAGE_LIMIT`, `AUDIT_RECORD`, `PORTAL_URL`, `AUTHENTICATION_PROVIDER`, `REPROCESS`, `APPROVAL_POLICY`, `APPROVAL_REQUEST`, `BULK_ACTION`, `COUPON`, `PROMOTION_CODE`, `WALLET`, `WALLET_TYPE`, `WALLET_GRANT`, `AUTO_TOPUP_CONFIG`, `WORKFLOW`, `WORKFLOW_TRIGGER`, `WORKFLOW_ACTION`, `WORKFLOW_ACTION_EXECUTION`, `CREDIT_TYPE`, `SIGNATURE_REQUEST`, `ATTACHMENT`, `DOCUMENT`, `EXCHANGE_RATE`

### 403 Forbidden Error

Forbidden

- `type` (enum, required)
  - Allowed values: `API_ERROR`, `INVALID_REQUEST`
- `code` (enum, required)
  - Allowed values: `RESOURCE_NOT_FOUND`, `RESOURCES_NOT_FOUND`, `UNABLE_TO_PROCESS_INSTRUCTIONS`, `BAD_REQUEST`, `UNSUPPORTED_MEDIA_TYPE`, `RESOURCE_ALREADY_EXISTS`, `CUSTOM_FIELD_VALUE_ALREADY_EXISTS`, `COULD_NOT_CREATE_RESOURCE`, `COULD_NOT_UPDATE_RESOURCE`, `COULD_NOT_DELETE_RESOURCE`, `MISSING_VERSION`, `UNSUPPORTED_VERSION`, `UNAUTHORISED`, `CUSTOMER_NOT_FOUND`, `PLATFORM_NOT_FOUND`, `PRICING_PLAN_NOT_FOUND`, `PRODUCT_NOT_FOUND`, `PRODUCT_ITEM_NOT_FOUND`, `PRICING_NOT_FOUND`, `PRICING_ITEM_NOT_FOUND`, `USER_NOT_FOUND`, `METER_NOT_FOUND`, `METER_VALUE_NOT_FOUND`, `METER_PROPERTY_NOT_FOUND`, `PRICING_ITEM_SUMMARIES_NOT_FOUND`, `MISSING_ID`, `INVALID_ID`, `MISSING_REFERENCE`, `MISSING_FIELD`, `INVALID_FIELD`, `INVALID_OPERATION`, `INTERNAL_ERROR`, `USER_NOT_ALLOWED`, `IDEMPOTENCY_CHECK_FAILED`, `INVALID_REQUEST`
- `message` (string, required)
- `field` (string, optional, nullable)
- `resource_id` (string, optional, nullable)
- `resource_type` (enum, optional, nullable)
  - Allowed values: `CUSTOMER`, `CUSTOM_FIELD`, `PLATFORM`, `PLATFORM_UPTODATE`, `METER`, `METER_VALUE`, `METER_PROPERTY`, `METER_PROPERTY_VARIABLE`, `METER_VALUE_CALCULATION`, `INGEST_DATA`, `METER_DATA`, `CHARGE_DATA`, `PERSIST_DATA`, `ADJUSTMENT_DATA`, `PRODUCT_CATEGORY`, `PRODUCT`, `PRODUCT_ITEM`, `PRICING`, `PRICING_GROUP`, `PRICING_ITEM`, `PRICING_ITEM_CONFIG`, `PRICING_PLAN_SUBSCRIPTION`, `PRICING_PLAN_SUBSCRIPTION_GROUP`, `PRICING_PLAN_SCHEDULE`, `SEAT_ASSIGNMENT`, `SHIPPING_ADDRESS`, `PRICING_PLAN`, `PRICING_PLAN_VERSION`, `PRICING_PLAN_GROUP`, `QUOTE`, `QUOTE_VERSION`, `QUOTE_TEMPLATE`, `QUOTE_VERSION_SUMMARY`, `API_KEY`, `USER`, `ROLE`, `PROXY_USER`, `EXTERNAL_CREDENTIALS`, `TOKEN`, `INVOICE`, `E_INVOICE`, `PDF`, `BILLING_ENTITY`, `FEATURE`, `MEMBERSHIP`, `PAYMENT`, `PAYMENT_ACCEPTOR`, `PAYMENT_METHOD`, `PAYMENT_METHOD_OPTIONS`, `PAYMENT_SCHEDULE`, `PAYMENT_REQUEST`, `INTEGRATION`, `WEBHOOK`, `WEBHOOK_EVENT`, `FILE`, `FILE_PROCESSING_SETTINGS`, `TEAM`, `DOWNLOAD_URL`, `CSV_REPORT`, `REPORT`, `REPORT_GENERATE_REQUEST`, `REPORT_CONFIGURATION`, `REPORT_SUBSCRIPTION`, `REPORT_DEFINITION`, `ACCOUNT_GROUP`, `ENTITY`, `EVENT_TRACE`, `EVENT_TRACE_LINK`, `PRICING_CATEGORY`, `CONTACT`, `ALERT_RULE`, `ALERT`, `USAGE_LIMIT`, `AUDIT_RECORD`, `PORTAL_URL`, `AUTHENTICATION_PROVIDER`, `REPROCESS`, `APPROVAL_POLICY`, `APPROVAL_REQUEST`, `BULK_ACTION`, `COUPON`, `PROMOTION_CODE`, `WALLET`, `WALLET_TYPE`, `WALLET_GRANT`, `AUTO_TOPUP_CONFIG`, `WORKFLOW`, `WORKFLOW_TRIGGER`, `WORKFLOW_ACTION`, `WORKFLOW_ACTION_EXECUTION`, `CREDIT_TYPE`, `SIGNATURE_REQUEST`, `ATTACHMENT`, `DOCUMENT`, `EXCHANGE_RATE`

### 500 Internal Server Error

Internal Server Error

- `type` (enum, required)
  - Allowed values: `API_ERROR`, `INVALID_REQUEST`
- `code` (enum, required)
  - Allowed values: `RESOURCE_NOT_FOUND`, `RESOURCES_NOT_FOUND`, `UNABLE_TO_PROCESS_INSTRUCTIONS`, `BAD_REQUEST`, `UNSUPPORTED_MEDIA_TYPE`, `RESOURCE_ALREADY_EXISTS`, `CUSTOM_FIELD_VALUE_ALREADY_EXISTS`, `COULD_NOT_CREATE_RESOURCE`, `COULD_NOT_UPDATE_RESOURCE`, `COULD_NOT_DELETE_RESOURCE`, `MISSING_VERSION`, `UNSUPPORTED_VERSION`, `UNAUTHORISED`, `CUSTOMER_NOT_FOUND`, `PLATFORM_NOT_FOUND`, `PRICING_PLAN_NOT_FOUND`, `PRODUCT_NOT_FOUND`, `PRODUCT_ITEM_NOT_FOUND`, `PRICING_NOT_FOUND`, `PRICING_ITEM_NOT_FOUND`, `USER_NOT_FOUND`, `METER_NOT_FOUND`, `METER_VALUE_NOT_FOUND`, `METER_PROPERTY_NOT_FOUND`, `PRICING_ITEM_SUMMARIES_NOT_FOUND`, `MISSING_ID`, `INVALID_ID`, `MISSING_REFERENCE`, `MISSING_FIELD`, `INVALID_FIELD`, `INVALID_OPERATION`, `INTERNAL_ERROR`, `USER_NOT_ALLOWED`, `IDEMPOTENCY_CHECK_FAILED`, `INVALID_REQUEST`
- `message` (string, required)
- `field` (string, optional, nullable)
- `resource_id` (string, optional, nullable)
- `resource_type` (enum, optional, nullable)
  - Allowed values: `CUSTOMER`, `CUSTOM_FIELD`, `PLATFORM`, `PLATFORM_UPTODATE`, `METER`, `METER_VALUE`, `METER_PROPERTY`, `METER_PROPERTY_VARIABLE`, `METER_VALUE_CALCULATION`, `INGEST_DATA`, `METER_DATA`, `CHARGE_DATA`, `PERSIST_DATA`, `ADJUSTMENT_DATA`, `PRODUCT_CATEGORY`, `PRODUCT`, `PRODUCT_ITEM`, `PRICING`, `PRICING_GROUP`, `PRICING_ITEM`, `PRICING_ITEM_CONFIG`, `PRICING_PLAN_SUBSCRIPTION`, `PRICING_PLAN_SUBSCRIPTION_GROUP`, `PRICING_PLAN_SCHEDULE`, `SEAT_ASSIGNMENT`, `SHIPPING_ADDRESS`, `PRICING_PLAN`, `PRICING_PLAN_VERSION`, `PRICING_PLAN_GROUP`, `QUOTE`, `QUOTE_VERSION`, `QUOTE_TEMPLATE`, `QUOTE_VERSION_SUMMARY`, `API_KEY`, `USER`, `ROLE`, `PROXY_USER`, `EXTERNAL_CREDENTIALS`, `TOKEN`, `INVOICE`, `E_INVOICE`, `PDF`, `BILLING_ENTITY`, `FEATURE`, `MEMBERSHIP`, `PAYMENT`, `PAYMENT_ACCEPTOR`, `PAYMENT_METHOD`, `PAYMENT_METHOD_OPTIONS`, `PAYMENT_SCHEDULE`, `PAYMENT_REQUEST`, `INTEGRATION`, `WEBHOOK`, `WEBHOOK_EVENT`, `FILE`, `FILE_PROCESSING_SETTINGS`, `TEAM`, `DOWNLOAD_URL`, `CSV_REPORT`, `REPORT`, `REPORT_GENERATE_REQUEST`, `REPORT_CONFIGURATION`, `REPORT_SUBSCRIPTION`, `REPORT_DEFINITION`, `ACCOUNT_GROUP`, `ENTITY`, `EVENT_TRACE`, `EVENT_TRACE_LINK`, `PRICING_CATEGORY`, `CONTACT`, `ALERT_RULE`, `ALERT`, `USAGE_LIMIT`, `AUDIT_RECORD`, `PORTAL_URL`, `AUTHENTICATION_PROVIDER`, `REPROCESS`, `APPROVAL_POLICY`, `APPROVAL_REQUEST`, `BULK_ACTION`, `COUPON`, `PROMOTION_CODE`, `WALLET`, `WALLET_TYPE`, `WALLET_GRANT`, `AUTO_TOPUP_CONFIG`, `WORKFLOW`, `WORKFLOW_TRIGGER`, `WORKFLOW_ACTION`, `WORKFLOW_ACTION_EXECUTION`, `CREDIT_TYPE`, `SIGNATURE_REQUEST`, `ATTACHMENT`, `DOCUMENT`, `EXCHANGE_RATE`

## Types

### CouponDiscount

- `type` (enum, optional)
  - Allowed values: `PERCENTAGE`, `AMOUNT`, `USAGE`
- `percentage` (string, optional, nullable)
- `amount` (Amount, optional)
- `usage` (CouponDiscountUsage, optional)
- `condition` (DiscountCondition, optional)

### CouponDuration

- `type` (enum, optional)
  - Allowed values: `ONE_TIME`, `FOREVER`, `PERIOD`
- `period` (Period, optional)

### CouponLimitedTo

- `product_category_ids` (list of string, optional, nullable)
- `product_ids` (list of string, optional, nullable)
- `product_item_ids` (list of string, optional, nullable)
- `product_categories` (list of ProductCategory, optional, nullable)
- `products` (list of Product, optional, nullable)
- `product_items` (list of ProductItem, optional, nullable)

### Amount

- `quantity` (string, optional)
- `currency` (enum, optional)
  - Allowed values: `AED`, `AFN`, `ALL`, `AMD`, `ANG`, `AOA`, `ARS`, `AUD`, `AWG`, `AZN`, `BAM`, `BBD`, `BDT`, `BGN`, `BHD`, `BIF`, `BMD`, `BND`, `BOB`, `BRL`, `BSD`, `BTN`, `BWP`, `BYN`, `BZD`, `CAD`, `CDF`, `CHF`, `CLF`, `CLP`, `CNY`, `COP`, `CRC`, `CUC`, `CUP`, `CVE`, `CZK`, `DJF`, `DKK`, `DOP`, `DZD`, `EGP`, `ERN`, `ETB`, `EUR`, `FJD`, `FKP`, `GBP`, `GEL`, `GHS`, `GIP`, `GMD`, `GNF`, `GTQ`, `GYD`, `HKD`, `HNL`, `HRK`, `HTG`, `HUF`, `IDR`, `ILS`, `INR`, `IQD`, `IRR`, `ISK`, `JMD`, `JOD`, `JPY`, `KES`, `KGS`, `KHR`, `KMF`, `KPW`, `KRW`, `KWD`, `KYD`, `KZT`, `LAK`, `LBP`, `LKR`, `LRD`, `LSL`, `LYD`, `MAD`, `MDL`, `MGA`, `MKD`, `MMK`, `MNT`, `MOP`, `MRO`, `MRU`, `MUR`, `MVR`, `MWK`, `MXN`, `MXV`, `MYR`, `MZN`, `NAD`, `NGN`, `NIO`, `NOK`, `NPR`, `NZD`, `OMR`, `PAB`, `PEN`, `PGK`, `PHP`, `PKR`, `PLN`, `PYG`, `QAR`, `RON`, `RSD`, `RUB`, `RWF`, `SAR`, `SBD`, `SCR`, `SDG`, `SEK`, `SGD`, `SHP`, `SLE`, `SOS`, `SRD`, `SSP`, `STN`, `SVC`, `SYP`, `SZL`, `THB`, `TJS`, `TMT`, `TND`, `TOP`, `TRY`, `TTD`, `TWD`, `TZS`, `UAH`, `UGX`, `USD`, `USN`, `UYI`, `UYU`, `UZS`, `VEF`, `VES`, `VND`, `VUV`, `WST`, `XAF`, `XAG`, `XAU`, `XBA`, `XBB`, `XBC`, `XBD`, `XCD`, `XDR`, `XOF`, `XPD`, `XPF`, `XPT`, `XSU`, `XTS`, `XUA`, `XXX`, `YER`, `ZAR`, `ZMW`, `ZWL`

### CouponDiscountUsage

- `meter_value_id` (string, optional) — Resource ID of type METER_VALUE
- `number` (string, optional, nullable)
- `amount` (Amount, optional)

### DiscountCondition

- `comparator` (enum, optional)
  - Allowed values: `EQUALS`, `NOT_EQUALS`, `IN`, `NOT_IN`, `GREATER_THAN`, `GREATER_THAN_OR_EQUALS`, `LESS_THAN`, `LESS_THAN_OR_EQUALS`, `EMPTY`, `NOT_EMPTY`, `CONTAINS`, `NOT_CONTAINS`
- `value` (DiscountConditionValue, optional)

### Period

- `type` (enum, optional)
  - Allowed values: `DAY`, `WEEK`, `MONTH`, `YEAR`
- `value` (integer, optional, nullable)

### ProductCategory

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `name` (string, optional)
- `reference` (string, optional)
- `description` (string, optional, nullable)
- `tax_category` (enum, optional, nullable) — The default tax category applied to the products in the product category.
  - Allowed values: `STANDARD`, `NO_TAX`, `EXEMPT`
- `display_order` (integer, optional, nullable)
- `customer_id` (string, optional, nullable) — Resource ID of type CUSTOMER

### Product

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `category_id` (string, optional) — The resource ID of the product category, that belongs to the product.
- `category` (ProductCategory, optional, nullable)
- `parent_product_id` (string, optional, nullable) — The resource ID of the original product, to which the product will belong to.
- `name` (string, optional)
- `reference` (string, optional)
- `description` (string, optional, nullable)
- `status` (enum, optional, nullable) — The status of the product.
  - Allowed values: `DRAFT`, `ACTIVE`, `ARCHIVED`, `DEPRECATED`
- `product_type` (enum, optional)
  - Allowed values: `DEFAULT`, `ADDON`
- `tax_category` (enum, optional, nullable) — The default tax category applied to the product.
  - Allowed values: `STANDARD`, `NO_TAX`, `EXEMPT`
- `features` (list of FeatureResourceReference, optional, nullable) — The features associated with the product.
- `custom_fields` (list of CustomFieldValue, optional, nullable)
- `display_order` (integer, optional, nullable) — Determines the order in which products are displayed on overview pages and invoices. The lowest number gets the highest priority.
- `linked_integrations` (list of LinkedIntegration, optional, nullable)
- `billing_entity_id` (string, optional, nullable) — The resource ID of the billing entity linked to this product.
- `customer_id` (string, optional, nullable)
- `agent_context` (AgentContext, optional) — Context for AI agents about this product. Intended for agents, not for customer-facing output.

### ProductItem

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `product_id` (string, optional, nullable) — The resource ID of the product, that belongs to the product item.
- `product` (Product, optional, nullable)
- `name` (string, optional, nullable)
- `status` (enum, optional, nullable)
  - Allowed values: `DRAFT`, `ACTIVE`, `ARCHIVED`, `DEPRECATED`
- `reference` (string, optional)
- `description` (string, optional, nullable)
- `type` (enum, optional, nullable) — The type of the product item.
  - Allowed values: `REVENUE`, `DEDUCTION`
- `model_type` (enum, optional, nullable)
  - Allowed values: `USAGE_BASED`, `USAGE_BASED_CONVERSION`, `RECURRING`, `ONE_OFF`, `PER_SEAT`, `CREDITS`
- `usage_based` (ProductItemUsageBased, optional) — Additional settings in case of a USAGE_BASED type.
- `credits` (ProductItemCredits, optional) — Additional settings in case of a CREDITS type.
- `meter_value_calculation` (MeterValueCalculation, optional, nullable)
- `tax_category` (enum, optional, nullable) — The default tax category applied to the product item.
  - Allowed values: `STANDARD`, `NO_TAX`, `EXEMPT`
- `display_order` (integer, optional, nullable)
- `unit_name` (UnitName, optional)
- `custom_fields` (list of CustomFieldValue, optional, nullable) — Custom fields associated to this product item
- `customer_id` (string, optional, nullable)
- `agent_context` (AgentContext, optional) — Context for AI agents about this product item. Intended for agents, not for customer-facing output.
- `meter_value_calculation_id` (string, optional, nullable, deprecated) — The linked meter value calculation, in case of a USAGE_BASED charge type.
- `report_meter_value_calculation_ids` (list of string, optional, nullable, deprecated) — Optional reporting meter value calculations, in case of a USAGE_BASED charge type.

### DiscountConditionValue

- `amount` (Amount, optional)

### FeatureResourceReference

- `id` (string, optional, nullable) — The ID of the feature.
- `reference` (string, optional) — The reference of the feature.

### CustomFieldValue

- `id` (string, optional, nullable) — Resource ID of type CUSTOM_FIELD
- `reference` (string, optional, nullable)
- `value` (string, optional, nullable)
- `values` (list of string, optional, nullable)
- `integration_details` (IntegrationDetails, optional, nullable)
- `integration_id` (string, optional) — The resource ID of the integration linked to the custom field

### LinkedIntegration

- `id` (string, optional)
- `link_details` (list of LinkDetail, optional)

### AgentContext

- `guidance` (string, optional, nullable) — Free-text guidance for AI agents on how to interpret and use this resource.

### ProductItemUsageBased

- `meter_value_calculation_id` (string, optional, nullable) — The linked meter value calculation
- `meter_value_calculation` (MeterValueCalculation, optional, nullable)
- `tiering_meter_value_calculation_id` (string, optional, nullable) — The optional alternative linked meter value calculation for tiering
- `tiering_meter_value_calculation` (MeterValueCalculation, optional, nullable)
- `report_meter_value_calculation_ids` (list of string, optional, nullable) — Optional reporting meter value calculations.
- `conditions` (MeterConditions, optional) — Optional conditions.

### ProductItemCredits

- `credit_type_id` (string, optional, nullable) — The linked meter value calculation
- `credit_type` (CreditType, optional, nullable)

### MeterValueCalculation

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `reference` (string, optional)
- `name` (string, optional, nullable)
- `description` (string, optional, nullable)
- `calculation_type` (enum, optional, nullable) — The type of calculation used for this billable metric.
  - Allowed values: `SUM`, `MAX`, `MIN`, `AVERAGE`, `UNIQUE`
- `persist` (boolean, optional, nullable) — Indicate if the data of the billable metric must be persisted to the next billing period of the schedule (default is false).
- `meter_id` (string, optional, nullable) — The ID of the meter.
- `meter` (Meter, optional, nullable)
- `meter_value_id` (string, optional, nullable) — The ID of the meter value.
- `meter_value` (MeterValue, optional, nullable)
- `meter_property_id` (string, optional, nullable) — The ID of the meter property.
- `meter_property` (MeterProperty, optional, nullable)

### UnitName

- `singular` (string, optional)
- `plural` (string, optional, nullable)

### IntegrationDetails

- `id` (string, optional, nullable)
- `reference` (string, optional, nullable)
- `payment_gateway_variant` (enum, optional)
  - Allowed values: `ADYEN`, `STRIPE`
- `adyen` (AdyenIntegrationDetails, optional)
- `stripe` (StripeIntegrationDetails, optional)

### LinkDetail

- `url` (string, optional, nullable)
- `custom_field_name` (string, optional, nullable)

### MeterConditions

- `name` (string, optional, nullable)
- `expression` (MeterConditionExpression, optional)
- `meter_properties` (list of MeterPropertyCondition, optional, nullable, deprecated)

### CreditType

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `reference` (string, optional)
- `status` (enum, optional, nullable)
  - Allowed values: `DRAFT`, `ACTIVE`, `INACTIVE`, `DEPRECATED`, `ARCHIVED`
- `name` (string, optional)
- `description` (string, optional, nullable)
- `unit_name` (UnitName, optional)
- `created_at` (string, optional, nullable)
- `updated_at` (string, optional, nullable)

### Meter

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `reference` (string, optional)
- `name` (string, optional, nullable)
- `description` (string, optional, nullable)
- `status` (enum, optional, nullable) — The status of the meter indicating the activity of the meter and the ability to update properties.
  - Allowed values: `DRAFT`, `ACTIVE`, `ARCHIVED`, `DEPRECATED`
- `meter_values` (list of MeterMeterValue, optional, nullable) — The values used as input to calculate billable units, used in the meter.
- `meter_properties` (list of MeterMeterProperty, optional, nullable) — The properties that provide information to give context to an event, used in the meter.

### MeterValue

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `reference` (string, optional)
- `name` (string, optional, nullable)
- `description` (string, optional, nullable)
- `status` (enum, optional, nullable) — The status of the meter value indicating the activity and the ability to update properties.
  - Allowed values: `DRAFT`, `ACTIVE`, `ARCHIVED`, `DEPRECATED`
- `type` (enum, optional, nullable) — The type of the meter value.
  - Allowed values: `NUMBER`, `AMOUNT`

### MeterProperty

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `reference` (string, optional)
- `name` (string, optional, nullable)
- `description` (string, optional, nullable)
- `status` (enum, optional) — The status of the meter property indicating the activity and the ability to update properties.
  - Allowed values: `DRAFT`, `ACTIVE`, `ARCHIVED`, `DEPRECATED`
- `type` (enum, optional, nullable) — The type of the meter property.
  - Allowed values: `NUMBER`, `ENUM`, `STRING`
- `enum_values` (list of string, optional, nullable) — The list of available ENUM values.

### AdyenIntegrationDetails

- `recurring_detail_reference` (string, optional)

### StripeIntegrationDetails

- `payment_method_id` (string, optional)

### MeterConditionExpression

- `operator` (enum, optional)
  - Allowed values: `AND`, `OR`, `XOR`
- `operands` (list of MeterConditionOperand, optional, nullable)

### MeterPropertyCondition

- `id` (string, optional, nullable) — Resource ID of type METER_PROPERTY
- `reference` (string, optional, nullable)
- `meter_property` (MeterProperty, optional, nullable)
- `value` (string, optional, nullable)
- `values` (list of string, optional, nullable)
- `meter_property_variable_id` (string, optional, nullable) — Resource ID of type METER_PROPERTY_VARIABLE
- `meter_property_variable` (MeterPropertyVariable, optional, nullable)
- `comparator` (enum, optional)
  - Allowed values: `EQUALS`, `NOT_EQUALS`, `IN`, `NOT_IN`, `GREATER_THAN`, `GREATER_THAN_OR_EQUALS`, `LESS_THAN`, `LESS_THAN_OR_EQUALS`, `EMPTY`, `NOT_EMPTY`, `CONTAINS`, `NOT_CONTAINS`

### MeterMeterValue

- `id` (string, optional, nullable) — Resource ID of type METER_VALUE
- `object` (MeterValue, optional, nullable)
- `reference` (string, optional, nullable)
- `required` (boolean, optional, nullable)

### MeterMeterProperty

- `id` (string, optional, nullable) — Resource ID of type METER_PROPERTY
- `object` (MeterProperty, optional, nullable)
- `reference` (string, optional, nullable)
- `required` (boolean, optional, nullable)

### MeterConditionOperand

- `meter_property` (MeterPropertyCondition, optional)
- `expression` (MeterConditionOperandExpression, optional, nullable)

### MeterPropertyVariable

- `object_type` (string, optional, nullable)
- `id` (string, optional, nullable)
- `reference` (string, optional)
- `name` (string, optional, nullable)
- `description` (string, optional, nullable)
- `meter_property_id` (string, optional, nullable) — The meter property whose values this variable lists. Set on create only.
- `meter_property_reference` (string, optional, nullable) — Alternative to meter_property_id on create.
- `type` (enum, optional, nullable)
  - Allowed values: `LIST`
- `status` (enum, optional, nullable)
  - Allowed values: `DRAFT`, `ACTIVE`, `ARCHIVED`, `DEPRECATED`
- `values` (list of string, optional, nullable) — The initial values, on create only. Edit them afterwards through the values endpoint.
- `value_count` (integer, optional, nullable)
- `created_at` (string, optional, nullable)
- `updated_at` (string, optional, nullable)

### MeterConditionOperandExpression

## Examples

**Response**

```json
{
  "object_type": "string",
  "id": "string",
  "name": "string",
  "reference": "string",
  "description": "string",
  "status": "DRAFT",
  "discount": {
    "type": "PERCENTAGE",
    "percentage": "string",
    "amount": {
      "quantity": "string",
      "currency": "AED"
    },
    "usage": {
      "meter_value_id": "string",
      "number": "string",
      "amount": {
        "quantity": "string",
        "currency": "AED"
      }
    },
    "condition": {
      "comparator": "EQUALS",
      "value": {
        "amount": {
          "quantity": "string",
          "currency": "AED"
        }
      }
    }
  },
  "duration": {
    "type": "ONE_TIME",
    "period": {
      "type": "DAY",
      "value": 1
    }
  },
  "limited_to": {
    "product_category_ids": [
      "string"
    ],
    "product_ids": [
      "string"
    ],
    "product_item_ids": [
      "string"
    ],
    "product_categories": [
      {
        "object_type": "string",
        "id": "string",
        "name": "string",
        "reference": "string",
        "description": "string",
        "tax_category": "STANDARD",
        "display_order": 1,
        "customer_id": "string"
      }
    ],
    "products": [
      {
        "object_type": "string",
        "id": "string",
        "category_id": "string",
        "category": {
          "object_type": "string",
          "id": "string",
          "name": "string",
          "reference": "string",
          "description": "string",
          "tax_category": "STANDARD",
          "display_order": 1,
          "customer_id": "string"
        },
        "parent_product_id": "string",
        "name": "string",
        "reference": "string",
        "description": "string",
        "status": "DRAFT",
        "product_type": "DEFAULT",
        "tax_category": "STANDARD",
        "features": [
          {
            "id": "string",
            "reference": "string"
          }
        ],
        "custom_fields": [
          {
            "id": "string",
            "reference": "string",
            "value": "string",
            "values": [
              "string"
            ],
            "integration_details": {
              "id": "string",
              "reference": "string",
              "payment_gateway_variant": "ADYEN",
              "adyen": {
                "recurring_detail_reference": "string"
              },
              "stripe": {
                "payment_method_id": "string"
              }
            },
            "integration_id": "string"
          }
        ],
        "display_order": 1,
        "linked_integrations": [
          {
            "id": "string",
            "link_details": [
              {
                "url": "string",
                "custom_field_name": "string"
              }
            ]
          }
        ],
        "billing_entity_id": "string",
        "customer_id": "string",
        "agent_context": {
          "guidance": "string"
        }
      }
    ],
    "product_items": [
      {
        "object_type": "string",
        "id": "string",
        "product_id": "string",
        "product": {
          "object_type": "string",
          "id": "string",
          "category_id": "string",
          "category": {
            "object_type": "string",
            "id": "string",
            "name": "string",
            "reference": "string",
            "description": "string",
            "tax_category": "STANDARD",
            "display_order": 1,
            "customer_id": "string"
          },
          "parent_product_id": "string",
          "name": "string",
          "reference": "string",
          "description": "string",
          "status": "DRAFT",
          "product_type": "DEFAULT",
          "tax_category": "STANDARD",
          "features": [
            {
              "id": "string",
              "reference": "string"
            }
          ],
          "custom_fields": [
            {
              "id": "string",
              "reference": "string",
              "value": "string",
              "values": [
                "string"
              ],
              "integration_details": {
                "id": "string",
                "reference": "string",
                "payment_gateway_variant": "ADYEN",
                "adyen": {
                  "recurring_detail_reference": "string"
                },
                "stripe": {
                  "payment_method_id": "string"
                }
              },
              "integration_id": "string"
            }
          ],
          "display_order": 1,
          "linked_integrations": [
            {
              "id": "string",
              "link_details": [
                {
                  "url": "string",
                  "custom_field_name": "string"
                }
              ]
            }
          ],
          "billing_entity_id": "string",
          "customer_id": "string",
          "agent_context": {
            "guidance": "string"
          }
        },
        "name": "string",
        "status": "DRAFT",
        "reference": "string",
        "description": "string",
        "type": "REVENUE",
        "model_type": "USAGE_BASED",
        "usage_based": {
          "meter_value_calculation_id": "string",
          "meter_value_calculation": {
            "object_type": "string",
            "id": "string",
            "reference": "string",
            "name": "string",
            "description": "string",
            "calculation_type": "SUM",
            "persist": true,
            "meter_id": "string",
            "meter": {
              "object_type": "string",
              "id": "string",
              "reference": "string",
              "name": "string",
              "description": "string",
              "status": "DRAFT",
              "meter_values": [
                {
                  "id": "string",
                  "object": {
                    "object_type": "string",
                    "id": "string",
                    "reference": "string",
                    "name": "string",
                    "description": "string",
                    "status": "DRAFT",
                    "type": "NUMBER"
                  },
                  "required": true
                }
              ],
              "meter_properties": [
                {
                  "id": "string",
                  "object": {
                    "object_type": "string",
                    "id": "string",
                    "reference": "string",
                    "name": "string",
                    "description": "string",
                    "status": "DRAFT",
                    "type": "NUMBER",
                    "enum_values": [
                      "string"
                    ]
                  },
                  "required": true
                }
              ]
            },
            "meter_value_id": "string",
            "meter_value": {
              "object_type": "string",
              "id": "string",
              "reference": "string",
              "name": "string",
              "description": "string",
              "status": "DRAFT",
              "type": "NUMBER"
            },
            "meter_property_id": "string",
            "meter_property": {
              "object_type": "string",
              "id": "string",
              "reference": "string",
              "name": "string",
              "description": "string",
              "status": "DRAFT",
              "type": "NUMBER",
              "enum_values": [
                "string"
              ]
            }
          },
          "tiering_meter_value_calculation_id": "string",
          "tiering_meter_value_calculation": {
            "object_type": "string",
            "id": "string",
            "reference": "string",
            "name": "string",
            "description": "string",
            "calculation_type": "SUM",
            "persist": true,
            "meter_id": "string",
            "meter": {
              "object_type": "string",
              "id": "string",
              "reference": "string",
              "name": "string",
              "description": "string",
              "status": "DRAFT",
              "meter_values": [
                {
                  "id": "string",
                  "object": {
                    "object_type": "string",
                    "id": "string",
                    "reference": "string",
                    "name": "string",
                    "description": "string",
                    "status": "DRAFT",
                    "type": "NUMBER"
                  },
                  "required": true
                }
              ],
              "meter_properties": [
                {
                  "id": "string",
                  "object": {
                    "object_type": "string",
                    "id": "string",
                    "reference": "string",
                    "name": "string",
                    "description": "string",
                    "status": "DRAFT",
                    "type": "NUMBER",
                    "enum_values": [
                      "string"
                    ]
                  },
                  "required": true
                }
              ]
            },
            "meter_value_id": "string",
            "meter_value": {
              "object_type": "string",
              "id": "string",
              "reference": "string",
              "name": "string",
              "description": "string",
              "status": "DRAFT",
              "type": "NUMBER"
            },
            "meter_property_id": "string",
            "meter_property": {
              "object_type": "string",
              "id": "string",
              "reference": "string",
              "name": "string",
              "description": "string",
              "status": "DRAFT",
              "type": "NUMBER",
              "enum_values": [
                "string"
              ]
            }
          },
          "report_meter_value_calculation_ids": [
            "string"
          ],
          "conditions": {
            "name": "string",
            "expression": {
              "operator": "AND",
              "operands": [
                {
                  "meter_property": {
                    "id": "string",
                    "reference": "string",
                    "meter_property": {
                      "object_type": "string",
                      "id": "string",
                      "reference": "string",
                      "name": "string",
                      "description": "string",
                      "status": "DRAFT",
                      "type": "NUMBER",
                      "enum_values": [
                        "string"
                      ]
                    },
                    "value": "string",
                    "values": [
                      "string"
                    ],
                    "meter_property_variable_id": "string",
                    "meter_property_variable": {
                      "object_type": "string",
                      "id": "string",
                      "reference": "string",
                      "name": "string",
                      "description": "string",
                      "meter_property_id": "string",
                      "type": "LIST",
                      "status": "DRAFT",
                      "value_count": 1,
                      "created_at": "string",
                      "updated_at": "string"
                    },
                    "comparator": "EQUALS"
                  },
                  "expression": {}
                }
              ]
            },
            "meter_properties": [
              {
                "id": "string",
                "reference": "string",
                "meter_property": {
                  "object_type": "string",
                  "id": "string",
                  "reference": "string",
                  "name": "string",
                  "description": "string",
                  "status": "DRAFT",
                  "type": "NUMBER",
                  "enum_values": [
                    "string"
                  ]
                },
                "value": "string",
                "values": [
                  "string"
                ],
                "meter_property_variable_id": "string",
                "meter_property_variable": {
                  "object_type": "string",
                  "id": "string",
                  "reference": "string",
                  "name": "string",
                  "description": "string",
                  "meter_property_id": "string",
                  "type": "LIST",
                  "status": "DRAFT",
                  "value_count": 1,
                  "created_at": "string",
                  "updated_at": "string"
                },
                "comparator": "EQUALS"
              }
            ]
          }
        },
        "credits": {
          "credit_type_id": "string",
          "credit_type": {
            "object_type": "string",
            "id": "string",
            "reference": "string",
            "status": "DRAFT",
            "name": "string",
            "description": "string",
            "unit_name": {
              "singular": "string",
              "plural": "string"
            },
            "created_at": "string",
            "updated_at": "string"
          }
        },
        "meter_value_calculation": {
          "object_type": "string",
          "id": "string",
          "reference": "string",
          "name": "string",
          "description": "string",
          "calculation_type": "SUM",
          "persist": true,
          "meter_id": "string",
          "meter": {
            "object_type": "string",
            "id": "string",
            "reference": "string",
            "name": "string",
            "description": "string",
            "status": "DRAFT",
            "meter_values": [
              {
                "id": "string",
                "object": {
                  "object_type": "string",
                  "id": "string",
                  "reference": "string",
                  "name": "string",
                  "description": "string",
                  "status": "DRAFT",
                  "type": "NUMBER"
                },
                "required": true
              }
            ],
            "meter_properties": [
              {
                "id": "string",
                "object": {
                  "object_type": "string",
                  "id": "string",
                  "reference": "string",
                  "name": "string",
                  "description": "string",
                  "status": "DRAFT",
                  "type": "NUMBER",
                  "enum_values": [
                    "string"
                  ]
                },
                "required": true
              }
            ]
          },
          "meter_value_id": "string",
          "meter_value": {
            "object_type": "string",
            "id": "string",
            "reference": "string",
            "name": "string",
            "description": "string",
            "status": "DRAFT",
            "type": "NUMBER"
          },
          "meter_property_id": "string",
          "meter_property": {
            "object_type": "string",
            "id": "string",
            "reference": "string",
            "name": "string",
            "description": "string",
            "status": "DRAFT",
            "type": "NUMBER",
            "enum_values": [
              "string"
            ]
          }
        },
        "tax_category": "STANDARD",
        "display_order": 1,
        "unit_name": {
          "singular": "string",
          "plural": "string"
        },
        "custom_fields": [
          {
            "id": "string",
            "reference": "string",
            "value": "string",
            "values": [
              "string"
            ],
            "integration_details": {
              "id": "string",
              "reference": "string",
              "payment_gateway_variant": "ADYEN",
              "adyen": {
                "recurring_detail_reference": "string"
              },
              "stripe": {
                "payment_method_id": "string"
              }
            },
            "integration_id": "string"
          }
        ],
        "customer_id": "string",
        "agent_context": {
          "guidance": "string"
        },
        "meter_value_calculation_id": "string",
        "report_meter_value_calculation_ids": [
          "string"
        ]
      }
    ]
  },
  "start_at": "string",
  "end_at": "string",
  "maximum_redemptions": 1,
  "number_of_redemptions": 1,
  "created_at": "string",
  "updated_at": "string"
}
```

**SDK Code**

```python
import requests

url = "https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate"

headers = {"X-API-KEY": "<apiKey>"}

response = requests.post(url, headers=headers)

print(response.json())
```

```javascript
const url = 'https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate';
const options = {method: 'POST', headers: {'X-API-KEY': '<apiKey>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate"

	req, _ := http.NewRequest("POST", url, nil)

	req.Header.Add("X-API-KEY", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<apiKey>'

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate")
  .header("X-API-KEY", "<apiKey>")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate', [
  'headers' => [
    'X-API-KEY' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate");
var request = new RestRequest(Method.POST);
request.AddHeader("X-API-KEY", "<apiKey>");
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = ["X-API-KEY": "<apiKey>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://test.api.solvimon.com/v1/coupons/:resourceIdOrReference/deactivate")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```