curl --request PATCH \
--url https://api.novu.co/v1/notification-groups/{id} \
--header 'Authorization: ApiKey <NOVU_API_KEY>' \
--header 'Content-Type: application/json' \
--data '{"name": "insert-new-name"}'
import { Novu, TemplateVariableTypeEnum, FilterPartTypeEnum, StepTypeEnum } from '@novu/node';
const novu = new Novu('<NOVU_API_KEY>');
await novu.notificationGroups.update("notificationGroupId", { name: "Changelog Updates"});
<?php
$url = 'https://api.novu.co/v1/notification-groups/:id';
$data = array(
"name": "name"
);
$options = array(
"http" => array(
"header" => "Content-type: application/json",
"header" => "Authorization: ApiKey REPLACE_WITH_API_KEY",
"method" => "PATCH",
"content" => json_encode($data)
)
);
$context = stream_context_create($options);
$result = file_get_contents($url, false, $context);
if ($result === FALSE) { /* Handle error */ }
echo $result;
require 'net/http'
require 'uri'
uri = URI.parse('https://api.novu.co/v1/notification-groups/:id')
http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.request_uri)
request.body = '{
"name": "name"
}'
request.content_type = 'application/json'
request.add_field('Authorization', 'ApiKey REPLACE_WITH_API_KEY')
response = http.request(request)
puts response.body
import requests
response = requests.patch('https://api.novu.co/v1/notification-groups/:id', json={
"name": "name",
}, headers={
'Content-Type': 'application/json'
'Authorization': 'ApiKey REPLACE_WITH_API_KEY'
})
print(response.json())
import co.novu.sdk.Novu;
public class Main {
public static void main(String[] args) {
String apiKey = "<NOVU_API_KEY>";
Novu novu = new Novu(apiKey);
novu.updateWorkflowGroup(workflowId, body);
}
}
package main
import (
"fmt"
"net/http"
"encoding/json"
)
func main() {
url := "https://api.novu.co/v1/notification-groups/:id"
data := map[string]string{
"name": "name"
}
jsonValue, _ := json.Marshal(data)
req, _ := http.NewRequest("PATCH", url, bytes.NewBuffer(jsonValue))
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "ApiKey REPLACE_WITH_API_KEY")
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"data": {
"_id": "string",
"name": "string",
"_environmentId": "string",
"_organizationId": "string",
"_parentId": "string"
}
}
Workflow groups
Update workflow group
workflow group was previously named notification group
PATCH
/
v1
/
notification-groups
/
{id}
curl --request PATCH \
--url https://api.novu.co/v1/notification-groups/{id} \
--header 'Authorization: ApiKey <NOVU_API_KEY>' \
--header 'Content-Type: application/json' \
--data '{"name": "insert-new-name"}'
import { Novu, TemplateVariableTypeEnum, FilterPartTypeEnum, StepTypeEnum } from '@novu/node';
const novu = new Novu('<NOVU_API_KEY>');
await novu.notificationGroups.update("notificationGroupId", { name: "Changelog Updates"});
<?php
$url = 'https://api.novu.co/v1/notification-groups/:id';
$data = array(
"name": "name"
);
$options = array(
"http" => array(
"header" => "Content-type: application/json",
"header" => "Authorization: ApiKey REPLACE_WITH_API_KEY",
"method" => "PATCH",
"content" => json_encode($data)
)
);
$context = stream_context_create($options);
$result = file_get_contents($url, false, $context);
if ($result === FALSE) { /* Handle error */ }
echo $result;
require 'net/http'
require 'uri'
uri = URI.parse('https://api.novu.co/v1/notification-groups/:id')
http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.request_uri)
request.body = '{
"name": "name"
}'
request.content_type = 'application/json'
request.add_field('Authorization', 'ApiKey REPLACE_WITH_API_KEY')
response = http.request(request)
puts response.body
import requests
response = requests.patch('https://api.novu.co/v1/notification-groups/:id', json={
"name": "name",
}, headers={
'Content-Type': 'application/json'
'Authorization': 'ApiKey REPLACE_WITH_API_KEY'
})
print(response.json())
import co.novu.sdk.Novu;
public class Main {
public static void main(String[] args) {
String apiKey = "<NOVU_API_KEY>";
Novu novu = new Novu(apiKey);
novu.updateWorkflowGroup(workflowId, body);
}
}
package main
import (
"fmt"
"net/http"
"encoding/json"
)
func main() {
url := "https://api.novu.co/v1/notification-groups/:id"
data := map[string]string{
"name": "name"
}
jsonValue, _ := json.Marshal(data)
req, _ := http.NewRequest("PATCH", url, bytes.NewBuffer(jsonValue))
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "ApiKey REPLACE_WITH_API_KEY")
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"data": {
"_id": "string",
"name": "string",
"_environmentId": "string",
"_organizationId": "string",
"_parentId": "string"
}
}
Enter your API key in the
Authorization field like the example shown below:E.g ApiKey 18d2e625f05d80ecurl --request PATCH \
--url https://api.novu.co/v1/notification-groups/{id} \
--header 'Authorization: ApiKey <NOVU_API_KEY>' \
--header 'Content-Type: application/json' \
--data '{"name": "insert-new-name"}'
import { Novu, TemplateVariableTypeEnum, FilterPartTypeEnum, StepTypeEnum } from '@novu/node';
const novu = new Novu('<NOVU_API_KEY>');
await novu.notificationGroups.update("notificationGroupId", { name: "Changelog Updates"});
<?php
$url = 'https://api.novu.co/v1/notification-groups/:id';
$data = array(
"name": "name"
);
$options = array(
"http" => array(
"header" => "Content-type: application/json",
"header" => "Authorization: ApiKey REPLACE_WITH_API_KEY",
"method" => "PATCH",
"content" => json_encode($data)
)
);
$context = stream_context_create($options);
$result = file_get_contents($url, false, $context);
if ($result === FALSE) { /* Handle error */ }
echo $result;
require 'net/http'
require 'uri'
uri = URI.parse('https://api.novu.co/v1/notification-groups/:id')
http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.request_uri)
request.body = '{
"name": "name"
}'
request.content_type = 'application/json'
request.add_field('Authorization', 'ApiKey REPLACE_WITH_API_KEY')
response = http.request(request)
puts response.body
import requests
response = requests.patch('https://api.novu.co/v1/notification-groups/:id', json={
"name": "name",
}, headers={
'Content-Type': 'application/json'
'Authorization': 'ApiKey REPLACE_WITH_API_KEY'
})
print(response.json())
import co.novu.sdk.Novu;
public class Main {
public static void main(String[] args) {
String apiKey = "<NOVU_API_KEY>";
Novu novu = new Novu(apiKey);
novu.updateWorkflowGroup(workflowId, body);
}
}
package main
import (
"fmt"
"net/http"
"encoding/json"
)
func main() {
url := "https://api.novu.co/v1/notification-groups/:id"
data := map[string]string{
"name": "name"
}
jsonValue, _ := json.Marshal(data)
req, _ := http.NewRequest("PATCH", url, bytes.NewBuffer(jsonValue))
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "ApiKey REPLACE_WITH_API_KEY")
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"data": {
"_id": "string",
"name": "string",
"_environmentId": "string",
"_organizationId": "string",
"_parentId": "string"
}
}
Authorizations
API key authentication. Allowed headers-- "Authorization: ApiKey <api_key>".
Path Parameters
Body
application/json
Was this page helpful?
⌘I