Usage
Use ManageContactGroupMembers to update contact records based on the provided action.
Basic Steps
- Determine the IDs of the contacts you want to update. For example, you might call Search to retrieve a set of contacts IDs you want to update. If you store the Cvent IDs for your contact records within your database, you can use these IDs to update the desired contacts.
- Construct an ID array and populate it with the IDs of each contact record you want to update.
- Optionally, specify the MessageId if you need to track the result of each record. Message IDs can represent unique identifiers from your system. Message IDs will be returned as Reference IDs in the result array for your tracking purposes.
- Call ManageContactGroupMembers, passing in the ID array, the action you want to take on the contacts, and the contact group ID.
Note
The “Remove” action removes contacts from the group and does not delete the contact group itself.
- Process the results in the ManageContactGroupMembers object to verify whether the objects have been successfully updated.
General Syntax
ManageContactGroupMembersResultArray = cventapi.ManageContactGroupMembers (ManageGroupAction Action, ID GroupId, CvObjectArray CvObjects)
Input
Name | Type | Description |
---|---|---|
Action | Manage Group Action | The action you are taking on the contacts. Valid actions Add and Remove. |
GroupId | ID | The ID of the contact that you adding or removing contacts to or from. |
CvObjects | CvObject Array | Array of one or more CvObject, which contains contact IDs to be updated, and optionally MessageIds which will be returned as ReferenceIds. |
Output
Name | Type | Description |
---|---|---|
Id | ID | ID of the contact that you attempted to update. |
ReferenceId | ID | The MessageId value in the input CvObject. |
Success | Boolean | Indicates whether the ManageContactGroupMembers call succeeded (True) or not (False) for this contact. |
Errors | Error Array | If an error occurred during the Create call, an array of one or more Error objects providing the error code and description. |
Validation Rules
The following validation rules should be applied to the ManageContactGroupMembers call:
Validation Rule | Description |
---|---|
Actions | Valid actions are Add and Remove. For the Add action to succeed, the contact must not already be a member of the specified contact group. For the Remove action to succeed, the contact must already be a member of the specified contact group. |
Uniqueness | Based on ID, only the first instance of a contact in the array will update the contact record. All subsequent instances will return an error message. |
Notes
Take into account the following notes when using the ManageContactGroupMembers call:
- Permissions: Your client application must be logged in with sufficient access rights to update contacts within the account.
- Maximum Number of Contacts Updated: You can update up to 200 individual contacts in a single ManageContactGroupMembers call. If the ManageContactGroupMembers request exceeds 200 contacts, then the entire operation fails.
Last updated on