PUT https://restapi.actonsoftware.com/ucl/v2/segment/{accountId}/list/{segmentId}
This endpoint allows you to update a All Contacts Segment in the account.
Parameters
Name | Parameter Type |
Allow Multiple |
Required/ Optional |
Data Type | Description |
---|---|---|---|---|---|
authorization | header | false | required | string | Insert your generated access token. (Bearer {access token}) |
accountID | Path | false | required | number | Account ID where query needs to be done |
segmentId | Path | Flase | required | String | Specify the list ID in which you would like to access. |
segmentName | Body | false | optional | String | Specify the name |
filter | Body | false | optional | “search” / “directSelect” | Specify the segment type |
patterns | Body | false | optional | String | Using a semicolon as the delimiter specifies the words to filter a search segment. |
recIds | Body | false | optional | String | Using a semicolon as the delimiter to specify the records you would like to have in a direct segment. |
folderName | Body | false | optional | String | Specify a folder to add the segment |
tags | Body | false | optional | String | Using a semicolon as the delimiter to specify the labels you would like to have in the segment. |
Response
[
{
"id": 101913,
"createdTime": 1654097116675,
"updatedTime": 1654104833053,
"accountId": 864,
"enabled": true,
"externalId": "g-0440",
"item": "{\"id\": \"g-0440\", \"name\": \"Test Contact List\", \"type\": \"Direct Select\", \"parent\": \"\", \"isEditable\": true, \"recordsCount\": 3, \"lastCountDate\": 1654104833006}",
"folderId": 103529,
"authorId": "827",
"username": null,
"position": 25,
"isFavorite": false,
"labels": [
{
"id": null,
"createdTime": null,
"updatedTime": null,
"accountId": null,
"enabled": true,
"name": "testLabel",
"color": null,
"views": 0,
"itemCount": null
}
],
"hasToAudit": false
}
]
Code Examples
cURL
curl --location --request PUT
'https://restapi.actonsoftware.com/ucl/v2/segment/{ACCOUNT_ID}/list/{SEGMENT_ID} \
--header 'Authorization: Bearer 0ce7825a-5bcb-3d08-b316-11fe6a5a0c0d' \
--header 'Content-Type: application/json' \
--data-raw '{
"segmentName": "AgusTestUpdated",
"filter": "directSelect"
}'