Skip to content

API reference

Other interfaces

The remaining ways data moves between Luceryn and other systems, and a list of the addresses under /api that are not interfaces, with the reason for each.

Closeout asset hand-off

  • A package reaches your systems three ways: this endpoint (your job asks), the project.asset_handoff.prepared webhook (Luceryn tells a webhook that ticked the event, with the whole package, signed), and the files (an Excel workbook, CSV files and the JSON document) that a signed-in person who may see the project's money downloads from the project's Asset hand-off page.
  • An optional email notice carries a link to that page and no asset or cost data.
  • The columns of the asset table, their headers and order, and the class code for each asset type are set by an administrator under Admin, Asset hand-off layout, so the files fit the receiving system's import layout. The record object of each asset keeps Luceryn's fixed names whatever the layout.
  • Luceryn holds no connection to the asset management system and no credential for it. Loading the package there, and telling Luceryn it was acknowledged, are done on your side and by a person.

Latest asset hand-off package of a project

GET/api/assets/handoff/latest

When a project closes, Luceryn prepares a package of the assets it delivered (schema luceryn.asset_handoff.v1) for your asset management system. This endpoint returns the most recently prepared package of one project as JSON, for your own integration job. Read only: acknowledging a hand-off is done by a person in Luceryn. Luceryn does not connect to the asset management system itself.

Authentication. The workspace's reporting token (it starts with rpt_), the same token as the OData reporting feed, sent as Authorization: Bearer, as the password of Authorization: Basic, or as ?token=. The Closeout asset hand-off switch must be on (off by default).

Request: Query string

Latest asset hand-off package of a project, request, Query string
FieldTypeRequiredDescriptionExample
projectstringYesThe project's id (a UUID), or its short code as Luceryn shows it (capitals do not matter). At most 80 characters. Projects in the bin are not found.CAP-014
tokenstringNoThe reporting token, for a client that cannot send a header. Prefer the header: a token in the address is written to logs.

Answer: 200: { "handoff": { ... }, "package": { ... } }. The log entry

Latest asset hand-off package of a project, answer, 200: { "handoff": { ... }, "package": { ... } }. The log entry
FieldTypeRequiredDescriptionExample
handoff.idstring (UUID)YesThe id of the package in the hand-off log; the same value as package.handoff_id.2b3c4d5e-6f70-4a81-9b92-a3b4c5d6e7f8
handoff.statusstringYesprepared, sent (a webhook delivery or the email notice went out) or acknowledged (a person in Luceryn recorded that the receiving system took it).sent
handoff.triggerstringYesmanual or automatic.manual
handoff.prepared_atstring (ISO 8601)YesWhen the package was prepared.2026-11-20T15:04:05.123+00:00
handoff.prepared_bystringYesThe person's name, or Luceryn (automatic).Sam Rivera
handoff.assetsintegerYesHow many assets the package holds.42
handoff.documentsintegerYesHow many closeout documents it lists.9
handoff.warningsintegerYesHow many checks did not pass.3
handoff.sent_atstring (ISO 8601) or nullYesWhen it was first announced.2026-11-20T15:04:07.512+00:00
handoff.acknowledged_atstring (ISO 8601) or nullYesWhen a person recorded the acknowledgement.
handoff.filesarray of { kind, name, bytes, sha256 }YesThe files of the package and the SHA-256 fingerprint of each. kind is workbook (the Excel file), assets-csv, project-csv, documents-csv or json. The files are downloaded in Luceryn by a signed-in person; this endpoint returns the JSON only.

Answer: 200: the package

The same JSON the project.asset_handoff.prepared webhook carries (without the four fields the webhook adds: project_label, url, files and latest_api).

Latest asset hand-off package of a project, answer, 200: the package
FieldTypeRequiredDescriptionExample
package.schemastringYesThe name and version of this layout.luceryn.asset_handoff.v1
package.handoff_idstring (UUID)YesThe id of this package in Luceryn's hand-off log. Use it to recognise a package you have already loaded.2b3c4d5e-6f70-4a81-9b92-a3b4c5d6e7f8
package.triggerstringYesmanual when a person prepared it, automatic when the scheduled run did.manual
package.prepared_atstring (ISO 8601, UTC)YesWhen the package was prepared.2026-11-20T15:04:05.123Z
package.prepared_bystringYesThe person's name, or Luceryn (automatic).Sam Rivera
package.projectobjectYesid, name, code, department, stage, status, start_date, end_date, currency, buildings (each with name, code, campus, address) and link (the project in Luceryn, behind sign-in).
package.cost_summaryobject or nullYesgross_floor_area_m2, gross_floor_area_sqft and rows; each row has key, label, budget, actual, budget_per_m2, actual_per_m2, budget_per_sqft and actual_per_sqft. The floor area and per-area figures are null unless the workspace's Floor area and cost per square metre switch is on.
package.fundingarray or nullYesFunding lines, each with fund, fiscal_year and amount.
package.layoutarrayYesThe columns the workspace chose for the asset table, in order: key, header and fixed (a fixed value, when the column has one). Set under Admin, Asset hand-off layout.
package.assetsarrayYesOne entry for each asset, ordered by tag. luceryn_asset_id; columns (the row exactly as the files carry it, under the workspace's own headers); record (the same asset under Luceryn's fixed names: tag, name, classification, class_code, category, location, department, attributes, manufacturer, model, serial_number, in_service_date, purchase_date, cost, currency, vendor, warranty_start, warranty_end, warranty_documents, external_ref, link); and warnings (the checks this asset did not pass).
package.documentsarrayYesThe closeout documents: kind, title, system, vendor, status, warranty_start, warranty_end, files (each with name and url) and url (the register entry in Luceryn, behind sign-in).
package.warningsarrayYesThe checks that did not pass, each with kind (no_classification, no_location, no_cost, no_warranty_document or class_not_mapped), asset_id, tag and message. A warning never stops a package.
package.countsobjectYesassets, documents and warnings.{ "assets": 42, "documents": 9, "warnings": 3 }

Errors

Latest asset hand-off package of a project, errors
StatusMessageWhen
401Unauthorized. Supply a reporting token (Authorization: Bearer).No token, an unknown token or a revoked token. The answer carries WWW-Authenticate: Bearer realm="Luceryn".
403Closeout asset hand-off is switched off for this workspace.The token is valid and the switch is off.
400Name the project: ?project=<project code or id>.No project, or one longer than 80 characters.
400More than one project has that code. Use the project id instead.Two projects of the workspace share the short code.
404No such project in this workspace.No project with that id or code in the token's workspace.
404No asset hand-off has been prepared for this project yet.The project exists and no package has been prepared for it.

Limits

  • A package holds at most 5,000 assets of one project.
  • One project in one request, and only its latest package. Earlier packages stay in the log in Luceryn.
  • Never cached (Cache-Control: private, no-store). No request rate limit is applied by Luceryn on this interface.
  • Errors come as { "error": "..." }.
Example request
curl "https://luceryn.example.com/api/assets/handoff/latest?project=CAP-014" \
  -H "Authorization: Bearer rpt_EXAMPLE_TOKEN_REPLACE_ME"
Example answer
{
  "handoff": {
    "id": "2b3c4d5e-6f70-4a81-9b92-a3b4c5d6e7f8",
    "status": "sent",
    "trigger": "manual",
    "prepared_at": "2026-11-20T15:04:05.123+00:00",
    "prepared_by": "Sam Rivera",
    "assets": 1,
    "documents": 1,
    "warnings": 0,
    "sent_at": "2026-11-20T15:04:07.512+00:00",
    "acknowledged_at": null,
    "files": [
      { "kind": "json", "name": "CAP-014-asset-handoff-2026-11-20.json", "bytes": 4210, "sha256": "9f2c0d6b1e4f7a8c5d2e9b0a1f6c3d4e7b8a9c0d1e2f3a4b5c6d7e8f9a0b1c2d" }
    ]
  },
  "package": {
    "schema": "luceryn.asset_handoff.v1",
    "prepared_at": "2026-11-20T15:04:05.123Z",
    "prepared_by": "Sam Rivera",
    "project": {
      "id": "9a1c7f2e-3b4d-4e5f-8a6b-7c8d9e0f1a2b",
      "name": "Science building roof replacement",
      "code": "CAP-014",
      "department": "Facilities",
      "stage": "closing",
      "status": "on track",
      "start_date": "2026-09-01",
      "end_date": "2027-06-30",
      "currency": "CAD",
      "buildings": [{ "name": "Science Building", "code": "SCI", "campus": "Main", "address": null }],
      "link": "https://luceryn.example.com/projects/9a1c7f2e-3b4d-4e5f-8a6b-7c8d9e0f1a2b"
    },
    "cost_summary": null,
    "funding": null,
    "layout": [{ "key": "tag", "header": "Asset tag", "fixed": null }, { "key": "name", "header": "Asset name", "fixed": null }],
    "assets": [
      {
        "luceryn_asset_id": "6d7e8f90-a1b2-4c3d-8e4f-5a6b7c8d9e0f",
        "columns": { "Asset tag": "AHU-0042", "Asset name": "Air handling unit, roof" },
        "record": {
          "tag": "AHU-0042", "name": "Air handling unit, roof", "classification": "Air handling unit", "class_code": "HVAC-AHU", "category": "equipment",
          "location": "Roof", "department": "Facilities", "attributes": { "Capacity": "40 kW" },
          "manufacturer": "Northfield Mechanical", "model": "NM-40", "serial_number": "SN-48213",
          "in_service_date": "2027-06-15", "purchase_date": "2027-03-02", "cost": 125000, "currency": "CAD",
          "vendor": "Northfield Mechanical Ltd", "warranty_start": "2027-06-15", "warranty_end": "2029-06-14",
          "warranty_documents": [{ "name": "AHU warranty.pdf", "url": "https://luceryn.example.com/api/project-files/0f1e2d3c-4b5a-4698-8776-655443322110" }],
          "external_ref": null, "link": "https://luceryn.example.com/assets/6d7e8f90-a1b2-4c3d-8e4f-5a6b7c8d9e0f"
        },
        "warnings": []
      }
    ],
    "documents": [
      { "kind": "Warranty", "title": "AHU warranty", "system": "HVAC", "vendor": "Northfield Mechanical Ltd", "status": "Accepted", "warranty_start": "2027-06-15", "warranty_end": "2029-06-14", "files": [{ "name": "AHU warranty.pdf", "url": "https://luceryn.example.com/api/project-files/0f1e2d3c-4b5a-4698-8776-655443322110" }], "url": "https://luceryn.example.com/projects/9a1c7f2e-3b4d-4e5f-8a6b-7c8d9e0f1a2b/construction?tab=closeout" }
    ],
    "warnings": [],
    "counts": { "assets": 1, "documents": 1, "warnings": 0 },
    "handoff_id": "2b3c4d5e-6f70-4a81-9b92-a3b4c5d6e7f8",
    "trigger": "manual"
  }
}

MaintainX work orders (Luceryn reads from MaintainX)

MaintainX work orders (Luceryn reads from MaintainX), basics
ItemDetail
DirectionOut of Luceryn, read only. Luceryn calls MaintainX's API to read the work orders people have linked to a project, and shows their status on the project. Every request is a GET: nothing is ever created or changed in MaintainX.
Addresshttps://api.getmaintainx.com/v1, fixed. Nobody types an address and no other host is called. Redirects are not followed.
AuthenticationA MaintainX API key that an administrator who holds Manage organization pastes on the MaintainX card under Admin, Connections, sent to MaintainX as Authorization: Bearer; when the key covers several MaintainX organizations, the organization id is sent as x-organization-id. Luceryn stores the key encrypted (AES-256-GCM), never shows it again (the card shows its last four characters) and removes it from any error text it keeps.
  • Switched on by MaintainX work orders (Admin, Industry and features; off by default). Off, nothing is read; links already made are kept.
  • Read for each linked work order: its number, title, status, priority, assignees, location, asset, due date and completed date. A change of status is written to the project's activity, and the project manager can be told when a work order is completed.
  • Linked work orders are read again every hour, oldest read first, at most 60 for a workspace in one run, and whenever someone presses Refresh on the project.
  • Timeout: 10 seconds for each request. Luceryn stops a batch while 5 requests are still left in MaintainX's own rate limit window, and stops refreshing after MaintainX has refused the key 3 times in a row, until the connection is tested again.
  • At most 200 work orders linked to one project; a search by title shows at most 25.
  • Dependency: a MaintainX plan with API access and a key created in your MaintainX account. No middleware.
  • Built from MaintainX's published API description and not yet run against real work orders: the connection is confirmed against your own MaintainX account during setup, with Test connection on the card.

Personal calendar feed (iCalendar)

Personal calendar feed (iCalendar), basics
ItemDetail
DirectionOut of Luceryn. A calendar application (Outlook, Google Calendar, Apple Calendar) subscribes to an address and reads it on its own schedule.
AddressGET /api/calendar/{token}.ics (the .ics ending is optional). Content-Type text/calendar.
AuthenticationThe token in the address is the credential. Each person creates their own under Settings, Calendar, and can replace it there; the old address then stops working. Luceryn looks the token up by its SHA-256 hash and keeps an encrypted copy so the person's settings page can show the address again.
  • Holds the plan tasks the person owns whose start date is between 90 days ago and 365 days ahead, and the milestones that name the person as owner. Cancelled items are left out.
  • Only items of projects the person can read are included. Items of archived projects are left out.
  • Every event is an all-day event. The summary is the project's short code or name, then the task's WBS code and name.
  • At most 500 tasks and 500 milestones.
  • Calendar applications are asked to refresh every 15 minutes (Cache-Control: private, max-age=900); how often they do is up to them.
  • Answers: 404 Invalid token for a token shorter than 16 characters; 404 Not found for an unknown token, which includes an address that has been replaced; 410 for a token marked revoked.

Audit log streaming to a SIEM

Audit log streaming to a SIEM, basics
ItemDetail
DirectionOut of Luceryn. Luceryn posts batches of audit events to a collector you run.
AddressAn https address you enter under Admin, SIEM. Two kinds of destination: a generic HTTPS collector, or a Splunk HTTP Event Collector.
AuthenticationGeneric HTTPS: every batch carries X-Luceryn-Source: siem and X-Luceryn-Signature: sha256= followed by the HMAC-SHA256 of the raw body, keyed with the destination's secret (verify it the way a webhook is verified). Splunk: the secret is sent as Authorization: Splunk followed by the token. The secret is stored encrypted.
  • Three sources can be streamed: the admin audit log, the AI activity ledger and AI actions.
  • A generic batch is one JSON object: destination, delivered_at, event_count and events. Each event has id, time, source, org_id, action, actor, target, status and detail.
  • A Splunk batch is one line for each event, each a JSON object with time, sourcetype (luceryn: followed by the source), source and event.
  • New events are collected every five minutes, in batches of up to 200 events.
  • Timeout: 10 seconds for each batch. A failed batch is tried again after 2, 4, 8 and so on minutes, never more than six hours apart; after 8 failed attempts it is set aside, and an administrator can send the set-aside batches again from the admin page.
  • The address must be https and must not be a private, local or internal address.

Public request form (web page and embed)

Public request form (web page and embed), basics
ItemDetail
DirectionInto Luceryn. People outside the workspace fill in a web page; each submission becomes a request in the workspace's intake.
AddressGET /request/{public id}, a web page. It can be shown inside your own website with an iframe; the form's settings give the snippet to paste.
AuthenticationNone for the visitor: the public id in the address selects the form. Replacing the link in the form's settings makes the old address stop working.
  • This is a page for people, not a machine endpoint: there is no API for posting a submission from another system.
  • Embedding is refused by default. Only the website origins listed in the form's settings may frame the page (https only, up to 20, a leading *. allows every subdomain).
  • At most 20 attempts in 10 minutes from one network address for each form.
  • A cap on submissions in any 24 hours for each form: 200 unless the administrator sets another number, never more than 5,000.
  • No file uploads. Short answers up to 300 characters, long answers up to 4,000.
  • A form that is switched off, unpublished or unknown shows the same notice, so the page does not say whether an address ever existed.

CRM API

For workspaces that use the CRM module. Tokens are created on the CRM settings page by a person who holds Administer CRM; each is shown once and stored as a SHA-256 hash, and can be revoked there. Errors are JSON of the form { "error": "message" }.

List contacts

GET/api/crm/v1/contacts

The workspace's CRM contacts, in name order.

Authentication. Authorization: Bearer followed by a CRM API token (it starts with crm_). The workspace's CRM must be switched on.

Request: Query string

List contacts, request, Query string
FieldTypeRequiredDescriptionExample
limitintegerNoHow many to return. Default 100, at most 500.100
emailstringNoReturn only the contact with this email address. Capitals do not matter.sam.rivera@example.edu

Answer: 200: { "contacts": [ ... ] }, each contact

List contacts, answer, 200: { "contacts": [ ... ] }, each contact
FieldTypeRequiredDescriptionExample
idstring (UUID)YesThe contact's id.4c5d6e7f-8a9b-4c0d-9e1f-2a3b4c5d6e7f
full_namestringYesThe contact's name.Sam Rivera
titlestring or nullYesJob title.Director, Capital Planning
emailstring or nullYesEmail address.sam.rivera@example.edu
phonestring or nullYesPhone number.204-555-0100
client_idstring (UUID) or nullYesThe id of the client the contact belongs to.
last_activity_atstring (ISO 8601) or nullYesWhen the contact last had activity.
created_atstring (ISO 8601)YesWhen the contact was created.2026-11-20T15:04:05.123+00:00

Errors

List contacts, errors
StatusMessageWhen
401UnauthorizedNo token, an unknown or revoked token, or the CRM is switched off.
500Query failedThe contacts could not be read.

Limits

  • At most 500 contacts in one request. There is no paging: narrow the request with email.
  • No request rate limit is applied by Luceryn on this interface.
Example request
curl "https://luceryn.example.com/api/crm/v1/contacts?limit=50" \
  -H "Authorization: Bearer crm_EXAMPLE_TOKEN_REPLACE_ME"
Example answer
{
  "contacts": [
    {
      "id": "4c5d6e7f-8a9b-4c0d-9e1f-2a3b4c5d6e7f",
      "full_name": "Sam Rivera",
      "title": "Director, Capital Planning",
      "email": "sam.rivera@example.edu",
      "phone": "204-555-0100",
      "client_id": null,
      "last_activity_at": null,
      "created_at": "2026-11-20T15:04:05.123+00:00"
    }
  ]
}

Create a contact

POST/api/crm/v1/contacts

Adds a contact. When a contact with the same email address already exists, nothing is added and that contact is returned with merged: true.

Authentication. Authorization: Bearer followed by a CRM API token (it starts with crm_). The workspace's CRM must be switched on.

Request: JSON body

Create a contact, request, JSON body
FieldTypeRequiredDescriptionExample
full_namestringYesThe contact's name. Cut to 120 characters.Sam Rivera
titlestringNoJob title. Cut to 120 characters.Director, Capital Planning
emailstringNoEmail address. Used to find an existing contact first.sam.rivera@example.edu
phonestringNoPhone number. Cut to 40 characters.204-555-0100

Answer: 201: { "contact": { ... } }. 200 with "merged": true when the email already existed. The contact

Create a contact, answer, 201: { "contact": { ... } }. 200 with "merged": true when the email already existed. The contact
FieldTypeRequiredDescriptionExample
idstring (UUID)YesThe contact's id.4c5d6e7f-8a9b-4c0d-9e1f-2a3b4c5d6e7f
full_namestringYesThe contact's name.Sam Rivera
titlestring or nullYesJob title.Director, Capital Planning
emailstring or nullYesEmail address.sam.rivera@example.edu
phonestring or nullYesPhone number.204-555-0100
client_idstring (UUID) or nullYesThe id of the client the contact belongs to.
last_activity_atstring (ISO 8601) or nullYesWhen the contact last had activity.
created_atstring (ISO 8601)YesWhen the contact was created.2026-11-20T15:04:05.123+00:00

Errors

Create a contact, errors
StatusMessageWhen
401UnauthorizedNo token, an unknown or revoked token, or the CRM is switched off.
400Invalid JSONThe body does not parse.
400full_name is requiredNo full_name.
500Insert failedThe contact could not be saved.

Limits

  • One contact in one request.
Example request
curl -X POST "https://luceryn.example.com/api/crm/v1/contacts" \
  -H "Authorization: Bearer crm_EXAMPLE_TOKEN_REPLACE_ME" \
  -H "Content-Type: application/json" \
  -d '{ "full_name": "Sam Rivera", "email": "sam.rivera@example.edu" }'
Example answer
{
  "contact": {
    "id": "4c5d6e7f-8a9b-4c0d-9e1f-2a3b4c5d6e7f",
    "full_name": "Sam Rivera",
    "title": null,
    "email": "sam.rivera@example.edu",
    "phone": null,
    "client_id": null,
    "last_activity_at": null,
    "created_at": "2026-11-20T15:04:05.123+00:00"
  }
}

List deals

GET/api/crm/v1/deals

The workspace's deals, newest first. Deleted deals are left out.

Authentication. Authorization: Bearer followed by a CRM API token (it starts with crm_). The workspace's CRM must be switched on.

Request: Query string

List deals, request, Query string
FieldTypeRequiredDescriptionExample
statusstringNoopen, won or lost. Any other value is ignored.open
limitintegerNoHow many to return. Default 100, at most 200.100

Answer: 200: { "deals": [ ... ] }, each deal

List deals, answer, 200: { "deals": [ ... ] }, each deal
FieldTypeRequiredDescriptionExample
idstring (UUID)YesThe deal's id.5e6f7a8b-9c0d-4e1f-a2b3-c4d5e6f7a8b9
namestringYesThe deal's name.Campus signage refresh
valuenumber or nullYesThe deal's value.48000
currencystring or nullYesThree letter currency code.CAD
statusstringYesopen, won or lost.open
probabilitynumber or nullYesChance of winning, in percent.20
expected_closestring (YYYY-MM-DD) or nullYesExpected close date.2027-03-31
forecast_categorystring or nullYesThe forecast category chosen for the deal.
client_idstring (UUID) or nullYesThe id of the client.
owner_idstring (UUID) or nullYesThe id of the person who owns the deal.
sourcestring or nullYesWhere the deal came from.api
next_stepstring or nullYesThe next step noted on the deal.
lost_reasonstring or nullYesThe reason given when the deal was lost.
created_atstring (ISO 8601)YesWhen the deal was created.2026-11-20T15:04:05.123+00:00
won_atstring (ISO 8601) or nullYesWhen the deal was won.
last_activity_atstring (ISO 8601) or nullYesWhen the deal last had activity.

Errors

List deals, errors
StatusMessageWhen
401UnauthorizedNo token, an unknown or revoked token, or the CRM is switched off.
500Query failedThe deals could not be read.

Limits

  • At most 200 deals in one request. There is no paging.
  • No request rate limit is applied by Luceryn on this interface.
Example request
curl "https://luceryn.example.com/api/crm/v1/deals?status=open" \
  -H "Authorization: Bearer crm_EXAMPLE_TOKEN_REPLACE_ME"
Example answer
{
  "deals": [
    {
      "id": "5e6f7a8b-9c0d-4e1f-a2b3-c4d5e6f7a8b9",
      "name": "Campus signage refresh",
      "value": 48000,
      "currency": "CAD",
      "status": "open",
      "probability": 20,
      "expected_close": "2027-03-31",
      "forecast_category": null,
      "client_id": null,
      "owner_id": null,
      "source": "api",
      "next_step": null,
      "lost_reason": null,
      "created_at": "2026-11-20T15:04:05.123+00:00",
      "won_at": null,
      "last_activity_at": "2026-11-20T15:04:05.123+00:00"
    }
  ]
}

Create a deal

POST/api/crm/v1/deals

Adds a deal in the first open stage of the workspace's pipeline. No webhook event is sent for a deal created this way.

Authentication. Authorization: Bearer followed by a CRM API token (it starts with crm_). The workspace's CRM must be switched on.

Request: JSON body

Create a deal, request, JSON body
FieldTypeRequiredDescriptionExample
namestringYesThe deal's name. Cut to 140 characters.Campus signage refresh
valuenumberNoThe deal's value.48000
expected_closestring (YYYY-MM-DD)NoExpected close date. Any other form is ignored.2027-03-31
sourcestringNoWhere the deal came from. Cut to 60 characters. Default api.website
descriptionstringNoNotes. Cut to 2,000 characters.Asked for a quote by email

Answer: 201: { "deal": { ... } }. The deal

Create a deal, answer, 201: { "deal": { ... } }. The deal
FieldTypeRequiredDescriptionExample
idstring (UUID)YesThe deal's id.5e6f7a8b-9c0d-4e1f-a2b3-c4d5e6f7a8b9
namestringYesThe deal's name.Campus signage refresh
valuenumber or nullYesThe deal's value.48000
currencystring or nullYesThree letter currency code.CAD
statusstringYesopen, won or lost.open
probabilitynumber or nullYesChance of winning, in percent.20
expected_closestring (YYYY-MM-DD) or nullYesExpected close date.2027-03-31
forecast_categorystring or nullYesThe forecast category chosen for the deal.
client_idstring (UUID) or nullYesThe id of the client.
owner_idstring (UUID) or nullYesThe id of the person who owns the deal.
sourcestring or nullYesWhere the deal came from.api
next_stepstring or nullYesThe next step noted on the deal.
lost_reasonstring or nullYesThe reason given when the deal was lost.
created_atstring (ISO 8601)YesWhen the deal was created.2026-11-20T15:04:05.123+00:00
won_atstring (ISO 8601) or nullYesWhen the deal was won.
last_activity_atstring (ISO 8601) or nullYesWhen the deal last had activity.

Errors

Create a deal, errors
StatusMessageWhen
401UnauthorizedNo token, an unknown or revoked token, or the CRM is switched off.
400Invalid JSONThe body does not parse.
400name is requiredNo name.
500Insert failedThe deal could not be saved.

Limits

  • One deal in one request.
Example request
curl -X POST "https://luceryn.example.com/api/crm/v1/deals" \
  -H "Authorization: Bearer crm_EXAMPLE_TOKEN_REPLACE_ME" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Campus signage refresh", "value": 48000, "expected_close": "2027-03-31" }'
Example answer
{
  "deal": {
    "id": "5e6f7a8b-9c0d-4e1f-a2b3-c4d5e6f7a8b9",
    "name": "Campus signage refresh",
    "value": 48000,
    "currency": null,
    "status": "open",
    "probability": 20,
    "expected_close": "2027-03-31",
    "forecast_category": null,
    "client_id": null,
    "owner_id": null,
    "source": "api",
    "next_step": null,
    "lost_reason": null,
    "created_at": "2026-11-20T15:04:05.123+00:00",
    "won_at": null,
    "last_activity_at": "2026-11-20T15:04:05.123+00:00"
  }
}

Web form lead capture

Web form lead capture

POST/api/crm/lead-capture

A form on your own website posts an enquiry here and it becomes a CRM lead with the source web_form. The endpoint answers browsers on any site (Access-Control-Allow-Origin: *).

Authentication. The workspace's web form token, in the query string (?token=) or as token in the body. The token is shown to CRM administrators on the CRM settings page. It is meant to sit in the source of a public web page, so it is a form identifier, not a secret. The CRM and the Web lead capture switch must both be on.

Request: JSON body

Web form lead capture, request, JSON body
FieldTypeRequiredDescriptionExample
full_namestringYesThe person's name (name is accepted too). Cut to 120 characters.Sam Rivera
companystringNoCut to 300 characters.Northfield College
titlestringNoCut to 300 characters.Director, Capital Planning
emailstringNoCut to 300 characters.sam.rivera@example.edu
phonestringNoCut to 300 characters.204-555-0100
messagestringNoThe enquiry (notes is accepted too). Cut to 300 characters.Please call about the spring program.
tokenstringNoThe web form token, when it is not in the query string.

Answer: 201

Web form lead capture, answer, 201
FieldTypeRequiredDescriptionExample
okbooleanYestrue. The lead's id is not returned.true

Errors

Web form lead capture, errors
StatusMessageWhen
400Invalid JSON.The body does not parse.
401Missing token.No token in the query string or the body.
401Unknown or disabled capture token.The token matches no workspace, or the workspace's CRM is off.
403Lead capture is switched off for this workspace.The Web lead capture switch is off.
400full_name is required.Neither full_name nor name.
429Daily capture limit reached.200 web form leads have arrived for the workspace in the last 24 hours.
500Couldn't record the lead.The lead could not be saved.

Limits

  • 200 leads for a workspace in any 24 hours.
  • Errors come as { "ok": false, "error": "..." }.
Example request
curl -X POST "https://luceryn.example.com/api/crm/lead-capture?token=EXAMPLE_FORM_TOKEN_REPLACE_ME" \
  -H "Content-Type: application/json" \
  -d '{ "full_name": "Sam Rivera", "email": "sam.rivera@example.edu", "message": "Please call about the spring program." }'
Example answer
{ "ok": true }

Salesforce

Salesforce closed-won intake

POST/api/integrations/salesforce/intake

A Salesforce Flow posts a won opportunity here and Luceryn creates the delivery project, linked to the client with the same account name (created when new) and managed by the person whose email matches the owner.

Authentication. X-Luceryn-Secret header carrying the workspace's Salesforce shared secret (it starts with sf_), created on the Salesforce card under Admin, Connections.

Request: JSON body: { "opportunity": { ... } }

Salesforce closed-won intake, request, JSON body: { "opportunity": { ... } }
FieldTypeRequiredDescriptionExample
opportunity.namestringYesBecomes the project's name. Cut to 140 characters.Science building roof replacement
opportunity.amountnumberNoBecomes the project's total budget and is written into its description.250000
opportunity.account_namestringNoThe client. Matched by name without regard to capitals; created when there is none.Northfield College
opportunity.owner_emailstringNoBecomes the project manager when a person with this email exists in the workspace.sam.rivera@example.edu
opportunity.descriptionstringNoWritten into the project's description. Cut to 1,500 characters.Three year maintenance program
opportunity.close_datestring (YYYY-MM-DD)NoAccepted and not used. The project's start date is the day the request arrives (Eastern time).2026-11-20

Answer: 201, or 200 with deduped: true

Salesforce closed-won intake, answer, 201, or 200 with deduped: true
FieldTypeRequiredDescriptionExample
okbooleanYestrue.true
project_idstring (UUID)YesThe project created, or the one found.9a1c7f2e-3b4d-4e5f-8a6b-7c8d9e0f1a2b
dedupedbooleanNotrue when a project with the same name was created in the last 24 hours; nothing new was created.true

Errors

Salesforce closed-won intake, errors
StatusMessageWhen
401UnauthorizedNo X-Luceryn-Secret header, one that does not start with sf_, or one that matches no active Salesforce connection.
400Invalid JSONThe body does not parse.
400opportunity.name is requiredNo opportunity name.
422<the plan's project limit message>The workspace has reached the number of active projects its plan allows.
500Couldn't create the projectThe project could not be saved.

Limits

  • One opportunity in one request.
  • The same opportunity name within 24 hours returns the first project instead of creating a second.
  • Errors come as { "error": "..." }.
Example request
curl -X POST "https://luceryn.example.com/api/integrations/salesforce/intake" \
  -H "X-Luceryn-Secret: sf_EXAMPLE_SECRET_REPLACE_ME" \
  -H "Content-Type: application/json" \
  -d '{ "opportunity": { "name": "Science building roof replacement", "amount": 250000, "account_name": "Northfield College" } }'
Example answer
{ "ok": true, "project_id": "9a1c7f2e-3b4d-4e5f-8a6b-7c8d9e0f1a2b" }

Jira issue updates (inbound webhook)

Jira issue updates (inbound webhook), basics
ItemDetail
DirectionInto Luceryn. Jira Cloud calls Luceryn when a linked issue changes, so the linked RAID item follows the issue's status.
AddressPOST /api/integrations/jira/webhook?token= followed by the token, registered in Jira for the Issue updated event.
AuthenticationThe token in the address, created on the Jira page under Admin. Jira Cloud does not sign its calls, so the token is the credential; Luceryn stores only its SHA-256 hash.
  • Fields read from Jira's body: issue.key, issue.fields.status.name and issue.fields.status.statusCategory.key. Nothing else is used.
  • Only RAID items of this workspace's own live projects that are linked to that issue key are changed.
  • A well formed call always answers 200, even when nothing matched. 401 for a missing or unknown token or a paused connection; 400 for a body that is not JSON.

Health check

Health check

GET/api/health

For an uptime monitor: says whether the application and its database are answering. It returns no workspace data.

Authentication. None.

Answer: 200 when healthy, 503 when the database cannot be reached within 3 seconds

Health check, answer, 200 when healthy, 503 when the database cannot be reached within 3 seconds
FieldTypeRequiredDescriptionExample
statusstringYesok or degraded.ok
dbstringYesok or unreachable.ok
took_msintegerYesHow long the check took, in milliseconds.41

Limits

  • Never cached (Cache-Control: no-store).
Example request
curl "https://luceryn.example.com/api/health"
Example answer
{ "status": "ok", "db": "ok", "took_ms": 41 }

Addresses under /api that are not interfaces

Everything else under /api serves the app itself, a provider that Luceryn connects to, or a signed-in person's download. They are listed so the reference is complete; none of them is meant to be called by a customer's system.

Addresses that are not customer interfaces
Address beginsWhat it isWhy it is not an interface
/api/cron/Scheduled jobs (among them the hourly MaintainX refresh and the automatic asset hand-off)Called only by Luceryn's own scheduler with a secret the service holds.
/api/webhooks/Calls from Microsoft Graph, the meeting recorder, Slack and Microsoft TeamsEach is called by that provider and verified with that provider's own signature or shared state. They are set up from the connection cards, not by calling them.
/api/billing/webhookThe payment provider's notificationsCalled by the payment provider and verified with its signature.
/api/integrations/atlassian/oauthSign-in return address for AtlassianPart of connecting an account in the browser.
/api/integrations/google/oauthSign-in return address for GooglePart of connecting an account in the browser.
/api/integrations/salesforce/oauthSign-in return address for SalesforcePart of connecting an account in the browser.
/api/integrations/slack/Slack sign-in return addresses and slash commandsCalled by Slack and verified with Slack's signature.
/api/admin/Maintenance actions and the workspace export downloadUsed by the admin screens with a signed-in session.
/api/teams/app-packageThe Microsoft Teams app package downloadA file download from the Teams connection card.
/api/versionBuild identitySays which build is running. Used by Luceryn's own release checks; it carries no workspace data.
/api/itsm/csatSatisfaction rating linksOpened by a person from a signed link in a service desk email.
/api/inbound-email/lazyMail catch-up triggerCalled by the app itself with a signed-in session.
/api/lyrian/chatThe assistant's chat streamCalled by the app itself with a signed-in session.
/api/quickstart/Project quick startCalled by the app itself with a signed-in session.
/api/documents/Word and PowerPoint downloads of a document, and draft streamingDownloads and streams for a signed-in person; they need a browser session, not a token.
/api/status-report-requests/predraftStatus report draftingCalled by the app itself with a signed-in session.
/api/project-files/File downloads and previewsDownloads for a signed-in person, checked against that person's access.
/api/plan-export/Plan PowerPoint exportA download for a signed-in person.
/api/raid/RAID log Excel exportA download for a signed-in person.
/api/construction/Construction registers Excel exportA download for a signed-in person.
/api/bluebeam/Review markups Excel exportA download for a signed-in person.
/api/assets/xlsxAsset register exportA download for a signed-in person.
/api/assets/stocktake/Stocktake exportA download for a signed-in person.
/api/assets/handoff/[id]/The files of an asset hand-off package (Excel, CSV, JSON)Downloads for a signed-in person who can read the project and see its money. A system reads the package from /api/assets/handoff/latest or receives it by webhook.
/api/capital/cost-summaryCost summary and cost list export (CSV or Excel)A download for a signed-in person who holds View financials.
/api/portfolio-benefits/exportBenefit measurements export (CSV or Excel)A download for a signed-in person who holds View financials.
/api/scoring/ranking/exportProject and proposal ranking export (Excel)A download for a signed-in person, checked against that person's access to scoring.
/api/stage-gates/decision-logGate decision log export (Excel)A download for a signed-in person, checked against that person's access to the project.
/api/sustainability/exportSustainability tracking export (CSV or Excel)A download for a signed-in person.
/api/vendors/evaluations/exportContractor evaluations exportA download for a signed-in person.
/api/reports/custom/Custom report exportA download for a signed-in person.
/api/invoices/Invoice print viewA page for a signed-in person.
/api/accounting/exportInvoice export for QuickBooks or Xero (CSV)A download for a signed-in person who holds the invoices permission, so the export is tied to a person. It is a file hand-off, not a token interface.
/api/resources/Assignment historyCalled by the app itself with a signed-in session.
/api/map/backgroundCampus map background imageAn image for a signed-in person.
/api/crm/documents/CRM document downloadA download for a signed-in person.
/api/crm/rfp-convertRFP conversionCalled by the app itself with a signed-in session.
/api/crm/rfp/RFP package downloadA download for a signed-in person.

A question about an interface?

These pages are written from the code that serves each interface. If something here does not match what you see, tell us and we will check it.

hello@luceryn.com