Bluestep JS Documentation
    Preparing search index...

    Class TextMessage

    Used to send an text. See [[B.Text]]

    Index

    Constructors

    Methods

    • The id of the relate entry that contains the phone number used for texting.

      Parameters

      • id: string

      Returns TextMessage

    • The message to send to the phone number.

      Parameters

      • message: string

      Returns TextMessage

    • Opt-in phone numbers to receive texts. Provide either numbers array or use id() for bluestepId lookup.

      Parameters

      • Optionalnumbers: string[]

      Returns void

    • Opt-out phone numbers from receiving texts. Provide either numbers array or use id() for bluestepId lookup.

      Parameters

      • Optionalnumbers: string[]

      Returns void

    • Reassigns a phone number from one bluestepId to another within the unit. Also updates all text message history to reference the new bluestepId. Throws if the target bluestepId already has this number (409 conflict).

      Parameters

      • number: string
      • fromBluestepId: string
      • toBluestepId: string

      Returns ReassignBluestepIdResponse

    • The recipient's phone number. Accepts multiple formats that will be automatically normalized to E.164:

      • E.164 format: +18013363043
      • International with 00 prefix: 0018013363043
      • US/Canada 10-digit: 8013363043 (assumes +1)
      • US/Canada 11-digit: 18013363043 (assumes +)
      • Formatted: (801) 336-3043, 801-336-3043

      International numbers (12+ digits) must include + or 00 prefix. Local numbers assume +1 (US/Canada).

      Parameters

      • to: string

      Returns TextMessage

    • The fully qualified unit id (e.g., 111000_U12345__148522) that has been pre-configured for Bandwidth Messaging.

      Parameters

      Returns TextMessage