Remove a privilege from a subscription entitlement override
curl --request DELETE \
--url https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code} \
--header 'Authorization: Bearer <token>'import requests
url = "https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.delete("https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}")
.header("Authorization", "Bearer <token>")
.asString();{
"entitlement": {
"code": "seats",
"name": "Number of seats",
"description": "Number of users of the account",
"privileges": [
{
"code": "max",
"name": "Maximum",
"value_type": "integer",
"config": {},
"value": 15,
"plan_value": 10,
"override_value": 15
},
{
"code": "max_admins",
"name": "Max Admins",
"value_type": "integer",
"config": {},
"value": 5,
"plan_value": 5,
"override_value": null
},
{
"code": "root",
"name": "Allow root user",
"value_type": "boolean",
"config": {},
"value": true,
"plan_value": true,
"override_value": null
},
{
"code": "provider",
"name": "SSO Provider",
"value_type": "select",
"value": "okta",
"plan_value": "google",
"override_value": "okta",
"config": {
"select_options": [
"google",
"okta"
]
}
}
],
"overrides": {
"max": 15,
"provider": "okta"
}
}
}{
"status": 400,
"error": "Bad request"
}{
"status": 401,
"error": "Unauthorized"
}{
"status": 404,
"error": "Not Found",
"code": "object_not_found"
}Features & Entitlements
Remove a privilege from a subscription entitlement override
This endpoint removes a specific privilege from a subscription entitlement. The privilege entitlement remains available from the plan.
DELETE
/
subscriptions
/
{external_id}
/
entitlements
/
{feature_code}
/
privileges
/
{privilege_code}
Remove a privilege from a subscription entitlement override
curl --request DELETE \
--url https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code} \
--header 'Authorization: Bearer <token>'import requests
url = "https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.delete("https://core.nozle.app/api/v1/subscriptions/{external_id}/entitlements/{feature_code}/privileges/{privilege_code}")
.header("Authorization", "Bearer <token>")
.asString();{
"entitlement": {
"code": "seats",
"name": "Number of seats",
"description": "Number of users of the account",
"privileges": [
{
"code": "max",
"name": "Maximum",
"value_type": "integer",
"config": {},
"value": 15,
"plan_value": 10,
"override_value": 15
},
{
"code": "max_admins",
"name": "Max Admins",
"value_type": "integer",
"config": {},
"value": 5,
"plan_value": 5,
"override_value": null
},
{
"code": "root",
"name": "Allow root user",
"value_type": "boolean",
"config": {},
"value": true,
"plan_value": true,
"override_value": null
},
{
"code": "provider",
"name": "SSO Provider",
"value_type": "select",
"value": "okta",
"plan_value": "google",
"override_value": "okta",
"config": {
"select_options": [
"google",
"okta"
]
}
}
],
"overrides": {
"max": 15,
"provider": "okta"
}
}
}{
"status": 400,
"error": "Bad request"
}{
"status": 401,
"error": "Unauthorized"
}{
"status": 404,
"error": "Not Found",
"code": "object_not_found"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
External ID of the existing subscription
Example:
"5eb02857-a71e-4ea2-bcf9-57d3a41bc6ba"
Code of the existing feature.
Example:
"seats"
Code of the privilege to remove from the subscription entitlement override.
Example:
"max_admins"
Query Parameters
Filter by subscription status. When provided, the subscription is looked up with this status instead of the default active status. Possible values are pending, active, terminated, or canceled.
Available options:
pending, active, terminated, canceled Example:
"active"
Response
Subscription entitlement with privilege override removed
Show child attributes
Show child attributes