How to generate a unique URL that can be used to open a process.

Is it possible to generate a unique URL to open a process in Appian?
I would like to be able to start an Appian process instance using an API from another system, and open that process from a screen like "Appian process list" on the other system.
A process has multiple User Input Tasks and also enters sub-processes, but I would like to be able to open the process from the "Appian Process List" no matter what state it is in.
Is it possible to generate and return a unique URL for opening a process, regardless of the task, when a process instance is launched? How should I implement this?

I've recently started learning Appian.
Please forgive me for asking a beginner's question.

Thanks in Advance.

  Discussion posts and replies are publicly visible

Parents Reply
  • Hello Stefan,

    I apologize for the unclear wording.
    I am hoping to implement the following process.

    1. When I click a button in an external system, use the API to start an Appian process. (The started process instance is called Process X.)
    2. When I click a URL link for Process X from the "Appian Process List" in the external system, the screen of the currently active task of Process X is opened in a new tab in the browser.
    *I used the word "open" to mean Process 2.

    Is it possible to implement the above?
    Thanks.

Children
  • 0
    Certified Lead Developer
    in reply to takuyak0088

    I would not want to recommend such a design, but yes.

    I already shared how to start a process. To open a task, you create a process report that creates the list of tasks. Then you create another API in which you use that process report to return the list of tasks. Use the a!urlfortask() function to create that link. This other system calls the API and shows the linked tasks in a list.

    To make this work seamlessly, you will have to make sure there is a common single sign on in place.

  • 0
    Certified Lead Developer
    in reply to takuyak0088

    As Stefan says, you can do it with the urlfortask() function, but it's true that I find the approach a bit confusing..."

  • So to launch a specific Appian process screen from an external system, two actions are required: "generating a URL using the API" and "clicking on the URL to open the tab."
    As David says, I find this procedure a bit confusing.

    Is it possible to implement the following process?
    Generate a unique URL associated with the process → Click on the URL and be redirected to the page of the currently active task by Appian's internal processing.

  • 0
    Certified Lead Developer
    in reply to takuyak0088
    Generate a unique URL associated with the process → Click on the URL and be redirected to the page of the currently active task by Appian's internal processing.

    Yes, you can generate a task link using the a!urlForTask() function. Any authenticated user with viewer access permissions will be able to access that task.

  • Sorry, I was unclear.

    I understand that the urlfortask() function can be used to obtain a URL to open the currently active task screen in a browser.

    However, I understand that this is a function that needs to be executed each time. I understand that in order to open the Appian screen from the task list of an external system, two actions are required each time: "executing the API to generate a URL" and "clicking the URL."

    What I wanted to say was, is it possible to implement the following:

    "When an Appian process is executed from an external system via API, a unique URL is generated and returned as a return value. Clicking on the generated URL will redirect to the page of the currently active task (no matter which user input task in the process or even if it is in a subprocess)"

  • 0
    Certified Lead Developer
    in reply to takuyak0088

    You can create a process report to store record id and active Task id. Now with first API call you can query the process report using a!queryProcessAnalytics(). Then in API output use a!urlfortask(taskIds:{TaskID})) to get the Unique url for the task e.g.

    <https://ENV_URL.appiancloud.com/suite/tempo/tasks/task/taskID

    Clicking on this generated URL will open the task. Only issue is this opens in Appian Tempo, so if you want it to be embedded into another system itself it will need additional configuration. But if idea is to click on link and navigate to Appian to complete the task then it will work after authentication.