curl --request PUT \
--url 'https://sandbox.circularo.com/api/v1/documents/rights?token=' \
--header 'Content-Type: application/json' \
--data '
{
"documents": [
{
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59"
}
],
"addRights": {
"editGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"editUsers": [
"john.doe@example.com"
],
"readGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"readUsers": [
"john.doe@example.com"
]
},
"isPublicComment": false,
"message": "Processed <b>as requested</b>, see <a href=\"https://example.com/report\">the report</a>.",
"private": true,
"removeRights": {
"editGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"editUsers": [
"john.doe@example.com"
],
"readGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"readUsers": [
"john.doe@example.com"
]
},
"setRights": {
"editGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"editUsers": [
"john.doe@example.com"
],
"readGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"readUsers": [
"john.doe@example.com"
]
}
}
'import requests
url = "https://sandbox.circularo.com/api/v1/documents/rights?token="
payload = {
"documents": [{ "id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59" }],
"addRights": {
"editGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"editUsers": ["john.doe@example.com"],
"readGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"readUsers": ["john.doe@example.com"]
},
"isPublicComment": False,
"message": "Processed <b>as requested</b>, see <a href=\"https://example.com/report\">the report</a>.",
"private": True,
"removeRights": {
"editGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"editUsers": ["john.doe@example.com"],
"readGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"readUsers": ["john.doe@example.com"]
},
"setRights": {
"editGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"editUsers": ["john.doe@example.com"],
"readGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"readUsers": ["john.doe@example.com"]
}
}
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({
documents: [{id: 'a0d01c9d-f72f-4c57-af11-e26bda19cc59'}],
addRights: {
editGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
editUsers: ['john.doe@example.com'],
readGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
readUsers: ['john.doe@example.com']
},
isPublicComment: false,
message: 'Processed <b>as requested</b>, see <a href="https://example.com/report">the report</a>.',
private: true,
removeRights: {
editGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
editUsers: ['john.doe@example.com'],
readGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
readUsers: ['john.doe@example.com']
},
setRights: {
editGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
editUsers: ['john.doe@example.com'],
readGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
readUsers: ['john.doe@example.com']
}
})
};
fetch('https://sandbox.circularo.com/api/v1/documents/rights?token=', 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://sandbox.circularo.com/api/v1/documents/rights?token=",
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([
'documents' => [
[
'id' => 'a0d01c9d-f72f-4c57-af11-e26bda19cc59'
]
],
'addRights' => [
'editGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'editUsers' => [
'john.doe@example.com'
],
'readGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'readUsers' => [
'john.doe@example.com'
]
],
'isPublicComment' => false,
'message' => 'Processed <b>as requested</b>, see <a href="https://example.com/report">the report</a>.',
'private' => true,
'removeRights' => [
'editGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'editUsers' => [
'john.doe@example.com'
],
'readGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'readUsers' => [
'john.doe@example.com'
]
],
'setRights' => [
'editGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'editUsers' => [
'john.doe@example.com'
],
'readGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'readUsers' => [
'john.doe@example.com'
]
]
]),
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://sandbox.circularo.com/api/v1/documents/rights?token="
payload := strings.NewReader("{\n \"documents\": [\n {\n \"id\": \"a0d01c9d-f72f-4c57-af11-e26bda19cc59\"\n }\n ],\n \"addRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"isPublicComment\": false,\n \"message\": \"Processed <b>as requested</b>, see <a href=\\\"https://example.com/report\\\">the report</a>.\",\n \"private\": true,\n \"removeRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"setRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\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://sandbox.circularo.com/api/v1/documents/rights?token=")
.header("Content-Type", "application/json")
.body("{\n \"documents\": [\n {\n \"id\": \"a0d01c9d-f72f-4c57-af11-e26bda19cc59\"\n }\n ],\n \"addRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"isPublicComment\": false,\n \"message\": \"Processed <b>as requested</b>, see <a href=\\\"https://example.com/report\\\">the report</a>.\",\n \"private\": true,\n \"removeRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"setRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.circularo.com/api/v1/documents/rights?token=")
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 \"documents\": [\n {\n \"id\": \"a0d01c9d-f72f-4c57-af11-e26bda19cc59\"\n }\n ],\n \"addRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"isPublicComment\": false,\n \"message\": \"Processed <b>as requested</b>, see <a href=\\\"https://example.com/report\\\">the report</a>.\",\n \"private\": true,\n \"removeRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"setRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"count": 22,
"errors": false,
"items": [
{
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59",
"index": "default_documents",
"status": 409,
"message": "Incorrect version",
"payload": {},
"type": "DOCUMENT:VERSION_CONFLICT"
}
]
}{
"status": 400,
"type": "VALIDATION:INPUT_INVALID",
"message": "Invalid input",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 401,
"type": "AUTH:UNAUTHORIZED",
"message": "Authentication failed",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 403,
"type": "AUTH:ACCESS_DENIED",
"message": "Access denied",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 404,
"type": "RESOURCE:NOT_FOUND",
"message": "Resource not found",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}Change who may read and edit documents and folders
PUT /documents/rights
Changes the per-record access lists of one or more documents and folders at once, and whether they are confined to those lists at all. Read access lets a user open the record; edit access covers reading as well. A folder is not treated as a single record - the change is carried down its subtree. At least one of the four changes has to be asked for.
The three ways of changing the lists are applied in a fixed order - the additions first, then the removals, then the replacement - so combining the replacement with either of the others means the replacement decides the outcome. Every user and group named has to exist, and a group belonging to another organization is refused as if it did not; whether the caller’s own organization group may be granted access at all is decided by a setting.
Users who are newly granted access are notified, and the accompanying message reaches them with it. Entries are processed independently and the request answers success even when some of them did not go through, so the outcome has to be read from the response body.
Token authorization: Authorize using a token — either a session token obtained from login or an API key — to call this endpoint.
curl --request PUT \
--url 'https://sandbox.circularo.com/api/v1/documents/rights?token=' \
--header 'Content-Type: application/json' \
--data '
{
"documents": [
{
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59"
}
],
"addRights": {
"editGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"editUsers": [
"john.doe@example.com"
],
"readGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"readUsers": [
"john.doe@example.com"
]
},
"isPublicComment": false,
"message": "Processed <b>as requested</b>, see <a href=\"https://example.com/report\">the report</a>.",
"private": true,
"removeRights": {
"editGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"editUsers": [
"john.doe@example.com"
],
"readGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"readUsers": [
"john.doe@example.com"
]
},
"setRights": {
"editGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"editUsers": [
"john.doe@example.com"
],
"readGroups": [
"d0a72e51-728e-4a1d-9a5c-13796122b6f8"
],
"readUsers": [
"john.doe@example.com"
]
}
}
'import requests
url = "https://sandbox.circularo.com/api/v1/documents/rights?token="
payload = {
"documents": [{ "id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59" }],
"addRights": {
"editGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"editUsers": ["john.doe@example.com"],
"readGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"readUsers": ["john.doe@example.com"]
},
"isPublicComment": False,
"message": "Processed <b>as requested</b>, see <a href=\"https://example.com/report\">the report</a>.",
"private": True,
"removeRights": {
"editGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"editUsers": ["john.doe@example.com"],
"readGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"readUsers": ["john.doe@example.com"]
},
"setRights": {
"editGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"editUsers": ["john.doe@example.com"],
"readGroups": ["d0a72e51-728e-4a1d-9a5c-13796122b6f8"],
"readUsers": ["john.doe@example.com"]
}
}
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({
documents: [{id: 'a0d01c9d-f72f-4c57-af11-e26bda19cc59'}],
addRights: {
editGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
editUsers: ['john.doe@example.com'],
readGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
readUsers: ['john.doe@example.com']
},
isPublicComment: false,
message: 'Processed <b>as requested</b>, see <a href="https://example.com/report">the report</a>.',
private: true,
removeRights: {
editGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
editUsers: ['john.doe@example.com'],
readGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
readUsers: ['john.doe@example.com']
},
setRights: {
editGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
editUsers: ['john.doe@example.com'],
readGroups: ['d0a72e51-728e-4a1d-9a5c-13796122b6f8'],
readUsers: ['john.doe@example.com']
}
})
};
fetch('https://sandbox.circularo.com/api/v1/documents/rights?token=', 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://sandbox.circularo.com/api/v1/documents/rights?token=",
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([
'documents' => [
[
'id' => 'a0d01c9d-f72f-4c57-af11-e26bda19cc59'
]
],
'addRights' => [
'editGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'editUsers' => [
'john.doe@example.com'
],
'readGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'readUsers' => [
'john.doe@example.com'
]
],
'isPublicComment' => false,
'message' => 'Processed <b>as requested</b>, see <a href="https://example.com/report">the report</a>.',
'private' => true,
'removeRights' => [
'editGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'editUsers' => [
'john.doe@example.com'
],
'readGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'readUsers' => [
'john.doe@example.com'
]
],
'setRights' => [
'editGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'editUsers' => [
'john.doe@example.com'
],
'readGroups' => [
'd0a72e51-728e-4a1d-9a5c-13796122b6f8'
],
'readUsers' => [
'john.doe@example.com'
]
]
]),
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://sandbox.circularo.com/api/v1/documents/rights?token="
payload := strings.NewReader("{\n \"documents\": [\n {\n \"id\": \"a0d01c9d-f72f-4c57-af11-e26bda19cc59\"\n }\n ],\n \"addRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"isPublicComment\": false,\n \"message\": \"Processed <b>as requested</b>, see <a href=\\\"https://example.com/report\\\">the report</a>.\",\n \"private\": true,\n \"removeRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"setRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\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://sandbox.circularo.com/api/v1/documents/rights?token=")
.header("Content-Type", "application/json")
.body("{\n \"documents\": [\n {\n \"id\": \"a0d01c9d-f72f-4c57-af11-e26bda19cc59\"\n }\n ],\n \"addRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"isPublicComment\": false,\n \"message\": \"Processed <b>as requested</b>, see <a href=\\\"https://example.com/report\\\">the report</a>.\",\n \"private\": true,\n \"removeRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"setRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.circularo.com/api/v1/documents/rights?token=")
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 \"documents\": [\n {\n \"id\": \"a0d01c9d-f72f-4c57-af11-e26bda19cc59\"\n }\n ],\n \"addRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"isPublicComment\": false,\n \"message\": \"Processed <b>as requested</b>, see <a href=\\\"https://example.com/report\\\">the report</a>.\",\n \"private\": true,\n \"removeRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n },\n \"setRights\": {\n \"editGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"editUsers\": [\n \"john.doe@example.com\"\n ],\n \"readGroups\": [\n \"d0a72e51-728e-4a1d-9a5c-13796122b6f8\"\n ],\n \"readUsers\": [\n \"john.doe@example.com\"\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"count": 22,
"errors": false,
"items": [
{
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59",
"index": "default_documents",
"status": 409,
"message": "Incorrect version",
"payload": {},
"type": "DOCUMENT:VERSION_CONFLICT"
}
]
}{
"status": 400,
"type": "VALIDATION:INPUT_INVALID",
"message": "Invalid input",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 401,
"type": "AUTH:UNAUTHORIZED",
"message": "Authentication failed",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 403,
"type": "AUTH:ACCESS_DENIED",
"message": "Access denied",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 404,
"type": "RESOURCE:NOT_FOUND",
"message": "Resource not found",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}Authorizations
Body
Note delivered to the users who are newly granted access, together with the notification telling them about the document. May carry basic formatting — bold, italic, underline, https links and bullet lists; everything else is stripped on input.
2000"Processed <b>as requested</b>, see <a href=\"https://example.com/report\">the report</a>."
Confines the documents to the users and groups named on them. While they are not private, the rights a caller holds for their metadata definition reach them as well. A caller who belongs to an organization always makes them private, whatever is sent here. At least one of private, addRights, setRights and removeRights must be provided.
Response
Returns the entries that did not go through.