Create collection

Create a collection or a subcollection in My Library.

POST https://cotlet.dev/api/v1/zotero/collections

write

Creates a collection with the name you give, at the top level or under a parent collection. Two collections may share a name, so the call returns the new key. It reaches nobody and runs without asking first; delete the collection in Zotero if you do not want it.

Parameters

Parameters: create_collection
NameTypeDescription
name string required string Collection name.
parent_collection_key string string Create it under this collection.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/zotero/collections \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"Jane Doe"}'
Python
result = client.call("zotero", "create_collection", {"name":"Jane Doe"})
Node.js
const result = await cotlet.call('zotero', 'create_collection', {"name":"Jane Doe"});
CLI
cotlet call zotero create_collection --data '{"name":"Jane Doe"}'

Example response

JSON

{
  "collection_key": "M2D7FQ4S",
  "name": "Chapter 2",
  "parent": "C4T8WZ2N"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.