OpenCode icon

OpenCode

Interact with OpenCode Server API for AI coding assistant sessions

Message → List

AI-generated

Summary

List messages in a session with an optional limit.

Inputs

  • sessionId (required) — Select a session
  • limit — Maximum number of messages to return

Output shape

Array of message objects from the session. Returns [{json: {messages: [], count: 0, sessionId}}] if no messages match.

Each item includes pairedItem indexing the input item.

Links

Discussion