curl --request PUT \
--url https://api.axiom.co/v2/rbac/roles/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"datasetCapabilities": {},
"description": "<string>",
"members": [
"<string>"
],
"orgCapabilities": {
"annotations": [],
"apiTokens": [],
"auditLog": [
"read"
],
"billing": [],
"dashboards": [],
"datasets": [],
"endpoints": [],
"flows": [],
"integrations": [],
"monitors": [],
"notifiers": [],
"rbac": [],
"sharedAccessKeys": [],
"users": [],
"views": []
},
"viewCapabilities": {}
}
'import requests
url = "https://api.axiom.co/v2/rbac/roles/{id}"
payload = {
"name": "<string>",
"datasetCapabilities": {},
"description": "<string>",
"members": ["<string>"],
"orgCapabilities": {
"annotations": [],
"apiTokens": [],
"auditLog": ["read"],
"billing": [],
"dashboards": [],
"datasets": [],
"endpoints": [],
"flows": [],
"integrations": [],
"monitors": [],
"notifiers": [],
"rbac": [],
"sharedAccessKeys": [],
"users": [],
"views": []
},
"viewCapabilities": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
datasetCapabilities: {},
description: '<string>',
members: ['<string>'],
orgCapabilities: {
annotations: [],
apiTokens: [],
auditLog: ['read'],
billing: [],
dashboards: [],
datasets: [],
endpoints: [],
flows: [],
integrations: [],
monitors: [],
notifiers: [],
rbac: [],
sharedAccessKeys: [],
users: [],
views: []
},
viewCapabilities: {}
})
};
fetch('https://api.axiom.co/v2/rbac/roles/{id}', 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://api.axiom.co/v2/rbac/roles/{id}",
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([
'name' => '<string>',
'datasetCapabilities' => [
],
'description' => '<string>',
'members' => [
'<string>'
],
'orgCapabilities' => [
'annotations' => [
],
'apiTokens' => [
],
'auditLog' => [
'read'
],
'billing' => [
],
'dashboards' => [
],
'datasets' => [
],
'endpoints' => [
],
'flows' => [
],
'integrations' => [
],
'monitors' => [
],
'notifiers' => [
],
'rbac' => [
],
'sharedAccessKeys' => [
],
'users' => [
],
'views' => [
]
],
'viewCapabilities' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://api.axiom.co/v2/rbac/roles/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"datasetCapabilities\": {},\n \"description\": \"<string>\",\n \"members\": [\n \"<string>\"\n ],\n \"orgCapabilities\": {\n \"annotations\": [],\n \"apiTokens\": [],\n \"auditLog\": [\n \"read\"\n ],\n \"billing\": [],\n \"dashboards\": [],\n \"datasets\": [],\n \"endpoints\": [],\n \"flows\": [],\n \"integrations\": [],\n \"monitors\": [],\n \"notifiers\": [],\n \"rbac\": [],\n \"sharedAccessKeys\": [],\n \"users\": [],\n \"views\": []\n },\n \"viewCapabilities\": {}\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://api.axiom.co/v2/rbac/roles/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"datasetCapabilities\": {},\n \"description\": \"<string>\",\n \"members\": [\n \"<string>\"\n ],\n \"orgCapabilities\": {\n \"annotations\": [],\n \"apiTokens\": [],\n \"auditLog\": [\n \"read\"\n ],\n \"billing\": [],\n \"dashboards\": [],\n \"datasets\": [],\n \"endpoints\": [],\n \"flows\": [],\n \"integrations\": [],\n \"monitors\": [],\n \"notifiers\": [],\n \"rbac\": [],\n \"sharedAccessKeys\": [],\n \"users\": [],\n \"views\": []\n },\n \"viewCapabilities\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.axiom.co/v2/rbac/roles/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"datasetCapabilities\": {},\n \"description\": \"<string>\",\n \"members\": [\n \"<string>\"\n ],\n \"orgCapabilities\": {\n \"annotations\": [],\n \"apiTokens\": [],\n \"auditLog\": [\n \"read\"\n ],\n \"billing\": [],\n \"dashboards\": [],\n \"datasets\": [],\n \"endpoints\": [],\n \"flows\": [],\n \"integrations\": [],\n \"monitors\": [],\n \"notifiers\": [],\n \"rbac\": [],\n \"sharedAccessKeys\": [],\n \"users\": [],\n \"views\": []\n },\n \"viewCapabilities\": {}\n}"
response = http.request(request)
puts response.read_body{
"name": "<string>",
"id": "<string>",
"datasetCapabilities": {},
"description": "<string>",
"members": [
"<string>"
],
"orgCapabilities": {
"annotations": [],
"apiTokens": [],
"auditLog": [
"read"
],
"billing": [],
"dashboards": [],
"datasets": [],
"endpoints": [],
"flows": [],
"integrations": [],
"monitors": [],
"notifiers": [],
"rbac": [],
"sharedAccessKeys": [],
"users": [],
"views": []
},
"viewCapabilities": {}
}Update role
Updates an existing role’s configuration including its permissions and member assignments.
curl --request PUT \
--url https://api.axiom.co/v2/rbac/roles/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"datasetCapabilities": {},
"description": "<string>",
"members": [
"<string>"
],
"orgCapabilities": {
"annotations": [],
"apiTokens": [],
"auditLog": [
"read"
],
"billing": [],
"dashboards": [],
"datasets": [],
"endpoints": [],
"flows": [],
"integrations": [],
"monitors": [],
"notifiers": [],
"rbac": [],
"sharedAccessKeys": [],
"users": [],
"views": []
},
"viewCapabilities": {}
}
'import requests
url = "https://api.axiom.co/v2/rbac/roles/{id}"
payload = {
"name": "<string>",
"datasetCapabilities": {},
"description": "<string>",
"members": ["<string>"],
"orgCapabilities": {
"annotations": [],
"apiTokens": [],
"auditLog": ["read"],
"billing": [],
"dashboards": [],
"datasets": [],
"endpoints": [],
"flows": [],
"integrations": [],
"monitors": [],
"notifiers": [],
"rbac": [],
"sharedAccessKeys": [],
"users": [],
"views": []
},
"viewCapabilities": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
datasetCapabilities: {},
description: '<string>',
members: ['<string>'],
orgCapabilities: {
annotations: [],
apiTokens: [],
auditLog: ['read'],
billing: [],
dashboards: [],
datasets: [],
endpoints: [],
flows: [],
integrations: [],
monitors: [],
notifiers: [],
rbac: [],
sharedAccessKeys: [],
users: [],
views: []
},
viewCapabilities: {}
})
};
fetch('https://api.axiom.co/v2/rbac/roles/{id}', 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://api.axiom.co/v2/rbac/roles/{id}",
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([
'name' => '<string>',
'datasetCapabilities' => [
],
'description' => '<string>',
'members' => [
'<string>'
],
'orgCapabilities' => [
'annotations' => [
],
'apiTokens' => [
],
'auditLog' => [
'read'
],
'billing' => [
],
'dashboards' => [
],
'datasets' => [
],
'endpoints' => [
],
'flows' => [
],
'integrations' => [
],
'monitors' => [
],
'notifiers' => [
],
'rbac' => [
],
'sharedAccessKeys' => [
],
'users' => [
],
'views' => [
]
],
'viewCapabilities' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://api.axiom.co/v2/rbac/roles/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"datasetCapabilities\": {},\n \"description\": \"<string>\",\n \"members\": [\n \"<string>\"\n ],\n \"orgCapabilities\": {\n \"annotations\": [],\n \"apiTokens\": [],\n \"auditLog\": [\n \"read\"\n ],\n \"billing\": [],\n \"dashboards\": [],\n \"datasets\": [],\n \"endpoints\": [],\n \"flows\": [],\n \"integrations\": [],\n \"monitors\": [],\n \"notifiers\": [],\n \"rbac\": [],\n \"sharedAccessKeys\": [],\n \"users\": [],\n \"views\": []\n },\n \"viewCapabilities\": {}\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://api.axiom.co/v2/rbac/roles/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"datasetCapabilities\": {},\n \"description\": \"<string>\",\n \"members\": [\n \"<string>\"\n ],\n \"orgCapabilities\": {\n \"annotations\": [],\n \"apiTokens\": [],\n \"auditLog\": [\n \"read\"\n ],\n \"billing\": [],\n \"dashboards\": [],\n \"datasets\": [],\n \"endpoints\": [],\n \"flows\": [],\n \"integrations\": [],\n \"monitors\": [],\n \"notifiers\": [],\n \"rbac\": [],\n \"sharedAccessKeys\": [],\n \"users\": [],\n \"views\": []\n },\n \"viewCapabilities\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.axiom.co/v2/rbac/roles/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"datasetCapabilities\": {},\n \"description\": \"<string>\",\n \"members\": [\n \"<string>\"\n ],\n \"orgCapabilities\": {\n \"annotations\": [],\n \"apiTokens\": [],\n \"auditLog\": [\n \"read\"\n ],\n \"billing\": [],\n \"dashboards\": [],\n \"datasets\": [],\n \"endpoints\": [],\n \"flows\": [],\n \"integrations\": [],\n \"monitors\": [],\n \"notifiers\": [],\n \"rbac\": [],\n \"sharedAccessKeys\": [],\n \"users\": [],\n \"views\": []\n },\n \"viewCapabilities\": {}\n}"
response = http.request(request)
puts response.read_body{
"name": "<string>",
"id": "<string>",
"datasetCapabilities": {},
"description": "<string>",
"members": [
"<string>"
],
"orgCapabilities": {
"annotations": [],
"apiTokens": [],
"auditLog": [
"read"
],
"billing": [],
"dashboards": [],
"datasets": [],
"endpoints": [],
"flows": [],
"integrations": [],
"monitors": [],
"notifiers": [],
"rbac": [],
"sharedAccessKeys": [],
"users": [],
"views": []
},
"viewCapabilities": {}
}Authorizations
The access token received from the authorization server in the OAuth 2.0 flow.
Path Parameters
Unique identifier of the role to update
Body
The updated role configuration
Defines a role and its associated permissions within the system
Unique name identifier for the role
Defines the available permissions for dataset operations
Show child attributes
Show child attributes
Detailed description of the role's purpose and scope
List of user IDs that are assigned to this role
Defines organization-wide permissions and capabilities
Show child attributes
Show child attributes
Defines the available permissions for view operations
Show child attributes
Show child attributes
Response
The role was successfully updated
Extends the base Role type to include a unique identifier
Unique name identifier for the role
Unique identifier for the role
Defines the available permissions for dataset operations
Show child attributes
Show child attributes
Detailed description of the role's purpose and scope
List of user IDs that are assigned to this role
Defines organization-wide permissions and capabilities
Show child attributes
Show child attributes
Defines the available permissions for view operations
Show child attributes
Show child attributes
Was this page helpful?