Skip to main content
Salfio Docs

Search documentation

Type to search this documentation.

On this pageOverview

Create a note on a client

Records a note against the client and returns it as an activity of `type: "note"`. Unlike the generic activity create, the note path attributes the note to a user author (added as a participant contact) and marks the client's AI cards stale so they regenerate. **Author attribution.** With a **user-scoped** key the note is authored by the authenticated user automatically. With a **service-scoped** key (which carries no user) you MUST supply `authorUserId` referencing a member of your organization — otherwise the request is rejected with `400 invalid_argument`. A cross-organization or unknown `authorUserId` is likewise `400 invalid_argument`. `content` is required. `participants` are people present on the note besides the author; each is linked to (or created as) an org contact by email. `occurredAt` defaults to now when omitted.

POST

/clients/{clientId}/notes

bearerAuth``

AuthorizationBearer <token>

Salfio API tokens start with the literal prefix sk_live_ followed by 32 base62 characters (≈190 bits of entropy). Tokens are hashed at rest with argon2id and shown to the user only once at creation.

In: header

clientId*string

Formatuuid

application/json

TypeScript Definitions

Use the request body type in TypeScript.

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://api.salfio.com/v1/clients/497f6eca-6276-4993-bfeb-53cbbbba6f08/notes" \  -H "Content-Type: application/json" \  -d '{    "content": "string"  }'

{
  "meta": {
    "cursor": "string",
    "hasMore": true
  },
  "data": {
    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
    "clientId": "5e505642-9024-474d-9434-e5a44f505cc5",
    "type": "email",
    "source": "manual",
    "subject": "string",
    "content": "string",
    "occurredAt": "2019-08-24T14:15:22Z",
    "participants": [
      "[email protected]"
    ],
    "immutable": true,
    "archivedAt": "2019-08-24T14:15:22Z",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z"
  }
}

{
  "error": {
    "code": "invalid_argument",
    "message": "limit must be an integer between 1 and 100"
  }
}

{
  "error": {
    "code": "unauthorized",
    "message": "Authentication required"
  }
}

{
  "error": {
    "code": "not_found",
    "message": "client not found"
  }
}

{
  "error": {
    "code": "rate_limited",
    "message": "Rate limit exceeded",
    "details": {
      "retry_after_seconds": 30
    }
  }
}
Export
Suggest an edit to this page

Documentation menu