ONE invoice:list
← Receivers

invoice:list

invoice family

mcp

List your workspace's estimates and invoices, newest first, up to 100 (default 50). Says when it is short: `total` counts them all, `truncated` is true when more exist than are shown.

Effect
ask
Awaits an outcome — the call returns the response below.
Caller
owner
The class of authority the caller must already hold, decided from the attested context with no round trip.
Cost
free
What one call costs, so you can budget before acting.
Reversible
yes
The effect can be undone by a later call.
Settles
offchain
Moves real value off chain — a balance changes.
Idempotent
yes
Safe to retry as-is.

Send it with your agent

One click hands your coding agent a prompt that registers the substrate, reads this contract, and makes the call. Launch opens the app; the others copy the prompt.

Claude Code
Codex
Cursor
Gemini CLI
Claude Desktop
ChatGPT
curl -X POST https://one.ie/api/ask/invoice:list \
  -H "Authorization: Bearer $ONE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"data": { "workspace": <string>, "kind": <estimate | invoice>, "status": <string>, "limit": <number> }}'

The key is never in a link. npx -y @oneie/cli login writes it to ~/.config/oneie/key on your machine.

Request

Validated before dispatch — an invalid payload is refused with the fix, never half-applied.

  • workspace string optional Defaults to the attested caller's own; the caller must control it
  • kind estimate | invoice optional Only this kind
  • status string optional Only this status, as invoice:get names it (overdue and expired included)
  • limit number optional 1 to 100; default 50

Response

What comes back from the call.

  • ok boolean
  • invoices object[]
  • count number Rows in this answer
  • total number Documents of this kind the workspace holds
  • truncated boolean true when total is more than the rows shown
  • error string sign_in_required · not_your_workspace · store_unavailable · no_db

Traffic

Every call to invoice:list, counted where it is dispatched — over HTTP or in-process alike. Aggregate only — no actor, no payload, no workspace.

Counting…

Wiring

Every place in the open source that names invoice:list, and the file that answers it. Read from the tree at build time — a receiver is reached by NAME through one door, so there is no import edge to follow and a grep is the honest shape of the question. Structure, not volume — the count is in Traffic above.

Called from

API route 1
  • one.ie/web/src/lib/receiver-index.generated.ts:250
CLI 2
  • packages/cli/src/invoice.ts:153
  • packages/cli/src/lib/money-receivers.ts:50
→

Answered by

invoice:list one.ie/web/src/lib/resolvers/customer-invoice.ts:313 Dispatched through POST /api/ask/invoice:list, after the envelope validates the payload.
JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "workspace": {
      "description": "Defaults to the attested caller's own; the caller must control it",
      "type": "string"
    },
    "kind": {
      "description": "Only this kind",
      "type": "string",
      "enum": [
        "estimate",
        "invoice"
      ]
    },
    "status": {
      "description": "Only this status, as invoice:get names it (overdue and expired included)",
      "type": "string"
    },
    "limit": {
      "description": "1 to 100; default 50",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    }
  }
}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "ok": {
      "type": "boolean"
    },
    "invoices": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "number": {
            "type": "string"
          },
          "kind": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "totalCents": {
            "type": "number"
          },
          "customerName": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "customerEmail": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "dueAt": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "number",
          "kind",
          "status",
          "totalCents"
        ]
      }
    },
    "count": {
      "description": "Rows in this answer",
      "type": "number"
    },
    "total": {
      "description": "Documents of this kind the workspace holds",
      "type": "number"
    },
    "truncated": {
      "description": "true when total is more than the rows shown",
      "type": "boolean"
    },
    "error": {
      "description": "sign_in_required · not_your_workspace · store_unavailable · no_db",
      "type": "string"
    }
  },
  "required": [
    "ok"
  ]
}