twin memory

Sources

What each connector delivered to an end user's memory - per app, source and connection, how many items, how many ended, and the newest.

POST /v1/memory/sourcesAuth: read key

The items connectors delivered to this end user, counted by the app, source and connection each came through. What the console's Connectors page shows for a connection. Items you add yourself are not counted. Makes no model call.

Headers

Authorizationstringrequired

Bearer tm_…. A read key is enough.

X-Twin-Accountstringrequired

The end user whose memory to read. See End users.

X-Request-Idstring

Your id for this request, echoed on the response.

Body

(none)object

Send {}.

Response

sourcesobject[]

One per app, source and connection, ordered by them. Each has provider (google), source (messages), connection (the connection's id), items (how many it delivered), ended (how many of those its app reported deleted, archived or trashed) and newest (the time of the newest item). Empty when nothing has been connected for this end user.

Errors

400bad request

X-Twin-Account is missing or not a usable id.

401unauthorized

The bearer is not a key this service issued.

404not found

no memory for end user 'user_42' yet.

503unavailable

At capacity, or this end user is being rebuilt. Retry after Retry-After seconds.

Request
curl https://api.twinmemory.dev/v1/memory/sources \
  -H "Authorization: Bearer $TWIN_MEMORY_API_KEY" \
  -H "X-Twin-Account: user_42" \
  -H "Content-Type: application/json" \
  -d '{}'
Response
{
  "sources": [
    {
      "provider": "github",
      "source": "events",
      "connection": "7c2e4a10-5b3d-4e8f-a1c6-2f9d8b7e6a01",
      "items": 214,
      "ended": 0,
      "newest": "2026-10-26T05:02:01+00:00"
    },
    {
      "provider": "google",
      "source": "messages",
      "connection": "0b9c51d2-6f1e-4a8c-9e2b-1d7f3c5a8e44",
      "items": 375,
      "ended": 3,
      "newest": "2026-10-26T05:02:01+00:00"
    }
  ]
}