next_since_id of your previous response as since_id. You then get only the emails that arrived after it, in one call. An empty data means nothing new. Emails from the few seconds just before the cursor can be returned again, so skip ids you already have: the ids of your previous check (all its pages) are enough to remember, older ones can never come back. There is no need to check often: emails stay in this folder for 2 weeks, and one check returns everything that arrived since the last one.has_more is true, more new emails arrived than limit: fetch them with next_starting_after as starting_after together with the same since_id, and keep the next_since_id of the first page for your next check (the extra pages echo the since_id you sent).curl --location 'https://api.plusvibe.ai/api/v1/unibox/other-emails?workspace_id=65f3c92d3dbe5dbb35374a9a&starting_after=undefined&since_id=6ae38953662ba44caeefedd9&limit=undefined' \
--header 'x-api-key: <api-key>'{
"next_since_id": "6af3e54b0000000000000000",
"has_more": true,
"next_starting_after": "string",
"data": [
{
"id": "string",
"thread_id": "string",
"message_id": "string",
"subject": "string",
"is_unread": 0,
"from_address_email": "string",
"from_address_json": [
{
"address": "string",
"name": "Jane Doe"
}
],
"to_address_email_list": "string",
"to_address_json": [
{
"address": "string",
"name": "John Smith"
}
],
"eaccount": "string",
"eaccount_first_name": "John",
"eaccount_last_name": "Smith",
"body": {
"html": "string"
},
"out_attachments": [
"string"
],
"timestamp_created": "string",
"source_modified_at": "string"
}
]
}