Add document tags

patch/v1/document/addTags

You can add tags (labels) to the document while creating it or after sending it, with your tenant IDs or any unique ID to make it easy to fetch or list documents based on tenants or users. Added tags can be accessed by all users within the same organization who have document permission.

Please refer to the Send document article, for adding tags (labels) while creating the document.

Code snippet

curl -X PATCH "https://api.boldsign.com/v1/document/addTags" 
     -H 'X-API-KEY: {your API key}'   
     -H "Content-Type: application/json" 
     -d "{\"documentId\": \"{documentId}\", \"tags\": [\"test\", \"api\"]}"
var apiClient = new ApiClient("https://api.boldsign.com", "{apikey}");
var documentclient = new DocumentClient(apiClient);
var addtag = new DocumentTags()
{
    DocumentId = "{documentId}",
    Tags = new List<string>() { "test", "api" },
};
await documentclient.AddTagAsync(addtag).ConfigureAwait(false);
import requests
import json

url = "https://api.boldsign.com/v1/document/addTags"

payload = json.dumps({
  "documentId": "{documentId}",
  "tags": [
    "test",
    "api"
  ]
})
headers = {
  'X-API-KEY': '{apikey}',
  'Content-Type': 'application/json'
}

response = requests.request("PATCH", url, headers=headers, data=payload)
print(response.text)
const axios = require('axios'); 
await axios.patch( 

    'https://api.boldsign.com/v1/document/addTags', 

    { 
        documentId: '{documentId}', 
        tags: [ 'test', 'api' ] 
    }, 

    { 
        headers: { 
            'X-API-KEY': '{Your API key}', 
            'Content-Type': 'application/json' 
        } 
    } 
); 

Request body

documentIdstringRequiredID of the requested document
tagsStringRequiredA collection of tags that will be added to the document. It can only contain a maximum of 50 tags. Each tag cannot exceed 255 characters and cannot contain white space.

Example response

200 Success