Skip to content
POST /template/{id}/share

Grants one user, team, or the whole org access at a level. `use` is what lets the grantee stamp a toolbox from it (`POST /toolbox { template_id }`); `edit` additionally lets them change its entries and its own grants. Re-granting the same grantee replaces the level rather than stacking. Requires `edit` access or ownership, and `template:share`.

Path Parameters

idstring
required·

Template id (tpl_…).

curl -X POST 'https://api.elaichi.ai/template/<id>/share' \
  -H 'Authorization: Bearer $ELAICHI_API_TOKEN' \
  -H 'Content-Type: application/json'
const response = await fetch('https://api.elaichi.ai/template/<id>/share', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer ' + process.env.ELAICHI_API_TOKEN,
    'Content-Type': 'application/json',
  },
});

const data = await response.json();
console.log(data);
import os
import requests

url = "https://api.elaichi.ai/template/<id>/share"
headers = {
    "Authorization": f"Bearer {os.environ['ELAICHI_API_TOKEN']}",
    "Content-Type": "application/json",
}

response = requests.post(url, headers=headers)
print(response.json())