community.general.catapult module – Send a sms / mms using the catapult bandwidth API
Note
This module is part of the community.general collection (version 11.3.0).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.catapult
.
DEPRECATED
- Removed in:
version 13.0.0
- Why:
DNS fails to resolve the API endpoint used by the module since Oct 2024. See the associated issue for details.
- Alternative:
There is none.
Synopsis
Allows notifications to be sent using SMS / MMS using the catapult bandwidth API.
Parameters
Parameter |
Comments |
---|---|
API Secret from API account page. |
|
API Token from API account page. |
|
The phone number or numbers the message should be sent to (must be in E.164 format, like |
|
For MMS messages, a media URL to the location of the media to be sent with the message. |
|
The contents of the text message (must be 2048 characters or less). |
|
One of your catapult telephone numbers the message should come from (must be in E.164 format, like |
|
User ID from API account page. |
Attributes
Attribute |
Support |
Description |
---|---|---|
Support: none |
Can run in |
|
Support: none |
Returns details on what has changed (or possibly needs changing in |
Notes
Note
Will return changed even if the media URL is wrong.
Will return changed if the destination number is invalid.
Examples
- name: Send a mms to multiple users
community.general.catapult:
src: "+15035555555"
dest:
- "+12525089000"
- "+12018994225"
media: "http://example.com/foobar.jpg"
msg: "Task is complete"
user_id: "{{ user_id }}"
api_token: "{{ api_token }}"
api_secret: "{{ api_secret }}"
- name: Send a sms to a single user
community.general.catapult:
src: "+15035555555"
dest: "+12018994225"
msg: "Consider yourself notified"
user_id: "{{ user_id }}"
api_token: "{{ api_token }}"
api_secret: "{{ api_secret }}"
Status
This module will be removed in version 13.0.0. [deprecated]
For more information see DEPRECATED.