From c5a7d6cfb85da7814982a30e141fc5a52a08abe7 Mon Sep 17 00:00:00 2001 From: Xaxis Date: Wed, 11 Nov 2026 14:47:55 -0900 Subject: [PATCH 1/2] The event fields say whole sats and a public note me.ochk.io reads payment_amount_sats as a whole number of sats above 0 and says so in its OpenAPI. A note is in the event's receipt, which anyone with its link can read, so the field says it is public. --- src/pages/me/api.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/pages/me/api.mdx b/src/pages/me/api.mdx index a7513a89..c4182a71 100644 --- a/src/pages/me/api.mdx +++ b/src/pages/me/api.mdx @@ -301,9 +301,9 @@ The request body is JSON. The fields, in any order: | `project_key` | yes | Your project, `pk_test_…` or `pk_live_…` | | `subtype` | yes | An event your project defined and enabled, built-in or your own | | `user_address` | backend | Who earns: the person's `did_oc` from their sign-in token. Accepted only when signed | -| `payment_amount_sats` | some | The payment, for an event priced as a share of one | +| `payment_amount_sats` | some | The payment in whole sats, for an event priced as a share of one | | `action_label` | no | A short label shown on the receipt: up to 280 characters of plain text | -| `note` | no | A note shown to the person: up to 280 characters of plain text | +| `note` | no | Public plain text shown to the person, in the event's receipt: up to 280 characters | | `is_agent` | no | `true` when an AI agent acted for the person | Sign the exact bytes you send, in one header: @@ -355,7 +355,7 @@ Without the SDK, the header is | 200 | `earned: false`, `reason: not_paying` | Outside your pay periods: no event recorded or charged | | 400 | `invalid_user_address` | `user_address` is not a `did:oc` | | 400 | `project_key_required`, `subtype_required` | A required field is missing | -| 400 | `payment_amount_sats_required` | The event is priced as a share of a payment and `payment_amount_sats` is missing | +| 400 | `payment_amount_sats_required` | The event is priced as a share of a payment and `payment_amount_sats` is missing, not above 0 or not whole sats | | 400 | `idempotency_key_too_long` | `Idempotency-Key` is longer than 200 characters | | 401 | `invalid_signature` | The header is there but does not verify (`stale_timestamp`, `future_timestamp`, `bad_signature`, `invalid_format`) | | 401 | `signature_required` | A live project, or one requiring signed events, got an unsigned request | From 3b9cb1d5091a68f9f581b0ee03a1b8ad9cb868ed Mon Sep 17 00:00:00 2001 From: Xaxis Date: Wed, 11 Nov 2026 14:56:04 -0900 Subject: [PATCH 2/2] The event fields say which built-ins keep a note or a label me.ochk.io keeps note on a class A built-in, action_label on a class B one, neither on class C, and both on your own events. The table promised both everywhere. --- src/pages/me/api.mdx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pages/me/api.mdx b/src/pages/me/api.mdx index c4182a71..6f06ce90 100644 --- a/src/pages/me/api.mdx +++ b/src/pages/me/api.mdx @@ -306,6 +306,10 @@ The request body is JSON. The fields, in any order: | `note` | no | Public plain text shown to the person, in the event's receipt: up to 280 characters | | `is_agent` | no | `true` when an AI agent acted for the person | +A built-in event keeps only the text its class shows: `note` on a class A event, +`action_label` on a class B event, neither on class C. Your own events keep +both. + Sign the exact bytes you send, in one header: ```