Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

 

Get a list of available 'send' groups, including 'merge' groups - pre-defined groups containing a list of mobile numbers to send a message to.
Also lists 'stop' groups - numbers in these groups will never be sent messages. Every account has at least one stop group, so that your recipients can always opt out of receiving messages from you. This is a legal requirement.

Code Block
themeRDark
languagec#
titleExample
linenumberstrue
Hashtable[] result = tmClient.getGroups();
foreach (Hashtable group in result) {
	Console.WriteLine("Group ID: {0}", group["id"]);
	Console.WriteLine("Group numbers: {0}", group[""]);
	Console.WriteLine("Group name: {0}", group["name"]);
	Console.WriteLine("Group IS STOP: {0}", group["is_stop"]);
}

Arguments:

String name: 

Name of the delivery report to retrieve or 'all' to retrieve all campaign/API report data.

Returns:

An array of Hashtable, each group represented by a Hashtable. Each Hashtable has 4 keys: 'is_stop', 'id', 'numbers' and 'name' e.g. name of the first returned group is group["name"]

Each Hashtable has 4 keys:

Hashtable key Value
name 

String. The name of the group.

quantity Integer. The quantity of numbers in the group.
id 

Integer. The unique ID of the group, unique for this account.

is_stopBoolean. Whether the group is a stop group, normally false.

Specific error codes:

None. 

Panel
title
  • Next
Panel
titleAll Functions
Panel
titleDownload