Skip to main content
PUT
/
subscriptions
/
{platformType}
/
{subscriptionRef}
Replace an existing subscription (full PUT)
curl --request PUT \
  --url https://{host}/subscriptions/{platformType}/{subscriptionRef} \
  --header 'Content-Type: application/json' \
  --data '
{
  "subscriptionName": "<string>",
  "owner": "<string>",
  "description": "<string>",
  "outputType": "application/json",
  "active": "false",
  "propertyReferences": [
    {
      "propertyID": "<string>",
      "operator": "<string>",
      "values": [
        "<string>"
      ]
    }
  ],
  "tagReferences": [
    {
      "tagID": "<string>",
      "operator": "<string>",
      "values": [
        "<string>"
      ]
    }
  ],
  "suppressionReferences": [
    {
      "suppressionID": "<string>",
      "operator": "<string>",
      "values": [
        "<string>"
      ],
      "revokeBy": "<string>"
    }
  ],
  "returnStructure": {
    "showAliases": false,
    "fields": [
      "<string>"
    ]
  },
  "schedule": {
    "frequency": "<string>",
    "at": "<string>"
  }
}
'
import requests

url = "https://{host}/subscriptions/{platformType}/{subscriptionRef}"

payload = {
"subscriptionName": "<string>",
"owner": "<string>",
"description": "<string>",
"outputType": "application/json",
"active": "false",
"propertyReferences": [
{
"propertyID": "<string>",
"operator": "<string>",
"values": ["<string>"]
}
],
"tagReferences": [
{
"tagID": "<string>",
"operator": "<string>",
"values": ["<string>"]
}
],
"suppressionReferences": [
{
"suppressionID": "<string>",
"operator": "<string>",
"values": ["<string>"],
"revokeBy": "<string>"
}
],
"returnStructure": {
"showAliases": False,
"fields": ["<string>"]
},
"schedule": {
"frequency": "<string>",
"at": "<string>"
}
}
headers = {"Content-Type": "application/json"}

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

print(response.text)
const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
subscriptionName: '<string>',
owner: '<string>',
description: '<string>',
outputType: 'application/json',
active: 'false',
propertyReferences: [{propertyID: '<string>', operator: '<string>', values: ['<string>']}],
tagReferences: [{tagID: '<string>', operator: '<string>', values: ['<string>']}],
suppressionReferences: [
{
suppressionID: '<string>',
operator: '<string>',
values: ['<string>'],
revokeBy: '<string>'
}
],
returnStructure: {showAliases: false, fields: ['<string>']},
schedule: {frequency: '<string>', at: '<string>'}
})
};

fetch('https://{host}/subscriptions/{platformType}/{subscriptionRef}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/subscriptions/{platformType}/{subscriptionRef}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'subscriptionName' => '<string>',
'owner' => '<string>',
'description' => '<string>',
'outputType' => 'application/json',
'active' => 'false',
'propertyReferences' => [
[
'propertyID' => '<string>',
'operator' => '<string>',
'values' => [
'<string>'
]
]
],
'tagReferences' => [
[
'tagID' => '<string>',
'operator' => '<string>',
'values' => [
'<string>'
]
]
],
'suppressionReferences' => [
[
'suppressionID' => '<string>',
'operator' => '<string>',
'values' => [
'<string>'
],
'revokeBy' => '<string>'
]
],
'returnStructure' => [
'showAliases' => false,
'fields' => [
'<string>'
]
],
'schedule' => [
'frequency' => '<string>',
'at' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

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

func main() {

url := "https://{host}/subscriptions/{platformType}/{subscriptionRef}"

payload := strings.NewReader("{\n \"subscriptionName\": \"<string>\",\n \"owner\": \"<string>\",\n \"description\": \"<string>\",\n \"outputType\": \"application/json\",\n \"active\": \"false\",\n \"propertyReferences\": [\n {\n \"propertyID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ]\n }\n ],\n \"tagReferences\": [\n {\n \"tagID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ]\n }\n ],\n \"suppressionReferences\": [\n {\n \"suppressionID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ],\n \"revokeBy\": \"<string>\"\n }\n ],\n \"returnStructure\": {\n \"showAliases\": false,\n \"fields\": [\n \"<string>\"\n ]\n },\n \"schedule\": {\n \"frequency\": \"<string>\",\n \"at\": \"<string>\"\n }\n}")

req, _ := http.NewRequest("PUT", 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(string(body))

}
HttpResponse<String> response = Unirest.put("https://{host}/subscriptions/{platformType}/{subscriptionRef}")
.header("Content-Type", "application/json")
.body("{\n \"subscriptionName\": \"<string>\",\n \"owner\": \"<string>\",\n \"description\": \"<string>\",\n \"outputType\": \"application/json\",\n \"active\": \"false\",\n \"propertyReferences\": [\n {\n \"propertyID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ]\n }\n ],\n \"tagReferences\": [\n {\n \"tagID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ]\n }\n ],\n \"suppressionReferences\": [\n {\n \"suppressionID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ],\n \"revokeBy\": \"<string>\"\n }\n ],\n \"returnStructure\": {\n \"showAliases\": false,\n \"fields\": [\n \"<string>\"\n ]\n },\n \"schedule\": {\n \"frequency\": \"<string>\",\n \"at\": \"<string>\"\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://{host}/subscriptions/{platformType}/{subscriptionRef}")

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

request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"subscriptionName\": \"<string>\",\n \"owner\": \"<string>\",\n \"description\": \"<string>\",\n \"outputType\": \"application/json\",\n \"active\": \"false\",\n \"propertyReferences\": [\n {\n \"propertyID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ]\n }\n ],\n \"tagReferences\": [\n {\n \"tagID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ]\n }\n ],\n \"suppressionReferences\": [\n {\n \"suppressionID\": \"<string>\",\n \"operator\": \"<string>\",\n \"values\": [\n \"<string>\"\n ],\n \"revokeBy\": \"<string>\"\n }\n ],\n \"returnStructure\": {\n \"showAliases\": false,\n \"fields\": [\n \"<string>\"\n ]\n },\n \"schedule\": {\n \"frequency\": \"<string>\",\n \"at\": \"<string>\"\n }\n}"

response = http.request(request)
puts response.read_body
{
  "subscriptionRef": "<string>",
  "subscriptionName": "<string>",
  "description": "<string>",
  "owner": "<string>",
  "outputType": "<string>",
  "webhook": {
    "uri": "<string>",
    "authType": "<string>",
    "authValue": "<string>"
  },
  "propertyReferences": [
    {
      "propertyID": "<string>",
      "operator": "<string>",
      "values": [
        "<string>"
      ]
    }
  ],
  "tagReferences": [
    {
      "tagID": "<string>",
      "operator": "<string>",
      "values": [
        "<string>"
      ]
    }
  ],
  "suppressionReferences": [
    {
      "suppressionID": "<string>",
      "operator": "<string>",
      "values": [
        "<string>"
      ],
      "revokeBy": "<string>"
    }
  ],
  "returnStructure": {
    "showAliases": false,
    "fields": [
      "<string>"
    ]
  },
  "schedule": {
    "frequency": "<string>",
    "at": "<string>"
  },
  "webhookStatus": "<string>",
  "lastTriggered": "<string>",
  "message": "<string>",
  "status": 123
}

Path Parameters

platformType
enum<string>
required

Technology platform (cloud or containers).

Available options:
cloud,
containers
subscriptionRef
string
required

Unique subscription identifier.

Body

application/json

Provide at least one of: propertyReferences, tagReferences, or suppressionReferences.

subscriptionName
string

Unique per platform if global; unique per owner if private.

owner
string

"" for global (admin only) or username for private; non-admins default to their username.

description
string
outputType
enum<string>
default:application/json

Only supported output type.

Available options:
application/json
active
enum<string>
default:false

true=active; false=dormant (no scheduled posts; on-demand still available).

Available options:
true,
false
webhook
object

Webhook destination for delivering subscription notifications.

propertyReferences
object[]
tagReferences
object[]
suppressionReferences
object[]
returnStructure
object
schedule
object

If omitted, notifications typically trigger nightly after analysis/reporting.

Response

Updated subscription

subscriptionRef
string
required

Unique ID assigned to the subscription.

subscriptionName
string
required
description
string
owner
string

Empty for global; username for private.

outputType
string
active
enum<string>
Available options:
true,
false
webhook
object

Webhook destination for delivering subscription notifications.

propertyReferences
object[]
tagReferences
object[]
suppressionReferences
object[]
returnStructure
object
schedule
object

If omitted, notifications typically trigger nightly after analysis/reporting.

webhookStatus
string

Success | Failure of last push to webhook (with timestamp).

lastTriggered
string

On-Demand Success/Failure or Scheduled Success/Failure with timestamp.

message
string

Error/status message (on error).

status
integer

HTTP-like status code (200, 204, 400, 401, 404, 415, 500).