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

# Void entitlements

POST https://restapi.ordergroove.com/entitlements/void/
Content-Type: application/json

Voids multiple entitlements. Entitlements are voided independently, so one entitlement failing does not stop the others from being voided — check each entry in `results` for an `error` field to see which succeeded. If any entitlement fails, the response status is `207` instead of `200`. For each entitlement voided:

- `live` is updated to `false`
- `expiration` is updated to the time of execution
- `grace_period` is updated to `0`
- An `EntitlementTransaction` is created
- An `entitlement.entitlements_voided` event is triggered upon successful modification

Requires [Application API Scope](/api-reference/authentication#application-api-scope) authentication.

Reference: https://developer.ordergroove.com/reference/entitlements-service-api/entitlements/post-entitlements-void

## Request

### Body (application/json)

This endpoint expects an object.

- `entitlement_public_ids` (list of string, required) — List of entitlement public_ids to void

## Response

### 200

- `results` (map from string to VoidResultEntrySuccess, required) — Void results, keyed by entitlement `public_id`.

### 207

Multi-Status. Returned when at least one entitlement in the request could not be voided. Check each entry in `results` for an `error` field to see which succeeded and which failed.

- `results` (map from string to VoidResultEntry, required) — Void results, keyed by entitlement `public_id`.

## Types

### VoidResultEntrySuccess

The outcome for a successfully voided entitlement.

- `entitlement_transaction` (EntitlementTransaction, required) — A transaction recorded against an entitlement.
- `entitlement` (Entitlement, required) — An entitlement granting a customer access to a resource.

### VoidResultEntry

The outcome for a single entitlement in the void request. On success, `entitlement_transaction` and `entitlement` are present. On failure, `error` is present instead.

- `entitlement_transaction` (EntitlementTransaction, optional) — A transaction recorded against an entitlement.
- `entitlement` (Entitlement, optional) — An entitlement granting a customer access to a resource.
- `error` (Problem, optional) — An error for a single entitlement that could not be voided.

### EntitlementTransaction

A transaction recorded against an entitlement.

- `transaction_type` (string, required) — The type of transaction.
- `public_id` (string, required) — Transaction ID.
- `entitlement_public_id` (string, required) — ID of the entitlement the transaction was recorded against.
- `merchant_user_id` (string, required) — Customer ID.
- `resource_public_id` (string, required) — Resource ID.
- `merchant_public_id` (string, required) — Merchant ID.
- `transaction_initiation_time` (string, required) — Time the transaction was initiated (UTC).
- `transaction_execution_time` (string, required, nullable) — Time the transaction was executed (UTC).
- `source_action` (string, required) — The action that triggered the transaction.
- `source_object` (string, required, nullable) — The type of object that triggered the transaction.
- `source_object_id` (string, required, nullable) — ID of the object that triggered the transaction.
- `access_type` (string, required, nullable) — The entitlement's access type at the time of the transaction.
- `grace_period` (integer, required, nullable) — Grace period, in seconds.
- `expiration` (string, required, nullable) — Expiration datetime (UTC).
- `grace_period_expiration` (string, required, nullable) — Expiration datetime including the grace period (UTC).

### Entitlement

An entitlement granting a customer access to a resource.

- `merchant` (string, required) — Merchant ID.
- `public_id` (string, required) — Entitlement ID.
- `merchant_user_id` (string, required) — Customer ID.
- `initial_activation_date` (string, required, nullable) — Initial activation date (UTC).
- `latest_activation_date` (string, required, nullable) — Latest activation date (UTC).
- `grace_period` (integer, required, nullable) — Grace period, in seconds.
- `live` (boolean, required) — Whether the resource this entitlement grants access to is currently accessible. Accounts for `grace_period`.
- `access_type` (string, required) — The entitlement's access type.
- `expiration` (string, required, nullable) — Entitlement access expiration date (UTC).
- `created` (string, required) — Date the entitlement was created (UTC).
- `last_updated` (string, required) — Date the entitlement was last updated (UTC).
- `grantees` (list of Grantee, required, nullable) — Grantees associated with the entitlement. `null` if there are none.
- `resource` (Resource, optional) — The resource this entitlement grants access to.

### Problem

An error for a single entitlement that could not be voided.

- `title` (string, required)
- `status` (integer, required)
- `detail` (string, optional)

### Grantee

- `external_id` (string, required) — The grantee's external ID.
- `name` (string, required) — The grantee's name.
- `created` (string, required) — Date the grantee was created (UTC).
- `updated` (string, required) — Date the grantee was last updated (UTC).

### Resource

- `public_id` (string, required) — Resource ID.
- `merchant` (string, required) — Merchant ID.
- `name` (string, required) — Resource name.
- `external_resource_id` (string, required, nullable) — Merchant resource ID.
- `identified_product_external_id` (string, required, nullable) — External ID of the Ordergroove product this resource is linked to for subscription renewal syncing. Present only when the resource is tied to a meta-entitlement; `null` otherwise.
- `description` (string, required, nullable) — Resource description.
- `image_url` (string, required, nullable) — Resource image URL.
- `created` (string, required) — Date the resource was created (UTC).
- `last_updated` (string, required) — Date the resource was last updated (UTC).

## Examples

### OK

**Request**

```json
{
  "entitlement_public_ids": [
    "4e9d934275734a859a7f8d98dc52c8af",
    "5289bf2ad76e4fde881ad1a89a55b5dc"
  ]
}
```

**Response**

```json
{
  "results": {
    "4e9d934275734a859a7f8d98dc52c8af": {
      "entitlement_transaction": {
        "transaction_type": "entitlement_voided",
        "public_id": "b95671a531974f6a98d7156e72284c34",
        "entitlement_public_id": "4e9d934275734a859a7f8d98dc52c8af",
        "merchant_user_id": "23799452926316",
        "resource_public_id": "3fa56741671444bdbcdf7b1554f67bee",
        "merchant_public_id": "80c9a167fb434fa0abe215c7f19a86cc",
        "transaction_initiation_time": "2026-04-07T18:36:24.908319269Z",
        "transaction_execution_time": "2026-04-07T18:36:24.908319269Z",
        "source_action": "api-call",
        "source_object": "user",
        "source_object_id": "dd0756ea-f502-4292-931e-b48f26677ef9_2026-04-07T18:36:24.908319269Z",
        "access_type": "time_based",
        "grace_period": 0,
        "expiration": "2026-04-07T18:36:24.908319269Z",
        "grace_period_expiration": "2026-04-07T18:36:24.908319269Z"
      },
      "entitlement": {
        "merchant": "80c9a167fb434fa0abe215c7f19a86cc",
        "public_id": "4e9d934275734a859a7f8d98dc52c8af",
        "merchant_user_id": "23799452926316",
        "initial_activation_date": null,
        "latest_activation_date": null,
        "grace_period": 0,
        "live": false,
        "access_type": "time_based",
        "expiration": "2026-04-07T18:36:24.908319269Z",
        "created": "2026-03-16T17:00:13.059Z",
        "last_updated": "2026-04-07T18:36:24.912728516Z",
        "grantees": [
          {
            "external_id": "qveq35",
            "name": "vwW4w4fv",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "F2VS",
            "name": "F4Q34",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "BES576FYE4DS5ET",
            "name": "AE5 YBEYA5V",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "W4T6C",
            "name": "A W AGW4",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "EM. DTSCRTRGXTD",
            "name": "awww eh5q",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "we5yyvw5",
            "name": "arg. ag",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "yvac3y",
            "name": "we. WT4GW4",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "QT4VQ3CRAE",
            "name": "SEH SRJMDSRZRGE",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          },
          {
            "external_id": "Wr gcax4wEab",
            "name": "ag wGaawg",
            "created": "2026-03-16T17:00:12.907Z",
            "updated": "2026-03-16T17:00:12.907Z"
          }
        ],
        "resource": {
          "public_id": "3fa56741671444bdbcdf7b1554f67bee",
          "merchant": "80c9a167fb434fa0abe215c7f19a86cc",
          "name": "Advanced Phonics for Professionals - With Tutoring",
          "external_resource_id": "53204456309100",
          "identified_product_external_id": null,
          "description": null,
          "image_url": null,
          "created": "2026-02-26T15:54:29.306Z",
          "last_updated": "2026-02-26T15:54:29.306Z"
        }
      }
    },
    "5289bf2ad76e4fde881ad1a89a55b5dc": {
      "entitlement_transaction": {
        "transaction_type": "entitlement_voided",
        "public_id": "452c6a1b3f3d4c178257ae2449709157",
        "entitlement_public_id": "5289bf2ad76e4fde881ad1a89a55b5dc",
        "merchant_user_id": "23799452926316",
        "resource_public_id": "04f5d0ab2dca4111ba785abc714e9010",
        "merchant_public_id": "80c9a167fb434fa0abe215c7f19a86cc",
        "transaction_initiation_time": "2026-04-07T18:36:24.908266844Z",
        "transaction_execution_time": "2026-04-07T18:36:24.908266844Z",
        "source_action": "api-call",
        "source_object": "user",
        "source_object_id": "dd0756ea-f502-4292-931e-b48f26677ef9_2026-04-07T18:36:24.908266844Z",
        "access_type": "time_based",
        "grace_period": 0,
        "expiration": "2026-04-07T18:36:24.908266844Z",
        "grace_period_expiration": "2026-04-07T18:36:24.908266844Z"
      },
      "entitlement": {
        "merchant": "80c9a167fb434fa0abe215c7f19a86cc",
        "public_id": "5289bf2ad76e4fde881ad1a89a55b5dc",
        "merchant_user_id": "23799452926316",
        "initial_activation_date": null,
        "latest_activation_date": null,
        "grace_period": 0,
        "live": false,
        "access_type": "time_based",
        "expiration": "2026-04-07T18:36:24.908266844Z",
        "created": "2026-04-07T16:45:43.119Z",
        "last_updated": "2026-04-07T18:36:24.917619184Z",
        "grantees": null,
        "resource": {
          "public_id": "04f5d0ab2dca4111ba785abc714e9010",
          "merchant": "80c9a167fb434fa0abe215c7f19a86cc",
          "name": "taco",
          "external_resource_id": "taco",
          "identified_product_external_id": null,
          "description": null,
          "image_url": null,
          "created": "2026-02-25T17:17:27.623Z",
          "last_updated": "2026-02-25T17:17:27.623Z"
        }
      }
    }
  }
}
```

**SDK Code**

```python OK
import requests

url = "https://restapi.ordergroove.com/entitlements/void/"

payload = { "entitlement_public_ids": ["4e9d934275734a859a7f8d98dc52c8af", "5289bf2ad76e4fde881ad1a89a55b5dc"] }
headers = {"Content-Type": "application/json"}

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

print(response.json())
```

```javascript OK
const url = 'https://restapi.ordergroove.com/entitlements/void/';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: '{"entitlement_public_ids":["4e9d934275734a859a7f8d98dc52c8af","5289bf2ad76e4fde881ad1a89a55b5dc"]}'
};

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

```go OK
package main

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

func main() {

	url := "https://restapi.ordergroove.com/entitlements/void/"

	payload := strings.NewReader("{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}")

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

	req.Header.Add("Content-Type", "application/json")

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

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

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

}
```

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

url = URI("https://restapi.ordergroove.com/entitlements/void/")

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

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}"

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

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

HttpResponse<String> response = Unirest.post("https://restapi.ordergroove.com/entitlements/void/")
  .header("Content-Type", "application/json")
  .body("{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://restapi.ordergroove.com/entitlements/void/', [
  'body' => '{
  "entitlement_public_ids": [
    "4e9d934275734a859a7f8d98dc52c8af",
    "5289bf2ad76e4fde881ad1a89a55b5dc"
  ]
}',
  'headers' => [
    'Content-Type' => 'application/json',
  ],
]);

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

```csharp OK
using RestSharp;

var client = new RestClient("https://restapi.ordergroove.com/entitlements/void/");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift OK
import Foundation

let headers = ["Content-Type": "application/json"]
let parameters = ["entitlement_public_ids": ["4e9d934275734a859a7f8d98dc52c8af", "5289bf2ad76e4fde881ad1a89a55b5dc"]] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://restapi.ordergroove.com/entitlements/void/")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

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()
```

### Partial failure

**Request**

```json
{
  "entitlement_public_ids": [
    "4e9d934275734a859a7f8d98dc52c8af",
    "5289bf2ad76e4fde881ad1a89a55b5dc"
  ]
}
```

**Response**

```json
{
  "results": {
    "4e9d934275734a859a7f8d98dc52c8af": {
      "entitlement_transaction": {
        "transaction_type": "entitlement_voided",
        "public_id": "b95671a531974f6a98d7156e72284c34",
        "entitlement_public_id": "4e9d934275734a859a7f8d98dc52c8af",
        "merchant_user_id": "23799452926316",
        "resource_public_id": "3fa56741671444bdbcdf7b1554f67bee",
        "merchant_public_id": "80c9a167fb434fa0abe215c7f19a86cc",
        "transaction_initiation_time": "2026-04-07T18:36:24.908319269Z",
        "transaction_execution_time": "2026-04-07T18:36:24.908319269Z",
        "source_action": "api-call",
        "source_object": "user",
        "source_object_id": "dd0756ea-f502-4292-931e-b48f26677ef9_2026-04-07T18:36:24.908319269Z",
        "access_type": "time_based",
        "grace_period": 0,
        "expiration": "2026-04-07T18:36:24.908319269Z",
        "grace_period_expiration": "2026-04-07T18:36:24.908319269Z"
      },
      "entitlement": {
        "merchant": "80c9a167fb434fa0abe215c7f19a86cc",
        "public_id": "4e9d934275734a859a7f8d98dc52c8af",
        "merchant_user_id": "23799452926316",
        "initial_activation_date": null,
        "latest_activation_date": null,
        "grace_period": 0,
        "live": false,
        "access_type": "time_based",
        "expiration": "2026-04-07T18:36:24.908319269Z",
        "created": "2026-03-16T17:00:13.059Z",
        "last_updated": "2026-04-07T18:36:24.912728516Z",
        "grantees": null
      }
    },
    "5289bf2ad76e4fde881ad1a89a55b5dc": {
      "error": {
        "title": "Not Found",
        "status": 404,
        "detail": "Entitlement 5289bf2ad76e4fde881ad1a89a55b5dc not found"
      }
    }
  }
}
```

**SDK Code**

```python Partial failure
import requests

url = "https://restapi.ordergroove.com/entitlements/void/"

payload = { "entitlement_public_ids": ["4e9d934275734a859a7f8d98dc52c8af", "5289bf2ad76e4fde881ad1a89a55b5dc"] }
headers = {"Content-Type": "application/json"}

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

print(response.json())
```

```javascript Partial failure
const url = 'https://restapi.ordergroove.com/entitlements/void/';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: '{"entitlement_public_ids":["4e9d934275734a859a7f8d98dc52c8af","5289bf2ad76e4fde881ad1a89a55b5dc"]}'
};

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

```go Partial failure
package main

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

func main() {

	url := "https://restapi.ordergroove.com/entitlements/void/"

	payload := strings.NewReader("{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}")

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

	req.Header.Add("Content-Type", "application/json")

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

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

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

}
```

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

url = URI("https://restapi.ordergroove.com/entitlements/void/")

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

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}"

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

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

HttpResponse<String> response = Unirest.post("https://restapi.ordergroove.com/entitlements/void/")
  .header("Content-Type", "application/json")
  .body("{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://restapi.ordergroove.com/entitlements/void/', [
  'body' => '{
  "entitlement_public_ids": [
    "4e9d934275734a859a7f8d98dc52c8af",
    "5289bf2ad76e4fde881ad1a89a55b5dc"
  ]
}',
  'headers' => [
    'Content-Type' => 'application/json',
  ],
]);

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

```csharp Partial failure
using RestSharp;

var client = new RestClient("https://restapi.ordergroove.com/entitlements/void/");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"entitlement_public_ids\": [\n    \"4e9d934275734a859a7f8d98dc52c8af\",\n    \"5289bf2ad76e4fde881ad1a89a55b5dc\"\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Partial failure
import Foundation

let headers = ["Content-Type": "application/json"]
let parameters = ["entitlement_public_ids": ["4e9d934275734a859a7f8d98dc52c8af", "5289bf2ad76e4fde881ad1a89a55b5dc"]] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://restapi.ordergroove.com/entitlements/void/")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

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()
```