@ixo/decision-oracle 0.0.0-stage → 0.2.1
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/LICENSE +201 -0
- package/README.md +794 -2
- package/dist/act.d.ts +87 -0
- package/dist/act.d.ts.map +1 -0
- package/dist/act.js +20 -0
- package/dist/act.js.map +1 -0
- package/dist/app.d.ts +22 -0
- package/dist/app.d.ts.map +1 -0
- package/dist/app.js +128 -0
- package/dist/app.js.map +1 -0
- package/dist/c2pa.wasm +0 -0
- package/dist/cli/commands/api.d.ts +50 -0
- package/dist/cli/commands/api.d.ts.map +1 -0
- package/dist/cli/commands/api.js +737 -0
- package/dist/cli/commands/api.js.map +1 -0
- package/dist/cli/commands/create-collection.d.ts +40 -0
- package/dist/cli/commands/create-collection.d.ts.map +1 -0
- package/dist/cli/commands/create-collection.js +318 -0
- package/dist/cli/commands/create-collection.js.map +1 -0
- package/dist/cli/commands/create-deed.d.ts +31 -0
- package/dist/cli/commands/create-deed.d.ts.map +1 -0
- package/dist/cli/commands/create-deed.js +208 -0
- package/dist/cli/commands/create-deed.js.map +1 -0
- package/dist/cli/commands/delegation.d.ts +26 -0
- package/dist/cli/commands/delegation.d.ts.map +1 -0
- package/dist/cli/commands/delegation.js +162 -0
- package/dist/cli/commands/delegation.js.map +1 -0
- package/dist/cli/commands/derive.d.ts +22 -0
- package/dist/cli/commands/derive.d.ts.map +1 -0
- package/dist/cli/commands/derive.js +53 -0
- package/dist/cli/commands/derive.js.map +1 -0
- package/dist/cli/commands/engine.d.ts +25 -0
- package/dist/cli/commands/engine.d.ts.map +1 -0
- package/dist/cli/commands/engine.js +107 -0
- package/dist/cli/commands/engine.js.map +1 -0
- package/dist/cli/commands/erase.d.ts +17 -0
- package/dist/cli/commands/erase.d.ts.map +1 -0
- package/dist/cli/commands/erase.js +117 -0
- package/dist/cli/commands/erase.js.map +1 -0
- package/dist/cli/commands/facts-run.d.ts +30 -0
- package/dist/cli/commands/facts-run.d.ts.map +1 -0
- package/dist/cli/commands/facts-run.js +409 -0
- package/dist/cli/commands/facts-run.js.map +1 -0
- package/dist/cli/commands/facts-scaffold.d.ts +22 -0
- package/dist/cli/commands/facts-scaffold.d.ts.map +1 -0
- package/dist/cli/commands/facts-scaffold.js +208 -0
- package/dist/cli/commands/facts-scaffold.js.map +1 -0
- package/dist/cli/commands/init.d.ts +18 -0
- package/dist/cli/commands/init.d.ts.map +1 -0
- package/dist/cli/commands/init.js +34 -0
- package/dist/cli/commands/init.js.map +1 -0
- package/dist/cli/commands/login.d.ts +9 -0
- package/dist/cli/commands/login.d.ts.map +1 -0
- package/dist/cli/commands/login.js +16 -0
- package/dist/cli/commands/login.js.map +1 -0
- package/dist/cli/commands/logout.d.ts +10 -0
- package/dist/cli/commands/logout.d.ts.map +1 -0
- package/dist/cli/commands/logout.js +28 -0
- package/dist/cli/commands/logout.js.map +1 -0
- package/dist/cli/commands/manifest.d.ts +12 -0
- package/dist/cli/commands/manifest.d.ts.map +1 -0
- package/dist/cli/commands/manifest.js +48 -0
- package/dist/cli/commands/manifest.js.map +1 -0
- package/dist/cli/commands/oracle-init.d.ts +48 -0
- package/dist/cli/commands/oracle-init.d.ts.map +1 -0
- package/dist/cli/commands/oracle-init.js +1122 -0
- package/dist/cli/commands/oracle-init.js.map +1 -0
- package/dist/cli/commands/org.d.ts +28 -0
- package/dist/cli/commands/org.d.ts.map +1 -0
- package/dist/cli/commands/org.js +309 -0
- package/dist/cli/commands/org.js.map +1 -0
- package/dist/cli/commands/protocol-review.d.ts +20 -0
- package/dist/cli/commands/protocol-review.d.ts.map +1 -0
- package/dist/cli/commands/protocol-review.js +162 -0
- package/dist/cli/commands/protocol-review.js.map +1 -0
- package/dist/cli/commands/publish-protocol.d.ts +43 -0
- package/dist/cli/commands/publish-protocol.d.ts.map +1 -0
- package/dist/cli/commands/publish-protocol.js +345 -0
- package/dist/cli/commands/publish-protocol.js.map +1 -0
- package/dist/cli/commands/register.d.ts +16 -0
- package/dist/cli/commands/register.d.ts.map +1 -0
- package/dist/cli/commands/register.js +54 -0
- package/dist/cli/commands/register.js.map +1 -0
- package/dist/cli/commands/relink.d.ts +11 -0
- package/dist/cli/commands/relink.d.ts.map +1 -0
- package/dist/cli/commands/relink.js +36 -0
- package/dist/cli/commands/relink.js.map +1 -0
- package/dist/cli/commands/rubric-fetch-form.d.ts +16 -0
- package/dist/cli/commands/rubric-fetch-form.d.ts.map +1 -0
- package/dist/cli/commands/rubric-fetch-form.js +83 -0
- package/dist/cli/commands/rubric-fetch-form.js.map +1 -0
- package/dist/cli/commands/rubric-validate.d.ts +72 -0
- package/dist/cli/commands/rubric-validate.d.ts.map +1 -0
- package/dist/cli/commands/rubric-validate.js +163 -0
- package/dist/cli/commands/rubric-validate.js.map +1 -0
- package/dist/cli/commands/scan.d.ts +13 -0
- package/dist/cli/commands/scan.d.ts.map +1 -0
- package/dist/cli/commands/scan.js +39 -0
- package/dist/cli/commands/scan.js.map +1 -0
- package/dist/cli/commands/skills.d.ts +11 -0
- package/dist/cli/commands/skills.d.ts.map +1 -0
- package/dist/cli/commands/skills.js +19 -0
- package/dist/cli/commands/skills.js.map +1 -0
- package/dist/cli/commands/submit-claim.d.ts +25 -0
- package/dist/cli/commands/submit-claim.d.ts.map +1 -0
- package/dist/cli/commands/submit-claim.js +155 -0
- package/dist/cli/commands/submit-claim.js.map +1 -0
- package/dist/cli/index.d.ts +15 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +206 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/cli/lib/agent-card-schema.d.ts +8 -0
- package/dist/cli/lib/agent-card-schema.d.ts.map +1 -0
- package/dist/cli/lib/agent-card-schema.js +169 -0
- package/dist/cli/lib/agent-card-schema.js.map +1 -0
- package/dist/cli/lib/ai-rest.d.ts +12 -0
- package/dist/cli/lib/ai-rest.d.ts.map +1 -0
- package/dist/cli/lib/ai-rest.js +36 -0
- package/dist/cli/lib/ai-rest.js.map +1 -0
- package/dist/cli/lib/args.d.ts +33 -0
- package/dist/cli/lib/args.d.ts.map +1 -0
- package/dist/cli/lib/args.js +24 -0
- package/dist/cli/lib/args.js.map +1 -0
- package/dist/cli/lib/authhub.d.ts +7 -0
- package/dist/cli/lib/authhub.d.ts.map +1 -0
- package/dist/cli/lib/authhub.js +210 -0
- package/dist/cli/lib/authhub.js.map +1 -0
- package/dist/cli/lib/chain.d.ts +264 -0
- package/dist/cli/lib/chain.d.ts.map +1 -0
- package/dist/cli/lib/chain.js +584 -0
- package/dist/cli/lib/chain.js.map +1 -0
- package/dist/cli/lib/devvars.d.ts +59 -0
- package/dist/cli/lib/devvars.d.ts.map +1 -0
- package/dist/cli/lib/devvars.js +206 -0
- package/dist/cli/lib/devvars.js.map +1 -0
- package/dist/cli/lib/engine.d.ts +54 -0
- package/dist/cli/lib/engine.d.ts.map +1 -0
- package/dist/cli/lib/engine.js +112 -0
- package/dist/cli/lib/engine.js.map +1 -0
- package/dist/cli/lib/identity-cards.d.ts +188 -0
- package/dist/cli/lib/identity-cards.d.ts.map +1 -0
- package/dist/cli/lib/identity-cards.js +261 -0
- package/dist/cli/lib/identity-cards.js.map +1 -0
- package/dist/cli/lib/matrix-account.d.ts +79 -0
- package/dist/cli/lib/matrix-account.d.ts.map +1 -0
- package/dist/cli/lib/matrix-account.js +228 -0
- package/dist/cli/lib/matrix-account.js.map +1 -0
- package/dist/cli/lib/oracle-account.d.ts +108 -0
- package/dist/cli/lib/oracle-account.d.ts.map +1 -0
- package/dist/cli/lib/oracle-account.js +207 -0
- package/dist/cli/lib/oracle-account.js.map +1 -0
- package/dist/cli/lib/project.d.ts +22 -0
- package/dist/cli/lib/project.d.ts.map +1 -0
- package/dist/cli/lib/project.js +62 -0
- package/dist/cli/lib/project.js.map +1 -0
- package/dist/cli/lib/session.d.ts +109 -0
- package/dist/cli/lib/session.d.ts.map +1 -0
- package/dist/cli/lib/session.js +354 -0
- package/dist/cli/lib/session.js.map +1 -0
- package/dist/cli/lib/workorder.d.ts +57 -0
- package/dist/cli/lib/workorder.d.ts.map +1 -0
- package/dist/cli/lib/workorder.js +101 -0
- package/dist/cli/lib/workorder.js.map +1 -0
- package/dist/config.d.ts +221 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +431 -0
- package/dist/config.js.map +1 -0
- package/dist/context.d.ts +88 -0
- package/dist/context.d.ts.map +1 -0
- package/dist/context.js +9 -0
- package/dist/context.js.map +1 -0
- package/dist/contracts/api.d.ts +3367 -0
- package/dist/contracts/api.d.ts.map +1 -0
- package/dist/contracts/api.js +1303 -0
- package/dist/contracts/api.js.map +1 -0
- package/dist/contracts/capabilities.d.ts +126 -0
- package/dist/contracts/capabilities.d.ts.map +1 -0
- package/dist/contracts/capabilities.js +164 -0
- package/dist/contracts/capabilities.js.map +1 -0
- package/dist/contracts/claim-source.d.ts +98 -0
- package/dist/contracts/claim-source.d.ts.map +1 -0
- package/dist/contracts/claim-source.js +17 -0
- package/dist/contracts/claim-source.js.map +1 -0
- package/dist/contracts/errors.d.ts +150 -0
- package/dist/contracts/errors.d.ts.map +1 -0
- package/dist/contracts/errors.js +121 -0
- package/dist/contracts/errors.js.map +1 -0
- package/dist/contracts/index.d.ts +15 -0
- package/dist/contracts/index.d.ts.map +1 -0
- package/dist/contracts/index.js +11 -0
- package/dist/contracts/index.js.map +1 -0
- package/dist/contracts/payment-gate.d.ts +129 -0
- package/dist/contracts/payment-gate.d.ts.map +1 -0
- package/dist/contracts/payment-gate.js +24 -0
- package/dist/contracts/payment-gate.js.map +1 -0
- package/dist/contracts/start-api-claim.d.ts +90 -0
- package/dist/contracts/start-api-claim.d.ts.map +1 -0
- package/dist/contracts/start-api-claim.js +22 -0
- package/dist/contracts/start-api-claim.js.map +1 -0
- package/dist/contracts/webhooks.d.ts +1487 -0
- package/dist/contracts/webhooks.d.ts.map +1 -0
- package/dist/contracts/webhooks.js +71 -0
- package/dist/contracts/webhooks.js.map +1 -0
- package/dist/contracts/work-order.d.ts +29 -0
- package/dist/contracts/work-order.d.ts.map +1 -0
- package/dist/contracts/work-order.js +12 -0
- package/dist/contracts/work-order.js.map +1 -0
- package/dist/cron/ai-cost.d.ts +29 -0
- package/dist/cron/ai-cost.d.ts.map +1 -0
- package/dist/cron/ai-cost.js +80 -0
- package/dist/cron/ai-cost.js.map +1 -0
- package/dist/cron/api-lane.d.ts +39 -0
- package/dist/cron/api-lane.d.ts.map +1 -0
- package/dist/cron/api-lane.js +203 -0
- package/dist/cron/api-lane.js.map +1 -0
- package/dist/cron/backlog.d.ts +50 -0
- package/dist/cron/backlog.d.ts.map +1 -0
- package/dist/cron/backlog.js +115 -0
- package/dist/cron/backlog.js.map +1 -0
- package/dist/cron/billing.d.ts +11 -0
- package/dist/cron/billing.d.ts.map +1 -0
- package/dist/cron/billing.js +69 -0
- package/dist/cron/billing.js.map +1 -0
- package/dist/cron/collection.d.ts +50 -0
- package/dist/cron/collection.d.ts.map +1 -0
- package/dist/cron/collection.js +118 -0
- package/dist/cron/collection.js.map +1 -0
- package/dist/cron/funding.d.ts +16 -0
- package/dist/cron/funding.d.ts.map +1 -0
- package/dist/cron/funding.js +262 -0
- package/dist/cron/funding.js.map +1 -0
- package/dist/cron/payer-billing.d.ts +38 -0
- package/dist/cron/payer-billing.d.ts.map +1 -0
- package/dist/cron/payer-billing.js +119 -0
- package/dist/cron/payer-billing.js.map +1 -0
- package/dist/cron/scan.d.ts +43 -0
- package/dist/cron/scan.d.ts.map +1 -0
- package/dist/cron/scan.js +250 -0
- package/dist/cron/scan.js.map +1 -0
- package/dist/db/client.d.ts +14 -0
- package/dist/db/client.d.ts.map +1 -0
- package/dist/db/client.js +14 -0
- package/dist/db/client.js.map +1 -0
- package/dist/db/index.d.ts +7 -0
- package/dist/db/index.d.ts.map +1 -0
- package/dist/db/index.js +7 -0
- package/dist/db/index.js.map +1 -0
- package/dist/db/schema.d.ts +6738 -0
- package/dist/db/schema.d.ts.map +1 -0
- package/dist/db/schema.js +1433 -0
- package/dist/db/schema.js.map +1 -0
- package/dist/define-oracle.d.ts +32 -0
- package/dist/define-oracle.d.ts.map +1 -0
- package/dist/define-oracle.js +80 -0
- package/dist/define-oracle.js.map +1 -0
- package/dist/dev-oracle.d.ts +9 -0
- package/dist/dev-oracle.d.ts.map +1 -0
- package/dist/dev-oracle.js +19 -0
- package/dist/dev-oracle.js.map +1 -0
- package/dist/dev-worker.d.ts +10 -0
- package/dist/dev-worker.d.ts.map +1 -0
- package/dist/dev-worker.js +12 -0
- package/dist/dev-worker.js.map +1 -0
- package/dist/env.d.ts +146 -0
- package/dist/env.d.ts.map +1 -0
- package/dist/env.js +10 -0
- package/dist/env.js.map +1 -0
- package/dist/facts/exif.d.ts +43 -0
- package/dist/facts/exif.d.ts.map +1 -0
- package/dist/facts/exif.js +224 -0
- package/dist/facts/exif.js.map +1 -0
- package/dist/facts/fact.d.ts +62 -0
- package/dist/facts/fact.d.ts.map +1 -0
- package/dist/facts/fact.js +105 -0
- package/dist/facts/fact.js.map +1 -0
- package/dist/facts/geo.d.ts +55 -0
- package/dist/facts/geo.d.ts.map +1 -0
- package/dist/facts/geo.js +267 -0
- package/dist/facts/geo.js.map +1 -0
- package/dist/facts/index.d.ts +31 -0
- package/dist/facts/index.d.ts.map +1 -0
- package/dist/facts/index.js +27 -0
- package/dist/facts/index.js.map +1 -0
- package/dist/facts/linked-doc.d.ts +60 -0
- package/dist/facts/linked-doc.d.ts.map +1 -0
- package/dist/facts/linked-doc.js +101 -0
- package/dist/facts/linked-doc.js.map +1 -0
- package/dist/facts/types.d.ts +278 -0
- package/dist/facts/types.d.ts.map +1 -0
- package/dist/facts/types.js +19 -0
- package/dist/facts/types.js.map +1 -0
- package/dist/index.d.ts +25 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +19 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/api-lane/accept.d.ts +29 -0
- package/dist/lib/api-lane/accept.d.ts.map +1 -0
- package/dist/lib/api-lane/accept.js +218 -0
- package/dist/lib/api-lane/accept.js.map +1 -0
- package/dist/lib/api-lane/claim-list.d.ts +44 -0
- package/dist/lib/api-lane/claim-list.d.ts.map +1 -0
- package/dist/lib/api-lane/claim-list.js +92 -0
- package/dist/lib/api-lane/claim-list.js.map +1 -0
- package/dist/lib/api-lane/company.d.ts +56 -0
- package/dist/lib/api-lane/company.d.ts.map +1 -0
- package/dist/lib/api-lane/company.js +103 -0
- package/dist/lib/api-lane/company.js.map +1 -0
- package/dist/lib/api-lane/events.d.ts +21 -0
- package/dist/lib/api-lane/events.d.ts.map +1 -0
- package/dist/lib/api-lane/events.js +111 -0
- package/dist/lib/api-lane/events.js.map +1 -0
- package/dist/lib/api-lane/ids.d.ts +39 -0
- package/dist/lib/api-lane/ids.d.ts.map +1 -0
- package/dist/lib/api-lane/ids.js +78 -0
- package/dist/lib/api-lane/ids.js.map +1 -0
- package/dist/lib/api-lane/index.d.ts +16 -0
- package/dist/lib/api-lane/index.d.ts.map +1 -0
- package/dist/lib/api-lane/index.js +16 -0
- package/dist/lib/api-lane/index.js.map +1 -0
- package/dist/lib/api-lane/linked.d.ts +264 -0
- package/dist/lib/api-lane/linked.d.ts.map +1 -0
- package/dist/lib/api-lane/linked.js +272 -0
- package/dist/lib/api-lane/linked.js.map +1 -0
- package/dist/lib/api-lane/media-type.d.ts +15 -0
- package/dist/lib/api-lane/media-type.d.ts.map +1 -0
- package/dist/lib/api-lane/media-type.js +73 -0
- package/dist/lib/api-lane/media-type.js.map +1 -0
- package/dist/lib/api-lane/member-emails.d.ts +83 -0
- package/dist/lib/api-lane/member-emails.d.ts.map +1 -0
- package/dist/lib/api-lane/member-emails.js +213 -0
- package/dist/lib/api-lane/member-emails.js.map +1 -0
- package/dist/lib/api-lane/members.d.ts +42 -0
- package/dist/lib/api-lane/members.d.ts.map +1 -0
- package/dist/lib/api-lane/members.js +75 -0
- package/dist/lib/api-lane/members.js.map +1 -0
- package/dist/lib/api-lane/notify.d.ts +47 -0
- package/dist/lib/api-lane/notify.d.ts.map +1 -0
- package/dist/lib/api-lane/notify.js +240 -0
- package/dist/lib/api-lane/notify.js.map +1 -0
- package/dist/lib/api-lane/pause.d.ts +41 -0
- package/dist/lib/api-lane/pause.d.ts.map +1 -0
- package/dist/lib/api-lane/pause.js +155 -0
- package/dist/lib/api-lane/pause.js.map +1 -0
- package/dist/lib/api-lane/record.d.ts +76 -0
- package/dist/lib/api-lane/record.d.ts.map +1 -0
- package/dist/lib/api-lane/record.js +337 -0
- package/dist/lib/api-lane/record.js.map +1 -0
- package/dist/lib/api-lane/retention.d.ts +43 -0
- package/dist/lib/api-lane/retention.d.ts.map +1 -0
- package/dist/lib/api-lane/retention.js +176 -0
- package/dist/lib/api-lane/retention.js.map +1 -0
- package/dist/lib/api-lane/review.d.ts +76 -0
- package/dist/lib/api-lane/review.d.ts.map +1 -0
- package/dist/lib/api-lane/review.js +355 -0
- package/dist/lib/api-lane/review.js.map +1 -0
- package/dist/lib/api-lane/reviewers.d.ts +109 -0
- package/dist/lib/api-lane/reviewers.d.ts.map +1 -0
- package/dist/lib/api-lane/reviewers.js +755 -0
- package/dist/lib/api-lane/reviewers.js.map +1 -0
- package/dist/lib/api-lane/source-delete.d.ts +16 -0
- package/dist/lib/api-lane/source-delete.d.ts.map +1 -0
- package/dist/lib/api-lane/source-delete.js +50 -0
- package/dist/lib/api-lane/source-delete.js.map +1 -0
- package/dist/lib/api-lane/source.d.ts +19 -0
- package/dist/lib/api-lane/source.d.ts.map +1 -0
- package/dist/lib/api-lane/source.js +226 -0
- package/dist/lib/api-lane/source.js.map +1 -0
- package/dist/lib/api-lane/submitter.d.ts +22 -0
- package/dist/lib/api-lane/submitter.d.ts.map +1 -0
- package/dist/lib/api-lane/submitter.js +34 -0
- package/dist/lib/api-lane/submitter.js.map +1 -0
- package/dist/lib/api-lane/timeline.d.ts +20 -0
- package/dist/lib/api-lane/timeline.d.ts.map +1 -0
- package/dist/lib/api-lane/timeline.js +23 -0
- package/dist/lib/api-lane/timeline.js.map +1 -0
- package/dist/lib/api-lane/webhook-crypto.d.ts +44 -0
- package/dist/lib/api-lane/webhook-crypto.d.ts.map +1 -0
- package/dist/lib/api-lane/webhook-crypto.js +103 -0
- package/dist/lib/api-lane/webhook-crypto.js.map +1 -0
- package/dist/lib/api-lane/webhooks.d.ts +117 -0
- package/dist/lib/api-lane/webhooks.d.ts.map +1 -0
- package/dist/lib/api-lane/webhooks.js +503 -0
- package/dist/lib/api-lane/webhooks.js.map +1 -0
- package/dist/lib/archive.d.ts +64 -0
- package/dist/lib/archive.d.ts.map +1 -0
- package/dist/lib/archive.js +305 -0
- package/dist/lib/archive.js.map +1 -0
- package/dist/lib/bech32.d.ts +8 -0
- package/dist/lib/bech32.d.ts.map +1 -0
- package/dist/lib/bech32.js +39 -0
- package/dist/lib/bech32.js.map +1 -0
- package/dist/lib/claim-erase.d.ts +22 -0
- package/dist/lib/claim-erase.d.ts.map +1 -0
- package/dist/lib/claim-erase.js +44 -0
- package/dist/lib/claim-erase.js.map +1 -0
- package/dist/lib/cursor.d.ts +11 -0
- package/dist/lib/cursor.d.ts.map +1 -0
- package/dist/lib/cursor.js +20 -0
- package/dist/lib/cursor.js.map +1 -0
- package/dist/lib/email/send.d.ts +43 -0
- package/dist/lib/email/send.d.ts.map +1 -0
- package/dist/lib/email/send.js +71 -0
- package/dist/lib/email/send.js.map +1 -0
- package/dist/lib/email/template.d.ts +217 -0
- package/dist/lib/email/template.d.ts.map +1 -0
- package/dist/lib/email/template.js +713 -0
- package/dist/lib/email/template.js.map +1 -0
- package/dist/lib/engine/adr36.d.ts +56 -0
- package/dist/lib/engine/adr36.d.ts.map +1 -0
- package/dist/lib/engine/adr36.js +76 -0
- package/dist/lib/engine/adr36.js.map +1 -0
- package/dist/lib/engine/client.d.ts +162 -0
- package/dist/lib/engine/client.d.ts.map +1 -0
- package/dist/lib/engine/client.js +473 -0
- package/dist/lib/engine/client.js.map +1 -0
- package/dist/lib/engine/types.d.ts +1356 -0
- package/dist/lib/engine/types.d.ts.map +1 -0
- package/dist/lib/engine/types.js +562 -0
- package/dist/lib/engine/types.js.map +1 -0
- package/dist/lib/errors.d.ts +73 -0
- package/dist/lib/errors.d.ts.map +1 -0
- package/dist/lib/errors.js +96 -0
- package/dist/lib/errors.js.map +1 -0
- package/dist/lib/facts/builder.d.ts +88 -0
- package/dist/lib/facts/builder.d.ts.map +1 -0
- package/dist/lib/facts/builder.js +239 -0
- package/dist/lib/facts/builder.js.map +1 -0
- package/dist/lib/facts/ctx.d.ts +34 -0
- package/dist/lib/facts/ctx.d.ts.map +1 -0
- package/dist/lib/facts/ctx.js +51 -0
- package/dist/lib/facts/ctx.js.map +1 -0
- package/dist/lib/facts/expected.d.ts +23 -0
- package/dist/lib/facts/expected.d.ts.map +1 -0
- package/dist/lib/facts/expected.js +16 -0
- package/dist/lib/facts/expected.js.map +1 -0
- package/dist/lib/facts/fact-cache.d.ts +469 -0
- package/dist/lib/facts/fact-cache.d.ts.map +1 -0
- package/dist/lib/facts/fact-cache.js +52 -0
- package/dist/lib/facts/fact-cache.js.map +1 -0
- package/dist/lib/facts/factset.d.ts +608 -0
- package/dist/lib/facts/factset.d.ts.map +1 -0
- package/dist/lib/facts/factset.js +226 -0
- package/dist/lib/facts/factset.js.map +1 -0
- package/dist/lib/facts/producer.d.ts +190 -0
- package/dist/lib/facts/producer.d.ts.map +1 -0
- package/dist/lib/facts/producer.js +15 -0
- package/dist/lib/facts/producer.js.map +1 -0
- package/dist/lib/facts/runner.d.ts +111 -0
- package/dist/lib/facts/runner.d.ts.map +1 -0
- package/dist/lib/facts/runner.js +438 -0
- package/dist/lib/facts/runner.js.map +1 -0
- package/dist/lib/facts/stock/ai-check.d.ts +100 -0
- package/dist/lib/facts/stock/ai-check.d.ts.map +1 -0
- package/dist/lib/facts/stock/ai-check.js +526 -0
- package/dist/lib/facts/stock/ai-check.js.map +1 -0
- package/dist/lib/facts/stock/ai-inputs.d.ts +104 -0
- package/dist/lib/facts/stock/ai-inputs.d.ts.map +1 -0
- package/dist/lib/facts/stock/ai-inputs.js +332 -0
- package/dist/lib/facts/stock/ai-inputs.js.map +1 -0
- package/dist/lib/facts/stock/ai-provider.d.ts +105 -0
- package/dist/lib/facts/stock/ai-provider.d.ts.map +1 -0
- package/dist/lib/facts/stock/ai-provider.js +250 -0
- package/dist/lib/facts/stock/ai-provider.js.map +1 -0
- package/dist/lib/facts/stock/ai-unique.d.ts +85 -0
- package/dist/lib/facts/stock/ai-unique.d.ts.map +1 -0
- package/dist/lib/facts/stock/ai-unique.js +208 -0
- package/dist/lib/facts/stock/ai-unique.js.map +1 -0
- package/dist/lib/facts/stock/archive.d.ts +63 -0
- package/dist/lib/facts/stock/archive.d.ts.map +1 -0
- package/dist/lib/facts/stock/archive.js +349 -0
- package/dist/lib/facts/stock/archive.js.map +1 -0
- package/dist/lib/facts/stock/c2pa-trust-list.d.ts +16 -0
- package/dist/lib/facts/stock/c2pa-trust-list.d.ts.map +1 -0
- package/dist/lib/facts/stock/c2pa-trust-list.js +637 -0
- package/dist/lib/facts/stock/c2pa-trust-list.js.map +1 -0
- package/dist/lib/facts/stock/c2pa.d.ts +56 -0
- package/dist/lib/facts/stock/c2pa.d.ts.map +1 -0
- package/dist/lib/facts/stock/c2pa.js +234 -0
- package/dist/lib/facts/stock/c2pa.js.map +1 -0
- package/dist/lib/facts/stock/call.d.ts +91 -0
- package/dist/lib/facts/stock/call.d.ts.map +1 -0
- package/dist/lib/facts/stock/call.js +281 -0
- package/dist/lib/facts/stock/call.js.map +1 -0
- package/dist/lib/facts/stock/capability.d.ts +39 -0
- package/dist/lib/facts/stock/capability.d.ts.map +1 -0
- package/dist/lib/facts/stock/capability.js +59 -0
- package/dist/lib/facts/stock/capability.js.map +1 -0
- package/dist/lib/facts/stock/ext-source.d.ts +51 -0
- package/dist/lib/facts/stock/ext-source.d.ts.map +1 -0
- package/dist/lib/facts/stock/ext-source.js +201 -0
- package/dist/lib/facts/stock/ext-source.js.map +1 -0
- package/dist/lib/facts/stock/frequency-fact.d.ts +59 -0
- package/dist/lib/facts/stock/frequency-fact.d.ts.map +1 -0
- package/dist/lib/facts/stock/frequency-fact.js +86 -0
- package/dist/lib/facts/stock/frequency-fact.js.map +1 -0
- package/dist/lib/facts/stock/frequency.d.ts +32 -0
- package/dist/lib/facts/stock/frequency.d.ts.map +1 -0
- package/dist/lib/facts/stock/frequency.js +48 -0
- package/dist/lib/facts/stock/frequency.js.map +1 -0
- package/dist/lib/facts/stock/index.d.ts +27 -0
- package/dist/lib/facts/stock/index.d.ts.map +1 -0
- package/dist/lib/facts/stock/index.js +28 -0
- package/dist/lib/facts/stock/index.js.map +1 -0
- package/dist/lib/facts/stock/normalize.d.ts +45 -0
- package/dist/lib/facts/stock/normalize.d.ts.map +1 -0
- package/dist/lib/facts/stock/normalize.js +135 -0
- package/dist/lib/facts/stock/normalize.js.map +1 -0
- package/dist/lib/facts/stock/phash.d.ts +55 -0
- package/dist/lib/facts/stock/phash.d.ts.map +1 -0
- package/dist/lib/facts/stock/phash.js +256 -0
- package/dist/lib/facts/stock/phash.js.map +1 -0
- package/dist/lib/facts/stock/rule-defaults.d.ts +72 -0
- package/dist/lib/facts/stock/rule-defaults.d.ts.map +1 -0
- package/dist/lib/facts/stock/rule-defaults.js +55 -0
- package/dist/lib/facts/stock/rule-defaults.js.map +1 -0
- package/dist/lib/facts/stock/send.d.ts +52 -0
- package/dist/lib/facts/stock/send.d.ts.map +1 -0
- package/dist/lib/facts/stock/send.js +148 -0
- package/dist/lib/facts/stock/send.js.map +1 -0
- package/dist/lib/facts/stock/unique-score.d.ts +138 -0
- package/dist/lib/facts/stock/unique-score.d.ts.map +1 -0
- package/dist/lib/facts/stock/unique-score.js +257 -0
- package/dist/lib/facts/stock/unique-score.js.map +1 -0
- package/dist/lib/facts/stock/unique-store.d.ts +420 -0
- package/dist/lib/facts/stock/unique-store.d.ts.map +1 -0
- package/dist/lib/facts/stock/unique-store.js +328 -0
- package/dist/lib/facts/stock/unique-store.js.map +1 -0
- package/dist/lib/facts/stock/unique.d.ts +35 -0
- package/dist/lib/facts/stock/unique.d.ts.map +1 -0
- package/dist/lib/facts/stock/unique.js +327 -0
- package/dist/lib/facts/stock/unique.js.map +1 -0
- package/dist/lib/facts/tools.d.ts +57 -0
- package/dist/lib/facts/tools.d.ts.map +1 -0
- package/dist/lib/facts/tools.js +325 -0
- package/dist/lib/facts/tools.js.map +1 -0
- package/dist/lib/facts/validate.d.ts +33 -0
- package/dist/lib/facts/validate.d.ts.map +1 -0
- package/dist/lib/facts/validate.js +137 -0
- package/dist/lib/facts/validate.js.map +1 -0
- package/dist/lib/hash.d.ts +44 -0
- package/dist/lib/hash.d.ts.map +1 -0
- package/dist/lib/hash.js +80 -0
- package/dist/lib/hash.js.map +1 -0
- package/dist/lib/http/client.d.ts +113 -0
- package/dist/lib/http/client.d.ts.map +1 -0
- package/dist/lib/http/client.js +330 -0
- package/dist/lib/http/client.js.map +1 -0
- package/dist/lib/ids.d.ts +17 -0
- package/dist/lib/ids.d.ts.map +1 -0
- package/dist/lib/ids.js +26 -0
- package/dist/lib/ids.js.map +1 -0
- package/dist/lib/ixo/attachments.d.ts +116 -0
- package/dist/lib/ixo/attachments.d.ts.map +1 -0
- package/dist/lib/ixo/attachments.js +290 -0
- package/dist/lib/ixo/attachments.js.map +1 -0
- package/dist/lib/ixo/authz.d.ts +40 -0
- package/dist/lib/ixo/authz.d.ts.map +1 -0
- package/dist/lib/ixo/authz.js +113 -0
- package/dist/lib/ixo/authz.js.map +1 -0
- package/dist/lib/ixo/blocksync/index.d.ts +90 -0
- package/dist/lib/ixo/blocksync/index.d.ts.map +1 -0
- package/dist/lib/ixo/blocksync/index.js +251 -0
- package/dist/lib/ixo/blocksync/index.js.map +1 -0
- package/dist/lib/ixo/blocksync/queries.d.ts +15 -0
- package/dist/lib/ixo/blocksync/queries.d.ts.map +1 -0
- package/dist/lib/ixo/blocksync/queries.js +144 -0
- package/dist/lib/ixo/blocksync/queries.js.map +1 -0
- package/dist/lib/ixo/blocksync/types.d.ts +184 -0
- package/dist/lib/ixo/blocksync/types.d.ts.map +1 -0
- package/dist/lib/ixo/blocksync/types.js +108 -0
- package/dist/lib/ixo/blocksync/types.js.map +1 -0
- package/dist/lib/ixo/cellnode.d.ts +35 -0
- package/dist/lib/ixo/cellnode.d.ts.map +1 -0
- package/dist/lib/ixo/cellnode.js +43 -0
- package/dist/lib/ixo/cellnode.js.map +1 -0
- package/dist/lib/ixo/chain-write.d.ts +130 -0
- package/dist/lib/ixo/chain-write.d.ts.map +1 -0
- package/dist/lib/ixo/chain-write.js +460 -0
- package/dist/lib/ixo/chain-write.js.map +1 -0
- package/dist/lib/ixo/chain.d.ts +1046 -0
- package/dist/lib/ixo/chain.d.ts.map +1 -0
- package/dist/lib/ixo/chain.js +279 -0
- package/dist/lib/ixo/chain.js.map +1 -0
- package/dist/lib/ixo/claim-bot.d.ts +49 -0
- package/dist/lib/ixo/claim-bot.d.ts.map +1 -0
- package/dist/lib/ixo/claim-bot.js +141 -0
- package/dist/lib/ixo/claim-bot.js.map +1 -0
- package/dist/lib/ixo/delegation-verify.d.ts +44 -0
- package/dist/lib/ixo/delegation-verify.d.ts.map +1 -0
- package/dist/lib/ixo/delegation-verify.js +101 -0
- package/dist/lib/ixo/delegation-verify.js.map +1 -0
- package/dist/lib/ixo/did.d.ts +13 -0
- package/dist/lib/ixo/did.d.ts.map +1 -0
- package/dist/lib/ixo/did.js +85 -0
- package/dist/lib/ixo/did.js.map +1 -0
- package/dist/lib/ixo/grant-chain.d.ts +55 -0
- package/dist/lib/ixo/grant-chain.d.ts.map +1 -0
- package/dist/lib/ixo/grant-chain.js +185 -0
- package/dist/lib/ixo/grant-chain.js.map +1 -0
- package/dist/lib/ixo/identity.d.ts +32 -0
- package/dist/lib/ixo/identity.d.ts.map +1 -0
- package/dist/lib/ixo/identity.js +104 -0
- package/dist/lib/ixo/identity.js.map +1 -0
- package/dist/lib/ixo/index.d.ts +118 -0
- package/dist/lib/ixo/index.d.ts.map +1 -0
- package/dist/lib/ixo/index.js +395 -0
- package/dist/lib/ixo/index.js.map +1 -0
- package/dist/lib/ixo/payment.d.ts +104 -0
- package/dist/lib/ixo/payment.d.ts.map +1 -0
- package/dist/lib/ixo/payment.js +136 -0
- package/dist/lib/ixo/payment.js.map +1 -0
- package/dist/lib/ixo/ucan-store.d.ts +30 -0
- package/dist/lib/ixo/ucan-store.d.ts.map +1 -0
- package/dist/lib/ixo/ucan-store.js +134 -0
- package/dist/lib/ixo/ucan-store.js.map +1 -0
- package/dist/lib/ixo/ucan.d.ts +96 -0
- package/dist/lib/ixo/ucan.d.ts.map +1 -0
- package/dist/lib/ixo/ucan.js +216 -0
- package/dist/lib/ixo/ucan.js.map +1 -0
- package/dist/lib/ixo/verified-read.d.ts +43 -0
- package/dist/lib/ixo/verified-read.d.ts.map +1 -0
- package/dist/lib/ixo/verified-read.js +73 -0
- package/dist/lib/ixo/verified-read.js.map +1 -0
- package/dist/lib/ixo/vfs.d.ts +27 -0
- package/dist/lib/ixo/vfs.d.ts.map +1 -0
- package/dist/lib/ixo/vfs.js +42 -0
- package/dist/lib/ixo/vfs.js.map +1 -0
- package/dist/lib/ixo/web-did.d.ts +7 -0
- package/dist/lib/ixo/web-did.d.ts.map +1 -0
- package/dist/lib/ixo/web-did.js +9 -0
- package/dist/lib/ixo/web-did.js.map +1 -0
- package/dist/lib/logger.d.ts +34 -0
- package/dist/lib/logger.d.ts.map +1 -0
- package/dist/lib/logger.js +126 -0
- package/dist/lib/logger.js.map +1 -0
- package/dist/lib/matrix/api.d.ts +57 -0
- package/dist/lib/matrix/api.d.ts.map +1 -0
- package/dist/lib/matrix/api.js +58 -0
- package/dist/lib/matrix/api.js.map +1 -0
- package/dist/lib/matrix/client.d.ts +41 -0
- package/dist/lib/matrix/client.d.ts.map +1 -0
- package/dist/lib/matrix/client.js +104 -0
- package/dist/lib/matrix/client.js.map +1 -0
- package/dist/lib/matrix/deliver.d.ts +224 -0
- package/dist/lib/matrix/deliver.d.ts.map +1 -0
- package/dist/lib/matrix/deliver.js +788 -0
- package/dist/lib/matrix/deliver.js.map +1 -0
- package/dist/lib/matrix/events.d.ts +114 -0
- package/dist/lib/matrix/events.d.ts.map +1 -0
- package/dist/lib/matrix/events.js +143 -0
- package/dist/lib/matrix/events.js.map +1 -0
- package/dist/lib/matrix/mxid.d.ts +24 -0
- package/dist/lib/matrix/mxid.d.ts.map +1 -0
- package/dist/lib/matrix/mxid.js +47 -0
- package/dist/lib/matrix/mxid.js.map +1 -0
- package/dist/lib/metrics.d.ts +105 -0
- package/dist/lib/metrics.d.ts.map +1 -0
- package/dist/lib/metrics.js +204 -0
- package/dist/lib/metrics.js.map +1 -0
- package/dist/lib/oauth/approvals.d.ts +160 -0
- package/dist/lib/oauth/approvals.d.ts.map +1 -0
- package/dist/lib/oauth/approvals.js +273 -0
- package/dist/lib/oauth/approvals.js.map +1 -0
- package/dist/lib/oauth/standing.d.ts +152 -0
- package/dist/lib/oauth/standing.d.ts.map +1 -0
- package/dist/lib/oauth/standing.js +299 -0
- package/dist/lib/oauth/standing.js.map +1 -0
- package/dist/lib/oauth/token.d.ts +60 -0
- package/dist/lib/oauth/token.d.ts.map +1 -0
- package/dist/lib/oauth/token.js +129 -0
- package/dist/lib/oauth/token.js.map +1 -0
- package/dist/lib/payments/extend.d.ts +42 -0
- package/dist/lib/payments/extend.d.ts.map +1 -0
- package/dist/lib/payments/extend.js +98 -0
- package/dist/lib/payments/extend.js.map +1 -0
- package/dist/lib/payments/facilitator.d.ts +220 -0
- package/dist/lib/payments/facilitator.d.ts.map +1 -0
- package/dist/lib/payments/facilitator.js +451 -0
- package/dist/lib/payments/facilitator.js.map +1 -0
- package/dist/lib/payments/gate.d.ts +207 -0
- package/dist/lib/payments/gate.d.ts.map +1 -0
- package/dist/lib/payments/gate.js +481 -0
- package/dist/lib/payments/gate.js.map +1 -0
- package/dist/lib/payments/header-seal.d.ts +33 -0
- package/dist/lib/payments/header-seal.d.ts.map +1 -0
- package/dist/lib/payments/header-seal.js +76 -0
- package/dist/lib/payments/header-seal.js.map +1 -0
- package/dist/lib/payments/index.d.ts +12 -0
- package/dist/lib/payments/index.d.ts.map +1 -0
- package/dist/lib/payments/index.js +11 -0
- package/dist/lib/payments/index.js.map +1 -0
- package/dist/lib/payments/price.d.ts +25 -0
- package/dist/lib/payments/price.d.ts.map +1 -0
- package/dist/lib/payments/price.js +43 -0
- package/dist/lib/payments/price.js.map +1 -0
- package/dist/lib/payments/reconcile.d.ts +77 -0
- package/dist/lib/payments/reconcile.d.ts.map +1 -0
- package/dist/lib/payments/reconcile.js +317 -0
- package/dist/lib/payments/reconcile.js.map +1 -0
- package/dist/lib/payments/refund.d.ts +34 -0
- package/dist/lib/payments/refund.d.ts.map +1 -0
- package/dist/lib/payments/refund.js +123 -0
- package/dist/lib/payments/refund.js.map +1 -0
- package/dist/lib/payments/review-billing.d.ts +222 -0
- package/dist/lib/payments/review-billing.d.ts.map +1 -0
- package/dist/lib/payments/review-billing.js +609 -0
- package/dist/lib/payments/review-billing.js.map +1 -0
- package/dist/lib/payments/settle.d.ts +44 -0
- package/dist/lib/payments/settle.d.ts.map +1 -0
- package/dist/lib/payments/settle.js +306 -0
- package/dist/lib/payments/settle.js.map +1 -0
- package/dist/lib/payments/terms.d.ts +27 -0
- package/dist/lib/payments/terms.d.ts.map +1 -0
- package/dist/lib/payments/terms.js +21 -0
- package/dist/lib/payments/terms.js.map +1 -0
- package/dist/lib/payouts.d.ts +20 -0
- package/dist/lib/payouts.d.ts.map +1 -0
- package/dist/lib/payouts.js +30 -0
- package/dist/lib/payouts.js.map +1 -0
- package/dist/lib/readiness.d.ts +42 -0
- package/dist/lib/readiness.d.ts.map +1 -0
- package/dist/lib/readiness.js +130 -0
- package/dist/lib/readiness.js.map +1 -0
- package/dist/lib/redact.d.ts +23 -0
- package/dist/lib/redact.d.ts.map +1 -0
- package/dist/lib/redact.js +67 -0
- package/dist/lib/redact.js.map +1 -0
- package/dist/lib/register.d.ts +85 -0
- package/dist/lib/register.d.ts.map +1 -0
- package/dist/lib/register.js +390 -0
- package/dist/lib/register.js.map +1 -0
- package/dist/lib/review/attestation.d.ts +92 -0
- package/dist/lib/review/attestation.d.ts.map +1 -0
- package/dist/lib/review/attestation.js +264 -0
- package/dist/lib/review/attestation.js.map +1 -0
- package/dist/lib/review/reviewer-grant.d.ts +146 -0
- package/dist/lib/review/reviewer-grant.d.ts.map +1 -0
- package/dist/lib/review/reviewer-grant.js +359 -0
- package/dist/lib/review/reviewer-grant.js.map +1 -0
- package/dist/lib/review/tasks.d.ts +18 -0
- package/dist/lib/review/tasks.d.ts.map +1 -0
- package/dist/lib/review/tasks.js +36 -0
- package/dist/lib/review/tasks.js.map +1 -0
- package/dist/lib/sentry.d.ts +89 -0
- package/dist/lib/sentry.d.ts.map +1 -0
- package/dist/lib/sentry.js +284 -0
- package/dist/lib/sentry.js.map +1 -0
- package/dist/lib/spans.d.ts +14 -0
- package/dist/lib/spans.d.ts.map +1 -0
- package/dist/lib/spans.js +28 -0
- package/dist/lib/spans.js.map +1 -0
- package/dist/lib/tracing.d.ts +31 -0
- package/dist/lib/tracing.d.ts.map +1 -0
- package/dist/lib/tracing.js +66 -0
- package/dist/lib/tracing.js.map +1 -0
- package/dist/lib/ttl-cache.d.ts +26 -0
- package/dist/lib/ttl-cache.d.ts.map +1 -0
- package/dist/lib/ttl-cache.js +61 -0
- package/dist/lib/ttl-cache.js.map +1 -0
- package/dist/lib/validator.d.ts +19 -0
- package/dist/lib/validator.d.ts.map +1 -0
- package/dist/lib/validator.js +32 -0
- package/dist/lib/validator.js.map +1 -0
- package/dist/lib/work-order/form.d.ts +40 -0
- package/dist/lib/work-order/form.d.ts.map +1 -0
- package/dist/lib/work-order/form.js +316 -0
- package/dist/lib/work-order/form.js.map +1 -0
- package/dist/lib/work-order/index.d.ts +20 -0
- package/dist/lib/work-order/index.d.ts.map +1 -0
- package/dist/lib/work-order/index.js +66 -0
- package/dist/lib/work-order/index.js.map +1 -0
- package/dist/middleware/api/audit.d.ts +9 -0
- package/dist/middleware/api/audit.d.ts.map +1 -0
- package/dist/middleware/api/audit.js +38 -0
- package/dist/middleware/api/audit.js.map +1 -0
- package/dist/middleware/api/auth.d.ts +29 -0
- package/dist/middleware/api/auth.d.ts.map +1 -0
- package/dist/middleware/api/auth.js +105 -0
- package/dist/middleware/api/auth.js.map +1 -0
- package/dist/middleware/api/console.d.ts +92 -0
- package/dist/middleware/api/console.d.ts.map +1 -0
- package/dist/middleware/api/console.js +446 -0
- package/dist/middleware/api/console.js.map +1 -0
- package/dist/middleware/api/errors.d.ts +48 -0
- package/dist/middleware/api/errors.d.ts.map +1 -0
- package/dist/middleware/api/errors.js +133 -0
- package/dist/middleware/api/errors.js.map +1 -0
- package/dist/middleware/api/idempotency.d.ts +23 -0
- package/dist/middleware/api/idempotency.d.ts.map +1 -0
- package/dist/middleware/api/idempotency.js +158 -0
- package/dist/middleware/api/idempotency.js.map +1 -0
- package/dist/middleware/api/keys.d.ts +14 -0
- package/dist/middleware/api/keys.d.ts.map +1 -0
- package/dist/middleware/api/keys.js +66 -0
- package/dist/middleware/api/keys.js.map +1 -0
- package/dist/middleware/api/membership.d.ts +32 -0
- package/dist/middleware/api/membership.d.ts.map +1 -0
- package/dist/middleware/api/membership.js +48 -0
- package/dist/middleware/api/membership.js.map +1 -0
- package/dist/middleware/api/oauth.d.ts +28 -0
- package/dist/middleware/api/oauth.d.ts.map +1 -0
- package/dist/middleware/api/oauth.js +109 -0
- package/dist/middleware/api/oauth.js.map +1 -0
- package/dist/middleware/api/rate-limit.d.ts +23 -0
- package/dist/middleware/api/rate-limit.d.ts.map +1 -0
- package/dist/middleware/api/rate-limit.js +70 -0
- package/dist/middleware/api/rate-limit.js.map +1 -0
- package/dist/middleware/api/types.d.ts +92 -0
- package/dist/middleware/api/types.d.ts.map +1 -0
- package/dist/middleware/api/types.js +7 -0
- package/dist/middleware/api/types.js.map +1 -0
- package/dist/middleware/api/wait.d.ts +21 -0
- package/dist/middleware/api/wait.d.ts.map +1 -0
- package/dist/middleware/api/wait.js +85 -0
- package/dist/middleware/api/wait.js.map +1 -0
- package/dist/middleware/capability.d.ts +32 -0
- package/dist/middleware/capability.d.ts.map +1 -0
- package/dist/middleware/capability.js +113 -0
- package/dist/middleware/capability.js.map +1 -0
- package/dist/middleware/database.d.ts +14 -0
- package/dist/middleware/database.d.ts.map +1 -0
- package/dist/middleware/database.js +18 -0
- package/dist/middleware/database.js.map +1 -0
- package/dist/middleware/error-handler.d.ts +13 -0
- package/dist/middleware/error-handler.d.ts.map +1 -0
- package/dist/middleware/error-handler.js +127 -0
- package/dist/middleware/error-handler.js.map +1 -0
- package/dist/middleware/observability.d.ts +32 -0
- package/dist/middleware/observability.d.ts.map +1 -0
- package/dist/middleware/observability.js +134 -0
- package/dist/middleware/observability.js.map +1 -0
- package/dist/middleware/rate-limit.d.ts +16 -0
- package/dist/middleware/rate-limit.d.ts.map +1 -0
- package/dist/middleware/rate-limit.js +56 -0
- package/dist/middleware/rate-limit.js.map +1 -0
- package/dist/middleware/ucan-auth.d.ts +39 -0
- package/dist/middleware/ucan-auth.d.ts.map +1 -0
- package/dist/middleware/ucan-auth.js +278 -0
- package/dist/middleware/ucan-auth.js.map +1 -0
- package/dist/networks.d.ts +34 -0
- package/dist/networks.d.ts.map +1 -0
- package/dist/networks.js +49 -0
- package/dist/networks.js.map +1 -0
- package/dist/oracle.d.ts +193 -0
- package/dist/oracle.d.ts.map +1 -0
- package/dist/oracle.js +245 -0
- package/dist/oracle.js.map +1 -0
- package/dist/routes/health.d.ts +16 -0
- package/dist/routes/health.d.ts.map +1 -0
- package/dist/routes/health.js +29 -0
- package/dist/routes/health.js.map +1 -0
- package/dist/routes/v1/admin.d.ts +18 -0
- package/dist/routes/v1/admin.d.ts.map +1 -0
- package/dist/routes/v1/admin.js +101 -0
- package/dist/routes/v1/admin.js.map +1 -0
- package/dist/routes/v1/api/admin-claims.d.ts +14 -0
- package/dist/routes/v1/api/admin-claims.d.ts.map +1 -0
- package/dist/routes/v1/api/admin-claims.js +82 -0
- package/dist/routes/v1/api/admin-claims.js.map +1 -0
- package/dist/routes/v1/api/admin-facilitator.d.ts +20 -0
- package/dist/routes/v1/api/admin-facilitator.d.ts.map +1 -0
- package/dist/routes/v1/api/admin-facilitator.js +64 -0
- package/dist/routes/v1/api/admin-facilitator.js.map +1 -0
- package/dist/routes/v1/api/admin.d.ts +9 -0
- package/dist/routes/v1/api/admin.d.ts.map +1 -0
- package/dist/routes/v1/api/admin.js +110 -0
- package/dist/routes/v1/api/admin.js.map +1 -0
- package/dist/routes/v1/api/audit.d.ts +8 -0
- package/dist/routes/v1/api/audit.d.ts.map +1 -0
- package/dist/routes/v1/api/audit.js +56 -0
- package/dist/routes/v1/api/audit.js.map +1 -0
- package/dist/routes/v1/api/batch.d.ts +17 -0
- package/dist/routes/v1/api/batch.d.ts.map +1 -0
- package/dist/routes/v1/api/batch.js +192 -0
- package/dist/routes/v1/api/batch.js.map +1 -0
- package/dist/routes/v1/api/claims-read.d.ts +43 -0
- package/dist/routes/v1/api/claims-read.d.ts.map +1 -0
- package/dist/routes/v1/api/claims-read.js +123 -0
- package/dist/routes/v1/api/claims-read.js.map +1 -0
- package/dist/routes/v1/api/claims.d.ts +131 -0
- package/dist/routes/v1/api/claims.d.ts.map +1 -0
- package/dist/routes/v1/api/claims.js +407 -0
- package/dist/routes/v1/api/claims.js.map +1 -0
- package/dist/routes/v1/api/collections-link.d.ts +14 -0
- package/dist/routes/v1/api/collections-link.d.ts.map +1 -0
- package/dist/routes/v1/api/collections-link.js +97 -0
- package/dist/routes/v1/api/collections-link.js.map +1 -0
- package/dist/routes/v1/api/export.d.ts +48 -0
- package/dist/routes/v1/api/export.d.ts.map +1 -0
- package/dist/routes/v1/api/export.js +251 -0
- package/dist/routes/v1/api/export.js.map +1 -0
- package/dist/routes/v1/api/index.d.ts +16 -0
- package/dist/routes/v1/api/index.d.ts.map +1 -0
- package/dist/routes/v1/api/index.js +68 -0
- package/dist/routes/v1/api/index.js.map +1 -0
- package/dist/routes/v1/api/keys.d.ts +9 -0
- package/dist/routes/v1/api/keys.d.ts.map +1 -0
- package/dist/routes/v1/api/keys.js +95 -0
- package/dist/routes/v1/api/keys.js.map +1 -0
- package/dist/routes/v1/api/me.d.ts +21 -0
- package/dist/routes/v1/api/me.d.ts.map +1 -0
- package/dist/routes/v1/api/me.js +122 -0
- package/dist/routes/v1/api/me.js.map +1 -0
- package/dist/routes/v1/api/members.d.ts +17 -0
- package/dist/routes/v1/api/members.d.ts.map +1 -0
- package/dist/routes/v1/api/members.js +406 -0
- package/dist/routes/v1/api/members.js.map +1 -0
- package/dist/routes/v1/api/meta.d.ts +12 -0
- package/dist/routes/v1/api/meta.d.ts.map +1 -0
- package/dist/routes/v1/api/meta.js +59 -0
- package/dist/routes/v1/api/meta.js.map +1 -0
- package/dist/routes/v1/api/openapi.gen.d.ts +2 -0
- package/dist/routes/v1/api/openapi.gen.d.ts.map +1 -0
- package/dist/routes/v1/api/openapi.gen.js +7 -0
- package/dist/routes/v1/api/openapi.gen.js.map +1 -0
- package/dist/routes/v1/api/protocols.d.ts +22 -0
- package/dist/routes/v1/api/protocols.d.ts.map +1 -0
- package/dist/routes/v1/api/protocols.js +153 -0
- package/dist/routes/v1/api/protocols.js.map +1 -0
- package/dist/routes/v1/api/review-billing.d.ts +18 -0
- package/dist/routes/v1/api/review-billing.d.ts.map +1 -0
- package/dist/routes/v1/api/review-billing.js +196 -0
- package/dist/routes/v1/api/review-billing.js.map +1 -0
- package/dist/routes/v1/api/review.d.ts +30 -0
- package/dist/routes/v1/api/review.d.ts.map +1 -0
- package/dist/routes/v1/api/review.js +302 -0
- package/dist/routes/v1/api/review.js.map +1 -0
- package/dist/routes/v1/api/sources.d.ts +10 -0
- package/dist/routes/v1/api/sources.d.ts.map +1 -0
- package/dist/routes/v1/api/sources.js +293 -0
- package/dist/routes/v1/api/sources.js.map +1 -0
- package/dist/routes/v1/api/uploads.d.ts +37 -0
- package/dist/routes/v1/api/uploads.d.ts.map +1 -0
- package/dist/routes/v1/api/uploads.js +414 -0
- package/dist/routes/v1/api/uploads.js.map +1 -0
- package/dist/routes/v1/api/views.d.ts +18 -0
- package/dist/routes/v1/api/views.d.ts.map +1 -0
- package/dist/routes/v1/api/views.js +95 -0
- package/dist/routes/v1/api/views.js.map +1 -0
- package/dist/routes/v1/api/webhooks.d.ts +14 -0
- package/dist/routes/v1/api/webhooks.d.ts.map +1 -0
- package/dist/routes/v1/api/webhooks.js +282 -0
- package/dist/routes/v1/api/webhooks.js.map +1 -0
- package/dist/routes/v1/api/work-orders.d.ts +45 -0
- package/dist/routes/v1/api/work-orders.d.ts.map +1 -0
- package/dist/routes/v1/api/work-orders.js +171 -0
- package/dist/routes/v1/api/work-orders.js.map +1 -0
- package/dist/routes/v1/claims.d.ts +21 -0
- package/dist/routes/v1/claims.d.ts.map +1 -0
- package/dist/routes/v1/claims.js +153 -0
- package/dist/routes/v1/claims.js.map +1 -0
- package/dist/routes/v1/collections.d.ts +45 -0
- package/dist/routes/v1/collections.d.ts.map +1 -0
- package/dist/routes/v1/collections.js +201 -0
- package/dist/routes/v1/collections.js.map +1 -0
- package/dist/routes/v1/index.d.ts +13 -0
- package/dist/routes/v1/index.d.ts.map +1 -0
- package/dist/routes/v1/index.js +41 -0
- package/dist/routes/v1/index.js.map +1 -0
- package/dist/routes/v1/info.d.ts +14 -0
- package/dist/routes/v1/info.d.ts.map +1 -0
- package/dist/routes/v1/info.js +75 -0
- package/dist/routes/v1/info.js.map +1 -0
- package/dist/routes/v1/mcp/index.d.ts +33 -0
- package/dist/routes/v1/mcp/index.d.ts.map +1 -0
- package/dist/routes/v1/mcp/index.js +252 -0
- package/dist/routes/v1/mcp/index.js.map +1 -0
- package/dist/routes/v1/mcp/oauth.d.ts +27 -0
- package/dist/routes/v1/mcp/oauth.d.ts.map +1 -0
- package/dist/routes/v1/mcp/oauth.js +500 -0
- package/dist/routes/v1/mcp/oauth.js.map +1 -0
- package/dist/routes/v1/mcp/tools.d.ts +71 -0
- package/dist/routes/v1/mcp/tools.d.ts.map +1 -0
- package/dist/routes/v1/mcp/tools.js +432 -0
- package/dist/routes/v1/mcp/tools.js.map +1 -0
- package/dist/routes/v1/mcp/ui.d.ts +45 -0
- package/dist/routes/v1/mcp/ui.d.ts.map +1 -0
- package/dist/routes/v1/mcp/ui.js +454 -0
- package/dist/routes/v1/mcp/ui.js.map +1 -0
- package/dist/routes/v1/oauth.d.ts +29 -0
- package/dist/routes/v1/oauth.d.ts.map +1 -0
- package/dist/routes/v1/oauth.js +256 -0
- package/dist/routes/v1/oauth.js.map +1 -0
- package/dist/routes/v1/reviewers.d.ts +22 -0
- package/dist/routes/v1/reviewers.d.ts.map +1 -0
- package/dist/routes/v1/reviewers.js +165 -0
- package/dist/routes/v1/reviewers.js.map +1 -0
- package/dist/routes/v1/reviews.d.ts +38 -0
- package/dist/routes/v1/reviews.d.ts.map +1 -0
- package/dist/routes/v1/reviews.js +234 -0
- package/dist/routes/v1/reviews.js.map +1 -0
- package/dist/routes/v1/shared.d.ts +586 -0
- package/dist/routes/v1/shared.d.ts.map +1 -0
- package/dist/routes/v1/shared.js +229 -0
- package/dist/routes/v1/shared.js.map +1 -0
- package/dist/routes/well-known.d.ts +15 -0
- package/dist/routes/well-known.d.ts.map +1 -0
- package/dist/routes/well-known.js +35 -0
- package/dist/routes/well-known.js.map +1 -0
- package/dist/runtime.d.ts +100 -0
- package/dist/runtime.d.ts.map +1 -0
- package/dist/runtime.js +144 -0
- package/dist/runtime.js.map +1 -0
- package/dist/testing/fake-tools.d.ts +104 -0
- package/dist/testing/fake-tools.d.ts.map +1 -0
- package/dist/testing/fake-tools.js +213 -0
- package/dist/testing/fake-tools.js.map +1 -0
- package/dist/testing/index.d.ts +54 -0
- package/dist/testing/index.d.ts.map +1 -0
- package/dist/testing/index.js +104 -0
- package/dist/testing/index.js.map +1 -0
- package/dist/testing/samples.d.ts +70 -0
- package/dist/testing/samples.d.ts.map +1 -0
- package/dist/testing/samples.js +92 -0
- package/dist/testing/samples.js.map +1 -0
- package/dist/workflows/claim-ingest.d.ts +250 -0
- package/dist/workflows/claim-ingest.d.ts.map +1 -0
- package/dist/workflows/claim-ingest.js +1020 -0
- package/dist/workflows/claim-ingest.js.map +1 -0
- package/dist/workflows/claim-source.d.ts +25 -0
- package/dist/workflows/claim-source.d.ts.map +1 -0
- package/dist/workflows/claim-source.js +107 -0
- package/dist/workflows/claim-source.js.map +1 -0
- package/dist/workflows/review-complete.d.ts +82 -0
- package/dist/workflows/review-complete.d.ts.map +1 -0
- package/dist/workflows/review-complete.js +455 -0
- package/dist/workflows/review-complete.js.map +1 -0
- package/dist/workflows/steps.d.ts +125 -0
- package/dist/workflows/steps.d.ts.map +1 -0
- package/dist/workflows/steps.js +325 -0
- package/dist/workflows/steps.js.map +1 -0
- package/docs/api.md +2595 -0
- package/docs/guide.md +1525 -0
- package/migrations/0000_init.sql +108 -0
- package/migrations/0001_review_attestation.sql +1 -0
- package/migrations/0002_decisions_facts.sql +1 -0
- package/migrations/0003_api_lane.sql +171 -0
- package/migrations/0004_api_v1_1.sql +19 -0
- package/migrations/0005_member_notify.sql +3 -0
- package/migrations/0006_source_collections.sql +16 -0
- package/migrations/0007_api_settlement.sql +27 -0
- package/migrations/0008_review_extend.sql +1 -0
- package/migrations/0009_card_refunds.sql +4 -0
- package/migrations/0010_even_scorpion.sql +16 -0
- package/migrations/0011_mcp_oauth.sql +27 -0
- package/migrations/0012_mcp_standing.sql +21 -0
- package/migrations/0013_unknown_krista_starr.sql +2 -0
- package/migrations/0014_last_carnage.sql +14 -0
- package/migrations/0015_company_authority.sql +26 -0
- package/migrations/0016_owner_only_links.sql +6 -0
- package/migrations/0017_organisations.sql +35 -0
- package/migrations/0018_remove_app_signed.sql +4 -0
- package/migrations/0019_submitted_via.sql +2 -0
- package/migrations/0020_drop_decision_to_pay.sql +4 -0
- package/migrations/0021_manual_erase.sql +25 -0
- package/migrations/0022_errored_facts.sql +1 -0
- package/migrations/0023_review_billing.sql +20 -0
- package/migrations/0024_pending_task_details.sql +1 -0
- package/migrations/meta/0000_snapshot.json +707 -0
- package/migrations/meta/0001_snapshot.json +714 -0
- package/migrations/meta/0002_snapshot.json +721 -0
- package/migrations/meta/0003_snapshot.json +1845 -0
- package/migrations/meta/0004_snapshot.json +1969 -0
- package/migrations/meta/0005_snapshot.json +1991 -0
- package/migrations/meta/0006_snapshot.json +2097 -0
- package/migrations/meta/0007_snapshot.json +2128 -0
- package/migrations/meta/0008_snapshot.json +2133 -0
- package/migrations/meta/0009_snapshot.json +2161 -0
- package/migrations/meta/0010_snapshot.json +2265 -0
- package/migrations/meta/0011_snapshot.json +2448 -0
- package/migrations/meta/0012_snapshot.json +2577 -0
- package/migrations/meta/0013_snapshot.json +2594 -0
- package/migrations/meta/0014_snapshot.json +2602 -0
- package/migrations/meta/0015_snapshot.json +2778 -0
- package/migrations/meta/0016_snapshot.json +2778 -0
- package/migrations/meta/0017_snapshot.json +2792 -0
- package/migrations/meta/0018_snapshot.json +2778 -0
- package/migrations/meta/0019_snapshot.json +2792 -0
- package/migrations/meta/0020_snapshot.json +2785 -0
- package/migrations/meta/0021_snapshot.json +2762 -0
- package/migrations/meta/0022_snapshot.json +2769 -0
- package/migrations/meta/0023_snapshot.json +2900 -0
- package/migrations/meta/0024_snapshot.json +2907 -0
- package/migrations/meta/_journal.json +181 -0
- package/openapi/decision-api.yaml +12204 -0
- package/package.json +123 -4
- package/skills/README.md +19 -0
- package/skills/add-openhands-support/SKILL.md +113 -0
- package/skills/create-collection/SKILL.md +199 -0
- package/skills/create-collection/reference/claims-stack.md +106 -0
- package/skills/create-collection/reference/collection.md +111 -0
- package/skills/create-oracle/SKILL.md +400 -0
- package/skills/create-rubric/SKILL.md +130 -0
- package/skills/create-rubric/reference/format-cheatsheet.md +186 -0
- package/skills/create-rubric/templates/claim-form.example.json +60 -0
- package/skills/decision-api-client/SKILL.md +236 -0
- package/skills/decision-api-oracle/SKILL.md +336 -0
- package/skills/publish-protocol/SKILL.md +151 -0
- package/skills/publish-protocol/reference/publishing.md +116 -0
- package/skills/reference/engine-contract.md +222 -0
- package/skills/write-facts/SKILL.md +221 -0
- package/skills/write-facts/reference/examples/http-vendor.ts +88 -0
- package/skills/write-facts/reference/examples/price-matches-agreement.ts +67 -0
- package/skills/write-facts/reference/facts-api.md +232 -0
- package/templates/project/.dev.vars.example +93 -0
- package/templates/project/.editorconfig +9 -0
- package/templates/project/CLAUDE.md +45 -0
- package/templates/project/README.md +199 -0
- package/templates/project/biome.json +37 -0
- package/templates/project/gitignore +29 -0
- package/templates/project/package.json +32 -0
- package/templates/project/src/facts/index.ts +19 -0
- package/templates/project/src/index.ts +25 -0
- package/templates/project/test/api-lane.test.ts +57 -0
- package/templates/project/test/facts.test.ts +14 -0
- package/templates/project/tsconfig.json +25 -0
- package/templates/project/vitest.config.ts +13 -0
- package/templates/project/wrangler.jsonc +446 -0
package/dist/config.d.ts
ADDED
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime configuration.
|
|
3
|
+
*
|
|
4
|
+
* Validates the non-secret `vars` (and any string secrets) with Zod so a
|
|
5
|
+
* misconfigured deployment fails loudly and early instead of at some random
|
|
6
|
+
* call site. Bindings (D1, KV, Workflows, ...) are objects supplied by the
|
|
7
|
+
* runtime and are typed by `src/env.ts` (`OracleBindings`), not validated here.
|
|
8
|
+
*
|
|
9
|
+
* This is the COMPLETE env for every lane of the oracle: a new var or secret
|
|
10
|
+
* lands HERE first, then in `src/env.ts` (`OracleVars` — the package's contract with a provider's
|
|
11
|
+
* wrangler.jsonc), then in wrangler.jsonc `vars` / .dev.vars.example.
|
|
12
|
+
*/
|
|
13
|
+
import { z } from "zod";
|
|
14
|
+
import type { OracleEnv } from "./env.js";
|
|
15
|
+
declare const ConfigSchema: z.ZodPipe<z.ZodObject<{
|
|
16
|
+
ENVIRONMENT: z.ZodDefault<z.ZodEnum<{
|
|
17
|
+
development: "development";
|
|
18
|
+
production: "production";
|
|
19
|
+
staging: "staging";
|
|
20
|
+
}>>;
|
|
21
|
+
LOG_LEVEL: z.ZodDefault<z.ZodEnum<{
|
|
22
|
+
debug: "debug";
|
|
23
|
+
error: "error";
|
|
24
|
+
info: "info";
|
|
25
|
+
warn: "warn";
|
|
26
|
+
}>>;
|
|
27
|
+
LOG_PRETTY: z.ZodDefault<z.ZodCodec<z.ZodString, z.ZodBoolean>>;
|
|
28
|
+
SERVICE_NAME: z.ZodDefault<z.ZodString>;
|
|
29
|
+
SERVICE_VERSION: z.ZodDefault<z.ZodString>;
|
|
30
|
+
CORS_ORIGINS: z.ZodDefault<z.ZodString>;
|
|
31
|
+
CRON_COLLECTIONS_PER_TICK: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
32
|
+
IXO_NETWORK: z.ZodDefault<z.ZodEnum<{
|
|
33
|
+
devnet: "devnet";
|
|
34
|
+
mainnet: "mainnet";
|
|
35
|
+
testnet: "testnet";
|
|
36
|
+
}>>;
|
|
37
|
+
BLOCKSYNC_GRAPHQL_URL: z.ZodOptional<z.ZodString>;
|
|
38
|
+
CHAIN_RPC_URL: z.ZodOptional<z.ZodString>;
|
|
39
|
+
MATRIX_HOMESERVER_URL: z.ZodOptional<z.ZodString>;
|
|
40
|
+
UCAN_STORE_URL: z.ZodOptional<z.ZodString>;
|
|
41
|
+
VFS_URL: z.ZodOptional<z.ZodString>;
|
|
42
|
+
IPFS_GATEWAY_URL: z.ZodOptional<z.ZodString>;
|
|
43
|
+
CLAIM_BOT_URL_OVERRIDE: z.ZodOptional<z.ZodString>;
|
|
44
|
+
IXO_CLIENT_SEQUENCE_MIN_DELAY_MS: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
45
|
+
ORACLE_HOSTNAME: z.ZodString;
|
|
46
|
+
ORACLE_DID: z.ZodString;
|
|
47
|
+
ORACLE_ADDRESS: z.ZodString;
|
|
48
|
+
ORACLE_MATRIX_USER_ID: z.ZodString;
|
|
49
|
+
ORACLE_ENTITY_DID: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
|
|
50
|
+
EVAL_ENGINE_HOSTNAME: z.ZodOptional<z.ZodString>;
|
|
51
|
+
EVALUATION_DENOM: z.ZodOptional<z.ZodString>;
|
|
52
|
+
EVALUATION_MIN_AMOUNT: z.ZodOptional<z.ZodString>;
|
|
53
|
+
AI_CHECK_MODEL: z.ZodDefault<z.ZodString>;
|
|
54
|
+
AI_PROVIDER: z.ZodDefault<z.ZodEnum<{
|
|
55
|
+
cloudflare: "cloudflare";
|
|
56
|
+
openrouter: "openrouter";
|
|
57
|
+
}>>;
|
|
58
|
+
AI_GATEWAY_ID: z.ZodOptional<z.ZodString>;
|
|
59
|
+
AI_AUDIO_VIDEO: z.ZodDefault<z.ZodCodec<z.ZodString, z.ZodBoolean>>;
|
|
60
|
+
AI_CHECK_MIN_CONFIDENCE: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
61
|
+
AI_IMAGE_DETAIL: z.ZodDefault<z.ZodEnum<{
|
|
62
|
+
auto: "auto";
|
|
63
|
+
high: "high";
|
|
64
|
+
low: "low";
|
|
65
|
+
}>>;
|
|
66
|
+
C2PA_IMAGE_CHECK: z.ZodPipe<z.ZodDefault<z.ZodEnum<{
|
|
67
|
+
false: "false";
|
|
68
|
+
true: "true";
|
|
69
|
+
}>>, z.ZodTransform<boolean, "false" | "true">>;
|
|
70
|
+
AUTO_SIGN: z.ZodDefault<z.ZodCodec<z.ZodString, z.ZodBoolean>>;
|
|
71
|
+
PORTAL_BASE_URL: z.ZodOptional<z.ZodString>;
|
|
72
|
+
API_LANE: z.ZodDefault<z.ZodCodec<z.ZodString, z.ZodBoolean>>;
|
|
73
|
+
API_PAYMENTS: z.ZodDefault<z.ZodCodec<z.ZodString, z.ZodBoolean>>;
|
|
74
|
+
API_PRICE_USD_CENTS: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
75
|
+
X402_FACILITATOR_URL: z.ZodOptional<z.ZodURL>;
|
|
76
|
+
X402_NETWORK: z.ZodOptional<z.ZodString>;
|
|
77
|
+
EARNINGS_ADDRESS: z.ZodOptional<z.ZodString>;
|
|
78
|
+
EARNINGS_BASE_WALLET: z.ZodOptional<z.ZodString>;
|
|
79
|
+
BILLING_ENGINE_URL: z.ZodOptional<z.ZodURL>;
|
|
80
|
+
CONSOLE_URL: z.ZodOptional<z.ZodURL>;
|
|
81
|
+
AUTH_HUB_URL: z.ZodOptional<z.ZodURL>;
|
|
82
|
+
ORACLE_ADMIN_DIDS: z.ZodPipe<z.ZodPipe<z.ZodOptional<z.ZodString>, z.ZodTransform<string[], string | undefined>>, z.ZodArray<z.ZodString>>;
|
|
83
|
+
STATUS_READER_DIDS: z.ZodPipe<z.ZodPipe<z.ZodOptional<z.ZodString>, z.ZodTransform<string[], string | undefined>>, z.ZodArray<z.ZodString>>;
|
|
84
|
+
SENTRY_TRACES_SAMPLE_RATE: z.ZodCatch<z.ZodCoercedNumber<unknown>>;
|
|
85
|
+
SENTRY_ENVIRONMENT: z.ZodOptional<z.ZodString>;
|
|
86
|
+
SERVICE_ED25519_MNEMONIC: z.ZodOptional<z.ZodString>;
|
|
87
|
+
ORACLE_SECP_MNEMONIC: z.ZodOptional<z.ZodString>;
|
|
88
|
+
OWNER_DELEGATION_CAR: z.ZodOptional<z.ZodString>;
|
|
89
|
+
ORACLE_MATRIX_ACCESS_TOKEN: z.ZodOptional<z.ZodString>;
|
|
90
|
+
OPENROUTER_API_KEY: z.ZodOptional<z.ZodString>;
|
|
91
|
+
UNIQUE_HMAC_KEY: z.ZodOptional<z.ZodString>;
|
|
92
|
+
WEBHOOK_ENCRYPTION_KEY: z.ZodOptional<z.ZodString>;
|
|
93
|
+
SENTRY_DSN: z.ZodOptional<z.ZodString>;
|
|
94
|
+
OPS_ALERT_WEBHOOK_URL: z.ZodPreprocess<z.ZodOptional<z.ZodURL>>;
|
|
95
|
+
EMAIL_FROM_ADDRESS: z.ZodOptional<z.ZodString>;
|
|
96
|
+
EMAIL_FROM_NAME: z.ZodOptional<z.ZodString>;
|
|
97
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
98
|
+
ENVIRONMENT: "development" | "production" | "staging";
|
|
99
|
+
LOG_LEVEL: "debug" | "error" | "info" | "warn";
|
|
100
|
+
LOG_PRETTY: boolean;
|
|
101
|
+
SERVICE_NAME: string;
|
|
102
|
+
SERVICE_VERSION: string;
|
|
103
|
+
CORS_ORIGINS: string;
|
|
104
|
+
CRON_COLLECTIONS_PER_TICK: number;
|
|
105
|
+
IXO_NETWORK: "devnet" | "mainnet" | "testnet";
|
|
106
|
+
CLAIM_BOT_URL_OVERRIDE?: string | undefined;
|
|
107
|
+
IXO_CLIENT_SEQUENCE_MIN_DELAY_MS: number;
|
|
108
|
+
ORACLE_HOSTNAME: string;
|
|
109
|
+
ORACLE_DID: string;
|
|
110
|
+
ORACLE_ADDRESS: string;
|
|
111
|
+
ORACLE_MATRIX_USER_ID: string;
|
|
112
|
+
ORACLE_ENTITY_DID?: string | undefined;
|
|
113
|
+
EVALUATION_DENOM?: string | undefined;
|
|
114
|
+
EVALUATION_MIN_AMOUNT?: string | undefined;
|
|
115
|
+
AI_CHECK_MODEL: string;
|
|
116
|
+
AI_PROVIDER: "cloudflare" | "openrouter";
|
|
117
|
+
AI_GATEWAY_ID?: string | undefined;
|
|
118
|
+
AI_AUDIO_VIDEO: boolean;
|
|
119
|
+
AI_CHECK_MIN_CONFIDENCE: number;
|
|
120
|
+
AI_IMAGE_DETAIL: "auto" | "high" | "low";
|
|
121
|
+
C2PA_IMAGE_CHECK: boolean;
|
|
122
|
+
AUTO_SIGN: boolean;
|
|
123
|
+
API_LANE: boolean;
|
|
124
|
+
API_PAYMENTS: boolean;
|
|
125
|
+
API_PRICE_USD_CENTS?: number | undefined;
|
|
126
|
+
X402_FACILITATOR_URL?: string | undefined;
|
|
127
|
+
X402_NETWORK?: string | undefined;
|
|
128
|
+
EARNINGS_ADDRESS?: string | undefined;
|
|
129
|
+
EARNINGS_BASE_WALLET?: string | undefined;
|
|
130
|
+
BILLING_ENGINE_URL?: string | undefined;
|
|
131
|
+
CONSOLE_URL?: string | undefined;
|
|
132
|
+
ORACLE_ADMIN_DIDS: string[];
|
|
133
|
+
STATUS_READER_DIDS: string[];
|
|
134
|
+
SENTRY_TRACES_SAMPLE_RATE: number;
|
|
135
|
+
SENTRY_ENVIRONMENT?: string | undefined;
|
|
136
|
+
SERVICE_ED25519_MNEMONIC?: string | undefined;
|
|
137
|
+
ORACLE_SECP_MNEMONIC?: string | undefined;
|
|
138
|
+
OWNER_DELEGATION_CAR?: string | undefined;
|
|
139
|
+
ORACLE_MATRIX_ACCESS_TOKEN?: string | undefined;
|
|
140
|
+
OPENROUTER_API_KEY?: string | undefined;
|
|
141
|
+
UNIQUE_HMAC_KEY?: string | undefined;
|
|
142
|
+
WEBHOOK_ENCRYPTION_KEY?: string | undefined;
|
|
143
|
+
SENTRY_DSN?: string | undefined;
|
|
144
|
+
OPS_ALERT_WEBHOOK_URL?: string | undefined;
|
|
145
|
+
EMAIL_FROM_ADDRESS?: string | undefined;
|
|
146
|
+
EMAIL_FROM_NAME?: string | undefined;
|
|
147
|
+
BLOCKSYNC_GRAPHQL_URL: string;
|
|
148
|
+
CHAIN_RPC_URL: string;
|
|
149
|
+
MATRIX_HOMESERVER_URL: string;
|
|
150
|
+
UCAN_STORE_URL: string;
|
|
151
|
+
VFS_URL: string;
|
|
152
|
+
IPFS_GATEWAY_URL: string;
|
|
153
|
+
EVAL_ENGINE_HOSTNAME: string;
|
|
154
|
+
PORTAL_BASE_URL: string;
|
|
155
|
+
AUTH_HUB_URL: string;
|
|
156
|
+
}, {
|
|
157
|
+
ENVIRONMENT: "development" | "production" | "staging";
|
|
158
|
+
LOG_LEVEL: "debug" | "error" | "info" | "warn";
|
|
159
|
+
LOG_PRETTY: boolean;
|
|
160
|
+
SERVICE_NAME: string;
|
|
161
|
+
SERVICE_VERSION: string;
|
|
162
|
+
CORS_ORIGINS: string;
|
|
163
|
+
CRON_COLLECTIONS_PER_TICK: number;
|
|
164
|
+
IXO_NETWORK: "devnet" | "mainnet" | "testnet";
|
|
165
|
+
BLOCKSYNC_GRAPHQL_URL?: string | undefined;
|
|
166
|
+
CHAIN_RPC_URL?: string | undefined;
|
|
167
|
+
MATRIX_HOMESERVER_URL?: string | undefined;
|
|
168
|
+
UCAN_STORE_URL?: string | undefined;
|
|
169
|
+
VFS_URL?: string | undefined;
|
|
170
|
+
IPFS_GATEWAY_URL?: string | undefined;
|
|
171
|
+
CLAIM_BOT_URL_OVERRIDE?: string | undefined;
|
|
172
|
+
IXO_CLIENT_SEQUENCE_MIN_DELAY_MS: number;
|
|
173
|
+
ORACLE_HOSTNAME: string;
|
|
174
|
+
ORACLE_DID: string;
|
|
175
|
+
ORACLE_ADDRESS: string;
|
|
176
|
+
ORACLE_MATRIX_USER_ID: string;
|
|
177
|
+
ORACLE_ENTITY_DID?: string | undefined;
|
|
178
|
+
EVAL_ENGINE_HOSTNAME?: string | undefined;
|
|
179
|
+
EVALUATION_DENOM?: string | undefined;
|
|
180
|
+
EVALUATION_MIN_AMOUNT?: string | undefined;
|
|
181
|
+
AI_CHECK_MODEL: string;
|
|
182
|
+
AI_PROVIDER: "cloudflare" | "openrouter";
|
|
183
|
+
AI_GATEWAY_ID?: string | undefined;
|
|
184
|
+
AI_AUDIO_VIDEO: boolean;
|
|
185
|
+
AI_CHECK_MIN_CONFIDENCE: number;
|
|
186
|
+
AI_IMAGE_DETAIL: "auto" | "high" | "low";
|
|
187
|
+
C2PA_IMAGE_CHECK: boolean;
|
|
188
|
+
AUTO_SIGN: boolean;
|
|
189
|
+
PORTAL_BASE_URL?: string | undefined;
|
|
190
|
+
API_LANE: boolean;
|
|
191
|
+
API_PAYMENTS: boolean;
|
|
192
|
+
API_PRICE_USD_CENTS?: number | undefined;
|
|
193
|
+
X402_FACILITATOR_URL?: string | undefined;
|
|
194
|
+
X402_NETWORK?: string | undefined;
|
|
195
|
+
EARNINGS_ADDRESS?: string | undefined;
|
|
196
|
+
EARNINGS_BASE_WALLET?: string | undefined;
|
|
197
|
+
BILLING_ENGINE_URL?: string | undefined;
|
|
198
|
+
CONSOLE_URL?: string | undefined;
|
|
199
|
+
AUTH_HUB_URL?: string | undefined;
|
|
200
|
+
ORACLE_ADMIN_DIDS: string[];
|
|
201
|
+
STATUS_READER_DIDS: string[];
|
|
202
|
+
SENTRY_TRACES_SAMPLE_RATE: number;
|
|
203
|
+
SENTRY_ENVIRONMENT?: string | undefined;
|
|
204
|
+
SERVICE_ED25519_MNEMONIC?: string | undefined;
|
|
205
|
+
ORACLE_SECP_MNEMONIC?: string | undefined;
|
|
206
|
+
OWNER_DELEGATION_CAR?: string | undefined;
|
|
207
|
+
ORACLE_MATRIX_ACCESS_TOKEN?: string | undefined;
|
|
208
|
+
OPENROUTER_API_KEY?: string | undefined;
|
|
209
|
+
UNIQUE_HMAC_KEY?: string | undefined;
|
|
210
|
+
WEBHOOK_ENCRYPTION_KEY?: string | undefined;
|
|
211
|
+
SENTRY_DSN?: string | undefined;
|
|
212
|
+
OPS_ALERT_WEBHOOK_URL?: string | undefined;
|
|
213
|
+
EMAIL_FROM_ADDRESS?: string | undefined;
|
|
214
|
+
EMAIL_FROM_NAME?: string | undefined;
|
|
215
|
+
}>>;
|
|
216
|
+
export type Config = z.infer<typeof ConfigSchema>;
|
|
217
|
+
export declare function loadConfig(env: OracleEnv): Config;
|
|
218
|
+
export declare function corsOrigins(config: Config): "*" | string[];
|
|
219
|
+
export declare const isProduction: (config: Config) => boolean;
|
|
220
|
+
export {};
|
|
221
|
+
//# sourceMappingURL=config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AASvC,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwZd,CAAC;AAIL,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAKlD,wBAAgB,UAAU,CAAC,GAAG,EAAE,SAAS,GAAG,MAAM,CAcjD;AAED,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,GAAG,GAAG,MAAM,EAAE,CAO1D;AAED,eAAO,MAAM,YAAY,WAAY,MAAM,KAAG,OAA8C,CAAC"}
|
package/dist/config.js
ADDED
|
@@ -0,0 +1,431 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime configuration.
|
|
3
|
+
*
|
|
4
|
+
* Validates the non-secret `vars` (and any string secrets) with Zod so a
|
|
5
|
+
* misconfigured deployment fails loudly and early instead of at some random
|
|
6
|
+
* call site. Bindings (D1, KV, Workflows, ...) are objects supplied by the
|
|
7
|
+
* runtime and are typed by `src/env.ts` (`OracleBindings`), not validated here.
|
|
8
|
+
*
|
|
9
|
+
* This is the COMPLETE env for every lane of the oracle: a new var or secret
|
|
10
|
+
* lands HERE first, then in `src/env.ts` (`OracleVars` — the package's contract with a provider's
|
|
11
|
+
* wrangler.jsonc), then in wrangler.jsonc `vars` / .dev.vars.example.
|
|
12
|
+
*/
|
|
13
|
+
import { z } from "zod";
|
|
14
|
+
import { bech32Valid } from "./lib/bech32.js";
|
|
15
|
+
import { networkDefaults } from "./networks.js";
|
|
16
|
+
const LogLevelSchema = z.enum(["debug", "info", "warn", "error"]);
|
|
17
|
+
/** A base URL the lane joins paths onto — a trailing slash would double every `/`. */
|
|
18
|
+
const BaseUrl = z.url().refine((u) => !u.endsWith("/"), "no trailing slash");
|
|
19
|
+
const ConfigSchema = z
|
|
20
|
+
.object({
|
|
21
|
+
ENVIRONMENT: z.enum(["development", "staging", "production"]).default("development"),
|
|
22
|
+
LOG_LEVEL: LogLevelSchema.default("info"),
|
|
23
|
+
/**
|
|
24
|
+
* Human-readable, colorized logs for the local terminal. Set ONLY in
|
|
25
|
+
* `.dev.vars` (loaded by `wrangler dev`, never uploaded) so every deployed env
|
|
26
|
+
* emits JSON — which is what Workers Logs ingests and makes queryable.
|
|
27
|
+
*/
|
|
28
|
+
LOG_PRETTY: z.stringbool().default(false),
|
|
29
|
+
SERVICE_NAME: z.string().min(1).default("eval-oracle"),
|
|
30
|
+
SERVICE_VERSION: z.string().min(1).default("0.0.0"),
|
|
31
|
+
/** Comma-separated allowed origins, or "*" for any. */
|
|
32
|
+
CORS_ORIGINS: z.string().default("*"),
|
|
33
|
+
/**
|
|
34
|
+
* Watched collections visited per cron tick (cron/scan.ts `runCronTick`) — bounds that tick's
|
|
35
|
+
* D1 select; a fleet larger than this rotates in across ticks, least-recently-scanned first
|
|
36
|
+
* (`lastScannedAt`). Raise it for a large fleet. Does not bound `scanCollection`
|
|
37
|
+
* (src/runtime.ts), which always scans the one collection it's given.
|
|
38
|
+
*/
|
|
39
|
+
CRON_COLLECTIONS_PER_TICK: z.coerce.number().int().min(1).max(500).default(25),
|
|
40
|
+
// --- IXO network (the pull lane) ---
|
|
41
|
+
// Every URL below must be on the SAME network as IXO_NETWORK or did resolution 401s. Unset ⇒
|
|
42
|
+
// defaulted from IXO_NETWORK by the transform below (networks.ts) — set one only to override
|
|
43
|
+
// (self-hosted Blocksync, a local engine, a tunnel).
|
|
44
|
+
IXO_NETWORK: z.enum(["devnet", "testnet", "mainnet"]).default("devnet"),
|
|
45
|
+
BLOCKSYNC_GRAPHQL_URL: z.string().min(1).optional(),
|
|
46
|
+
/** Chain RPC — the SDK query client behind the authz-grants read and the chain write. */
|
|
47
|
+
CHAIN_RPC_URL: z.string().min(1).optional(),
|
|
48
|
+
/** Default/fallback Matrix home server when an entity DID declares no MatrixHomeServer service. */
|
|
49
|
+
MATRIX_HOMESERVER_URL: z.string().min(1).optional(),
|
|
50
|
+
UCAN_STORE_URL: z.string().min(1).optional(),
|
|
51
|
+
/**
|
|
52
|
+
* The IXO Virtual Filesystem — the first two claim-body lanes (lib/ixo/index.ts): the
|
|
53
|
+
* collection's claims lane (`/api/fs/cid`, read under our evaluate grant), then public copies
|
|
54
|
+
* (`/public/cid`).
|
|
55
|
+
*/
|
|
56
|
+
VFS_URL: z.string().min(1).optional(),
|
|
57
|
+
/** The IPFS gateway a claim body is read from (`/ipfs/<cid>`) when neither the VFS nor Matrix has it. */
|
|
58
|
+
IPFS_GATEWAY_URL: z.string().min(1).optional(),
|
|
59
|
+
/**
|
|
60
|
+
* Local-dev escape hatch: when set, the claim-bot URL is used as-is instead
|
|
61
|
+
* of being derived (`https://claim.bot.<homeserver domain>`) — local
|
|
62
|
+
* harnesses run the bot on a plain host:port. Never set in deployed envs.
|
|
63
|
+
*/
|
|
64
|
+
CLAIM_BOT_URL_OVERRIDE: z.string().min(1).optional(),
|
|
65
|
+
/**
|
|
66
|
+
* Read by the SDK's SequenceManagerDO straight off `env`, not through this config — listed so
|
|
67
|
+
* the schema is the one complete inventory. Minimum gap (ms) between two sequence allocations
|
|
68
|
+
* from the oracle account.
|
|
69
|
+
*/
|
|
70
|
+
IXO_CLIENT_SEQUENCE_MIN_DELAY_MS: z.coerce.number().int().nonnegative().default(1000),
|
|
71
|
+
// --- This oracle's identity ---
|
|
72
|
+
/**
|
|
73
|
+
* OUR canonical did:web host. The audience of every inbound UCAN invocation is pinned to THIS,
|
|
74
|
+
* never the request Host; it is also the issuer of every invocation we mint.
|
|
75
|
+
*/
|
|
76
|
+
ORACLE_HOSTNAME: z.string().min(1),
|
|
77
|
+
/**
|
|
78
|
+
* The oracle's PUBLIC chain identifiers — config, not credentials. `ORACLE_ADDRESS` must be
|
|
79
|
+
* the `ORACLE_SECP_MNEMONIC` wallet's address (asserted at first use by the chain client);
|
|
80
|
+
* `ORACLE_MATRIX_USER_ID` is the MXID derived from `ORACLE_DID` (cross-checked, never re-derived).
|
|
81
|
+
*/
|
|
82
|
+
ORACLE_DID: z.string().min(1),
|
|
83
|
+
ORACLE_ADDRESS: z.string().min(1),
|
|
84
|
+
ORACLE_MATRIX_USER_ID: z.string().min(1),
|
|
85
|
+
/**
|
|
86
|
+
* The on-chain oracle ENTITY (`did:ixo:entity:…`, declared by `decision-oracle oracle init`
|
|
87
|
+
* and owned by the provider's AuthHub session) — NOT the kit's runtime `ORACLE_DID`, which is an
|
|
88
|
+
* address DID with no entity record. The portal resolves this kit's API from that entity's
|
|
89
|
+
* `#eval` service (blocksync `entity(id) { service }` → its did.json), so it is what the Matrix
|
|
90
|
+
* review card and the room's eval-context event name as `oracleDid`. Unset (or "" — the
|
|
91
|
+
* wrangler.jsonc placeholder) ⇒ falls back to `ORACLE_DID`: the card is still delivered but
|
|
92
|
+
* cannot be answered from chat, only from the portal's claim page.
|
|
93
|
+
*/
|
|
94
|
+
ORACLE_ENTITY_DID: z.preprocess((v) => v || undefined, z
|
|
95
|
+
.string()
|
|
96
|
+
.startsWith("did:ixo:entity:", "expected the oracle ENTITY did (did:ixo:entity:…)")
|
|
97
|
+
.optional()),
|
|
98
|
+
/**
|
|
99
|
+
* The decision engine we ask for decisions (docs/ENGINE-CONTRACT.md). A host we CALL: the
|
|
100
|
+
* invocation audience is its did:web, resolved from `https://<host>/.well-known/did.json`
|
|
101
|
+
* (lib/ixo/did.ts; plain http for localhost — lib/engine/client.ts `engineBaseUrl`) — a
|
|
102
|
+
* different thing from ORACLE_HOSTNAME, which is who WE are. Defaults to the network's engine
|
|
103
|
+
* host (`networks.ts`); set it for a local engine (`localhost:8787`) or a tunnel.
|
|
104
|
+
*/
|
|
105
|
+
EVAL_ENGINE_HOSTNAME: z.string().min(1).optional(),
|
|
106
|
+
// --- The chain fee (register gate 4) ---
|
|
107
|
+
/**
|
|
108
|
+
* The coin a collection's on-chain `Payments.evaluation` must pay this oracle in, per network
|
|
109
|
+
* (owner ruling: mainnet real USDC over IBC, devnet/testnet any stand-in such as `uixo`). Both
|
|
110
|
+
* or neither; when set they REPLACE `pricing.evaluation` (oracle.ts `effectivePricing`) at the
|
|
111
|
+
* register gate and on `/v1/info` — a `pricing.byProtocol` entry still wins for its protocol.
|
|
112
|
+
* REQUIRED on mainnet (refined below), with no default anywhere in code: a mainnet oracle can
|
|
113
|
+
* never fall back to a stand-in coin written in `defineOracle`. The denom is matched EXACTLY
|
|
114
|
+
* (`requireEvaluationPayment`); the amount is an integer base-unit string.
|
|
115
|
+
*/
|
|
116
|
+
EVALUATION_DENOM: z.string().min(1).optional(),
|
|
117
|
+
EVALUATION_MIN_AMOUNT: z.string().regex(/^\d+$/, "an integer base-unit string").optional(),
|
|
118
|
+
// --- Connectors (the facts lane, README "How a claim flows" step 4) ---
|
|
119
|
+
/**
|
|
120
|
+
* The model pinned for `aiChecks` facts (either provider) — per-CLAIM calls. Frequent + needs image
|
|
121
|
+
* support, so it stays lean; the FactSet records what actually answered. It must also support
|
|
122
|
+
* strict `json_schema` structured output (stock/ai-check.ts sends one) — a cheaper model that
|
|
123
|
+
* does not, such as `qwen/qwen3.7-flash`, cannot answer this lane at all.
|
|
124
|
+
*/
|
|
125
|
+
// GPT-6 Luna: OpenAI's high-volume tier ("Fast" in the org's mapping), half gpt-5.6-luna's price;
|
|
126
|
+
// the image/PDF/strict-schema/judge lanes were evaluated on the gateway before it became the pin.
|
|
127
|
+
AI_CHECK_MODEL: z.string().min(1).default("openai/gpt-6-luna"),
|
|
128
|
+
/**
|
|
129
|
+
* Which provider every AI lane calls — the AI check, `tools.ai.judge`, the same-event judge
|
|
130
|
+
* (stock/ai-provider.ts). `cloudflare`: the Worker's `AI` binding through the AI Gateway
|
|
131
|
+
* `AI_GATEWAY_ID` (Unified Billing credits or the gateway's stored keys — no third-party key
|
|
132
|
+
* here). `openrouter`: the OpenRouter API with `OPENROUTER_API_KEY`. Either one's pieces are
|
|
133
|
+
* checked at the point of use, as the key always was: an oracle whose rubrics declare no AI
|
|
134
|
+
* fact needs none of them.
|
|
135
|
+
*/
|
|
136
|
+
AI_PROVIDER: z.enum(["cloudflare", "openrouter"]).default("cloudflare"),
|
|
137
|
+
/** The AI Gateway the `cloudflare` provider routes through — its name in the dashboard. */
|
|
138
|
+
AI_GATEWAY_ID: z.string().min(1).optional(),
|
|
139
|
+
/**
|
|
140
|
+
* The audio + video input lanes. Off ⇒ an audio/video attachment reaches the model as a
|
|
141
|
+
* labelled descriptor ("content not sent"), so a rule that needed it fails honestly. Only
|
|
142
|
+
* OpenRouter can read them: on with any other provider fails at isolate start (refined below).
|
|
143
|
+
*/
|
|
144
|
+
AI_AUDIO_VIDEO: z.stringbool().default(false),
|
|
145
|
+
/**
|
|
146
|
+
* Confidence floor for an AI check's verdict: a response scoring below this is the UNREACHABLE
|
|
147
|
+
* path (→ the fact's `error`), not a trusted verdict.
|
|
148
|
+
*/
|
|
149
|
+
AI_CHECK_MIN_CONFIDENCE: z.coerce.number().int().min(0).max(100).default(60),
|
|
150
|
+
/**
|
|
151
|
+
* `image_url.detail` for every image the AI lanes send (an AI check's photos, the same-event
|
|
152
|
+
* judge's pair evidence). `high` because a photographed screen (moiré, a pixel grid, a cursor)
|
|
153
|
+
* or a generated image (garbled text) is only visible at full resolution — `low` downsamples
|
|
154
|
+
* it away and the fake gets paid. `high` costs more image tokens per call; `low` is the flat,
|
|
155
|
+
* cheap setting for an oracle whose checks never turn on fine detail.
|
|
156
|
+
*/
|
|
157
|
+
AI_IMAGE_DETAIL: z.enum(["low", "high", "auto"]).default("high"),
|
|
158
|
+
/**
|
|
159
|
+
* C2PA image provenance gate: when on AND an aiCheck carries an image, the raw bytes are read for
|
|
160
|
+
* a signed Content Credentials manifest BEFORE the model call. A cryptographically TRUSTED,
|
|
161
|
+
* AI-generated manifest fails the check outright — proof, not a guess, so no model call.
|
|
162
|
+
* Anything inconclusive (no manifest — the common case, since a screenshot strips it — untrusted,
|
|
163
|
+
* or unreadable) falls through to the LLM. Fail-safe: it can only ever ADD a rejection, so a trust
|
|
164
|
+
* glitch never rejects real work. Verified against the official C2PA Trust List. OFF by default.
|
|
165
|
+
*/
|
|
166
|
+
C2PA_IMAGE_CHECK: z
|
|
167
|
+
.enum(["true", "false"])
|
|
168
|
+
.default("false")
|
|
169
|
+
.transform((v) => v === "true"),
|
|
170
|
+
// --- Policy (the act lane, README "How a claim flows" step 6) ---
|
|
171
|
+
/**
|
|
172
|
+
* Sign `MsgEvaluateClaim` on a terminal verdict without a human in the loop. `false` ⇒ the
|
|
173
|
+
* decision is still recorded and receipted, but submission is the operator's (portal) job.
|
|
174
|
+
* Mirrored by the oracle config (`defineOracle`) `policies.autoSign` for the provider-facing surface.
|
|
175
|
+
*/
|
|
176
|
+
AUTO_SIGN: z.stringbool().default(true),
|
|
177
|
+
/** Portal origin for the deep links in review notifications. No trailing slash. */
|
|
178
|
+
PORTAL_BASE_URL: z.string().min(1).optional(),
|
|
179
|
+
// --- The Decision API lane (Go Prod) ---
|
|
180
|
+
// A second, off-chain intake (go-prod spec §3, App. C): paid claims submitted over HTTP to
|
|
181
|
+
// `/v1/api`, decided by the same engine, never written to chain. EVERY knob below defaults to
|
|
182
|
+
// off or unset, so an oracle that never opts in runs exactly the chain lane it always has
|
|
183
|
+
// (§16.1: "the chain lane is untouched throughout"). The URLs are not defaulted per network:
|
|
184
|
+
// each lane that needs one refuses loudly at the point of use.
|
|
185
|
+
/** Mount the `/v1/api` router (§16.1). Off ⇒ the lane is dormant: no routes, no cron work. */
|
|
186
|
+
API_LANE: z.stringbool().default(false),
|
|
187
|
+
/**
|
|
188
|
+
* The x402 payment gate (§4, §16.1). Off ⇒ every NEW submit answers
|
|
189
|
+
* `503 SOURCE_PAUSED { reason: payments-disabled }` — nothing is ever accepted unpaid. Also the
|
|
190
|
+
* runbook's kill switch for a facilitator outage (§16.4).
|
|
191
|
+
*/
|
|
192
|
+
API_PAYMENTS: z.stringbool().default(false),
|
|
193
|
+
/**
|
|
194
|
+
* The published price per decision in whole USD cents (1 PAY = 1 USD) — every source pays it,
|
|
195
|
+
* there are no per-source prices. Unset ⇒ the gate refuses loudly at use rather than quote a
|
|
196
|
+
* guessed price.
|
|
197
|
+
*/
|
|
198
|
+
API_PRICE_USD_CENTS: z.coerce.number().int().positive().optional(),
|
|
199
|
+
/** Our x402 facilitator worker (App. E #10). No trailing slash. */
|
|
200
|
+
X402_FACILITATOR_URL: BaseUrl.optional(),
|
|
201
|
+
/**
|
|
202
|
+
* The chain every 402 names, as x402 v2 spells networks — CAIP-2, whose namespace for a Cosmos
|
|
203
|
+
* SDK chain is `cosmos:` (`cosmos:devnet-1`, `cosmos:pandora-8` testnet, `cosmos:ixo-5` mainnet).
|
|
204
|
+
*/
|
|
205
|
+
X402_NETWORK: z
|
|
206
|
+
.string()
|
|
207
|
+
.regex(/^cosmos:[-_a-zA-Z0-9]{1,32}$/, "expected cosmos:<chain-id>")
|
|
208
|
+
.optional(),
|
|
209
|
+
/**
|
|
210
|
+
* Where this operator's earnings land (payments spec §3.2: named as each offer's `payTo`; IXO
|
|
211
|
+
* never sets it). `EARNINGS_ADDRESS`: the `ixo1…` account for PAY and USDC on IXO — "payouts"
|
|
212
|
+
* means only a company paying its people (`OracleConfig.payouts`), never this. Unset ⇒ those
|
|
213
|
+
* ways to pay are not offered (today: no 402 can be made, 503 payments-disabled). Checked
|
|
214
|
+
* here, checksum included, so a typo fails at isolate start.
|
|
215
|
+
*/
|
|
216
|
+
EARNINGS_ADDRESS: z
|
|
217
|
+
.string()
|
|
218
|
+
.regex(/^ixo1[02-9ac-hj-np-z]{38}$/, "expected an ixo1… account")
|
|
219
|
+
.refine(bech32Valid, "not a valid ixo1 address (bad checksum)")
|
|
220
|
+
.optional(),
|
|
221
|
+
/** The operator's Base wallet (`0x…`) for USDC on Base. Unset ⇒ that way to pay is not offered. */
|
|
222
|
+
EARNINGS_BASE_WALLET: z
|
|
223
|
+
.string()
|
|
224
|
+
.regex(/^0x[0-9a-fA-F]{40}$/, "expected a 0x… wallet address")
|
|
225
|
+
.optional(),
|
|
226
|
+
/** Charge lookups and the spend figures on `/v1/api/me`. No trailing slash. */
|
|
227
|
+
BILLING_ENGINE_URL: BaseUrl.optional(),
|
|
228
|
+
/**
|
|
229
|
+
* The Decision Console — every error's `docsUrl`, the 402's `fundingUrl` and every email link
|
|
230
|
+
* (unset ⇒ the API lane's emails are skipped). No trailing slash.
|
|
231
|
+
*/
|
|
232
|
+
CONSOLE_URL: BaseUrl.optional(),
|
|
233
|
+
/**
|
|
234
|
+
* IXO AuthHub — the OAuth authorization server of `/v1/mcp` (MCP over OAuth, spec
|
|
235
|
+
* 2026-10-06): the PRM's `authorization_servers`, the access token's exact `iss` (its JWKS at
|
|
236
|
+
* `<url>/.well-known/jwks.json`), the approve link's host, and the one `did:web` the approvals
|
|
237
|
+
* back-channel (`/v1/oauth/approvals/:id`) accepts. Defaults to the network's AuthHub
|
|
238
|
+
* (`networks.ts`); set it for a local AuthHub. No trailing slash.
|
|
239
|
+
*/
|
|
240
|
+
AUTH_HUB_URL: BaseUrl.optional(),
|
|
241
|
+
/**
|
|
242
|
+
* Comma-separated `did:ixo` admins of THIS oracle — its operator's people — allowed on
|
|
243
|
+
* `GET /v1/admin/status` and `/v1/api/admin/*` (pauses, allow-lists — the console's operator
|
|
244
|
+
* view). Split and checked HERE, so a typo fails
|
|
245
|
+
* at isolate start rather than silently locking the operators out; unset ⇒ nobody is an
|
|
246
|
+
* operator.
|
|
247
|
+
*/
|
|
248
|
+
ORACLE_ADMIN_DIDS: z
|
|
249
|
+
.string()
|
|
250
|
+
.optional()
|
|
251
|
+
.transform((v) => (v ?? "")
|
|
252
|
+
.split(",")
|
|
253
|
+
.map((d) => d.trim())
|
|
254
|
+
.filter(Boolean))
|
|
255
|
+
.pipe(z.array(z.string().startsWith("did:ixo:", "expected a did:ixo operator DID"))),
|
|
256
|
+
/**
|
|
257
|
+
* Comma-separated DIDs of any method (a monitoring service's `did:web`, say) allowed to read
|
|
258
|
+
* `GET /v1/admin/status` and nothing else. Kept apart from ORACLE_ADMIN_DIDS because operators also
|
|
259
|
+
* gate write routes — a monitor must never need to be made one. Unset ⇒ nobody.
|
|
260
|
+
*/
|
|
261
|
+
STATUS_READER_DIDS: z
|
|
262
|
+
.string()
|
|
263
|
+
.optional()
|
|
264
|
+
.transform((v) => (v ?? "")
|
|
265
|
+
.split(",")
|
|
266
|
+
.map((d) => d.trim())
|
|
267
|
+
.filter(Boolean))
|
|
268
|
+
.pipe(z.array(z.string().regex(/^did:[a-z0-9]+:\S+$/, "expected a did:<method>:<id>"))),
|
|
269
|
+
/**
|
|
270
|
+
* Share of requests Sentry traces, 0..1. Unset ⇒ 0.1 — full tracing is a cost, not a default
|
|
271
|
+
* (observability spec §5.1). `sentryOptions` (lib/sentry.ts) reads the raw var itself, since the
|
|
272
|
+
* SDK is initialized before this schema runs. A bad value is the default here too, never a
|
|
273
|
+
* failed `loadConfig`: telemetry must not take the oracle down.
|
|
274
|
+
*/
|
|
275
|
+
SENTRY_TRACES_SAMPLE_RATE: z.coerce.number().min(0).max(1).catch(0.1),
|
|
276
|
+
/**
|
|
277
|
+
* The Sentry environment tag. Unset ⇒ `ENVIRONMENT` — set it only to tell apart two deploys that
|
|
278
|
+
* share one (a testnet and a mainnet oracle both `production`, say). Read raw by `sentryOptions`.
|
|
279
|
+
*/
|
|
280
|
+
SENTRY_ENVIRONMENT: z.string().min(1).optional(),
|
|
281
|
+
// --- Secrets (from .dev.vars / `wrangler secret put`) ---
|
|
282
|
+
// Optional so non-auth routes (health) boot without secrets; each read path fails loudly
|
|
283
|
+
// (AppError.internal) — or no-ops where the comment says so — at the point of use.
|
|
284
|
+
/**
|
|
285
|
+
* The did:web key: SHA256(mnemonic) → Ed25519 seed (lib/ixo/identity.ts). Signs every UCAN
|
|
286
|
+
* invocation we mint (engine, claim bot, UCAN Store) and backs `/.well-known/did.json`.
|
|
287
|
+
*/
|
|
288
|
+
SERVICE_ED25519_MNEMONIC: z.string().min(1).optional(),
|
|
289
|
+
/**
|
|
290
|
+
* The oracle ACCOUNT key (secp256k1) — signs `MsgEvaluateClaim`. `ORACLE_ADDRESS` must be this
|
|
291
|
+
* wallet's address. Unset ⇒ the chain-write lane logs one line and skips — the decision itself
|
|
292
|
+
* is never affected.
|
|
293
|
+
*/
|
|
294
|
+
ORACLE_SECP_MNEMONIC: z.string().min(1).optional(),
|
|
295
|
+
/**
|
|
296
|
+
* The oracle OWNER's UCAN delegation to the decision engine (base64 CAR) — sent once, at
|
|
297
|
+
* register. The engine bills the owner's credits per decision (ENGINE-CONTRACT.md "Billing"),
|
|
298
|
+
* and this is how it finds their subscription: `subscriptions/read` on `ixo:subscriptions`, plus
|
|
299
|
+
* `billing/pay` bound to THIS oracle's did:web. Mint it with eval-engine's
|
|
300
|
+
* `decision-oracle delegation --for engine` as the owner. Unset ⇒ register refuses, loudly.
|
|
301
|
+
*/
|
|
302
|
+
OWNER_DELEGATION_CAR: z.string().min(1).optional(),
|
|
303
|
+
/**
|
|
304
|
+
* The oracle bot's Matrix access token — a full account credential, so a secret, never a var,
|
|
305
|
+
* never logged. Read by the review-notification lane (lib/matrix/deliver.ts): unset ⇒ every
|
|
306
|
+
* lane entry point (`notify-review`, `notify-folded`) logs one line and skips — no claim is
|
|
307
|
+
* ever blocked on it.
|
|
308
|
+
*/
|
|
309
|
+
ORACLE_MATRIX_ACCESS_TOKEN: z.string().min(1).optional(),
|
|
310
|
+
/** OpenRouter key — read only when AI_PROVIDER=openrouter and a rubric asks for an AI fact. */
|
|
311
|
+
OPENROUTER_API_KEY: z.string().min(1).optional(),
|
|
312
|
+
/**
|
|
313
|
+
* HMAC key for the duplicate-detection body digest (dup-detection spec §4 L1; the stock
|
|
314
|
+
* producer's `unique` lane, lib/facts/stock/unique.ts) — KEYED because claim answers are
|
|
315
|
+
* low-entropy PII: a plain hash is dictionary-reversible, and the keyed digest is what lets
|
|
316
|
+
* `claim_body_digests` outlive lawful erasure of `normalized_text`. One long-lived secret per
|
|
317
|
+
* oracle: rotating it orphans every registered digest (the registries would need re-filling).
|
|
318
|
+
* REQUIRED when `API_LANE` is on (the refinement below): an API submit with a `submitter` is
|
|
319
|
+
* counted by this key's digest, so without it the first such submit would 500 — a missing key
|
|
320
|
+
* must fail at isolate start instead. Otherwise required only at the point of use — a rubric
|
|
321
|
+
* declaring `unique` fails loudly without it, mirroring OPENROUTER_API_KEY.
|
|
322
|
+
*/
|
|
323
|
+
UNIQUE_HMAC_KEY: z.string().min(1).optional(),
|
|
324
|
+
/**
|
|
325
|
+
* The per-deployment key the Decision API lane encrypts webhook signing secrets with at rest —
|
|
326
|
+
* every endpoint's and every source's own (go-prod §4.5, §6.1 — App. C names no var for it;
|
|
327
|
+
* this is it). REQUIRED when `API_LANE` is on (the refinement below): every source is created
|
|
328
|
+
* with a signing secret (contracts v1.1), so without the key the lane could not create a
|
|
329
|
+
* source, and a missing key must fail at isolate start — not as a trail of dead deliveries.
|
|
330
|
+
* Like UNIQUE_HMAC_KEY it is for life: rotating it strands every stored secret.
|
|
331
|
+
*/
|
|
332
|
+
WEBHOOK_ENCRYPTION_KEY: z.string().min(1).optional(),
|
|
333
|
+
/**
|
|
334
|
+
* Sentry DSN. UNSET ⇒ the whole error-reporting lane is a no-op — the same "unset ⇒ lane off"
|
|
335
|
+
* contract as the Matrix and chain-write lanes, so local dev and CI never ship events. A DSN is
|
|
336
|
+
* not a credential (it only permits *writing* events), but it lives with the secrets because it
|
|
337
|
+
* decides where this service's errors go.
|
|
338
|
+
*/
|
|
339
|
+
SENTRY_DSN: z.string().min(1).optional(),
|
|
340
|
+
/**
|
|
341
|
+
* A Slack-compatible incoming webhook (`{ text }`) for ops alerts — `reportAlert`
|
|
342
|
+
* (lib/sentry.ts): the pages (a lost settlement, a dead webhook, a paused collection or source,
|
|
343
|
+
* a failing cron job), one message per condition per 30 minutes. A secret: the URL is the
|
|
344
|
+
* credential. UNSET (or "") ⇒ alerts go to Sentry only (and nowhere without `SENTRY_DSN`) — no
|
|
345
|
+
* POST, no error.
|
|
346
|
+
*/
|
|
347
|
+
OPS_ALERT_WEBHOOK_URL: z.preprocess((v) => (v === "" ? undefined : v), z.url().optional()),
|
|
348
|
+
/**
|
|
349
|
+
* The FROM address for pause/resume/review-request notices (lib/email/send.ts). UNSET ⇒ the
|
|
350
|
+
* whole email lane no-ops — the same "unset ⇒ off" contract as ORACLE_MATRIX_ACCESS_TOKEN — so
|
|
351
|
+
* local dev and a fresh deploy never fail loud over a domain that hasn't been onboarded onto
|
|
352
|
+
* Cloudflare Email Sending yet (`wrangler email sending enable <domain>`, out of band).
|
|
353
|
+
*/
|
|
354
|
+
EMAIL_FROM_ADDRESS: z.string().min(1).optional(),
|
|
355
|
+
/** Display name on outbound notices. Unset ⇒ the oracle's own `name` (`defineOracle`). */
|
|
356
|
+
EMAIL_FROM_NAME: z.string().min(1).optional(),
|
|
357
|
+
})
|
|
358
|
+
.refine((c) => (c.EVALUATION_DENOM === undefined) === (c.EVALUATION_MIN_AMOUNT === undefined), {
|
|
359
|
+
path: ["EVALUATION_MIN_AMOUNT"],
|
|
360
|
+
message: "EVALUATION_DENOM and EVALUATION_MIN_AMOUNT are set together or not at all",
|
|
361
|
+
})
|
|
362
|
+
.refine((c) => c.IXO_NETWORK !== "mainnet" || c.EVALUATION_DENOM !== undefined, {
|
|
363
|
+
path: ["EVALUATION_DENOM"],
|
|
364
|
+
message: "required on mainnet (with EVALUATION_MIN_AMOUNT): the coin collections pay this oracle in — real USDC, never a stand-in",
|
|
365
|
+
})
|
|
366
|
+
.refine((c) => !c.API_LANE || c.WEBHOOK_ENCRYPTION_KEY !== undefined, {
|
|
367
|
+
path: ["WEBHOOK_ENCRYPTION_KEY"],
|
|
368
|
+
message: "required when API_LANE is on (it encrypts every source's webhook signing secret)",
|
|
369
|
+
})
|
|
370
|
+
.refine((c) => !c.API_LANE || c.UNIQUE_HMAC_KEY !== undefined, {
|
|
371
|
+
path: ["UNIQUE_HMAC_KEY"],
|
|
372
|
+
message: "required when API_LANE is on (a submit's submitter is recorded by its digest)",
|
|
373
|
+
})
|
|
374
|
+
.refine((c) => !c.API_PAYMENTS || c.X402_FACILITATOR_URL !== undefined, {
|
|
375
|
+
path: ["X402_FACILITATOR_URL"],
|
|
376
|
+
message: "required when API_PAYMENTS is on (every paid submit verifies and settles through it)",
|
|
377
|
+
})
|
|
378
|
+
// `cloudflare` became the default: an oracle upgrading with only its OpenRouter key would fail
|
|
379
|
+
// every AI fact at the point of use — say so once, at start, instead.
|
|
380
|
+
.refine((c) => !(c.AI_PROVIDER === "cloudflare" && c.OPENROUTER_API_KEY && c.AI_GATEWAY_ID === undefined), {
|
|
381
|
+
path: ["AI_PROVIDER"],
|
|
382
|
+
message: "OPENROUTER_API_KEY is set but AI_PROVIDER defaults to cloudflare and AI_GATEWAY_ID is unset — set AI_PROVIDER=openrouter to keep OpenRouter, or AI_GATEWAY_ID (+ the `ai` binding) for the Cloudflare AI Gateway",
|
|
383
|
+
})
|
|
384
|
+
.refine((c) => !c.AI_AUDIO_VIDEO || c.AI_PROVIDER === "openrouter", {
|
|
385
|
+
path: ["AI_AUDIO_VIDEO"],
|
|
386
|
+
message: "audio/video inputs need AI_PROVIDER=openrouter (the Cloudflare AI Gateway route cannot read them)",
|
|
387
|
+
})
|
|
388
|
+
.transform((c) => {
|
|
389
|
+
// The one place the nine per-network URLs turn from "maybe set" into "definitely set": an
|
|
390
|
+
// explicit var always wins, an unset one falls back to IXO_NETWORK's row in networks.ts.
|
|
391
|
+
const d = networkDefaults(c.IXO_NETWORK);
|
|
392
|
+
return {
|
|
393
|
+
...c,
|
|
394
|
+
BLOCKSYNC_GRAPHQL_URL: c.BLOCKSYNC_GRAPHQL_URL ?? d.blocksync,
|
|
395
|
+
CHAIN_RPC_URL: c.CHAIN_RPC_URL ?? d.rpc,
|
|
396
|
+
MATRIX_HOMESERVER_URL: c.MATRIX_HOMESERVER_URL ?? d.matrix,
|
|
397
|
+
UCAN_STORE_URL: c.UCAN_STORE_URL ?? d.ucanStore,
|
|
398
|
+
VFS_URL: c.VFS_URL ?? d.vfs,
|
|
399
|
+
IPFS_GATEWAY_URL: c.IPFS_GATEWAY_URL ?? d.ipfsGateway,
|
|
400
|
+
EVAL_ENGINE_HOSTNAME: c.EVAL_ENGINE_HOSTNAME ?? d.engineHost,
|
|
401
|
+
PORTAL_BASE_URL: c.PORTAL_BASE_URL ?? d.portal,
|
|
402
|
+
AUTH_HUB_URL: c.AUTH_HUB_URL ?? d.authHub,
|
|
403
|
+
};
|
|
404
|
+
});
|
|
405
|
+
// Memoize per Env object so we validate once per isolate, not once per request.
|
|
406
|
+
const cache = new WeakMap();
|
|
407
|
+
export function loadConfig(env) {
|
|
408
|
+
const cached = cache.get(env);
|
|
409
|
+
if (cached)
|
|
410
|
+
return cached;
|
|
411
|
+
const parsed = ConfigSchema.safeParse(env);
|
|
412
|
+
if (!parsed.success) {
|
|
413
|
+
const issues = parsed.error.issues
|
|
414
|
+
.map((i) => `${i.path.join(".") || "(root)"}: ${i.message}`)
|
|
415
|
+
.join("; ");
|
|
416
|
+
throw new Error(`Invalid environment configuration: ${issues}`);
|
|
417
|
+
}
|
|
418
|
+
cache.set(env, parsed.data);
|
|
419
|
+
return parsed.data;
|
|
420
|
+
}
|
|
421
|
+
export function corsOrigins(config) {
|
|
422
|
+
const raw = config.CORS_ORIGINS.trim();
|
|
423
|
+
if (raw === "*" || raw === "")
|
|
424
|
+
return "*";
|
|
425
|
+
return raw
|
|
426
|
+
.split(",")
|
|
427
|
+
.map((o) => o.trim())
|
|
428
|
+
.filter(Boolean);
|
|
429
|
+
}
|
|
430
|
+
export const isProduction = (config) => config.ENVIRONMENT === "production";
|
|
431
|
+
//# sourceMappingURL=config.js.map
|