Legacy Dev Forum Posts

 View Only

Sign Up

  • 1.  Get Campaign Sorted List

    Posted 06-05-2025 18:12

    jlee | 2017-06-15 14:15:04 UTC | #1

    Does anyone know how to query a campaign that is in progress and see what order the calls should flow?

    We have a list that when you export it is in a particular order, you can sort the campaign based on a set of rules. We are just curious how that sorting works and would like see in real time what order the calls are queued up in when we add new calls to list, recycle the campaign, things like that.

    A big thing we want to confirm is if the sorting is in levels similar to how you can sort by multiple criteria in Excel. Example: Sort by: Dialed Attempts then Sort by: Name then Sort by: Number then

    That isn't the exact example we are trying to sort by but should give you an idea of what we are trying to ensure works.

    I have attached an example of a sorting example in Excel that we are hoping campaign sorting works like.

    <img src="//inin-prod-use1-developerforum.s3.amazonaws.com/original/1X/2217037143666ccafc3aaeb35f61c1ca43a36615.png" width="612" height="500">

    Thanks in advance


    anon28066628 | 2017-06-15 14:31:44 UTC | #2

    The list can only be exported as a csv; the actively running record set in progress can't be queried for order AFAIK.

    This endpoint: POST /api/v2/outbound/contactlists/{contactListId}/contacts

    Will add a contact to a running or non-running list. If the campaign is in progress and the query string param: ?priority=true

    Is added, then it will be the next contact dialed. This "priority" is a one-time event that forces it to be next-dialed during the current campaign run; upon later export of the list you'll find it's been added to the bottom of the static record set.


    jlee | 2017-06-15 15:16:45 UTC | #3

    Thank you for the information about export and priority.

    Do you know if the sort order in a campaign is as described in my original post?

    Also what happens to a priority post if the campaign is recycled?

    This is the scenario:

    • I have 10 numbers in a list
    • The queue is on 5 of 10 in the queue
    • A priority number is posted
    • The campaign is recycled before the priority contact is dialed

    Does the priority number get dialed next or does other sorting on the campaign overwrite the priority at that point?

    Thanks


    anon28066628 | 2017-06-15 15:38:08 UTC | #4

    Hi Jeremy, I'm not sure about the sort order - multidimensional sorting is a feature so I assume the first dimension takes precedence followed by the others as your post describes (you should test this).

    The priority elevation is a temporary status that only takes effect within context of the current campaign. It becomes the next contact dialed (if >1 are scheduled as priority, they're dialed in the order added). If the campaign is recycled, the priority is lost and they will be at the end of the list if no sorting is specified. If sorting is specified, they'll be sorted with other records depending on the contact's field values when it was added.


    jlee | 2017-06-15 19:03:01 UTC | #5

    I verified a multidimensional sort worked.

    I created a list in excel, exported it to csv. I then stacked sorted Excel and Purecloud with the same rules and the calls came through in the queue in the same order Excel had them sorted.

    <img src="//inin-prod-use1-developerforum.s3.amazonaws.com/original/1X/252875bfe07a81bd76f9dc5d5166eb9b8e0dfb1c.png" width="596" height="499">


    anon28066628 | 2017-06-15 20:31:07 UTC | #6

    Thank you for verifying this and sharing your confirmation. I hope the information about priority and campaign recycle is clear as well.

    Best, R. J.


    jlee | 2017-06-15 20:43:58 UTC | #7

    We are using priority and setting a custom field when priority calls come in. That way if there is a recycle, it will keep priorities at the top, with multidimensional sorts below the priority sort.

    Thanks for your help.


    anon28066628 | 2017-06-15 20:45:42 UTC | #8

    Excellent solution - I will have to keep that in my toolkit :slight_smile:


    system | 2017-07-16 20:45:49 UTC | #9

    This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.


    This post was migrated from the old Developer Forum.

    ref: 1418