SMS Libraries and APIs

Get SMS log by ID

Fetch a single SMS log by ID for the team, with messageContent decrypted.

get/sms/v1/sms/logs/{sms_log_id}

Path parameters

sms_log_idstring required

Response

Successful Response

teamIdstring nullable

ID of the team that owns this record

createdBystring nullable

ID of the user who created this record

updatedBystring nullable

ID of the user who last updated this record

createdAtstring date-time
updatedAtstring date-time
_idstring nullable

MongoDB document ObjectID

phoneProvider'twilio' | 'telnyx' | 'vonage' required
phoneNumberIdstring nullable

Phone number config ID

assistantNumberstring nullable

Assistant's phone number

userNumberstring nullable

User's phone number

direction'inbound' | 'outbound'
messageContentstring nullable

Encrypted message text

status'pending' | 'received' | 'delivered' | 'failed'
errorCode'validation_error' | 'phone_number_not_found' | 'credentials_error' | 'credentials_not_found' | 'send_failed' | 'rate_limit_error' | 'upstream_error' | 'encryption_error' | 'server_error' | 'phone_provider_not_supported'
errorMessagestring nullable

Human-readable error message

numSegmentsinteger nullable

Carrier segment count. Inbound SMS is billed per segment; also the metering baseline.

notesstring nullable

Additional notes or context

maskStatusstring

Zero data retention masking status for this SMS log

Example response

{
  "teamId": "5eb7cf5a86d9755df3a6c593",
  "createdBy": "5eb7cf5a86d9755df3a6c593",
  "updatedBy": "5eb7cf5a86d9755df3a6c593",
  "_id": "5eb7cf5a86d9755df3a6c593",
  "phoneNumberId": "5eb7cf5a86d9755df3a6c593",
  "meta": {
    "assistantId": "5eb7cf5a86d9755df3a6c593",
    "workflowId": "5eb7cf5a86d9755df3a6c593",
    "campaignId": "5eb7cf5a86d9755df3a6c593"
  }
}

Changes

Changed in 1 of the 3 revisions of this API.2

    • added the optional property maskStatus to the response with the 200 status

      response-optional-property-added

    • added the optional property numSegments to the response with the 200 status

      response-optional-property-added