Genesys Cloud - Main

 View Only

Sign Up

Expand all | Collapse all

Analytics API - Interval

  Thread closed by the administrator, not accepting new replies.
  • 1.  Analytics API - Interval

    Posted 07-08-2020 13:04
    No replies, thread closed.
    When making a POST call against https://api.mypurecloud.com/api/v2/analytics/conversations/details/jobs where the body references an interval:

    {
    "interval": "2020-06-01T00:00:00.000Z/2020-06-02T00:00:00.000Z"
    }

    I would expect to return a result set of conversations where the start timestamp falls within my interval. 

    According to the following documentation, The interval will filter based on the conversation start timestamp
    https://developer.mypurecloud.com/api/rest/v2/analytics/query_syntax_detail.html

    However, when I run GET https://api.mypurecloud.com/api/v2/analytics/conversations/details/jobs/########-####-####-####-############/results, I'm returning conversations with start dates outside of my interval. Have I misunderstood the purpose/intention of interval?


    Thank you.

    #Unsure/Other

    ------------------------------
    Mary
    ------------------------------


  • 2.  RE: Analytics API - Interval

    Posted 07-08-2020 14:21
    No replies, thread closed.
    @Maisey Harris do you happen to know how that API interval is supposed to work/really works? All of the calls listed were active during the Interval specified, but they don't match the statement on the linked page in the Developer Center, as Mary points out. ​

    ------------------------------
    George Ganahl GCP (Genesys Cloud), ICCE
    Principal Technology Consultant
    Genesys
    ------------------------------



  • 3.  RE: Analytics API - Interval

    Posted 07-08-2020 14:25
    No replies, thread closed.
    Hi Mary,

    There is an additional flag you can set on your POST request body: startOfDayIntervalMatching. See the API docs here. When that is true, you will only receive conversations that started during the interval, as opposed to receiving all conversations that had activity during that window. Hope that helps!

    ------------------------------
    Maisey Harris
    Development Group Manager, Analytics UI & Reporting
    Genesys
    ------------------------------



  • 4.  RE: Analytics API - Interval

    Posted 07-08-2020 14:40
    No replies, thread closed.
    Thanks, Maisey!

    The example and instructions on https://developer.mypurecloud.com/api/rest/v2/analytics/query_syntax_detail.html make no mention of that flag, which is where the confusion comes in. I'll see if I can figure out who owns that page.

    ------------------------------
    George Ganahl GCP (Genesys Cloud), ICCE
    Principal Technology Consultant
    Genesys
    ------------------------------



  • 5.  RE: Analytics API - Interval

    Posted 07-08-2020 15:04
    Edited by Mary Vo 07-08-2020 15:05
    No replies, thread closed.
    @Maisey Harris I looked under the /api/v2/analytics/conversations/aggregates/query section of the API doc you linked, I did not see reference to startOfDayIntervalMatching. I'm curious does the body need to include both interval and startOfDayIntervalMatching? Also, would you be able to shed some light on the purpose of interval? Thank you.

    ------------------------------
    Mary
    ------------------------------



  • 6.  RE: Analytics API - Interval

    Posted 07-08-2020 15:28
    No replies, thread closed.
    I'd recommend you take any API / Developer questions to the development forum.  They'll be better able to assist you over there.  https://developer.mypurecloud.com/forum/

    ------------------------------
    Darlene Oordt
    Sr. Director Product Management
    Genesys - Employees
    ------------------------------



  • 7.  RE: Analytics API - Interval

    Posted 07-08-2020 15:29
    No replies, thread closed.
    You will always need an interval in your request, so that we know what period of time to query. 

    There are two scenarios:
    1. startOfDayIntervalMatching: true
    • Your results will contain interactions that started during your query interval.
    2. startOfDayIntervalMatching: false (default)
    • Your results will contain interactions that had any segment activity during your query interval.

    I hope that helps!


    ------------------------------
    Maisey Harris
    Development Group Manager, Analytics UI & Reporting
    Genesys
    ------------------------------



  • 8.  RE: Analytics API - Interval

    Posted 07-08-2020 15:54
    No replies, thread closed.
    Also, Mary, the  startOfDayIntervalMatching parameter is listed on the page documenting that POST:
    https://developer.mypurecloud.com/api/rest/v2/analytics/#post-api-v2-analytics-conversations-details-jobs

    ------------------------------
    George Ganahl GCP (Genesys Cloud), ICCE
    Principal Technology Consultant
    Genesys
    ------------------------------



  • 9.  RE: Analytics API - Interval

    Posted 07-08-2020 16:38
    No replies, thread closed.
    @Maisey Harris So, the startOfDayIntervalMatching returns interactions that started during my query interval. However, when I don't have the startOFDayIntervalMatching filter, what does the interval actually return? What purpose does it actually serve? From my example, I couldn't pinpoint the pattern of data that interval would return. Is the interval based on a different timestamp dimension?



    ------------------------------
    Mary
    ------------------------------



  • 10.  RE: Analytics API - Interval

    Posted 07-08-2020 19:17
    No replies, thread closed.
    When startOfDayIntervalMatching is false, think of the interval as searching for segmentEnd and segmentStart, anywhere throughout the conversation, as opposed to conversationStart.

    ------------------------------
    Maisey Harris
    Development Group Manager, Analytics UI & Reporting
    Genesys
    ------------------------------



  • 11.  RE: Analytics API - Interval

    Posted 07-09-2020 16:17
    Edited by Mary Vo 07-09-2020 16:19
    No replies, thread closed.
    @Maisey Harris Is it possible to call an interval from beginning of time (for our company's data)? I ask because we're interested in replicating data from the PureCloud API to a physical data store for business users to report on. We'd like to start from initial date in which PureCloud was implemented at the company and page through the API to replicate data until current date.

    ------------------------------
    Mary
    ------------------------------



  • 12.  RE: Analytics API - Interval

    Posted 07-09-2020 16:41
    No replies, thread closed.

    Mary –


    I'll stress again the best place to ask your development related questions is on the developer forum: 
    https://developer.mypurecloud.com/forum/

     

     






  • 13.  RE: Analytics API - Interval

    Posted 07-09-2020 16:58
    No replies, thread closed.
    Also, I recommend you read the documentation - especially the limitations section as I believe it addresses your questions.

    ------------------------------
    Darlene Oordt
    Sr. Director Product Management
    Genesys - Employees
    ------------------------------