Skip to main content
The guava.Client can send SMS messages from your Guava numbers and wait for inbound replies. This is useful for sending confirmations and reminders, or for collecting a response between calls.
SMS messaging is available in the Python and TypeScript SDKs. For other languages, call the equivalent Messages REST API directly.

send_sms / sendSms

Send a single SMS message. The from_number must be one of your Guava numbers with SMS configured, and the message is delivered to to_number.
Returns nothing (Python None; TypeScript resolves void). Raises (Python) / rejects (TypeScript) if the from_number isn’t owned by your organization or doesn’t have SMS configured.
Sending SMS requires your organization to complete SMS brand and campaign registration. See Outbound & SMS Compliance.

next_sms / nextSms

Wait for the next inbound SMS sent to one of your Guava numbers from a given number, and return it. next_sms polls your inbox and only returns messages received after the call begins, so a reply to an earlier message won’t be returned twice.
Note the direction: from_number is the external number you’re waiting to hear from (the customer), and to_number is your Guava number that receives the reply — the opposite of send_sms.
Returns the message (Python dict / TypeScript SmsMessage), or None / null if the timeout elapses with no new message. A message has the following fields: