Skip to main content

Workato Genie connector

Workato requires a conversation create call followed by an SSE message call. Giant Tree uses the native Workato adapter, not the generic HTTP runtime.

Prerequisites​

  • Workato Agent Studio Genie handle
  • Workato API key
  • Workato IdP user ID for the end user
  • The IdP user must be allowed to use the Genie

Manifest​

{
"schema_version": 1,
"key": "workato-genie",
"version": "1.0.0",
"name": "Workato Genie",
"description": "Workato Agent Studio connector",
"icon": "zap",
"runtime": "workato",
"auth": [
{
"key": "api_key",
"type": "bearer",
"credential": "api_key"
}
],
"config_schema": {
"type": "object",
"required": ["genie_id", "idp_user_id"],
"properties": {
"genie_id": {
"type": "string",
"title": "Genie handle"
},
"idp_user_id": {
"type": "string",
"title": "Workato IdP user ID"
},
"base_url": {
"type": "string",
"title": "API base URL"
}
}
},
"operations": {}
}

Install the catalog entry​

  1. Open Connectors → Catalog.
  2. Find Workato Genie.
  3. Select Connect agent.
  4. Enter:
    • Genie handle — for example gin-AcRRAtNG-NNrhsJ-AB
    • Workato IdP user ID — the user's Workato identity
    • API base URL — usually https://genie-api.trial.workato.com
  5. Enter the Workato API key as the credential.
  6. Test with a message.

How the adapter works​

For each new thread:

POST /api/v1/genies/{genie_id}/chat/conversations
Authorization: Bearer <api_key>
X-IDP-User-ID: <idp_user_id>

The returned conversation_id becomes the thread reference. Each message:

POST /api/v1/genies/{genie_id}/chat/conversations/{conversation_id}/messages
Content-Type: application/json

{ "message": "...", "stream": true }

The adapter parses SSE events:

  • agent.message
  • processing.finished
  • skill.confirmation_required → awaiting_approval
  • runtime_connection.auth_required → auth_required

Approval and auth pauses are surfaced as resume_ref values.

Agent registration​

Use Create agent from the installed connector. The adapter is set to workato, and the Genie/IdP config is carried into the agent. You do not need to specify operations or request paths.

OAuth 2.0 (PKCE) mode​

Workato also supports per-user OAuth 2.0 with PKCE. Use the Workato Genie (OAuth) catalog entry instead of the API-key entry.

Workato side​

Create a Genie client with OAuth 2.0 (PKCE) in Agent Studio. Record:

  • Genie handle
  • OAuth client ID
  • Redirect URL

The redirect URL must be:

https://YOUR_HOST/oauth/callback

No client secret is used. Workato Identity uses PKCE.

Giant Tree setup​

  1. Open Agents → Catalog.
  2. Select Workato Genie (OAuth) → Connect agent.
  3. Fill in:
    • Genie handle
    • OAuth client ID
    • API base URL (optional; defaults to the Workato runtime)
  4. Leave the default authorization URL:
    https://id.workato.com/oauth/authorize
  5. Leave the default token URL:
    https://id.workato.com/oauth/token
  6. Leave the default scopes:
    openid profile email
  7. Connect the agent. The agent is created as a draft.
  8. Activate it and bind it to a door.

First call​

The first ask returns auth_required with an auth_url. The end user:

  1. Opens the URL.
  2. Signs in through Workato Identity.
  3. Grants the requested scopes.
  4. Is redirected back to /oauth/callback.

Giant Tree stores the access and refresh tokens per agent and user, then the retry uses the OAuth token instead of an API key.

The OAuth mode does not send X-IDP-User-ID; the Workato Identity token carries the user identity.

Important​

  • OAuth Workato connectors cannot be tested from the connector card because no end-user principal exists there. Test through a door ask.
  • Workato refresh tokens are single-use and rotate. Giant Tree persists the new refresh token after each refresh.
  • The redirect URL must exactly match the Workato client configuration.
  • Scope must include openid profile email, and must not include offline_access.

Test expectations​

A successful test returns completed and the final agent message. If Workato asks for approval or connection, the test returns awaiting_approval or auth_required with a reason.

Troubleshooting​

SymptomFix
401 from WorkatoCheck API key and base URL
403/empty groupsEnsure the IdP user is permitted to use the Genie
No conversation IDCheck the Genie handle and Workato account region
Test returns awaiting_approvalComplete the approval in Workato or resume with resolution
Test returns auth_requiredComplete the connector auth flow and retry