Light APIv1.0.0

API / Reference / User Comments

Create user comment

POST https://api.light.inc/v1/user-comments

Creates a new user comment

resourceId is the id of the record being commented on (any record type; there is no resourceType), and it is not validated — a wrong id is accepted silently. content is stored and returned verbatim with no length limit and no mention syntax. createdBy is always the caller; for an API key that is the key's service-account id.

Authorization

Send one of these on every request. See Authentication for how to get credentials.

  • API key

    Basic authentication header of the form Basic <api_key>, where <api_key> is your api key.

  • Bearer token

Request body

application/json;charset=UTF-8

  • resourceId string · uuid

    ID of the resource this comment is attached to (e.g. vendor, customer, etc.).

  • content string

    Comment content.

Response

  • id string · uuid

    ID of the comment.

  • companyId string · uuid

    ID of the company this comment belongs to.

  • resourceId string · uuid

    ID of the resource this comment is attached to (e.g. vendor, customer, etc.).

  • content string

    Comment content.

  • createdBy string · uuid

    ID of the user who created the comment.

  • createdAt string · date-time

    Timestamp when the comment was created.

  • updatedAt string · date-time

    Timestamp when the comment was last updated.