Legacy Dev Forum Posts

 View Only

Sign Up

  • 1.  Comparing Dates in UTC

    Posted 06-05-2025 19:10

    melissalsmith | 2020-07-14 21:16:53 UTC | #1

    I'm attempting the following scenario in architect:

    An inbound call comes in to the flow, a data action gets that lead from Dynamics CRM and returns "CreatedOn" date - which is in UTC.

    If the CreatedOn date returned from Dynamics is equal to today (but not this exact time in UTC, just today's current date), I want to transfer the call to a queue.

    If the Created on date returned from Dynamics is not equal to today i.e. yesterday, I want to do something else with the call.

    Any suggestions on comparing my "CreatedOn" date from Dynamics with the current day from PureCloud?


    Jason_Mathison | 2020-07-15 12:42:01 UTC | #2

    Hi Melissa,

    Deciding if something was created "today" can be a bit tough when you are dealing with UTC, as daylight savings time can mess that up. If instead if you could check for "Was created in the past x hours" you should be able to do that pretty easily.

    Something like a decision node that checks this: DateTimeDiff(GetCurrentDateTimeUtc, createdon) < MakeDuration(0, x, 0, 0)

    If "today" is a hard requirement then additional thought is going to be required :slight_smile: --Jason


    system | 2020-08-15 12:46:24 UTC | #3

    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: 8288