ClickCease

Leni HTTP API

Custom analysts

Create, list, update, and delete custom analysts owned by the project-key user.

GET/users/custom-analysts

No body. Returns the owner’s custom model payload, including identifiers used for later updates or analysis.

POST/users/custom-analysts

FieldRequirementBehavior
nameRequiredDisplay name.
baseRequiredBuilt-in base model such as leniq-pro.
toneRequiredprofessional, friendly, authoritative, consultative, or funny.
emojiOptionalDisplay icon.
organisationMemoryOptionalnoteTitle and noteContext plus optional base64 files; multipart uses organisationMemoryFiles.
{
  "name": "Lease reviewer",
  "base": "leniq-pro",
  "tone": "professional",
  "emoji": "📄"
}

Returns HTTP 201 with the created analyst. A failed follow-up organization-memory sync can return 502.

PUT/users/custom-analysts/:analystId

name, base, and tone are required. Optional emoji, description, and organisationMemory update display and owned memory. Supplying organisationMemory.noteId updates that note; omitting it creates a note when title and context exist.

DELETE/users/custom-analysts/:analystId

No body. Deletes only an analyst owned by the authenticated project-key context.

curl -sS -X DELETE "https://api.prod.ca-central-1.leni.co/users/custom-analysts/<analyst-uuid>" \
  -H "X-Api-Key: $LENI_API_KEY"