Policy Automation for B2C Service

Get Involved. Join the Conversation.

Comments

  • Harriet Franklin

    Great examples, Davin !

  • Davin Fifield

    Hi Jonathan, 

    I assume you mean in Agent Desktop? The OPA workspace control doesn't provide a specific way of doing this, so I think your only option is to trigger an update based on a data change that is made in the Service Cloud database by the OPA interview when it completes. 

     

    Davin.

  • Davin Fifield

    There is a much easier way, which is simply to drop an OPA control onto your Incident workspace, and use the Mapping Settings on the Data tab in Oracle Policy Modeling to choose options along these lines:

    In Who is this interview for? choose Contact centre staff (Account)

    In At start of interview choose Load a particular: Incident

    In At end of interview choose Update Incident

    This approach requires you to have Single-Sign On enabled between your RightNow and OPA sites (which is done by default if they were provisioned together), and to be licensed for the OPA Agent Cloud Service. 

  • Nisar

    I probably should have started with the use case scenario. Sorry about that. So here goes:

    • In the Agent Console, the OPA interview (which is a part of the Incident Workspace) starts
    • At the end of the interview, the page is redirected to, let's say, /app/myOPA page.
    • Inside myOPA page, my goal is to use the Javascript API and set a "Yes/No" field on the Incident Workspace. Since I can't touch the workspace fields via the OPA control, I intend to the the JS API to do the same.

    Is this approach right?

  • Davin Fifield

    What do you want to do exactly with the Javascript API. Set the incident ID to something? Are you in the incident workspace?

     

    The best way to create incidents with OPA inside Agent Desktop is to use the Policy Automation control instead of the Browser Control, and use the mapping in Oracle Policy Modeling to create the incident. This will make sure the incident ID of the incident workspace is set when the interview completes.

     

     

  • Nisar

    Hi Davin,

    The URL points to a CP page.

    EDIT: I can't seem to copy-paste the direct HTML of the page, so attaching the same

    50327opa.html (431 Bytes)
  • Davin Fifield

    What is the URL of the redirected page?

     

    We might need to get someone more experienced with the Agent Desktop to help us understand why you can't successfully use the Javascript API - that isn't an OPA feature.

  • Nisar

    Hi Scott and Davin,

    The interview is running within the ServiceCloud CX and not a CP page. At the end of the interview, we are using the "Submit and Redirect" option and inside the redirected page, Javascript API code is set to run.

    I'm assuming that the moment the interview ends and the page redirection takes place, it opens the page within the browser control. And this is where I intend to use the Javascript API

  • Davin Fifield

    A couple of questions.

    1. It sounds like you are using the Browser Control instead of the built in OPA control for Agent Desktop. Can I ask why?

    2. Since you are using the Browser Control you can provide the incident ID via the supported command-line parameters. In combination with the Delay Load option this should allow you to do what you need.

  • Scott Berry

    Just to clarify, do you mean you have embedded the interview on a Customer Portal page via the OPA Widget, or the interview is running within the ServiceCloud CX? In the Customer Portal the Interview is rendered inside an iframe, and because of this the iframe javascript does not have permission to reach outside of the iframe to the parent window. You may however use javascript on the parent page which sets a controls value inside the Interview with something like:

    window.frames['myIFrame'].document.getElementById('myIFrameElemId')
    
  • Harriet Franklin

    Great document Jasmine.

  • Janelle Guzik

    Great article that explains OPA very well.  I am going to use this when I try and explain to others what OPA can bring to the table.

  • Davin Fifield

    It depends what you are trying to do.

     

    The Assess Service is a SOAP web service that accepts data and turns richly structured responses, which you can then use to drive widget logic or render answers however you wish. You will need to decide what RightNow data to pass to the service, and what to do with the returned results.

     

    The Interview Service is a SOAP web service that maintains interview session state for you, and manages the logic of which screens should be shown next etc. You need to render the complete screens yourself based on the metadata returned, and handle any data submission logic using the provided data structures. Data is not loaded from or saved to RightNow, even if a mapping is specified for the interview.

     

    Davin.

     

  • Harriet Franklin

    Great online demo site, Heike