MailSlurpAPI.Api.SmsController (mailslurp v15.14.0)

API calls for all endpoints tagged SmsController.

Link to this section Summary

Functions

Delete SMS message. Delete an SMS message

Delete all SMS messages Delete all SMS messages or all messages for a given phone number

Get SMS content including body. Expects SMS to exist by ID. For SMS that may not have arrived yet use the WaitForController. Returns a SMS summary object with content.

Get all SMS messages in all phone numbers in paginated form. . By default returns all SMS messages across all phone numbers sorted by ascending created at date. Responses are paginated. You can restrict results to a list of phone number IDs. You can also filter out read messages

Link to this section Functions

Link to this function

delete_sms_message(connection, sms_id, opts \\ [])

@spec delete_sms_message(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, nil} | {:error, Tesla.Env.t()}

Delete SMS message. Delete an SMS message

parameters

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • sms_id (String.t):
  • opts (KeywordList): [optional] Optional parameters

returns

Returns

} on success {:error, info} on failure

Link to this function

delete_sms_messages(connection, opts \\ [])

@spec delete_sms_messages(Tesla.Env.client(), keyword()) ::
  {:ok, nil} | {:error, Tesla.Env.t()}

Delete all SMS messages Delete all SMS messages or all messages for a given phone number

parameters

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • opts (KeywordList): [optional] Optional parameters
    • :phone_number_id (String.t):

returns

Returns

} on success {:error, info} on failure

Link to this function

get_sms_message(connection, sms_id, opts \\ [])

@spec get_sms_message(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, MailSlurpAPI.Model.SmsDto.t()} | {:error, Tesla.Env.t()}

Get SMS content including body. Expects SMS to exist by ID. For SMS that may not have arrived yet use the WaitForController. Returns a SMS summary object with content.

parameters

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • sms_id (String.t):
  • opts (KeywordList): [optional] Optional parameters

returns

Returns

} on success {:error, info} on failure

Link to this function

get_sms_messages_paginated(connection, opts \\ [])

@spec get_sms_messages_paginated(Tesla.Env.client(), keyword()) ::
  {:ok, MailSlurpAPI.Model.PageSmsProjection.t()} | {:error, Tesla.Env.t()}

Get all SMS messages in all phone numbers in paginated form. . By default returns all SMS messages across all phone numbers sorted by ascending created at date. Responses are paginated. You can restrict results to a list of phone number IDs. You can also filter out read messages

parameters

Parameters

  • connection (MailSlurpAPI.Connection): Connection to server
  • opts (KeywordList): [optional] Optional parameters
    • :phone_number (String.t): Optional receiving phone number to filter SMS messages for
    • :page (integer()): Optional page index in SMS list pagination
    • :size (integer()): Optional page size in SMS list pagination. Maximum size is 100. Use page index and sort to page through larger results
    • :sort (String.t): Optional createdAt sort direction ASC or DESC
    • :unread_only (boolean()): Optional filter for unread SMS only. All SMS are considered unread until they are viewed in the dashboard or requested directly
    • :since (DateTime.t): Optional filter SMSs received after given date time
    • :before (DateTime.t): Optional filter SMSs received before given date time

returns

Returns

} on success {:error, info} on failure