{
  "openruna_format": "flow-graph-v1",
  "title": "OIDC client workflow",
  "slug": "oidc-client-workflow",
  "source_filename": "2034_Code_Webhook_Automate_Webhook.json",
  "nodes": [
    {
      "id": "Webhook",
      "name": "Webhook",
      "integration": "webhook",
      "kind": "trigger"
    },
    {
      "id": "Code",
      "name": "Code",
      "integration": "code",
      "kind": "logic"
    },
    {
      "id": "user info",
      "name": "user info",
      "integration": "httpRequest",
      "kind": "action"
    },
    {
      "id": "send back login page",
      "name": "send back login page",
      "integration": "respondToWebhook",
      "kind": "action"
    },
    {
      "id": "IF token is present",
      "name": "IF token is present",
      "integration": "if",
      "kind": "logic"
    },
    {
      "id": "Welcome page",
      "name": "Welcome page",
      "integration": "html",
      "kind": "action"
    },
    {
      "id": "send back welcome page",
      "name": "send back welcome page",
      "integration": "respondToWebhook",
      "kind": "action"
    },
    {
      "id": "IF user info ok",
      "name": "IF user info ok",
      "integration": "if",
      "kind": "logic"
    },
    {
      "id": "login form",
      "name": "login form",
      "integration": "html",
      "kind": "action"
    },
    {
      "id": "Set variables : auth, token, userinfo, client id, scope",
      "name": "Set variables : auth, token, userinfo, client id, scope",
      "integration": "set",
      "kind": "logic"
    },
    {
      "id": "IF we have code in URI and not in PKCE mode",
      "name": "IF we have code in URI and not in PKCE mode",
      "integration": "if",
      "kind": "logic"
    },
    {
      "id": "get access_token from /token endpoint with code",
      "name": "get access_token from /token endpoint with code",
      "integration": "httpRequest",
      "kind": "action"
    }
  ],
  "edges": [
    {
      "from": "Code",
      "to": "IF we have code in URI and not in PKCE mode"
    },
    {
      "from": "Webhook",
      "to": "Set variables : auth, token, userinfo, client id, scope"
    },
    {
      "from": "user info",
      "to": "IF user info ok"
    },
    {
      "from": "login form",
      "to": "send back login page"
    },
    {
      "from": "Welcome page",
      "to": "send back welcome page"
    },
    {
      "from": "IF user info ok",
      "to": "Welcome page"
    },
    {
      "from": "IF user info ok",
      "to": "login form"
    },
    {
      "from": "IF token is present",
      "to": "user info"
    },
    {
      "from": "IF token is present",
      "to": "login form"
    },
    {
      "from": "IF we have code in URI and not in PKCE mode",
      "to": "get access_token from /token endpoint with code"
    },
    {
      "from": "IF we have code in URI and not in PKCE mode",
      "to": "IF token is present"
    },
    {
      "from": "get access_token from /token endpoint with code",
      "to": "user info"
    },
    {
      "from": "Set variables : auth, token, userinfo, client id, scope",
      "to": "Code"
    }
  ]
}