Genesys Cloud - Main

 View Only

Sign Up

  Thread closed by the administrator, not accepting new replies.
  • 1.  Call flow data tables

    Posted 03-28-2025 20:18
    No replies, thread closed.

    New to Genesys cloud. I am trying to create a call flow that starts off by looking at the ANI and based on the ANI it routes to a queue or another menu. I thought the best way to do it would be using a data table, and selecting call.ani. I think I am just not creating my data table correctly I am not sure what fields to use. 


    #ArchitectureandDesign

    ------------------------------
    ty Ashcraft
    Network Analyst
    ------------------------------


  • 2.  RE: Call flow data tables

    Posted 03-29-2025 07:09
    Edited by Orhun Sahin 03-29-2025 07:08
    No replies, thread closed.

    You're on the right track; Here's how to set up the Data Table and the corresponding Architect flow:

    1. Creating the Data Table

    The key is to define columns that hold the information you need for routing.

    • Go to Admin > Architect > Data Tables tab.
    • Click "Add".
    • Name: Give it a descriptive name (e.g., ANIRoutingLookup, CallerID_Routing).
    • Division: Assign it to the appropriate division.
    • Reference Schema:
      • For the key column (which Genesys automatically requires), you'll use this for the ANI.
        • Property Name: key (This is fixed)
        • Property Type: String
      • Now, add custom columns for the routing information:
        • Column 1 (Routing Type):
          • Property Name: RoutingType (or DestinationType, TargetType)
          • Property Type: String (You'll store values like "Queue" or "Menu" here).
        • Column 2 (Routing Target Name):
          • Property Name: RoutingTargetName (or DestinationName, TargetValue)
          • Property Type: String (You'll store the exact name of the Queue or Menu here).
    • Save the schema.

    2. Populating the Data Table

    • Select your newly created Data Table and go to the Rows tab.
    • Click "Add Row".
    • For each row:
      • key: Enter the full ANI you want to match. Crucially, ensure this matches the format Call.Ani will provide. Typically, this is E.164 format (e.g., +13175551212). You might need to test a call or check logs to confirm the exact format Call.Ani presents in your environment.
      • RoutingType: Enter either Queue or Menu.
      • RoutingTargetName: Enter the exact name of the Genesys Cloud Queue or Architect Menu you want to route to for that specific ANI.
    • Add rows for all the ANIs you want special routing for.
    • Publish the Data Table.

    3. Building the Architect Inbound Call Flow

    • Create or Edit an Inbound Call flow.
    • Data Table Lookup Action:
      • Drag a "Call Data Action" from the Toolbox under the "Data" category onto your flow canvas.
      • Select Category: Genesys Cloud Data Table Lookup.
      • Action: Select the Data Table you created (e.g., ANIRoutingLookup).
      • Inputs:
        • key: Set this input value to Call.Ani. Use the expression editor (Literal mode -> Type Call.Ani).
      • Outputs:
        • Map the outputs to flow variables. Create new Flow-scoped variables if needed:
          • RoutingType: Map to Flow.FoundRoutingType (String variable).
          • RoutingTargetName: Map to Flow.FoundTargetName (String variable).
    • Decision Logic (After Lookup):
      • The "Call Data Action" has Success and Failure paths.
        • Failure Path: This means the Call.Ani was not found as a key in your Data Table. Decide what happens here (e.g., route to a default main menu, a default queue, play a generic greeting).
        • Success Path: The ANI was found! Now you need to check what kind of routing was specified.
      • Add a "Decision" or "Switch" action on the Success path.
        • Using Switch (Recommended):
          • Expression: Flow.FoundRoutingType
          • Cases:
            • Add a case for "Queue" (ensure quotes for string comparison).
            • Add a case for "Menu" (ensure quotes).
            • The Default case can handle unexpected values found in the table (error handling or default route).
    • Routing Actions:
      • Under the "Queue" Case:
        • Add a "Transfer to ACD" action.
        • Queue: Use the expression FindQueue(Flow.FoundTargetName). This looks up the queue by the name stored in your variable.
      • Under the "Menu" Case:
        • Add a "Transfer to Menu" action.
        • Menu: Use the expression FindMenu(Flow.FoundTargetName). This looks up the menu by the name stored in your variable.
    • Default/Failure Routing: Connect the Failure path of the Data Table Lookup and the Default path of the Switch (if used) to your desired default routing logic (e.g., a standard "Transfer to Menu" or "Transfer to ACD" action for callers not in the table).
    • Error Handling: Consider adding checks after FindQueue or FindMenu in case the name in the data table doesn't perfectly match an existing queue/menu (though careful data entry avoids this). The FindQueue/FindMenu functions have failure paths you can use.
    • Validate and Publish your Architect flow.

    Key Considerations:

    1. ANI Format: This is the most common point of failure. Double-check the exact format Call.Ani provides (e.g., with or without '+', country code, etc.) and ensure your Data Table key column uses the identical format. You might need to manipulate Call.Ani in the flow before the lookup if the formats differ (e.g., using string functions like Replace or Substring).
    2. Exact Names: The RoutingTargetName in the Data Table must exactly match the configured name of the Queue or Menu in Genesys Cloud for FindQueue() and FindMenu() to work.
    3. Scalability: Data Tables are great for dozens or hundreds of entries. If you anticipate thousands, performance might become a consideration, and other methods (like a Data Action calling an external API/Lambda) could be explored, but for most standard use cases, Data Tables are perfect.
    4. Publishing: Remember to Publish both the Data Table (after adding/editing rows) and the Architect flow for changes to take effect.



    ------------------------------
    Orhun Sahin
    Software Development Engineer
    ------------------------------



  • 3.  RE: Call flow data tables

    Posted 03-31-2025 09:51
    No replies, thread closed.

    There is no FindMenu expression



    ------------------------------
    Melissa Bailey
    Software Engineer
    ------------------------------



  • 4.  RE: Call flow data tables

    Posted 04-01-2025 15:42
    No replies, thread closed.

    Unfortunately, you are correct.

    One of the failings of Architect (IMHO) is that there are a number of objects that cannot be dynamically referenced. (Menus and Call Flows are two examples). There is an idea out in Aha! (https://genesyscloud.ideas.aha.io/ideas/SSA-I-246) that goes some way to discuss this.



    ------------------------------
    Paul Simpson
    Views expressed are my own and do not necessarily reflect those of my employer.
    ------------------------------



  • 5.  RE: Call flow data tables
    Best Answer

    Posted 04-01-2025 15:48
    Edited by Jason Kleitz 04-01-2025 15:57
    No replies, thread closed.

    I was able to get accomplished what I wanted to happen. It just took watching the flow. DNIS presents as +1234567890 but ani presents as tel:+1234567890. Once I figured that out I just created a quick boolean table matching the call.ani and now I can allow only certain numbers to access the queue and route the rest to a different menu by using a data table lookup at the beginning of the inbound flow.