External transfer to disaster recovery site

I need to replicate a current deployment on our old system in Genesys:

One option in the main menu of script XYZ transfers callers to an external site - Site A. In a disaster recovery situation, the customer dials a separate/different number to access script XYZ, authenticates using a passcode, then is prompted to select option 1 (DR_off) or option 2 (DR_on). This sets a variable in the script and then they get disconnected. If they press option 2, the XYZ script will route callers to the DR site, Site B. After the event, the customer calls back in and presses option 1 and the callers are routed back to the primary site, Site A.

I know how to route based on the DNIS for the separate number and authenticate the customer but I can figure out how to invoked the disaster recovery external transfer. Can this be done in Genesys? Is there a way to dynamically update a data table?

Data Tables would be a good option for this. Refer to the API resources /api/v2/flows/datatables/{datatableId}/* for various operations you can perform to manage the table programmatically. You would use the Genesys Cloud data action integration to make these requests from a flow. You can use the DataTable Lookup action to read information from the data table and make a routing decision.

You can also use an emergency group. Use a data action to activate/deactivate the emergency group. Use the evaluate schedule action in the flow to check to see if the emergency is active.

Thanks Tim! We're fairly new to Genesys cloud. I will play with the data actions to see if I can come up with a solution.

Thanks Melissa! Unfortunately, the emergency schedule wont work because the customer wants to control when they "have an emergency". We dont want to give them admin access because they are far from technical. That is why the current solution allows them to just press 1 or 2 and then disconnects them. I'm surprised they haven't messed that up yet.

In addition, per the contract we have to come as close as possible to a "like for like" solution when we move them to Genesys.

The data action to activate/deactivate the emergency group will use the credentials you create for the purecloud data actions integration, not the caller's credentials. The caller doesn't even need to be a genesys user at all. They call a number, which routes to a flow, the flow authenticates their passcode, then executes the data action.

I have the API call working on the developer's tools website. I can't get it to work with the Action in Architect. I have tried "requestTemplate": "{"DRState": ${input.DRState},"key":"${input.DNIS}"}". This one fails with the error: "Unrecognized token 'On': was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 'false')\n at [Source: (String)"{"DRState": On,"key":"7752413349"}"; line: 1, column: 15]", The field is set to sting in the contract.

I have also tried "requestTemplate": "{"DRState": \”${input.DRState}\”,"key":"${input.DNIS}"}" based on a recommendation. This fails as well with: Parse error on line 7:
... "requestTemplate": "{"DRState": \”${i
-----------------------^
Expecting 'STRING', 'NUMBER', 'NULL', 'TRUE', 'FALSE', '{', '[', got 'undefined'

Any help would be appreciated.

Put quotes around ${input.DRState} like you did for "${input.DNIS}"

Thank you Melissa!!!!!