@ixo/decision-oracle 0.2.2 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/lib/email/template.js +1 -1
- package/dist/lib/email/template.js.map +1 -1
- package/dist/lib/payments/gate.js +2 -2
- package/dist/lib/payments/gate.js.map +1 -1
- package/dist/lib/payments/review-billing.js +1 -1
- package/dist/lib/payments/review-billing.js.map +1 -1
- package/dist/lib/register.js +1 -1
- package/dist/lib/register.js.map +1 -1
- package/dist/lib/review/reviewer-grant.d.ts +3 -2
- package/dist/lib/review/reviewer-grant.d.ts.map +1 -1
- package/dist/lib/review/reviewer-grant.js +3 -4
- package/dist/lib/review/reviewer-grant.js.map +1 -1
- package/dist/routes/v1/api/openapi.gen.d.ts.map +1 -1
- package/dist/routes/v1/api/openapi.gen.js +1 -1
- package/dist/routes/v1/api/openapi.gen.js.map +1 -1
- package/dist/routes/v1/reviewers.js +4 -9
- package/dist/routes/v1/reviewers.js.map +1 -1
- package/docs/api.md +3 -3
- package/docs/guide.md +1 -1
- package/openapi/decision-api.yaml +8 -8
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"openapi.gen.js","sourceRoot":"","sources":["../../../../src/routes/v1/api/openapi.gen.ts"],"names":[],"mappings":"AAAA,+FAA+F;AAC/F,iGAAiG;AACjG,sEAAsE;AAEtE,mGAAmG;AACnG,wEAAwE;AACxE,MAAM,CAAC,MAAM,gBAAgB,GAA4B,IAAI,CAAC,KAAK,CAAC
|
|
1
|
+
{"version":3,"file":"openapi.gen.js","sourceRoot":"","sources":["../../../../src/routes/v1/api/openapi.gen.ts"],"names":[],"mappings":"AAAA,+FAA+F;AAC/F,iGAAiG;AACjG,sEAAsE;AAEtE,mGAAmG;AACnG,wEAAwE;AACxE,MAAM,CAAC,MAAM,gBAAgB,GAA4B,IAAI,CAAC,KAAK,CAAC,+gkXAA+gkX,CAAC,CAAC"}
|
|
@@ -65,16 +65,11 @@ reviewers.post("/:collectionId/reviewers", validate("param", CollectionParam), v
|
|
|
65
65
|
const { delegation } = c.req.valid("json");
|
|
66
66
|
const config = c.get("config");
|
|
67
67
|
const { did } = c.get("principal");
|
|
68
|
-
|
|
68
|
+
await watchedOr404(c, collectionId);
|
|
69
69
|
const grant = await parseReviewerGrant(config, delegation, collectionId);
|
|
70
|
-
//
|
|
71
|
-
//
|
|
72
|
-
|
|
73
|
-
throw new AppError("This reviewer grant can't be used: the owner already sees its reviews.", {
|
|
74
|
-
code: "REVIEWER_GRANT_INVALID",
|
|
75
|
-
details: { reason: "audience" },
|
|
76
|
-
});
|
|
77
|
-
}
|
|
70
|
+
// A grant to the owner is allowed (owner, 2026-10-21): being in the review room lets them SEE
|
|
71
|
+
// reviews, and answering takes a grant like anyone else's. Revoking it stops their answers; the
|
|
72
|
+
// room seat stays theirs by right (`ensureReviewRoom`).
|
|
78
73
|
// The caller files only what they signed themselves: an uploaded grant is a controller's own
|
|
79
74
|
// word, never one they found.
|
|
80
75
|
if (grant.rootDid !== did) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reviewers.js","sourceRoot":"","sources":["../../../src/routes/v1/reviewers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAA2B,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAC/E,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAC9E,OAAO,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AACpE,OA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C,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC;AACnC,CAAC,CACF,CAAC"}
|
package/docs/api.md
CHANGED
|
@@ -1582,7 +1582,7 @@ once deployed. Every value is validated by Zod at isolate start, so a bad env fa
|
|
|
1582
1582
|
| `EARNINGS_ADDRESS` | vars | unset | Where your earnings for decisions land in PAY and USDC on IXO: your own `ixo1…` account, sent as each offer's `payTo` (the facilitator checks it, never picks one). Checked at start, checksum included. Needed only when IXO's plan for the oracle takes PAY (the engine's `GET /v1/oracles/me` `accepts` holds `upay`; KV-cached 5 min): unset then ⇒ new x402 submits answer `503 SOURCE_PAUSED { reason: payments-disabled }`. A plan without PAY (card and/or USDC on Base) sends no ixo-pay terms and never reads it; a plan the engine cannot tell is the same 503 |
|
|
1583
1583
|
| `EARNINGS_BASE_WALLET` | vars | unset | Your Base wallet (`0x…`) for USDC on Base. Unset ⇒ that way to pay is not offered |
|
|
1584
1584
|
| `BILLING_ENGINE_URL` | vars | unset | Charge lookups and the spend figures on `/v1/api/me`. No trailing slash |
|
|
1585
|
-
| `CONSOLE_URL` | vars | unset | The Decision Console — every error's `docsUrl`, the 402's `fundingUrl`, and every email link (the `balance.low` email's is `<CONSOLE_URL>/credits`). Unset ⇒ the API lane's emails are logged skips. No trailing slash |
|
|
1585
|
+
| `CONSOLE_URL` | vars | unset | The Decision Console — every error's `docsUrl`, the 402's `fundingUrl`, and every email link (the `balance.low` email's is `<CONSOLE_URL>/billing/credits`). Unset ⇒ the API lane's emails are logged skips. No trailing slash |
|
|
1586
1586
|
| `AUTH_HUB_URL` | vars | per `IXO_NETWORK` (`https://dev.auth.ixo.earth`, `https://test.auth.ixo.earth`, `https://auth.ixo.earth`) | IXO AuthHub, the OAuth server of `/v1/mcp`: the protected-resource metadata's `authorization_servers`, the exact `iss` of an access token (its JWKS at `<url>/.well-known/jwks.json`), the approve link's host, and the one `did:web` (`did:web:<its host>`) the approvals back-channel accepts. Set it only for a local AuthHub. No trailing slash |
|
|
1587
1587
|
| `ORACLE_ADMIN_DIDS` | vars | unset | Comma-separated `did:ixo` admins of this oracle — the oracle's operator's own people — allowed on `GET /v1/admin/status` and `/v1/api/admin/*`. Unset ⇒ nobody |
|
|
1588
1588
|
| `STATUS_READER_DIDS` | vars | unset | Comma-separated DIDs of any method (`did:web:…`, `did:ixo:…`, each checked as `did:<method>:<id>`) allowed to read `GET /v1/admin/status` and nothing else — for a monitoring service, e.g. your decision engine's status board, identified by its DID. Kept apart from `ORACLE_ADMIN_DIDS` so a monitor is never made an operator. Unset ⇒ nobody |
|
|
@@ -1715,7 +1715,7 @@ check.**
|
|
|
1715
1715
|
| `PATCH /v1/collections/:id/settings` | UCAN `collections/settings` (never `*`) + the collection's **current** chain owner (the entity's owner, read live off Blocksync; no enroller, grant holder or `ORACLE_ADMIN_DIDS`) — `403` otherwise, `404` unwatched | `{ operatorAmounts: "off" \| "allowed" }` (strict). Whether the act seam's on-chain amount (`policies.act`, `signEvaluation`) may stand on this collection: `"off"`, the default, ⇒ the lane pays its default and logs `act.amount-ignored-not-opted-in`. Recorded with the owner who set it: `"allowed"` stands only while that address still owns the collection's entity, so after a transfer it reads `"off"` until the new owner sets it. Answers the collection row, as `GET /v1/collections` does |
|
|
1716
1716
|
| `GET /v1/collections/:id/settings` | UCAN `collections/settings-read` (never `*`) + the collection's **current** chain owner, as the PATCH — `403` otherwise, `404` unwatched, `503` on chain trouble | `{ operatorAmounts, operatorAmountsBy, effective }`: what the owner set, the address that set it, and whether it is in force NOW — `effective` is the act lane's own reading (`operatorAmountsEffective`, `lib/ixo/chain-write.ts`): `true` only when `operatorAmounts` is `"allowed"` and `operatorAmountsBy` is the live owner, so after a transfer the value reads `"allowed"` with `effective: false` until the new owner says yes |
|
|
1717
1717
|
| `GET /v1/claims?collectionId=&limit=&cursor=` | UCAN `claims/read` + read gate | Summary list, newest first, keyset-paginated (`limit` default 100, max 500) |
|
|
1718
|
-
| `POST /v1/collections/:id/reviewers` | UCAN `collections/reviewers-grant` (never `*`) + a **current controller** of the collection's entity (read live off Blocksync), who must be the grant's issuer | `{ delegation }` — a base64 CAR the controller signed: a reviewer grant (below). Checked as the review gate checks it (no revocation step), then filed in `collection_reviewers
|
|
1718
|
+
| `POST /v1/collections/:id/reviewers` | UCAN `collections/reviewers-grant` (never `*`) + a **current controller** of the collection's entity (read live off Blocksync), who must be the grant's issuer | `{ delegation }` — a base64 CAR the controller signed: a reviewer grant (below). Checked as the review gate checks it (no revocation step), then filed in `collection_reviewers`. A controller may name **themselves**, and a grant to the collection's owner is filed like any other: one person may post an ask and review it (the owner's seat in the review room only lets them see reviews; answering always takes a grant). `201` + the grant row (`memberDid`, `rootDid`, `delegationCid`, `delegation`, `expiresAt`, `revokedAt`, `createdAt`). The same CAR again answers the same row; a revoked one is `409` (sign a new one). `400 REVIEWER_GRANT_INVALID` / `403 REVIEWER_NOT_AUTHORIZED` as the gate, `404` unwatched |
|
|
1719
1719
|
| `GET /v1/collections/:id/reviewers` | UCAN `collections/reviewers-read` (never `*`) | A current controller: `{ reviewers: [...] }`, every grant on the collection; a reviewer: only their own, CAR included (the Portal sends it with an answer); anyone else `403` |
|
|
1720
1720
|
| `POST /v1/collections/:id/reviewers/:delegationCid/revoke` | UCAN `collections/reviewers-revoke` (never `*`) + a current controller | Stamps `revokedAt` (once) and kicks the reviewer from the collection's review room. Every later answer and every pending fold under that grant is refused. `404` for an unknown grant |
|
|
1721
1721
|
| `GET /v1/claims/:claimId` | UCAN `claims/read` + read gate, or a live reviewer of the claim's collection (a filed, unrevoked grant inside its window whose root is still a controller — read live, so Blocksync down is `503`), or the claim's own submitter (matched by EITHER the claim's on-chain agent DID or its agent address, invoking as themselves; one Blocksync claim read, cached a day — a claim Blocksync does not know yet is not cached — tried only after the other doors; Blocksync down is `503`) | The full record: ingest ⟕ decision ⟕ review. The submitter sees the decision and its public receipt (which names who reviewed), but never the review's answers: `review.answers` and `review.reviewerDid` come back `null`, and so do the internal failure texts `ingest.error`, `decision.chainError` and `decision.erroredFacts`. `404` when this oracle has not seen the claim. The submitter gets no other read: not the list, not `/v1/reviews`, not another claim |
|
|
@@ -2069,7 +2069,7 @@ receivers de-duplicate on `Oracle-Event-Id`. An erased row stays erased and goes
|
|
|
2069
2069
|
minutes) reads each active source's payer balance against its `refillFloorCents`. The first read
|
|
2070
2070
|
below the floor sends one `balance.low` webhook (`{ sourceId, balanceCents, floorCents }`) and one
|
|
2071
2071
|
email to the source's `contactEmail`: the source's name, the balance and the floor as dollars, and
|
|
2072
|
-
an "Add credits" link to `${CONSOLE_URL}/credits`. The webhook goes once per crossing (a recovery
|
|
2072
|
+
an "Add credits" link to `${CONSOLE_URL}/billing/credits`. The webhook goes once per crossing (a recovery
|
|
2073
2073
|
above the floor re-arms it). The email goes once per UTC day while the balance stays under the
|
|
2074
2074
|
floor (`notice_balance_low:<sourceId>:<yyyy-mm-dd>`): still low tomorrow is a new email, a balance
|
|
2075
2075
|
bobbing around its floor within a day is one, and a send that fails is retried on the next check.
|
package/docs/guide.md
CHANGED
|
@@ -1280,7 +1280,7 @@ claim is ever blocked on one.
|
|
|
1280
1280
|
facilitator configured, the balance watch (every 5 minutes) sends a `balance.low` webhook the
|
|
1281
1281
|
first time the payer's balance drops below it, and emails the source's `contactEmail` once per UTC
|
|
1282
1282
|
day while it stays below (a send that fails is retried on the next check): the balance against the floor in dollars, and an "Add credits" link to your console's
|
|
1283
|
-
Credits page (`CONSOLE_URL/credits`). Without `CONSOLE_URL` or a sender, the email is a logged skip.
|
|
1283
|
+
Credits page (`CONSOLE_URL/billing/credits`). Without `CONSOLE_URL` or a sender, the email is a logged skip.
|
|
1284
1284
|
|
|
1285
1285
|
**Uptime and status.** Point your uptime monitor (Sentry Uptime, or any HTTP checker, every
|
|
1286
1286
|
minute) at `GET /health/ready`, not `/health`: `/health` only proves the worker boots, while
|
|
@@ -335,10 +335,10 @@ info:
|
|
|
335
335
|
|
|
336
336
|
|
|
337
337
|
**Changes in 1.19.0.** No wire change. The CLI gains the console's onboarding steps:
|
|
338
|
-
`decision-oracle org create` (an organisation entity, idempotent by name), `decision-oracle api
|
|
339
|
-
link <sourceId>` (signs the organisation's link, PUTs it to the engine and calls `POST
|
|
340
|
-
/v1/api/sources/{sourceId}/company/sync`: `pending-link` → `active`), `decision-oracle org
|
|
341
|
-
and `decision-oracle logout`.
|
|
338
|
+
`decision-oracle org create` (an organisation entity, idempotent by name), `decision-oracle api
|
|
339
|
+
source link <sourceId>` (signs the organisation's link, PUTs it to the engine and calls `POST
|
|
340
|
+
/v1/api/sources/{sourceId}/company/sync`: `pending-link` → `active`), `decision-oracle org
|
|
341
|
+
balance` and `decision-oracle logout`.
|
|
342
342
|
|
|
343
343
|
|
|
344
344
|
**Changes in 1.20.0.** Additive: `ClaimRecord.decision.erroredFacts` and
|
|
@@ -7754,14 +7754,14 @@ components:
|
|
|
7754
7754
|
maxTimeoutSeconds: 120
|
|
7755
7755
|
extra:
|
|
7756
7756
|
nonce: 7c1e2a4b-9d3f-4e8a-b6c5-2f1d0e9a8b7c
|
|
7757
|
-
fundingUrl: https://console.ixo.earth/credits
|
|
7757
|
+
fundingUrl: https://console.ixo.earth/billing/credits
|
|
7758
7758
|
price:
|
|
7759
7759
|
amountMicroUsd: 1200000
|
|
7760
7760
|
amountCents: 120
|
|
7761
7761
|
currency: USD
|
|
7762
7762
|
amount: "1200000"
|
|
7763
7763
|
asset: upay
|
|
7764
|
-
fundingUrl: https://console.ixo.earth/credits
|
|
7764
|
+
fundingUrl: https://console.ixo.earth/billing/credits
|
|
7765
7765
|
docsUrl: https://console.ixo.earth/docs/errors#PAYMENT_REQUIRED
|
|
7766
7766
|
SPEND_CAP:
|
|
7767
7767
|
value:
|
|
@@ -7777,7 +7777,7 @@ components:
|
|
|
7777
7777
|
currency: USD
|
|
7778
7778
|
amount: "1200000"
|
|
7779
7779
|
asset: upay
|
|
7780
|
-
fundingUrl: https://console.ixo.earth/credits
|
|
7780
|
+
fundingUrl: https://console.ixo.earth/billing/credits
|
|
7781
7781
|
docsUrl: https://console.ixo.earth/docs/errors#SPEND_CAP
|
|
7782
7782
|
INSUFFICIENT_CREDITS:
|
|
7783
7783
|
value:
|
|
@@ -7793,7 +7793,7 @@ components:
|
|
|
7793
7793
|
currency: USD
|
|
7794
7794
|
amount: "1200000"
|
|
7795
7795
|
asset: upay
|
|
7796
|
-
fundingUrl: https://console.ixo.earth/credits
|
|
7796
|
+
fundingUrl: https://console.ixo.earth/billing/credits
|
|
7797
7797
|
docsUrl: https://console.ixo.earth/docs/errors#INSUFFICIENT_CREDITS
|
|
7798
7798
|
NotFound:
|
|
7799
7799
|
description: "`NOT_FOUND` — unknown, or another source's (never 403 across sources)."
|
package/package.json
CHANGED