curl --request POST \
--url https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"aclEntries": [
{
"classId": "<string>",
"className": "<string>",
"description": "<string>",
"displayName": "<string>",
"displayName_i18n": "<string>",
"thumbnailPictureUrl": "<string>",
"value": "<string>"
}
],
"appMetadata": {},
"description": "<string>",
"id": "<string>",
"kind": "<string>",
"name": "<string>",
"name_i18n": "<string>",
"privileges": {}
}
'import requests
url = "https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles"
payload = {
"aclEntries": [
{
"classId": "<string>",
"className": "<string>",
"description": "<string>",
"displayName": "<string>",
"displayName_i18n": "<string>",
"thumbnailPictureUrl": "<string>",
"value": "<string>"
}
],
"appMetadata": {},
"description": "<string>",
"id": "<string>",
"kind": "<string>",
"name": "<string>",
"name_i18n": "<string>",
"privileges": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
aclEntries: [
{
classId: '<string>',
className: '<string>',
description: '<string>',
displayName: '<string>',
displayName_i18n: '<string>',
thumbnailPictureUrl: '<string>',
value: '<string>'
}
],
appMetadata: {},
description: '<string>',
id: '<string>',
kind: '<string>',
name: '<string>',
name_i18n: '<string>',
privileges: {}
})
};
fetch('https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles', 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://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'aclEntries' => [
[
'classId' => '<string>',
'className' => '<string>',
'description' => '<string>',
'displayName' => '<string>',
'displayName_i18n' => '<string>',
'thumbnailPictureUrl' => '<string>',
'value' => '<string>'
]
],
'appMetadata' => [
],
'description' => '<string>',
'id' => '<string>',
'kind' => '<string>',
'name' => '<string>',
'name_i18n' => '<string>',
'privileges' => [
]
]),
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://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles"
payload := strings.NewReader("{\n \"aclEntries\": [\n {\n \"classId\": \"<string>\",\n \"className\": \"<string>\",\n \"description\": \"<string>\",\n \"displayName\": \"<string>\",\n \"displayName_i18n\": \"<string>\",\n \"thumbnailPictureUrl\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"appMetadata\": {},\n \"description\": \"<string>\",\n \"id\": \"<string>\",\n \"kind\": \"<string>\",\n \"name\": \"<string>\",\n \"name_i18n\": \"<string>\",\n \"privileges\": {}\n}")
req, _ := http.NewRequest("POST", 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.post("https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"aclEntries\": [\n {\n \"classId\": \"<string>\",\n \"className\": \"<string>\",\n \"description\": \"<string>\",\n \"displayName\": \"<string>\",\n \"displayName_i18n\": \"<string>\",\n \"thumbnailPictureUrl\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"appMetadata\": {},\n \"description\": \"<string>\",\n \"id\": \"<string>\",\n \"kind\": \"<string>\",\n \"name\": \"<string>\",\n \"name_i18n\": \"<string>\",\n \"privileges\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"aclEntries\": [\n {\n \"classId\": \"<string>\",\n \"className\": \"<string>\",\n \"description\": \"<string>\",\n \"displayName\": \"<string>\",\n \"displayName_i18n\": \"<string>\",\n \"thumbnailPictureUrl\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"appMetadata\": {},\n \"description\": \"<string>\",\n \"id\": \"<string>\",\n \"kind\": \"<string>\",\n \"name\": \"<string>\",\n \"name_i18n\": \"<string>\",\n \"privileges\": {}\n}"
response = http.request(request)
puts response.read_body{
"aclEntries": [
{
"classId": "<string>",
"className": "<string>",
"description": "<string>",
"displayName": "<string>",
"displayName_i18n": "<string>",
"thumbnailPictureUrl": "<string>",
"type": "USER",
"value": "<string>"
}
],
"appMetadata": {},
"description": "<string>",
"id": "<string>",
"kind": "<string>",
"name": "<string>",
"name_i18n": "<string>",
"privileges": {},
"type": "LIBRARY"
}Post libraryv1beta1 roles
Creates a new role in the library.
curl --request POST \
--url https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"aclEntries": [
{
"classId": "<string>",
"className": "<string>",
"description": "<string>",
"displayName": "<string>",
"displayName_i18n": "<string>",
"thumbnailPictureUrl": "<string>",
"value": "<string>"
}
],
"appMetadata": {},
"description": "<string>",
"id": "<string>",
"kind": "<string>",
"name": "<string>",
"name_i18n": "<string>",
"privileges": {}
}
'import requests
url = "https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles"
payload = {
"aclEntries": [
{
"classId": "<string>",
"className": "<string>",
"description": "<string>",
"displayName": "<string>",
"displayName_i18n": "<string>",
"thumbnailPictureUrl": "<string>",
"value": "<string>"
}
],
"appMetadata": {},
"description": "<string>",
"id": "<string>",
"kind": "<string>",
"name": "<string>",
"name_i18n": "<string>",
"privileges": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
aclEntries: [
{
classId: '<string>',
className: '<string>',
description: '<string>',
displayName: '<string>',
displayName_i18n: '<string>',
thumbnailPictureUrl: '<string>',
value: '<string>'
}
],
appMetadata: {},
description: '<string>',
id: '<string>',
kind: '<string>',
name: '<string>',
name_i18n: '<string>',
privileges: {}
})
};
fetch('https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles', 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://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'aclEntries' => [
[
'classId' => '<string>',
'className' => '<string>',
'description' => '<string>',
'displayName' => '<string>',
'displayName_i18n' => '<string>',
'thumbnailPictureUrl' => '<string>',
'value' => '<string>'
]
],
'appMetadata' => [
],
'description' => '<string>',
'id' => '<string>',
'kind' => '<string>',
'name' => '<string>',
'name_i18n' => '<string>',
'privileges' => [
]
]),
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://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles"
payload := strings.NewReader("{\n \"aclEntries\": [\n {\n \"classId\": \"<string>\",\n \"className\": \"<string>\",\n \"description\": \"<string>\",\n \"displayName\": \"<string>\",\n \"displayName_i18n\": \"<string>\",\n \"thumbnailPictureUrl\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"appMetadata\": {},\n \"description\": \"<string>\",\n \"id\": \"<string>\",\n \"kind\": \"<string>\",\n \"name\": \"<string>\",\n \"name_i18n\": \"<string>\",\n \"privileges\": {}\n}")
req, _ := http.NewRequest("POST", 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.post("https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"aclEntries\": [\n {\n \"classId\": \"<string>\",\n \"className\": \"<string>\",\n \"description\": \"<string>\",\n \"displayName\": \"<string>\",\n \"displayName_i18n\": \"<string>\",\n \"thumbnailPictureUrl\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"appMetadata\": {},\n \"description\": \"<string>\",\n \"id\": \"<string>\",\n \"kind\": \"<string>\",\n \"name\": \"<string>\",\n \"name_i18n\": \"<string>\",\n \"privileges\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://aodocs.altirnao.com/api/library/v1beta1/{libId}/roles")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"aclEntries\": [\n {\n \"classId\": \"<string>\",\n \"className\": \"<string>\",\n \"description\": \"<string>\",\n \"displayName\": \"<string>\",\n \"displayName_i18n\": \"<string>\",\n \"thumbnailPictureUrl\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"appMetadata\": {},\n \"description\": \"<string>\",\n \"id\": \"<string>\",\n \"kind\": \"<string>\",\n \"name\": \"<string>\",\n \"name_i18n\": \"<string>\",\n \"privileges\": {}\n}"
response = http.request(request)
puts response.read_body{
"aclEntries": [
{
"classId": "<string>",
"className": "<string>",
"description": "<string>",
"displayName": "<string>",
"displayName_i18n": "<string>",
"thumbnailPictureUrl": "<string>",
"type": "USER",
"value": "<string>"
}
],
"appMetadata": {},
"description": "<string>",
"id": "<string>",
"kind": "<string>",
"name": "<string>",
"name_i18n": "<string>",
"privileges": {},
"type": "LIBRARY"
}Authorizations
The access token received from the authorization server in the OAuth 2.0 flow.
Path Parameters
The ID of the library
Body
The list of user/group/field members of the role
Show child attributes
Show child attributes
App Metadata let developers associate metadata with various configuration entities. The metadata is isolated within app namespaces in order to prevent one application from interfering with another's metadata.
Show child attributes
Show child attributes
The description of the role
The ID of the role (read-only field)
The name of the role
The internationalized name of the role (read-only field)
The list of privileges belonging to predefined role types (read-only field)
Show child attributes
Show child attributes
The type of role in the library: LIBRARY (administrators, contributors, readers), DOCUMENT (document creator, version creator), CUSTOM for any role created manually (including predefined roles) (read-only field)
LIBRARY, DOCUMENT, PREDEFINED, CUSTOM Response
A ApiLibraryRole response
The list of user/group/field members of the role
Show child attributes
Show child attributes
App Metadata let developers associate metadata with various configuration entities. The metadata is isolated within app namespaces in order to prevent one application from interfering with another's metadata.
Show child attributes
Show child attributes
The description of the role
The ID of the role (read-only field)
The name of the role
The internationalized name of the role (read-only field)
The list of privileges belonging to predefined role types (read-only field)
Show child attributes
Show child attributes
The type of role in the library: LIBRARY (administrators, contributors, readers), DOCUMENT (document creator, version creator), CUSTOM for any role created manually (including predefined roles) (read-only field)
LIBRARY, DOCUMENT, PREDEFINED, CUSTOM