Doesn’t work with many lists
-
The api url has changed to https://api.icpro.co/icp/ although the old one still seems to work for now.
When using the /lists endpoint, a maximum of 20 results are returned. There doesn’t seem to be a way to specify the number of results you want or any form of pagination, so if the list you want to add to is not in the first 20 results returned the following in /lib/functions.php will fail:
$listId = $ListArr[$lists];
I added a check to just use the user provided ID if it doesn’t exist in the array of the first 20
if (array_key_exists($lists, $ListArr)) {
$listId = $ListArr[$lists];
} else {
$listId = $lists;
}
The topic ‘Doesn’t work with many lists’ is closed to new replies.