You are here

function MCAPI::listAddStaticSegment in Mailchimp 6.2

Save a segment against a list for later use. There is no limit to the number of segments which can be saved. Static Segments <strong>are not</strong> tied to any merge data, interest groups, etc. They essentially allow you to configure an unlimited number of custom segments which will have standard performance. When using proper segments, Static Segments are one of the available options for segmentation just as if you used a merge var (and they can be used with other segmentation options), though performance may degrade at that point.

Related

Parameters

string $id the list id to connect to. Get by calling lists():

string $name a unique name per list for the segment - 25 character maximum length, anything longer will be truncated:

Return value

int the id of the new segment, otherwise an error will be thrown.

File

./MCAPI.class.php, line 1351

Class

MCAPI

Code

function listAddStaticSegment($id, $name) {
  $params = array();
  $params["id"] = $id;
  $params["name"] = $name;
  return $this
    ->callServer("listAddStaticSegment", $params);
}