omi icon indicating copy to clipboard operation
omi copied to clipboard

hume-ai: create_omi_memory posts to /v1/integrations/{app_id}/memories, a route the backend does not serve (404) — emotion memories are never saved ($25 bounty proposed)

Open Suyann opened this issue 2 months ago • 2 comments

Symptom

plugins/hume-ai/app.py → create_omi_memory() never saves an emotion memory. Every call logs ✗ Omi API error: 404 - {"detail":"Not Found"} and returns {"success": false}, so the "create memory from detected emotion" path of the Hume plugin is dead in production.

Evidence

The plugin posts to https://api.omi.me/v1/integrations/{app_id}/memories?uid={uid} (plugins/hume-ai/app.py:273). That route does not exist on the backend — backend/routers/integration.py only registers the v2 import routes:

POST /v2/integrations/{app_id}/user/memories      (create memories)
POST /v2/integrations/{app_id}/user/conversations
GET  /v2/integrations/{app_id}/memories

Live check against production (no key needed — a missing route 404s, a real route asks for the key):

$ curl -s -X POST -H 'Content-Type: application/json' -d '{"text":"t"}' \
    'https://api.omi.me/v1/integrations/testapp/memories?uid=u1'
{"detail":"Not Found"}                                   # HTTP 404

$ curl -s -X POST -H 'Content-Type: application/json' -d '{"text":"t"}' \
    'https://api.omi.me/v2/integrations/testapp/user/memories?uid=u1'
{"detail":"Missing or invalid Authorization header. Must be 'Bearer API_KEY'"}   # HTTP 401

The payload the plugin already sends ({"text": ..., "timestamp": ..., "emotions": [...]}) is accepted by the v2 route (ExternalIntegrationCreateMemory requires text or memories; extra keys are ignored), so only the path is wrong.

Fix

One-line route change to /v2/integrations/{app_id}/user/memories?uid=, plus a hermetic regression test (stubs the Hume SDK and httpx, pins route/header/payload) registered in .github/checks-manifest.yaml. PR incoming.

Bounty

Per the Contribution guide ("No bounties available? … suggest your own"), proposing a US$25 bounty for this fix + regression test. cc @josancamon19 @kodjima33

Investigated and fixed with Claude Code on behalf of @Suyann; every command above was actually run.

Suyann avatar Sep 17 '26 13:09 Suyann

Locking this task / bounty.

As an active contributor with merged PRs (#14224, #14546), claiming lock privilege per official Omi Contribution Guidelines:

  • Clean implementation is submitted in PR #14679: https://github.com/BasedHardware/omi/pull/14679
  • Posts emotion memories to served v2 route /v2/integrations/{APP_ID}/user/memories.
  • All 17 CI and manifest checks pass 100% green. Ready for review!

shuoYun114 avatar Sep 19 '26 02:09 shuoYun114

For the record: this issue was opened together with PR #14342 (2026-09-17), which fixes it with a hermetic regression test and manifest registration. #14342 was approved by @kodjima33 on 2026-09-17 and re-approved on 2026-09-18 (5/5), verified end to end by the maintainer assistant, and is conflict-free against current main (the manifest conflict noted in the review was resolved on 2026-09-19). So the fix is already in the merge queue rather than unclaimed; leaving the merge decision to the maintainers.

Suyann avatar Sep 19 '26 04:09 Suyann