LogoLogo
Jump to...Create Free API Account
  • Developer Center Introduction
  • Getting Started
    • Get an API Key
    • Send a Message
    • Add a Subscriber
    • Setting up Webhooks
  • Check Delivery Status
  • API Basics
    • Request / Response Headers
    • Request Parameters
    • Rate Limits
    • Error Response Codes
  • Messaging Routes
    • 10DLC
    • Toll-Free
    • Short Code
    • iMessage
    • RCS / RBM
  • Tutorials
    • Message Sending
      • Send an SMS Message
      • Send an MMS Message
      • Send an iMessage
        • Sender Identity
        • Subscriber Opt In
        • Send iMessages
        • SMS Fallback
      • Message Templates
      • Receive and Reply to Messages
    • Manage Subscribers
      • Custom Subscriber Attributes
      • Group Subscribers
      • Bulk Create/Update Subscribers
    • Webhooks
      • Setting up your first webhook
  • Use Cases
    • Generate and validate 2FA / MFA codes via SMS
  • FAQ
  • API Reference
Powered by GitBook
LogoLogo

Resources

  • Help Center
  • Contact

Company

  • About Us
  • Privacy Policy
  • Service Agreement

Connect with Us

  • YouTube
  • Facebook
  • X (Twitter)
  • Instagram

Mobile Text Alerts © 2025

On this page

Was this helpful?

Export as PDF
  1. Tutorials
  2. Manage Subscribers

Group Subscribers

Learn how to create and update groups of subscribers, useful for targeted messaging.

PreviousCustom Subscriber AttributesNextBulk Create/Update Subscribers

Last updated 4 days ago

Was this helpful?

Organizing subscribers into different groups enables you to easily send out targeted messages to specific segments. With Mobile Text Alerts, you can add, edit, and remove groups and subscribers via the or with the , making it easy to keep your contact lists updated.

Manage Groups with the API

Create a new Group

Example request

curl -L \                                                              
  --request POST \                                                     
  --url 'https://api.mobile-text-alerts.com/v3/groups' \
  --header 'Authorization: Bearer 3098eebf-7661-5858-890e-65cd054a0b03' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "Example"
  }'

Successful response: "message": "Created group Example."

Request Fields

Delete Group

Groups can be deleted without needed to supply a request body. Simply include the {groupId} of the group to be deleted as a path parameter with your DELETE request.

Example Request

In the below example we are deleting groupId: 187561 .

curl --request DELETE --location 'https://api.mobile-text-alerts.com/v3/groups/187561'  
--header 'Authorization: Bearer 3098eebf-7661-5858-890e-65cd054a0b03'     

Successful Response: {"message":"Group deleted successfully."}

Update Groups

Example Request

In the below example, we are updating groupId: 187561 .

curl -L \
  --request PATCH \
  --url 'https://api.mobile-text-alerts.com/v3/groups/187561' \
  --header 'Authorization: Bearer 3098eebf-7661-5858-890e-65cd054a0b03' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "New Name"
  }'

Successful response: "message": "Updated group New Name."

Request Fields

List All Groups

This endpoint produces paginated results. You may need to make multiple queries to retrieve every group on your account.

Query responses include the following data:

  • page - the current page of results being shown

  • pageSize- number of groups shown per page

  • total - the total number of groups on your account

Example Request

curl --location 'https://api.mobile-text-alerts.com/v3/groups'\
  --header 'Authorization: Bearer 3098eebf-7661-5858-890e-65cd054a0b03'

Successful response:

{"data":
    {"rows":
    [{"id":187561,
        "name":"Test Group",
        "hidden":0,
        "displayName":null,
        "welcomeMessage":"",
        "sortOrder":null,
        "description":"First group created for testing.",
        "createdAt":"2025-05-29T19:04:14.000Z",
        "memberCount":0,"type":"static"},
    {"id":187572,
        "name":"API-Test",
        "hidden":0,
        "displayName":null,
        "welcomeMessage":"",
        "sortOrder":null,
        "description":null,
        "createdAt":"2025-05-29T14:47:26.000Z",
        "memberCount":0,"type":"static"}],
"page":0,"pageSize":25,"total":2}}

Manage Group Members

Add Subscriber to Group

To add a subscriber to a group you will need both the subscriberId and the groupId . The subscriberId is passed on the body of the request, while the groupId is specified as a path parameter.

Example request:

In the below example we are adding subscriberId :108767117 to groupId: 187561 .

curl -X POST --location 'https://api.mobile-text-alerts.com/v3/groups/187561/subscribers' \
--header 'Authorization: Bearer 3098eebf-7661-5858-890e-65cd054a0b03' 
--header 'Content-Type: application/json'  \
--data '{"subscriberId":108767117}'

Successful response: {"message":"Added subscriber 108767117 to group 187561."}

By default, when adding a subscriber to a group the addToDripCampaigns field will be set to true . Set this field to false if you don't want this subscriber included in drip campaigns.

Delete Group Member

Example request

In the below example we are deleting subscriberId :108767117 from groupId: 187561 .

curl --request DELETE --location 'https://api.mobile-text-alerts.com/v3/groups/187561/subscribers/108767117'  
--header 'Authorization: Bearer 3098eebf-7661-5858-890e-65cd054a0b03'  

Successful Response: {"message":"Deleted subscriber 108767117 from group 187561."}

The Mobile Text Alerts API allows you to , , s metadata or for your account.

Note that these actions are used to make changes to the group itself, not the subscribers that may be contained within the group. See to see actions for adding/removing subscribers from your groups.

A POST call to the endpoint will create a new group, for the group metadata when creating a new group.

The fields that contain the metadata about a group can be added or updated at anytime by calling the PATCH endpoint with the identifying {groupId} of the group to be updated. that contain the group metadata.

Call the GET endpoint to see all the groups on your account.

Subscribers can be or from your groups with the API endpoints documented below.

Subscribers can be removed from a group by identifying them with the groupId and subscriberId in the path parameters to the DELETE endpoint.

create a group
delete a group
update an existing group'
view all groups
Manage Group Members
/groups
see below for all the additional request fields
/groups/{groupId}
See below for all the optional request fields
/groups
added
deleted
/groups/{groupId}/subscribers/{subscriberId
online dashboard
MTA API
Manage Group Members in the online dashboard
Name
Type
Description

name - required

string

The name of the group.

hidden

boolean

Indicates if the group is hidden.

description

string

Description of the group.

displayName

string

An alternate display name for this group

sortOrder

number

Override default sorting when displaying this group on the subscriber sign up page

isTemporary

boolean

When set to true, this group is marked as temporary. Temporary groups are deleted at midnight of the day following their creation.

createdAt

string

Timestamp of when the group was created. For example: "2025-05-29T19:04:14.000Z"

Name
Type
Description

name - required

string

The name of the group.

hidden

boolean

Indicates if the group is hidden.

description

string

Description of the group.

displayName

string

An alternate display name for this group

sortOrder

number

Override default sorting when displaying this group on the subscriber sign up page

isTemporary

boolean

When set to true, this group is marked as temporary. Temporary groups are deleted at midnight of the day following their creation.

createdAt

string

Timestamp of when the group was created. For example: "2025-05-29T19:04:14.000Z"

Delete Group

delete
Authorizations
Path parameters
groupIdstringRequired
Responses
200
Success
application/json
400
BadRequestError
application/json
401
UnauthorizedError
application/json
403
ForbiddenError
application/json
500
InternalServerError
application/json
delete
DELETE /v3/groups/{groupId} HTTP/1.1
Host: api.mobile-text-alerts.com
Authorization: Bearer apiKey
Accept: */*
{
  "statusCode": "MTANoLinkedAccountError",
  "success": true,
  "error": "text",
  "message": "text",
  "data": null
}

List Groups

get
Authorizations
Query parameters
Responses
200
Success
application/json
Responseall of
400
BadRequestError
application/json
401
UnauthorizedError
application/json
403
ForbiddenError
application/json
500
InternalServerError
application/json
get
GET /v3/groups HTTP/1.1
Host: api.mobile-text-alerts.com
Authorization: Bearer apiKey
Accept: */*
{
  "statusCode": "MTANoLinkedAccountError",
  "success": true,
  "error": "text",
  "message": "text",
  "data": {
    "rows": [
      {
        "id": 1,
        "name": "text",
        "hidden": 1,
        "welcomeMessage": "text",
        "description": "text",
        "parentWebinarId": "text",
        "displayName": "text",
        "sortOrder": 1,
        "type": "static",
        "settings": {
          "match": "AND",
          "conditions": [
            {
              "type": "text",
              "conditionAttribute": "text",
              "conditionOperator": "equals",
              "conditionCategory": "text",
              "conditionValue": [
                "text"
              ],
              "conditionSubOperator": "equals",
              "conditionSubValue": [
                "text"
              ]
            }
          ]
        },
        "isTemporary": true,
        "createdAt": "2025-06-08T10:41:27.031Z",
        "memberCount": 1
      }
    ],
    "page": 1,
    "pageSize": 1,
    "total": 1
  }
}

Remove Subscriber from Group

delete
Authorizations
Path parameters
groupIdstringRequired
subscriberIdstringRequired
Responses
200
Success
application/json
400
BadRequestError
application/json
401
UnauthorizedError
application/json
403
ForbiddenError
application/json
500
InternalServerError
application/json
delete
DELETE /v3/groups/{groupId}/subscribers/{subscriberId} HTTP/1.1
Host: api.mobile-text-alerts.com
Authorization: Bearer apiKey
Accept: */*
{
  "statusCode": "MTANoLinkedAccountError",
  "success": true,
  "error": "text",
  "message": "text",
  "data": null
}
  • Manage Groups with the API
  • Create a new Group
  • POSTCreate Group
  • Delete Group
  • DELETEDelete Group
  • Update Groups
  • PATCHUpdate Group
  • List All Groups
  • GETList Groups
  • Manage Group Members
  • Add Subscriber to Group
  • POSTAdd Subscriber to Group
  • Delete Group Member
  • DELETERemove Subscriber from Group

Create Group

post
Authorizations
Body
idnumberOptional
accountIdnumberOptional
namestringOptional
hiddennumberOptional
keywordstringOptional
welcomeMessagestringOptional
descriptionstringOptional
parentWebinarIdstringOptional
displayNamestring | nullableOptional
sortOrdernumber | nullableOptional
typestring · enumOptionalPossible values:
isTemporarybooleanOptional
createdAtone ofOptional
string · date-timeOptional
or
stringOptional
or
string | nullableOptional
Responses
200
Success
application/json
Responseall of
400
BadRequestError
application/json
401
UnauthorizedError
application/json
403
ForbiddenError
application/json
500
InternalServerError
application/json
post
POST /v3/groups HTTP/1.1
Host: api.mobile-text-alerts.com
Authorization: Bearer apiKey
Content-Type: application/json
Accept: */*
Content-Length: 472

{
  "id": 1,
  "accountId": 1,
  "name": "text",
  "hidden": 1,
  "keyword": "text",
  "welcomeMessage": "text",
  "description": "text",
  "parentWebinarId": "text",
  "displayName": "text",
  "sortOrder": 1,
  "type": "static",
  "settings": {
    "match": "AND",
    "conditions": [
      {
        "type": "text",
        "conditionAttribute": "text",
        "conditionOperator": "equals",
        "conditionCategory": "text",
        "conditionValue": [
          "text"
        ],
        "conditionSubOperator": "equals",
        "conditionSubValue": [
          "text"
        ]
      }
    ]
  },
  "isTemporary": true,
  "createdAt": "2025-06-08T10:41:27.031Z"
}
{
  "statusCode": "MTANoLinkedAccountError",
  "success": true,
  "error": "text",
  "message": "text",
  "data": {
    "id": 1,
    "name": "text",
    "hidden": 1,
    "welcomeMessage": "text",
    "description": "text",
    "parentWebinarId": "text",
    "displayName": "text",
    "sortOrder": 1,
    "type": "static",
    "settings": {
      "match": "AND",
      "conditions": [
        {
          "type": "text",
          "conditionAttribute": "text",
          "conditionOperator": "equals",
          "conditionCategory": "text",
          "conditionValue": [
            "text"
          ],
          "conditionSubOperator": "equals",
          "conditionSubValue": [
            "text"
          ]
        }
      ]
    },
    "isTemporary": true,
    "createdAt": "2025-06-08T10:41:27.031Z",
    "memberCount": 1
  }
}

Update Group

patch
Authorizations
Path parameters
groupIdstringRequired
Body
idnumberOptional
accountIdnumberOptional
namestringOptional
hiddennumberOptional
keywordstringOptional
welcomeMessagestringOptional
descriptionstringOptional
parentWebinarIdstringOptional
displayNamestring | nullableOptional
sortOrdernumber | nullableOptional
typestring · enumOptionalPossible values:
isTemporarybooleanOptional
createdAtone ofOptional
string · date-timeOptional
or
stringOptional
or
string | nullableOptional
Responses
200
Success
application/json
Responseall of
400
BadRequestError
application/json
401
UnauthorizedError
application/json
403
ForbiddenError
application/json
500
InternalServerError
application/json
patch
PATCH /v3/groups/{groupId} HTTP/1.1
Host: api.mobile-text-alerts.com
Authorization: Bearer apiKey
Content-Type: application/json
Accept: */*
Content-Length: 472

{
  "id": 1,
  "accountId": 1,
  "name": "text",
  "hidden": 1,
  "keyword": "text",
  "welcomeMessage": "text",
  "description": "text",
  "parentWebinarId": "text",
  "displayName": "text",
  "sortOrder": 1,
  "type": "static",
  "settings": {
    "match": "AND",
    "conditions": [
      {
        "type": "text",
        "conditionAttribute": "text",
        "conditionOperator": "equals",
        "conditionCategory": "text",
        "conditionValue": [
          "text"
        ],
        "conditionSubOperator": "equals",
        "conditionSubValue": [
          "text"
        ]
      }
    ]
  },
  "isTemporary": true,
  "createdAt": "2025-06-08T10:41:27.031Z"
}
{
  "statusCode": "MTANoLinkedAccountError",
  "success": true,
  "error": "text",
  "message": "text",
  "data": {
    "id": 1,
    "name": "text",
    "hidden": 1,
    "welcomeMessage": "text",
    "description": "text",
    "parentWebinarId": "text",
    "displayName": "text",
    "sortOrder": 1,
    "type": "static",
    "settings": {
      "match": "AND",
      "conditions": [
        {
          "type": "text",
          "conditionAttribute": "text",
          "conditionOperator": "equals",
          "conditionCategory": "text",
          "conditionValue": [
            "text"
          ],
          "conditionSubOperator": "equals",
          "conditionSubValue": [
            "text"
          ]
        }
      ]
    },
    "isTemporary": true,
    "createdAt": "2025-06-08T10:41:27.031Z",
    "memberCount": 1
  }
}

Add Subscriber to Group

post

Required Fields: subscriberId

Note: Field addToDripCampaigns is true by default.

undefined

Authorizations
Path parameters
groupIdstringRequired
Body
subscriberIdnumberRequired
addToDripCampaignsbooleanOptional
Responses
200
Success
application/json
400
BadRequestError
application/json
401
UnauthorizedError
application/json
403
ForbiddenError
application/json
500
InternalServerError
application/json
post
POST /v3/groups/{groupId}/subscribers HTTP/1.1
Host: api.mobile-text-alerts.com
Authorization: Bearer apiKey
Content-Type: application/json
Accept: */*
Content-Length: 44

{
  "subscriberId": 1,
  "addToDripCampaigns": true
}
{
  "statusCode": "MTANoLinkedAccountError",
  "success": true,
  "error": "text",
  "message": "text",
  "data": null
}