curl --request PUT \
--url https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"mode": "everyone",
"groupAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"memberAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"accessLevel": "VIEW"
}
'import requests
url = "https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access"
payload = {
"mode": "everyone",
"groupAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"memberAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"accessLevel": "VIEW"
}
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({
mode: 'everyone',
groupAccess: [{id: '<string>', accessLevel: 'VIEW'}],
memberAccess: [{id: '<string>', accessLevel: 'VIEW'}],
accessLevel: 'VIEW'
})
};
fetch('https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access', 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://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access",
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([
'mode' => 'everyone',
'groupAccess' => [
[
'id' => '<string>',
'accessLevel' => 'VIEW'
]
],
'memberAccess' => [
[
'id' => '<string>',
'accessLevel' => 'VIEW'
]
],
'accessLevel' => 'VIEW'
]),
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://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access"
payload := strings.NewReader("{\n \"mode\": \"everyone\",\n \"groupAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"memberAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"accessLevel\": \"VIEW\"\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://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"mode\": \"everyone\",\n \"groupAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"memberAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"accessLevel\": \"VIEW\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access")
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 \"mode\": \"everyone\",\n \"groupAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"memberAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"accessLevel\": \"VIEW\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"dashboardId": "<string>",
"mode": "everyone",
"accessLevel": "MANAGE",
"groupAccess": [
{
"id": "<string>",
"accessLevel": "MANAGE"
}
],
"memberAccess": [
{
"id": "<string>",
"accessLevel": "MANAGE"
}
]
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}{
"error": {
"title": "RateLimitExceeded",
"detail": "<string>",
"retryAfterMs": 123
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}Update dashboard access
Replaces the access policy. Send the complete policy: groups and members not listed lose their access. Use mode “everyone” to give every organization member accessLevel (plus any listed groupAccess/memberAccess), or mode “restricted” so only the listed groups and members, the creator and organization admins can access it; restricting removes the default everyone access. groupAccess and memberAccess are required (send [] for none), and listing one principal twice with different levels is rejected. The GET response can be sent back unchanged, and sending the current policy again changes nothing. View-only members are capped at VIEW whatever their grant. For a dashboard in a folder, mode “inherit” removes the dashboard’s own access so it uses its folder’s access. Requires admin access to the organization.
curl --request PUT \
--url https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"mode": "everyone",
"groupAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"memberAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"accessLevel": "VIEW"
}
'import requests
url = "https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access"
payload = {
"mode": "everyone",
"groupAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"memberAccess": [
{
"id": "<string>",
"accessLevel": "VIEW"
}
],
"accessLevel": "VIEW"
}
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({
mode: 'everyone',
groupAccess: [{id: '<string>', accessLevel: 'VIEW'}],
memberAccess: [{id: '<string>', accessLevel: 'VIEW'}],
accessLevel: 'VIEW'
})
};
fetch('https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access', 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://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access",
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([
'mode' => 'everyone',
'groupAccess' => [
[
'id' => '<string>',
'accessLevel' => 'VIEW'
]
],
'memberAccess' => [
[
'id' => '<string>',
'accessLevel' => 'VIEW'
]
],
'accessLevel' => 'VIEW'
]),
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://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access"
payload := strings.NewReader("{\n \"mode\": \"everyone\",\n \"groupAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"memberAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"accessLevel\": \"VIEW\"\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://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"mode\": \"everyone\",\n \"groupAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"memberAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"accessLevel\": \"VIEW\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://charts.basedash.com/api/public/organizations/{orgId}/dashboards/{id}/access")
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 \"mode\": \"everyone\",\n \"groupAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"memberAccess\": [\n {\n \"id\": \"<string>\",\n \"accessLevel\": \"VIEW\"\n }\n ],\n \"accessLevel\": \"VIEW\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"dashboardId": "<string>",
"mode": "everyone",
"accessLevel": "MANAGE",
"groupAccess": [
{
"id": "<string>",
"accessLevel": "MANAGE"
}
],
"memberAccess": [
{
"id": "<string>",
"accessLevel": "MANAGE"
}
]
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}{
"error": {
"title": "RateLimitExceeded",
"detail": "<string>",
"retryAfterMs": 123
}
}{
"error": {
"title": "<string>",
"detail": "<string>"
}
}Authorizations
API key authentication using Bearer token format: Bearer <basedash_api_key>
Body
- Option 1
- Option 2
- Option 3
everyone Organization groups and their access level. Required: send [] for none.
500Show child attributes
Show child attributes
Organization members and their access level. Required: send [] for none.
500Show child attributes
Show child attributes
Access level for every member of the organization
MANAGE, EDIT, VIEW Response
Dashboard access updated successfully
Show child attributes
Show child attributes