Skip to content

fix(openhands-api): share the Agent Canvas link for delegated conversations - #714

Merged
saurya merged 1 commit into
mainfrom
fix/openhands-api-canvas-conversation-link
Oct 2, 2026
Merged

saurya merged 1 commit into
mainfrom
fix/openhands-api-canvas-conversation-link

Conversation

@lilagrc

@lilagrc lilagrc commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

HUMAN:

  • A human has tested these changes.

Manually verified this, along with OpenHands/OpenHands#17842 and OpenHands/enterprise#606, produced the correct, canvas conversation link when for a sub agent delegated conversation.

TODO


AGENT:

Why

When an agent delegates work with POST /api/v1/app-conversations, it gives the user a link built from this skill: https://app.all-hands.dev/conversations/<id> in the delegation checklist, and {base_url}/conversations/<id> in the Python example. Both open the legacy UI, not Agent Canvas, which is served at /canvas. The checklist also hardcodes the Cloud host, so agents running on self-hosted Enterprise link to a different server.

Summary

  • The Python client has a new OpenHandsAPI.app_conversation_ui_url(conversation_id). It returns the conversation's conversation_ui_url, which the app server adds in fix(conversations): OHE-3432 return an Agent Canvas link in the API enterprise#606. Servers that don't return it yet get <base_url>/canvas/conversations/<id>.
  • The delegation checklist, the cURL flow, the Python example, and the skill README now point to that link. The checklist also says not to share conversation_url, which is the sandbox's agent-server API.
  • skills/index.js is regenerated with npm run build:skills.

Issue Number

Fixes #717

Tracked in Linear as OHE-3432. Related fixes: OpenHands/enterprise#606 (server) and OpenHands/OpenHands#17842 (Agent Canvas).

How to Test

  • uv run pytest -q tests/test_openhands_api_python.py: the two new tests failed before the change (AttributeError: 'OpenHandsAPI' object has no attribute 'app_conversation_ui_url') and pass now. They cover the server-provided link and the fallback.

  • uv run pytest -q: 1102 passed, 23 skipped. python scripts/sync_extensions.py --check is clean.

  • End to end, read-only, against a live OpenHands Enterprise instance, using the edited client with an existing conversation:

    api = OpenHandsAPI(base_url="https://<enterprise-host>")
    conversation_id = api.app_conversations_search(limit=1)["items"][0]["id"]
    url = api.app_conversation_ui_url(conversation_id)
    httpx.get(url, follow_redirects=True)
    server returns conversation_ui_url: False
    link path: /canvas/conversations/da94b2ca40b640bf9a2c5702a99be7a9
    GET link -> 200 text/html; charset=utf-8
    served by Agent Canvas bundle: True
    

    That instance doesn't run the server change yet, so this exercised the fallback. The link opens the conversation in Agent Canvas. The server-provided path is covered by the unit test until the server change is deployed.

Video/Screenshots

None. The change is to a client helper and docs.

Notes

  • The local Agent Canvas section still gives <LOCAL_AGENT_SERVER_URL>/conversations/<id>. That's correct: standalone Agent Canvas serves at the root, not under /canvas.
  • The TypeScript client has no conversation-lookup helper, so it isn't changed.
  • Other automation scripts in this repo (github-issue-to-pr, gitlab-issue-to-mr, slack-channel-monitor, news-digest, and others) also build /conversations/<id> links. They are separate skills and are left for follow-up PRs.

This PR was drafted by an AI agent on behalf of the user.

@lilagrc can click here to continue refining the PR

…ations

The delegation checklist and Python example built the legacy
/conversations/<id> route. OpenHandsAPI.app_conversation_ui_url() returns
the server's conversation_ui_url and falls back to
<base_url>/canvas/conversations/<id> on servers that predate the field.

Co-authored-by: openhands <openhands@all-hands.dev>
@saurya
saurya merged commit f9a2aaf into main Oct 2, 2026
20 of 23 checks passed
@saurya
saurya deleted the fix/openhands-api-canvas-conversation-link branch October 2, 2026 01:00
@openhands-release-bot openhands-release-bot Bot added the released: v0.26.0 Shipped in v0.26.0 label Oct 2, 2026
@openhands-release-bot

Copy link
Copy Markdown
Contributor

🚀 Released in v0.26.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released: v0.26.0 Shipped in v0.26.0 type: fix A bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

openhands-api skill shares delegated conversations as legacy UI links instead of Agent Canvas

3 participants