Skip to content

client

Get a client sentiment snapshot

GET/v1/clients/{clientId}/sentiment

Reads a computed sentiment snapshot for one client: a bucket, a confidence, evidence counts, the top drivers, risk flags and suggested next actions, derived with deterministic local rules from the client's recent CRM activities, opportunities and quotes. All of that text moves the score, but an evidence snippet quotes only text another published read already returns, so an email body, a meeting transcript summary, an opportunity's notes and a quote's description or loss reason are scored and never quoted. Contacts and opportunities are read through the same visibility rules contact.search and opportunity.search apply. A key needs opportunity:read as well as client:read, because the snapshot returns opportunity and quote titles. A hidden client answers not_found.

Parameters

NameInRequiredTypeDescription
clientIdpathYesstring—
windowDaysqueryNointeger—

Request body

No request body.

Responses and errors

  • 200

    Get a client sentiment snapshot

    • snapshot (required): object
    • markdown (required): string
  • 400

    Error envelope. `error.code` carries the typed outcome and `error.type` resolves to its description.

    • ValidationFailedError:
    • allOf: ErrorEnvelope
  • 401

    Error envelope. `error.code` carries the typed outcome and `error.type` resolves to its description.

    • UnauthorizedError:
    • allOf: ErrorEnvelope
  • 403

    Error envelope. `error.code` carries the typed outcome and `error.type` resolves to its description.

    • ForbiddenError:
    • allOf: ErrorEnvelope
  • 404

    Error envelope. `error.code` carries the typed outcome and `error.type` resolves to its description.

    • NotFoundError:
    • allOf: ErrorEnvelope
  • 429

    Error envelope. `error.code` carries the typed outcome and `error.type` resolves to its description.

    • RateLimitedError:
    • allOf: ErrorEnvelope
  • 503

    Error envelope. `error.code` carries the typed outcome and `error.type` resolves to its description.

    • UnavailableError:
    • allOf: ErrorEnvelope

Example

curl --request GET \
  --url 'https://api.scopable.io/v1/clients/{clientId}/sentiment' \
  --header 'Authorization: Bearer $SCOPABLE_API_KEY'

Replace $SCOPABLE_API_KEY with a key created in Settings, API.

View the OpenAPI 3.1 source

Need help with the API? …