Skip to content

feat(gateway): add platform-managed LINE support - #14979

Closed
David-0x221Eight wants to merge 4 commits into
NousResearch:mainfrom
Pieverse-Eng:feat/platform-managed-line
Closed

feat(gateway): add platform-managed LINE support#14979
David-0x221Eight wants to merge 4 commits into
NousResearch:mainfrom
Pieverse-Eng:feat/platform-managed-line

Conversation

@David-0x221Eight

Copy link
Copy Markdown
Contributor

Summary

Adds a native LINE platform adapter to Hermes for hosted, platform-managed LINE Messenger integration.

This is the Hermes-side half of a platform-managed LINE integration: tenant pods receive internally forwarded LINE webhook events on /line/webhook, authorize paired LINE users through LINE_ALLOWED_USERS, and send text replies through a configurable LINE API base URL. In hosted mode that base can point at a platform proxy, so the real central LINE channel access token stays outside the tenant pod.

Related to #6081, #8398, and #6676.

What Changed

  • Added gateway.platforms.line.LineAdapter with HMAC webhook verification, text event parsing, webhook server startup, and LINE Push API text sends.
  • Added LINE config/env support for token, channel secret, API base URL, webhook host/port/path, home channel, and allowlist authorization.
  • Wired LINE into gateway adapter creation, prompt hints, send-message tooling, cron delivery, toolsets, and CLI platform metadata.
  • Added focused tests for config, signature verification, event parsing, outbound proxy URL behavior, authorization, prompt/toolset registration, and send-message routing.

Scope Notes

This implementation is intentionally text-first and focused on the platform-managed path. It does not attempt to cover the full LINE Messaging API surface, such as image, audio, video, stickers, or file delivery. The narrower scope is meant to provide a maintainable adapter for deployments where LINE credentials and webhook ingress are managed by an external platform layer.

Existing upstream LINE work in #8398 and #6676 is broader native LINE bot support. This PR keeps the first upstream slice smaller and centered on the hosted/proxy integration contract.

Validation

  • uv run --extra dev --extra messaging pytest tests/gateway/test_line.py tests/agent/test_prompt_builder.py::TestPromptBuilderConstants::test_platform_hints_known_platforms tests/test_toolsets.py::TestToolsetConsistency::test_hermes_platforms_share_core_tools -q
    • 13 passed, 6 warnings
  • git show --check --format=short HEAD
    • passed with no whitespace errors

@alt-glitch alt-glitch added type/feature New feature or request P3 Low — cosmetic, nice to have comp/gateway Gateway runner, session dispatch, delivery labels Apr 24, 2026
@0xildefonso
0xildefonso deleted the feat/platform-managed-line branch April 26, 2026 10:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/gateway Gateway runner, session dispatch, delivery P3 Low — cosmetic, nice to have type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants