@learncard/network-brain-service 3.18.0 → 3.19.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/.env.example +38 -2
- package/CHANGELOG.md +118 -0
- package/README.md +42 -0
- package/compose.inbox.yml +7 -0
- package/dist/accesslayer/auth-grant/read.d.ts +1 -0
- package/dist/accesslayer/auth-grant/read.d.ts.map +1 -1
- package/dist/accesslayer/consentflowcontract/relationships/create.d.ts.map +1 -1
- package/dist/accesslayer/consentflowcontract/relationships/update.d.ts.map +1 -1
- package/dist/accesslayer/credential-activity/create.d.ts.map +1 -1
- package/dist/accesslayer/credential-refresh/email-delivery.d.ts +18 -0
- package/dist/accesslayer/credential-refresh/email-delivery.d.ts.map +1 -0
- package/dist/accesslayer/credential-refresh/index.d.ts +1 -0
- package/dist/accesslayer/credential-refresh/index.d.ts.map +1 -1
- package/dist/accesslayer/credential-refresh/read.d.ts.map +1 -1
- package/dist/accesslayer/credential-refresh/update.d.ts.map +1 -1
- package/dist/accesslayer/inbox-batch/store.d.ts +33 -0
- package/dist/accesslayer/inbox-batch/store.d.ts.map +1 -0
- package/dist/accesslayer/inbox-credential/create.d.ts +5 -0
- package/dist/accesslayer/inbox-credential/create.d.ts.map +1 -1
- package/dist/accesslayer/inbox-credential/refresh.d.ts +71 -0
- package/dist/accesslayer/inbox-credential/refresh.d.ts.map +1 -0
- package/dist/accesslayer/inbox-credential/update.d.ts +1 -1
- package/dist/accesslayer/inbox-credential/update.d.ts.map +1 -1
- package/dist/accesslayer/presentation/read.d.ts.map +1 -1
- package/dist/accesslayer/presentation/relationships/create.d.ts +2 -2
- package/dist/accesslayer/presentation/relationships/create.d.ts.map +1 -1
- package/dist/accesslayer/presentation/relationships/read.d.ts.map +1 -1
- package/dist/accesslayer/share-link/abandon.d.ts +3 -0
- package/dist/accesslayer/share-link/abandon.d.ts.map +1 -0
- package/dist/accesslayer/share-link/cleanup.d.ts +6 -0
- package/dist/accesslayer/share-link/cleanup.d.ts.map +1 -0
- package/dist/accesslayer/share-link/errors.d.ts +8 -0
- package/dist/accesslayer/share-link/errors.d.ts.map +1 -0
- package/dist/accesslayer/share-link/finalize.d.ts +3 -0
- package/dist/accesslayer/share-link/finalize.d.ts.map +1 -0
- package/dist/accesslayer/share-link/helpers.d.ts +56 -0
- package/dist/accesslayer/share-link/helpers.d.ts.map +1 -0
- package/dist/accesslayer/share-link/index.d.ts +12 -0
- package/dist/accesslayer/share-link/index.d.ts.map +1 -0
- package/dist/accesslayer/share-link/list.d.ts +5 -0
- package/dist/accesslayer/share-link/list.d.ts.map +1 -0
- package/dist/accesslayer/share-link/read.d.ts +5 -0
- package/dist/accesslayer/share-link/read.d.ts.map +1 -0
- package/dist/accesslayer/share-link/receipt.d.ts +11 -0
- package/dist/accesslayer/share-link/receipt.d.ts.map +1 -0
- package/dist/accesslayer/share-link/recovery.d.ts +6 -0
- package/dist/accesslayer/share-link/recovery.d.ts.map +1 -0
- package/dist/accesslayer/share-link/reserve.d.ts +4 -0
- package/dist/accesslayer/share-link/reserve.d.ts.map +1 -0
- package/dist/accesslayer/share-link/revoke.d.ts +3 -0
- package/dist/accesslayer/share-link/revoke.d.ts.map +1 -0
- package/dist/accesslayer/share-link/transaction-execution.d.ts +18 -0
- package/dist/accesslayer/share-link/transaction-execution.d.ts.map +1 -0
- package/dist/accesslayer/share-link/transaction.d.ts +15 -0
- package/dist/accesslayer/share-link/transaction.d.ts.map +1 -0
- package/dist/accesslayer/share-link/types.d.ts +370 -0
- package/dist/accesslayer/share-link/types.d.ts.map +1 -0
- package/dist/app.d.ts +4 -0
- package/dist/app.d.ts.map +1 -1
- package/dist/cache/atomic-counter.test-helpers.d.ts +3 -0
- package/dist/cache/atomic-counter.test-helpers.d.ts.map +1 -0
- package/dist/cache/atomic-counter.test.d.ts +2 -0
- package/dist/cache/atomic-counter.test.d.ts.map +1 -0
- package/dist/cache/index.d.ts +1 -1
- package/dist/cache/index.d.ts.map +1 -1
- package/dist/config/environment.d.ts +55 -0
- package/dist/config/environment.d.ts.map +1 -1
- package/dist/constants/auth-grant.d.ts +2 -0
- package/dist/constants/auth-grant.d.ts.map +1 -1
- package/dist/credential-refresh.d.ts.map +1 -1
- package/dist/helpers/activity.helpers.d.ts +4 -0
- package/dist/helpers/activity.helpers.d.ts.map +1 -1
- package/dist/helpers/boost.helpers.d.ts.map +1 -1
- package/dist/helpers/contact-method.helpers.d.ts.map +1 -1
- package/dist/helpers/contact-method.helpers.test.d.ts +2 -0
- package/dist/helpers/contact-method.helpers.test.d.ts.map +1 -0
- package/dist/helpers/credential-refresh-email-content.helpers.d.ts +44 -0
- package/dist/helpers/credential-refresh-email-content.helpers.d.ts.map +1 -0
- package/dist/helpers/credential-refresh-email-content.helpers.test.d.ts +2 -0
- package/dist/helpers/credential-refresh-email-content.helpers.test.d.ts.map +1 -0
- package/dist/helpers/credential-refresh-email.helpers.d.ts +17 -0
- package/dist/helpers/credential-refresh-email.helpers.d.ts.map +1 -0
- package/dist/helpers/credential-refresh-proof.helpers.d.ts +4 -0
- package/dist/helpers/credential-refresh-proof.helpers.d.ts.map +1 -0
- package/dist/helpers/credential-refresh-proof.helpers.test.d.ts +2 -0
- package/dist/helpers/credential-refresh-proof.helpers.test.d.ts.map +1 -0
- package/dist/helpers/credential-refresh.helpers.d.ts +45 -2
- package/dist/helpers/credential-refresh.helpers.d.ts.map +1 -1
- package/dist/helpers/credential.helpers.d.ts +2 -1
- package/dist/helpers/credential.helpers.d.ts.map +1 -1
- package/dist/helpers/credentialSubject.helpers.d.ts +3 -0
- package/dist/helpers/credentialSubject.helpers.d.ts.map +1 -0
- package/dist/helpers/credentialSubject.helpers.test.d.ts +2 -0
- package/dist/helpers/credentialSubject.helpers.test.d.ts.map +1 -0
- package/dist/helpers/finalize-inbox.helpers.d.ts.map +1 -1
- package/dist/helpers/inbox-batch-http.helpers.d.ts +15 -0
- package/dist/helpers/inbox-batch-http.helpers.d.ts.map +1 -0
- package/dist/helpers/inbox-batch-http.helpers.test.d.ts +2 -0
- package/dist/helpers/inbox-batch-http.helpers.test.d.ts.map +1 -0
- package/dist/helpers/inbox-batch-status.helpers.d.ts +3 -0
- package/dist/helpers/inbox-batch-status.helpers.d.ts.map +1 -0
- package/dist/helpers/inbox-batch.helpers.d.ts +10 -0
- package/dist/helpers/inbox-batch.helpers.d.ts.map +1 -0
- package/dist/helpers/inbox-batch.helpers.test.d.ts +2 -0
- package/dist/helpers/inbox-batch.helpers.test.d.ts.map +1 -0
- package/dist/helpers/inbox-issuance-error.helpers.d.ts +13 -0
- package/dist/helpers/inbox-issuance-error.helpers.d.ts.map +1 -0
- package/dist/helpers/inbox-queue.helpers.d.ts +11 -0
- package/dist/helpers/inbox-queue.helpers.d.ts.map +1 -0
- package/dist/helpers/inbox-queue.helpers.test.d.ts +2 -0
- package/dist/helpers/inbox-queue.helpers.test.d.ts.map +1 -0
- package/dist/helpers/inbox-refresh.helpers.d.ts +186 -0
- package/dist/helpers/inbox-refresh.helpers.d.ts.map +1 -0
- package/dist/helpers/inbox.helpers.d.ts +9 -1
- package/dist/helpers/inbox.helpers.d.ts.map +1 -1
- package/dist/helpers/notificationMessages.d.ts +1 -1
- package/dist/helpers/notificationMessages.d.ts.map +1 -1
- package/dist/helpers/notifications.helpers.d.ts.map +1 -1
- package/dist/helpers/presentation-metadata.d.ts +4 -0
- package/dist/helpers/presentation-metadata.d.ts.map +1 -0
- package/dist/helpers/presentation.helpers.d.ts +1 -1
- package/dist/helpers/presentation.helpers.d.ts.map +1 -1
- package/dist/helpers/profile.helpers.d.ts +1 -0
- package/dist/helpers/profile.helpers.d.ts.map +1 -1
- package/dist/helpers/rateLimit.helpers.d.ts.map +1 -1
- package/dist/helpers/refresh-send-intent.helpers.d.ts +51 -0
- package/dist/helpers/refresh-send-intent.helpers.d.ts.map +1 -0
- package/dist/helpers/share-content-client/adapters.d.ts +10 -0
- package/dist/helpers/share-content-client/adapters.d.ts.map +1 -0
- package/dist/helpers/share-content-client/canonical.d.ts +7 -0
- package/dist/helpers/share-content-client/canonical.d.ts.map +1 -0
- package/dist/helpers/share-content-client/client.d.ts +5 -0
- package/dist/helpers/share-content-client/client.d.ts.map +1 -0
- package/dist/helpers/share-content-client/config.d.ts +11 -0
- package/dist/helpers/share-content-client/config.d.ts.map +1 -0
- package/dist/helpers/share-content-client/index.d.ts +6 -0
- package/dist/helpers/share-content-client/index.d.ts.map +1 -0
- package/dist/helpers/share-content-client/responses.d.ts +16 -0
- package/dist/helpers/share-content-client/responses.d.ts.map +1 -0
- package/dist/helpers/share-content-client/types.d.ts +145 -0
- package/dist/helpers/share-content-client/types.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/budget-helpers.d.ts +5 -0
- package/dist/helpers/share-link-coordinator/budget-helpers.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/cleanup-runner.d.ts +3 -0
- package/dist/helpers/share-link-coordinator/cleanup-runner.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/coordinator.d.ts +4 -0
- package/dist/helpers/share-link-coordinator/coordinator.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/index.d.ts +5 -0
- package/dist/helpers/share-link-coordinator/index.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/recovery-runner.d.ts +9 -0
- package/dist/helpers/share-link-coordinator/recovery-runner.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/runtime.d.ts +11 -0
- package/dist/helpers/share-link-coordinator/runtime.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/stat.d.ts +4 -0
- package/dist/helpers/share-link-coordinator/stat.d.ts.map +1 -0
- package/dist/helpers/share-link-coordinator/types.d.ts +160 -0
- package/dist/helpers/share-link-coordinator/types.d.ts.map +1 -0
- package/dist/helpers/share-link-lifecycle/index.d.ts +5 -0
- package/dist/helpers/share-link-lifecycle/index.d.ts.map +1 -0
- package/dist/helpers/share-link-lifecycle/lease.helpers.d.ts +4 -0
- package/dist/helpers/share-link-lifecycle/lease.helpers.d.ts.map +1 -0
- package/dist/helpers/share-link-lifecycle/recovery.helpers.d.ts +21 -0
- package/dist/helpers/share-link-lifecycle/recovery.helpers.d.ts.map +1 -0
- package/dist/helpers/share-link-lifecycle/request-hash.helpers.d.ts +9 -0
- package/dist/helpers/share-link-lifecycle/request-hash.helpers.d.ts.map +1 -0
- package/dist/helpers/share-link-lifecycle/types.d.ts +14 -0
- package/dist/helpers/share-link-lifecycle/types.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/budget.d.ts +12 -0
- package/dist/helpers/share-link-maintenance/budget.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/config.d.ts +48 -0
- package/dist/helpers/share-link-maintenance/config.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/index.d.ts +8 -0
- package/dist/helpers/share-link-maintenance/index.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/runner.d.ts +19 -0
- package/dist/helpers/share-link-maintenance/runner.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/runtime.d.ts +36 -0
- package/dist/helpers/share-link-maintenance/runtime.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/scheduler.d.ts +18 -0
- package/dist/helpers/share-link-maintenance/scheduler.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/telemetry.d.ts +5 -0
- package/dist/helpers/share-link-maintenance/telemetry.d.ts.map +1 -0
- package/dist/helpers/share-link-maintenance/types.d.ts +53 -0
- package/dist/helpers/share-link-maintenance/types.d.ts.map +1 -0
- package/dist/helpers/share-link-owner/config.d.ts +16 -0
- package/dist/helpers/share-link-owner/config.d.ts.map +1 -0
- package/dist/helpers/share-link-owner/diagnostics.d.ts +26 -0
- package/dist/helpers/share-link-owner/diagnostics.d.ts.map +1 -0
- package/dist/helpers/share-link-owner/lazy-initializer.d.ts +2 -0
- package/dist/helpers/share-link-owner/lazy-initializer.d.ts.map +1 -0
- package/dist/helpers/share-link-owner-projection.d.ts +4 -0
- package/dist/helpers/share-link-owner-projection.d.ts.map +1 -0
- package/dist/helpers/share-link-passcode-abuse.d.ts +2 -0
- package/dist/helpers/share-link-passcode-abuse.d.ts.map +1 -0
- package/dist/helpers/share-link-passcode.d.ts +6 -0
- package/dist/helpers/share-link-passcode.d.ts.map +1 -0
- package/dist/helpers/share-link-policy/index.d.ts +4 -0
- package/dist/helpers/share-link-policy/index.d.ts.map +1 -0
- package/dist/helpers/share-link-policy/production.d.ts +13 -0
- package/dist/helpers/share-link-policy/production.d.ts.map +1 -0
- package/dist/helpers/share-link-policy/resolver.d.ts +6 -0
- package/dist/helpers/share-link-policy/resolver.d.ts.map +1 -0
- package/dist/helpers/share-link-policy/types.d.ts +16 -0
- package/dist/helpers/share-link-policy/types.d.ts.map +1 -0
- package/dist/helpers/share-link-public/config.d.ts +13 -0
- package/dist/helpers/share-link-public/config.d.ts.map +1 -0
- package/dist/helpers/share-link-view-notification.d.ts +2 -0
- package/dist/helpers/share-link-view-notification.d.ts.map +1 -0
- package/dist/helpers/shim.d.ts +1 -1
- package/dist/helpers/shim.d.ts.map +1 -1
- package/dist/inbox-queue-local.d.ts +2 -0
- package/dist/inbox-queue-local.d.ts.map +1 -0
- package/dist/index.js +2 -2
- package/dist/models/AuthGrant.d.ts.map +1 -1
- package/dist/models/CredentialActivity.d.ts +1 -0
- package/dist/models/CredentialActivity.d.ts.map +1 -1
- package/dist/models/CredentialRefresh.d.ts +5 -2
- package/dist/models/CredentialRefresh.d.ts.map +1 -1
- package/dist/models/InboxCredential.d.ts +1 -0
- package/dist/models/InboxCredential.d.ts.map +1 -1
- package/dist/models/Presentation.d.ts +2 -0
- package/dist/models/Presentation.d.ts.map +1 -1
- package/dist/models/Profile.d.ts +2 -0
- package/dist/models/Profile.d.ts.map +1 -1
- package/dist/models/ShareLink.d.ts +44 -0
- package/dist/models/ShareLink.d.ts.map +1 -0
- package/dist/models/ShareViewReceipt.d.ts +22 -0
- package/dist/models/ShareViewReceipt.d.ts.map +1 -0
- package/dist/models/credential-refresh-constraints.d.ts.map +1 -1
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.d.ts.map +1 -1
- package/dist/models/share-link-constraints.d.ts +3 -0
- package/dist/models/share-link-constraints.d.ts.map +1 -0
- package/dist/openapi.d.ts.map +1 -1
- package/dist/public-share-link-http.d.ts +4 -0
- package/dist/public-share-link-http.d.ts.map +1 -0
- package/dist/routes/act-as.test.d.ts +2 -0
- package/dist/routes/act-as.test.d.ts.map +1 -0
- package/dist/routes/activity.d.ts +3 -0
- package/dist/routes/activity.d.ts.map +1 -1
- package/dist/routes/app-store.d.ts.map +1 -1
- package/dist/routes/auth-grants.d.ts +10 -0
- package/dist/routes/auth-grants.d.ts.map +1 -1
- package/dist/routes/boosts.d.ts +494 -0
- package/dist/routes/boosts.d.ts.map +1 -1
- package/dist/routes/contracts.d.ts +2 -2
- package/dist/routes/contracts.d.ts.map +1 -1
- package/dist/routes/credential-refreshes.d.ts.map +1 -1
- package/dist/routes/credentials.d.ts +1 -1
- package/dist/routes/credentials.d.ts.map +1 -1
- package/dist/routes/inbox.d.ts +953 -11
- package/dist/routes/inbox.d.ts.map +1 -1
- package/dist/routes/index.d.ts +154 -85
- package/dist/routes/index.d.ts.map +1 -1
- package/dist/routes/presentations.d.ts +1 -0
- package/dist/routes/presentations.d.ts.map +1 -1
- package/dist/routes/profile-manager.d.ts.map +1 -1
- package/dist/routes/profiles.d.ts.map +1 -1
- package/dist/routes/public-share-links.d.ts +230 -0
- package/dist/routes/public-share-links.d.ts.map +1 -0
- package/dist/routes/share-links.d.ts +844 -0
- package/dist/routes/share-links.d.ts.map +1 -0
- package/dist/routes/workflows.d.ts.map +1 -1
- package/dist/services/delivery/adapters/postmark.adapter.d.ts.map +1 -1
- package/dist/services/delivery/adapters/postmark.adapter.test.d.ts +2 -0
- package/dist/services/delivery/adapters/postmark.adapter.test.d.ts.map +1 -0
- package/dist/services/registry/registry.factory.d.ts.map +1 -1
- package/dist/types/activity.d.ts +4 -0
- package/dist/types/activity.d.ts.map +1 -1
- package/dist/types/consentflowcontract.d.ts +1 -1
- package/dist/types/credential-refresh.d.ts +10 -1
- package/dist/types/credential-refresh.d.ts.map +1 -1
- package/dist/types/inbox-batch.d.ts +38 -0
- package/dist/types/inbox-batch.d.ts.map +1 -0
- package/inbox-e2e-setup.ts +53 -1
- package/inbox-elasticmq.conf +10 -0
- package/lambda.ts +64 -16
- package/package.json +24 -16
- package/scripts/seed-demo-persona.ts +425 -0
- package/scripts/setup-inbox-queues.ts +60 -0
- package/serverless-local.yml +2 -0
- package/serverless.yml +111 -0
- package/shareLinkMaintenanceLambda.ts +49 -0
- package/src/accesslayer/auth-grant/read.ts +2 -1
- package/src/accesslayer/consentflowcontract/relationships/create.ts +9 -16
- package/src/accesslayer/consentflowcontract/relationships/update.ts +15 -28
- package/src/accesslayer/credential-activity/create.ts +1 -0
- package/src/accesslayer/credential-refresh/email-delivery.ts +116 -0
- package/src/accesslayer/credential-refresh/index.ts +1 -0
- package/src/accesslayer/credential-refresh/read.ts +8 -2
- package/src/accesslayer/credential-refresh/update.ts +4 -0
- package/src/accesslayer/inbox-batch/store.ts +469 -0
- package/src/accesslayer/inbox-credential/create.ts +51 -19
- package/src/accesslayer/inbox-credential/refresh.ts +221 -0
- package/src/accesslayer/inbox-credential/update.ts +1 -1
- package/src/accesslayer/presentation/read.ts +57 -25
- package/src/accesslayer/presentation/relationships/create.ts +54 -11
- package/src/accesslayer/presentation/relationships/read.ts +21 -6
- package/src/accesslayer/share-link/abandon.ts +100 -0
- package/src/accesslayer/share-link/cleanup.ts +271 -0
- package/src/accesslayer/share-link/errors.ts +32 -0
- package/src/accesslayer/share-link/finalize.ts +265 -0
- package/src/accesslayer/share-link/helpers.ts +419 -0
- package/src/accesslayer/share-link/index.ts +11 -0
- package/src/accesslayer/share-link/list.ts +162 -0
- package/src/accesslayer/share-link/read.ts +107 -0
- package/src/accesslayer/share-link/receipt.ts +548 -0
- package/src/accesslayer/share-link/recovery.ts +545 -0
- package/src/accesslayer/share-link/reserve.ts +684 -0
- package/src/accesslayer/share-link/revoke.ts +197 -0
- package/src/accesslayer/share-link/transaction-execution.ts +72 -0
- package/src/accesslayer/share-link/transaction.ts +126 -0
- package/src/accesslayer/share-link/types.ts +601 -0
- package/src/app.ts +6 -0
- package/src/cache/atomic-counter.test-helpers.ts +27 -0
- package/src/cache/atomic-counter.test.ts +6 -0
- package/src/cache/index.ts +25 -13
- package/src/config/environment.ts +40 -0
- package/src/constants/auth-grant.ts +5 -0
- package/src/credential-refresh.ts +5 -1
- package/src/docker-entry.ts +65 -0
- package/src/helpers/activity.helpers.ts +4 -0
- package/src/helpers/app-counter.helpers.ts +1 -1
- package/src/helpers/boost.helpers.ts +4 -31
- package/src/helpers/contact-method.helpers.test.ts +43 -0
- package/src/helpers/contact-method.helpers.ts +3 -4
- package/src/helpers/credential-refresh-email-content.helpers.test.ts +222 -0
- package/src/helpers/credential-refresh-email-content.helpers.ts +155 -0
- package/src/helpers/credential-refresh-email.helpers.ts +201 -0
- package/src/helpers/credential-refresh-proof.helpers.test.ts +103 -0
- package/src/helpers/credential-refresh-proof.helpers.ts +43 -0
- package/src/helpers/credential-refresh.helpers.ts +375 -99
- package/src/helpers/credential.helpers.ts +4 -1
- package/src/helpers/credentialSubject.helpers.test.ts +114 -0
- package/src/helpers/credentialSubject.helpers.ts +40 -0
- package/src/helpers/finalize-inbox.helpers.ts +29 -14
- package/src/helpers/inbox-batch-http.helpers.test.ts +188 -0
- package/src/helpers/inbox-batch-http.helpers.ts +150 -0
- package/src/helpers/inbox-batch-status.helpers.ts +11 -0
- package/src/helpers/inbox-batch.helpers.test.ts +668 -0
- package/src/helpers/inbox-batch.helpers.ts +374 -0
- package/src/helpers/inbox-issuance-error.helpers.ts +25 -0
- package/src/helpers/inbox-queue.helpers.test.ts +253 -0
- package/src/helpers/inbox-queue.helpers.ts +372 -0
- package/src/helpers/inbox-refresh.helpers.ts +432 -0
- package/src/helpers/inbox.helpers.ts +275 -36
- package/src/helpers/notificationMessages.ts +18 -1
- package/src/helpers/notifications.helpers.ts +4 -2
- package/src/helpers/presentation-metadata.ts +41 -0
- package/src/helpers/presentation.helpers.ts +27 -20
- package/src/helpers/profile.helpers.ts +7 -0
- package/src/helpers/rateLimit.helpers.ts +2 -5
- package/src/helpers/refresh-send-intent.helpers.ts +273 -0
- package/src/helpers/share-content-client/adapters.ts +55 -0
- package/src/helpers/share-content-client/canonical.ts +25 -0
- package/src/helpers/share-content-client/client.ts +440 -0
- package/src/helpers/share-content-client/config.ts +189 -0
- package/src/helpers/share-content-client/index.ts +27 -0
- package/src/helpers/share-content-client/responses.ts +273 -0
- package/src/helpers/share-content-client/types.ts +253 -0
- package/src/helpers/share-link-coordinator/budget-helpers.ts +53 -0
- package/src/helpers/share-link-coordinator/cleanup-runner.ts +286 -0
- package/src/helpers/share-link-coordinator/coordinator.ts +714 -0
- package/src/helpers/share-link-coordinator/index.ts +8 -0
- package/src/helpers/share-link-coordinator/recovery-runner.ts +428 -0
- package/src/helpers/share-link-coordinator/runtime.ts +88 -0
- package/src/helpers/share-link-coordinator/stat.ts +30 -0
- package/src/helpers/share-link-coordinator/types.ts +353 -0
- package/src/helpers/share-link-lifecycle/index.ts +4 -0
- package/src/helpers/share-link-lifecycle/lease.helpers.ts +35 -0
- package/src/helpers/share-link-lifecycle/recovery.helpers.ts +173 -0
- package/src/helpers/share-link-lifecycle/request-hash.helpers.ts +130 -0
- package/src/helpers/share-link-lifecycle/types.ts +58 -0
- package/src/helpers/share-link-maintenance/budget.ts +63 -0
- package/src/helpers/share-link-maintenance/config.ts +312 -0
- package/src/helpers/share-link-maintenance/index.ts +24 -0
- package/src/helpers/share-link-maintenance/runner.ts +223 -0
- package/src/helpers/share-link-maintenance/runtime.ts +334 -0
- package/src/helpers/share-link-maintenance/scheduler.ts +126 -0
- package/src/helpers/share-link-maintenance/telemetry.ts +70 -0
- package/src/helpers/share-link-maintenance/types.ts +89 -0
- package/src/helpers/share-link-owner/config.ts +48 -0
- package/src/helpers/share-link-owner/diagnostics.ts +89 -0
- package/src/helpers/share-link-owner/lazy-initializer.ts +29 -0
- package/src/helpers/share-link-owner-projection.ts +52 -0
- package/src/helpers/share-link-passcode-abuse.ts +36 -0
- package/src/helpers/share-link-passcode.ts +47 -0
- package/src/helpers/share-link-policy/index.ts +7 -0
- package/src/helpers/share-link-policy/production.ts +88 -0
- package/src/helpers/share-link-policy/resolver.ts +108 -0
- package/src/helpers/share-link-policy/types.ts +48 -0
- package/src/helpers/share-link-public/config.ts +41 -0
- package/src/helpers/share-link-view-notification.ts +18 -0
- package/src/helpers/shim.ts +32 -31
- package/src/inbox-queue-local.ts +28 -0
- package/src/models/AuthGrant.ts +1 -0
- package/src/models/CredentialActivity.ts +3 -5
- package/src/models/CredentialRefresh.ts +4 -2
- package/src/models/InboxCredential.ts +2 -0
- package/src/models/Presentation.ts +2 -2
- package/src/models/Profile.ts +3 -2
- package/src/models/ShareLink.ts +130 -0
- package/src/models/ShareViewReceipt.ts +69 -0
- package/src/models/credential-refresh-constraints.test.ts +8 -3
- package/src/models/credential-refresh-constraints.ts +5 -0
- package/src/models/index.ts +2 -0
- package/src/models/share-link-constraints.ts +93 -0
- package/src/openapi.ts +8 -0
- package/src/public-share-link-http.ts +49 -0
- package/src/routes/act-as.test.ts +239 -0
- package/src/routes/app-store.ts +4 -13
- package/src/routes/auth-grants.ts +13 -11
- package/src/routes/boosts.ts +916 -103
- package/src/routes/contracts.ts +2 -11
- package/src/routes/credential-refreshes.test.ts +8 -2
- package/src/routes/credential-refreshes.ts +4 -1
- package/src/routes/credentials.ts +2 -1
- package/src/routes/inbox.ts +95 -49
- package/src/routes/index.ts +216 -46
- package/src/routes/presentations.ts +19 -3
- package/src/routes/profile-manager.ts +10 -2
- package/src/routes/profiles.ts +17 -6
- package/src/routes/public-share-links.ts +814 -0
- package/src/routes/share-links.ts +640 -0
- package/src/routes/skills.ts +1 -1
- package/src/routes/workflows.ts +43 -24
- package/src/services/delivery/adapters/postmark.adapter.test.ts +54 -0
- package/src/services/delivery/adapters/postmark.adapter.ts +16 -1
- package/src/services/registry/registry.factory.ts +2 -1
- package/src/types/activity.ts +2 -0
- package/src/types/credential-refresh.ts +21 -2
- package/src/types/inbox-batch.ts +46 -0
- package/test/atomic-counter.e2e.ts +12 -0
- package/test/auth-grant.spec.ts +21 -21
- package/test/credential-refresh-email.spec.ts +663 -0
- package/test/credential-refresh-publication.spec.ts +2 -0
- package/test/dids.spec.ts +10 -1
- package/test/guardian-gated-routes.spec.ts +13 -0
- package/test/helpers/inbox-e2e-environment.ts +6 -0
- package/test/helpers/share-link-fixtures.ts +94 -0
- package/test/inbox-batch.spec.ts +1338 -0
- package/test/inbox-refresh.spec.ts +534 -0
- package/test/managed-recipient-inbox.spec.ts +130 -0
- package/test/notificationMessages.spec.ts +13 -0
- package/test/openapi.spec.ts +61 -1
- package/test/presentations.spec.ts +54 -6
- package/test/profiles.spec.ts +67 -1
- package/test/refresh-send.spec.ts +1799 -0
- package/test/registry.spec.ts +56 -11
- package/test/share-content-client.contract.spec.ts +365 -0
- package/test/share-content-client.unit.spec.ts +462 -0
- package/test/share-link-abuse.unit.spec.ts +65 -0
- package/test/share-link-coordinator.neo4j.spec.ts +684 -0
- package/test/share-link-coordinator.unit.spec.ts +990 -0
- package/test/share-link-dependency-diagnostics.unit.spec.ts +127 -0
- package/test/share-link-lifecycle.neo4j.spec.ts +1268 -0
- package/test/share-link-lifecycle.unit.spec.ts +205 -0
- package/test/share-link-list-cursor.unit.spec.ts +86 -0
- package/test/share-link-list.neo4j.spec.ts +324 -0
- package/test/share-link-maintenance.neo4j.spec.ts +355 -0
- package/test/share-link-maintenance.unit.spec.ts +1113 -0
- package/test/share-link-owner-policy.unit.spec.ts +210 -0
- package/test/share-link-owner-route.unit.spec.ts +752 -0
- package/test/share-link-owner-runtime.unit.spec.ts +102 -0
- package/test/share-link-passcode.unit.spec.ts +29 -0
- package/test/share-link-policy.unit.spec.ts +135 -0
- package/test/share-link-presentation-metadata.unit.spec.ts +49 -0
- package/test/share-link-production-policy.unit.spec.ts +77 -0
- package/test/share-link-public-config.unit.spec.ts +64 -0
- package/test/share-link-public-http-adapter.unit.spec.ts +315 -0
- package/test/share-link-public-route.unit.spec.ts +800 -0
- package/test/share-link-receipt.neo4j.spec.ts +943 -0
- package/test/share-link-recovery.neo4j.spec.ts +935 -0
- package/test/share-link-recovery.unit.spec.ts +726 -0
- package/vitest.config.ts +10 -0
- package/vitest.inbox-e2e.config.ts +5 -1
- package/vitest.integration.config.ts +2 -0
- package/vitest.share-links-neo4j.config.ts +19 -0
- package/vitest.share-links-unit.config.ts +28 -0
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
import type { InboxCredentialRefreshReceipt, PublishCredentialRefreshInput, PublishCredentialRefreshResult, VC } from '@learncard/types';
|
|
2
|
+
import type { ProfileType } from '../types/profile';
|
|
3
|
+
import type { CredentialRefreshRecord } from '../types/credential-refresh';
|
|
4
|
+
export declare const assertInboxRefreshEnabled: (scope?: string) => Promise<void>;
|
|
5
|
+
export declare const inboxRefreshRequestDigest: (request: unknown) => string;
|
|
6
|
+
export declare const getInboxRefreshIssueKey: (issuerProfileId: string, key: string) => string;
|
|
7
|
+
export declare const getInboxRefreshReplay: (issuerProfileId: string, key: string | undefined, requestDigest: string) => Promise<{
|
|
8
|
+
inbox: import("@learncard/types").InboxCredentialType;
|
|
9
|
+
requestDigest: string;
|
|
10
|
+
claimUrl?: string;
|
|
11
|
+
} | null>;
|
|
12
|
+
export declare const getInboxRefreshReceipt: (refreshId: string, domain: string) => Promise<InboxCredentialRefreshReceipt>;
|
|
13
|
+
export declare const prepareInboxRefresh: (credential: unknown, issuer: ProfileType, domain: string) => Promise<{
|
|
14
|
+
credential: {
|
|
15
|
+
[x: string]: any;
|
|
16
|
+
'@context': (string | Record<string, any>)[];
|
|
17
|
+
type: string[];
|
|
18
|
+
issuer: string | {
|
|
19
|
+
[x: string]: any;
|
|
20
|
+
id?: string | undefined;
|
|
21
|
+
type?: string | string[] | undefined;
|
|
22
|
+
name?: string | undefined;
|
|
23
|
+
url?: string | undefined;
|
|
24
|
+
phone?: string | undefined;
|
|
25
|
+
description?: string | undefined;
|
|
26
|
+
endorsement?: any[] | undefined;
|
|
27
|
+
image?: string | {
|
|
28
|
+
id: string;
|
|
29
|
+
type: string;
|
|
30
|
+
caption?: string | undefined;
|
|
31
|
+
} | undefined;
|
|
32
|
+
email?: string | undefined;
|
|
33
|
+
address?: {
|
|
34
|
+
type: string | string[];
|
|
35
|
+
addressCountry?: string | undefined;
|
|
36
|
+
addressCountryCode?: string | undefined;
|
|
37
|
+
addressRegion?: string | undefined;
|
|
38
|
+
addressLocality?: string | undefined;
|
|
39
|
+
streetAddress?: string | undefined;
|
|
40
|
+
postOfficeBoxNumber?: string | undefined;
|
|
41
|
+
postalCode?: string | undefined;
|
|
42
|
+
geo?: {
|
|
43
|
+
type: string | string[];
|
|
44
|
+
latitude: number;
|
|
45
|
+
longitude: number;
|
|
46
|
+
} | undefined;
|
|
47
|
+
} | undefined;
|
|
48
|
+
otherIdentifier?: {
|
|
49
|
+
type: string | string[];
|
|
50
|
+
identifier: string;
|
|
51
|
+
identifierType: string;
|
|
52
|
+
}[] | undefined;
|
|
53
|
+
official?: string | undefined;
|
|
54
|
+
parentOrg?: any;
|
|
55
|
+
familyName?: string | undefined;
|
|
56
|
+
givenName?: string | undefined;
|
|
57
|
+
additionalName?: string | undefined;
|
|
58
|
+
patronymicName?: string | undefined;
|
|
59
|
+
honorificPrefix?: string | undefined;
|
|
60
|
+
honorificSuffix?: string | undefined;
|
|
61
|
+
familyNamePrefix?: string | undefined;
|
|
62
|
+
dateOfBirth?: string | undefined;
|
|
63
|
+
};
|
|
64
|
+
credentialSubject: {
|
|
65
|
+
[x: string]: any;
|
|
66
|
+
id?: string | undefined;
|
|
67
|
+
} | {
|
|
68
|
+
[x: string]: any;
|
|
69
|
+
id?: string | undefined;
|
|
70
|
+
}[];
|
|
71
|
+
id?: string | undefined;
|
|
72
|
+
refreshService?: {
|
|
73
|
+
[x: string]: any;
|
|
74
|
+
type: string;
|
|
75
|
+
id?: string | undefined;
|
|
76
|
+
} | {
|
|
77
|
+
[x: string]: any;
|
|
78
|
+
type: string;
|
|
79
|
+
id?: string | undefined;
|
|
80
|
+
}[] | undefined;
|
|
81
|
+
credentialSchema?: {
|
|
82
|
+
[x: string]: any;
|
|
83
|
+
id: string;
|
|
84
|
+
type: string;
|
|
85
|
+
} | {
|
|
86
|
+
[x: string]: any;
|
|
87
|
+
id: string;
|
|
88
|
+
type: string;
|
|
89
|
+
}[] | undefined;
|
|
90
|
+
issuanceDate?: string | undefined;
|
|
91
|
+
expirationDate?: string | undefined;
|
|
92
|
+
credentialStatus?: {
|
|
93
|
+
[x: string]: any;
|
|
94
|
+
type: string;
|
|
95
|
+
id?: string | undefined;
|
|
96
|
+
} | {
|
|
97
|
+
[x: string]: any;
|
|
98
|
+
type: string;
|
|
99
|
+
id?: string | undefined;
|
|
100
|
+
}[] | undefined;
|
|
101
|
+
name?: string | undefined;
|
|
102
|
+
description?: string | undefined;
|
|
103
|
+
validFrom?: string | undefined;
|
|
104
|
+
validUntil?: string | undefined;
|
|
105
|
+
status?: {
|
|
106
|
+
[x: string]: any;
|
|
107
|
+
type: string;
|
|
108
|
+
id?: string | undefined;
|
|
109
|
+
} | {
|
|
110
|
+
[x: string]: any;
|
|
111
|
+
type: string;
|
|
112
|
+
id?: string | undefined;
|
|
113
|
+
}[] | undefined;
|
|
114
|
+
termsOfUse?: {
|
|
115
|
+
[x: string]: any;
|
|
116
|
+
type: string;
|
|
117
|
+
id?: string | undefined;
|
|
118
|
+
} | {
|
|
119
|
+
[x: string]: any;
|
|
120
|
+
type: string;
|
|
121
|
+
id?: string | undefined;
|
|
122
|
+
}[] | undefined;
|
|
123
|
+
evidence?: {
|
|
124
|
+
[x: string]: any;
|
|
125
|
+
type: string[];
|
|
126
|
+
id?: string | undefined;
|
|
127
|
+
name?: string | undefined;
|
|
128
|
+
narrative?: string | undefined;
|
|
129
|
+
description?: string | undefined;
|
|
130
|
+
genre?: string | undefined;
|
|
131
|
+
audience?: string | undefined;
|
|
132
|
+
} | {
|
|
133
|
+
[x: string]: any;
|
|
134
|
+
type: string[];
|
|
135
|
+
id?: string | undefined;
|
|
136
|
+
name?: string | undefined;
|
|
137
|
+
narrative?: string | undefined;
|
|
138
|
+
description?: string | undefined;
|
|
139
|
+
genre?: string | undefined;
|
|
140
|
+
audience?: string | undefined;
|
|
141
|
+
}[] | undefined;
|
|
142
|
+
renderMethod?: Record<string, any> | {
|
|
143
|
+
type: "TemplateRenderMethod";
|
|
144
|
+
renderSuite: string;
|
|
145
|
+
template: string;
|
|
146
|
+
renderProperty?: string[] | undefined;
|
|
147
|
+
outputPreference?: {
|
|
148
|
+
mediaType: string;
|
|
149
|
+
} | undefined;
|
|
150
|
+
} | (Record<string, any> | {
|
|
151
|
+
type: "TemplateRenderMethod";
|
|
152
|
+
renderSuite: string;
|
|
153
|
+
template: string;
|
|
154
|
+
renderProperty?: string[] | undefined;
|
|
155
|
+
outputPreference?: {
|
|
156
|
+
mediaType: string;
|
|
157
|
+
} | undefined;
|
|
158
|
+
})[] | undefined;
|
|
159
|
+
};
|
|
160
|
+
aggregate: {
|
|
161
|
+
refreshId: string;
|
|
162
|
+
issuerProfileId: string;
|
|
163
|
+
issuerDid: string;
|
|
164
|
+
credentialId: string;
|
|
165
|
+
state: string;
|
|
166
|
+
currentVersion: number;
|
|
167
|
+
createdAt: string;
|
|
168
|
+
updatedAt: string;
|
|
169
|
+
credentialStatusDigest: string;
|
|
170
|
+
inboxCredentialStatus: string;
|
|
171
|
+
materialDigest: string;
|
|
172
|
+
};
|
|
173
|
+
}>;
|
|
174
|
+
export declare const publishPendingInboxRefresh: (aggregate: CredentialRefreshRecord, issuer: ProfileType, input: PublishCredentialRefreshInput, domain: string) => Promise<PublishCredentialRefreshResult>;
|
|
175
|
+
export declare const finalizeInboxRefresh: (params: {
|
|
176
|
+
inboxId: string;
|
|
177
|
+
holderDid: string;
|
|
178
|
+
holderProfile?: ProfileType | null;
|
|
179
|
+
domain: string;
|
|
180
|
+
accepted?: boolean;
|
|
181
|
+
}) => Promise<{
|
|
182
|
+
credential: VC;
|
|
183
|
+
uri: string;
|
|
184
|
+
}>;
|
|
185
|
+
export declare const resumeInboxRefreshDelivery: (refreshId: string, domain: string) => Promise<void>;
|
|
186
|
+
//# sourceMappingURL=inbox-refresh.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inbox-refresh.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/inbox-refresh.helpers.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACR,6BAA6B,EAC7B,6BAA6B,EAC7B,8BAA8B,EAC9B,EAAE,EACL,MAAM,kBAAkB,CAAC;AA0B1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AAuBxE,eAAO,MAAM,yBAAyB,GAAU,QAAQ,MAAM,KAAG,OAAO,CAAC,IAAI,CAS5E,CAAC;AAEF,eAAO,MAAM,yBAAyB,GAAI,SAAS,OAAO,KAAG,MAIjC,CAAC;AAE7B,eAAO,MAAM,uBAAuB,GAAI,iBAAiB,MAAM,EAAE,KAAK,MAAM,KAAG,MAChD,CAAC;AAEhC,eAAO,MAAM,qBAAqB,GAC9B,iBAAiB,MAAM,EACvB,KAAK,MAAM,GAAG,SAAS,EACvB,eAAe,MAAM;;;;SAUxB,CAAC;AASF,eAAO,MAAM,sBAAsB,GAC/B,WAAW,MAAM,EACjB,QAAQ,MAAM,KACf,OAAO,CAAC,6BAA6B,CAevC,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAC5B,YAAY,OAAO,EACnB,QAAQ,WAAW,EACnB,QAAQ,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuDjB,CAAC;AAGF,eAAO,MAAM,0BAA0B,GACnC,WAAW,uBAAuB,EAClC,QAAQ,WAAW,EACnB,OAAO,6BAA6B,EACpC,QAAQ,MAAM,KACf,OAAO,CAAC,8BAA8B,CAoExC,CAAC;AAGF,eAAO,MAAM,oBAAoB,GAAU,QAAQ;IAC/C,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IACnC,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;CACtB,KAAG,OAAO,CAAC;IAAE,UAAU,EAAE,EAAE,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAiJ1C,CAAC;AAGF,eAAO,MAAM,0BAA0B,GACnC,WAAW,MAAM,EACjB,QAAQ,MAAM,KACf,OAAO,CAAC,IAAI,CAiBd,CAAC"}
|
|
@@ -15,11 +15,19 @@ export declare const issueToInbox: (issuerProfile: ProfileType, recipient: Conta
|
|
|
15
15
|
activityId?: string;
|
|
16
16
|
integrationId?: string;
|
|
17
17
|
guardianEmail?: string;
|
|
18
|
-
|
|
18
|
+
refresh?: boolean;
|
|
19
|
+
idempotencyKey?: string;
|
|
20
|
+
refreshRequestDigest?: string;
|
|
21
|
+
}) | undefined, ctx: Context, beforeDelivery?: () => Promise<void>) => Promise<{
|
|
22
|
+
refresh?: import("@learncard/types").InboxCredentialRefreshReceipt;
|
|
19
23
|
status: "PENDING" | "ISSUED" | "EXPIRED" | "DELIVERED" | "CLAIMED";
|
|
20
24
|
inboxCredential: InboxCredentialType;
|
|
21
25
|
claimUrl?: string;
|
|
22
26
|
recipientDid?: string;
|
|
23
27
|
guardianStatus?: "AWAITING_GUARDIAN" | "GUARDIAN_APPROVED" | "GUARDIAN_REJECTED";
|
|
24
28
|
}>;
|
|
29
|
+
export declare const resolveInboxCredentialInput: (input: IssueInboxCredentialType, ctx: Context) => Promise<{
|
|
30
|
+
credential: VC | UnsignedVC | VP;
|
|
31
|
+
resolvedBoostUri?: string;
|
|
32
|
+
}>;
|
|
25
33
|
//# sourceMappingURL=inbox.helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inbox.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/inbox.helpers.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inbox.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/inbox.helpers.ts"],"names":[],"mappings":"AAgBA,OAAO,EACH,EAAE,EACF,UAAU,EAGV,EAAE,EACF,sBAAsB,EACtB,mBAAmB,EACnB,wBAAwB,EAE3B,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAE,WAAW,EAAE,2BAA2B,EAAE,MAAM,eAAe,CAAC;AAIzE,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAmClC,eAAO,MAAM,2BAA2B,GAAU,YAAY,UAAU,KAAG,OAAO,CAAC,OAAO,CAUzF,CAAC;AAEF,eAAO,MAAM,cAAc,GACvB,eAAe,WAAW,EAC1B,yBAAyB,2BAA2B,EACpD,WAAW,sBAAsB,EACjC,YAAY,EAAE,GAAG,UAAU,GAAG,EAAE,EAChC,gBAAe,wBAAwB,CAAC,eAAe,CAAC,GAAG;IACvD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB,aAAK,EACN,KAAK,OAAO,EACZ,cAAc,MAAM,KACrB,OAAO,CAAC;IACP,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,SAAS,GAAG,SAAS,GAAG,WAAW,CAAC;IACnE,eAAe,EAAE,mBAAmB,CAAC;IACrC,YAAY,CAAC,EAAE,MAAM,CAAC;CACzB,CAwGA,CAAC;AAEF,eAAO,MAAM,YAAY,GACrB,eAAe,WAAW,EAC1B,WAAW,sBAAsB,EACjC,YAAY,EAAE,GAAG,UAAU,GAAG,EAAE,EAChC,gBAAe,wBAAwB,CAAC,eAAe,CAAC,GAAG;IACvD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oBAAoB,CAAC,EAAE,MAAM,CAAC;CACjC,aAAK,EACN,KAAK,OAAO,EAEZ,iBAAiB,MAAM,OAAO,CAAC,IAAI,CAAC,KACrC,OAAO,CAAC;IACP,OAAO,CAAC,EAAE,OAAO,kBAAkB,EAAE,6BAA6B,CAAC;IACnE,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,SAAS,GAAG,WAAW,GAAG,SAAS,CAAC;IACnE,eAAe,EAAE,mBAAmB,CAAC;IACrC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,mBAAmB,GAAG,mBAAmB,GAAG,mBAAmB,CAAC;CACpF,CA8wBA,CAAC;AAOF,eAAO,MAAM,2BAA2B,GACpC,OAAO,wBAAwB,EAC/B,KAAK,OAAO,KACb,OAAO,CAAC;IAAE,UAAU,EAAE,EAAE,GAAG,UAAU,GAAG,EAAE,CAAC;IAAC,gBAAgB,CAAC,EAAE,MAAM,CAAA;CAAE,CAoDzE,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type NotificationMessageKey = 'boostReceived' | 'boostAccepted' | 'boostAcceptedConnect' | 'credentialReceived' | 'endorsementReceived' | 'connectionAccepted' | 'connectionRequest' | 'connectionRequestExpiredInvite' | 'presentationReceived' | 'issuanceDelivered' | 'issuanceClaimed' | 'issuanceError' | 'guardianApprovalPending' | 'guardianApproved' | 'guardianRejected' | 'parentAccountApproved' | 'appListingSubmitted' | 'appListingWithdrawn' | 'appListingApproved' | 'appListingRejected' | 'consentFlowViewRequest' | 'consentFlowInvite' | 'consentFlowShare' | 'consentFlowTransactionCreated' | 'consentFlowInsightsShared' | 'consentFlowTransactionReconsented' | 'consentFlowTransactionUpdatedTerms' | 'consentFlowTransactionWithdrawn' | 'consentFlowTransactionSyncedSingle' | 'consentFlowTransactionSyncedPlural' | 'credentialRevokedNamed' | 'credentialRevokedUnnamed' | 'credentialSuspendedNamed' | 'credentialSuspendedUnnamed' | 'credentialRestoredNamed' | 'credentialRestoredUnnamed' | 'credentialRefreshed';
|
|
1
|
+
export type NotificationMessageKey = 'boostReceived' | 'boostAccepted' | 'boostAcceptedConnect' | 'credentialReceived' | 'endorsementReceived' | 'connectionAccepted' | 'connectionRequest' | 'connectionRequestExpiredInvite' | 'presentationReceived' | 'issuanceDelivered' | 'issuanceClaimed' | 'issuanceError' | 'guardianApprovalPending' | 'guardianApproved' | 'guardianRejected' | 'parentAccountApproved' | 'appListingSubmitted' | 'appListingWithdrawn' | 'appListingApproved' | 'appListingRejected' | 'consentFlowViewRequest' | 'consentFlowInvite' | 'consentFlowShare' | 'consentFlowTransactionCreated' | 'consentFlowInsightsShared' | 'consentFlowTransactionReconsented' | 'consentFlowTransactionUpdatedTerms' | 'consentFlowTransactionWithdrawn' | 'consentFlowTransactionSyncedSingle' | 'consentFlowTransactionSyncedPlural' | 'credentialRevokedNamed' | 'credentialRevokedUnnamed' | 'credentialSuspendedNamed' | 'credentialSuspendedUnnamed' | 'credentialRestoredNamed' | 'credentialRestoredUnnamed' | 'credentialRefreshed' | 'shareViewed';
|
|
2
2
|
type MessageTemplate = {
|
|
3
3
|
title: string;
|
|
4
4
|
body: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notificationMessages.d.ts","sourceRoot":"","sources":["../../src/helpers/notificationMessages.ts"],"names":[],"mappings":"AAmBA,MAAM,MAAM,sBAAsB,GAC5B,eAAe,GACf,eAAe,GACf,sBAAsB,GACtB,oBAAoB,GACpB,qBAAqB,GACrB,oBAAoB,GACpB,mBAAmB,GACnB,gCAAgC,GAChC,sBAAsB,GACtB,mBAAmB,GACnB,iBAAiB,GACjB,eAAe,GACf,yBAAyB,GACzB,kBAAkB,GAClB,kBAAkB,GAClB,uBAAuB,GACvB,qBAAqB,GACrB,qBAAqB,GACrB,oBAAoB,GACpB,oBAAoB,GACpB,wBAAwB,GACxB,mBAAmB,GACnB,kBAAkB,GAElB,+BAA+B,GAC/B,2BAA2B,GAC3B,mCAAmC,GACnC,oCAAoC,GACpC,iCAAiC,GACjC,oCAAoC,GACpC,oCAAoC,GACpC,wBAAwB,GACxB,0BAA0B,GAC1B,0BAA0B,GAC1B,4BAA4B,GAC5B,yBAAyB,GACzB,2BAA2B,GAG3B,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"notificationMessages.d.ts","sourceRoot":"","sources":["../../src/helpers/notificationMessages.ts"],"names":[],"mappings":"AAmBA,MAAM,MAAM,sBAAsB,GAC5B,eAAe,GACf,eAAe,GACf,sBAAsB,GACtB,oBAAoB,GACpB,qBAAqB,GACrB,oBAAoB,GACpB,mBAAmB,GACnB,gCAAgC,GAChC,sBAAsB,GACtB,mBAAmB,GACnB,iBAAiB,GACjB,eAAe,GACf,yBAAyB,GACzB,kBAAkB,GAClB,kBAAkB,GAClB,uBAAuB,GACvB,qBAAqB,GACrB,qBAAqB,GACrB,oBAAoB,GACpB,oBAAoB,GACpB,wBAAwB,GACxB,mBAAmB,GACnB,kBAAkB,GAElB,+BAA+B,GAC/B,2BAA2B,GAC3B,mCAAmC,GACnC,oCAAoC,GACpC,iCAAiC,GACjC,oCAAoC,GACpC,oCAAoC,GACpC,wBAAwB,GACxB,0BAA0B,GAC1B,0BAA0B,GAC1B,4BAA4B,GAC5B,yBAAyB,GACzB,2BAA2B,GAG3B,qBAAqB,GACrB,aAAa,CAAC;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;AAEF,eAAO,MAAM,oCAAoC,GAC7C,QAAQ,0CAA0C,KACnD,oCAyBF,CAAC;AAEF,eAAO,MAAM,6BAA6B,GACtC,cAAc,eAAe,KAC9B,MAAM,GAAG,SAKX,CAAC;AAUF,wBAAsB,sBAAsB,CACxC,YAAY,EAAE,eAAe,EAC7B,OAAO,GAAE,2BAAgC,yFA+B5C;AAED,wBAAsB,gBAAgB,CAClC,YAAY,EAAE,eAAe,EAC7B,OAAO,GAAE,2BAAgC,oBA8H5C"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const PresentationMetadataValidator: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
3
|
+
export declare const assertPresentationMetadataRecipient: (metadata: Record<string, unknown> | undefined, senderProfileId: string, recipientProfileId: string) => void;
|
|
4
|
+
//# sourceMappingURL=presentation-metadata.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"presentation-metadata.d.ts","sourceRoot":"","sources":["../../src/helpers/presentation-metadata.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmBxB,eAAO,MAAM,6BAA6B,wCAOpC,CAAC;AAEP,eAAO,MAAM,mCAAmC,GAC5C,UAAU,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,EAC7C,iBAAiB,MAAM,EACvB,oBAAoB,MAAM,KAC3B,IAMF,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { VP, JWE } from '@learncard/types';
|
|
2
2
|
import { ProfileType } from '../types/profile';
|
|
3
3
|
export declare const getPresentationUri: (id: string, domain: string) => string;
|
|
4
|
-
export declare const sendPresentation: (from: ProfileType, to: ProfileType, presentation: VP | JWE, domain: string) => Promise<string>;
|
|
4
|
+
export declare const sendPresentation: (from: ProfileType, to: ProfileType, presentation: VP | JWE, domain: string, metadata?: Record<string, unknown>) => Promise<string>;
|
|
5
5
|
export declare const acceptPresentation: (profile: ProfileType, uri: string) => Promise<boolean>;
|
|
6
6
|
//# sourceMappingURL=presentation.helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"presentation.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/presentation.helpers.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,EAAE,EAAE,GAAG,EAAoC,MAAM,kBAAkB,CAAC;AAe7E,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,eAAO,MAAM,kBAAkB,GAAI,IAAI,MAAM,EAAE,QAAQ,MAAM,KAAG,MACpB,CAAC;AAE7C,eAAO,MAAM,gBAAgB,GACzB,MAAM,WAAW,EACjB,IAAI,WAAW,EACf,cAAc,EAAE,GAAG,GAAG,EACtB,QAAQ,MAAM,
|
|
1
|
+
{"version":3,"file":"presentation.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/presentation.helpers.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,EAAE,EAAE,GAAG,EAAoC,MAAM,kBAAkB,CAAC;AAe7E,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,eAAO,MAAM,kBAAkB,GAAI,IAAI,MAAM,EAAE,QAAQ,MAAM,KAAG,MACpB,CAAC;AAE7C,eAAO,MAAM,gBAAgB,GACzB,MAAM,WAAW,EACjB,IAAI,WAAW,EACf,cAAc,EAAE,GAAG,GAAG,EACtB,QAAQ,MAAM,EACd,WAAW,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KACnC,OAAO,CAAC,MAAM,CAuBhB,CAAC;AAKF,eAAO,MAAM,kBAAkB,GAAU,SAAS,WAAW,EAAE,KAAK,MAAM,KAAG,OAAO,CAAC,OAAO,CA6B3F,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ProfileType } from '../types/profile';
|
|
2
2
|
export declare const transformProfileId: (rawInput: string) => string;
|
|
3
|
+
export declare const PublicProfileIdValidator: import("zod").ZodString;
|
|
3
4
|
export declare const getOrCreateFederatedProfile: (senderDid: string, senderServiceDid: string, displayName: string) => Promise<ProfileType>;
|
|
4
5
|
//# sourceMappingURL=profile.helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"profile.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/profile.helpers.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"profile.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/profile.helpers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,eAAO,MAAM,kBAAkB,GAAI,UAAU,MAAM,KAAG,MACL,CAAC;AAElD,eAAO,MAAM,wBAAwB,yBAGpC,CAAC;AAWF,eAAO,MAAM,2BAA2B,GACpC,WAAW,MAAM,EACjB,kBAAkB,MAAM,EACxB,aAAa,MAAM,KACpB,OAAO,CAAC,WAAW,CA4BrB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rateLimit.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/rateLimit.helpers.ts"],"names":[],"mappings":"AAcA,MAAM,MAAM,eAAe,GAAG;IAE1B,GAAG,EAAE,MAAM,CAAC;IAEZ,KAAK,EAAE,MAAM,CAAC;IAEd,aAAa,EAAE,MAAM,CAAC;IAEtB,WAAW,EAAE,MAAM,CAAC;CACvB,CAAC;AAeF,eAAO,MAAM,iBAAiB,GAAU,SAAS,eAAe,EAAE,KAAG,OAAO,CAAC,IAAI,
|
|
1
|
+
{"version":3,"file":"rateLimit.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/rateLimit.helpers.ts"],"names":[],"mappings":"AAcA,MAAM,MAAM,eAAe,GAAG;IAE1B,GAAG,EAAE,MAAM,CAAC;IAEZ,KAAK,EAAE,MAAM,CAAC;IAEd,aAAa,EAAE,MAAM,CAAC;IAEtB,WAAW,EAAE,MAAM,CAAC;CACvB,CAAC;AAeF,eAAO,MAAM,iBAAiB,GAAU,SAAS,eAAe,EAAE,KAAG,OAAO,CAAC,IAAI,CAkBhF,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import type { ManagedCredentialRefreshReceipt, SendBoostResponse } from '@learncard/types';
|
|
2
|
+
export declare const REFRESH_SEND_INTENT_STALE_MS: number;
|
|
3
|
+
export type RefreshSendIntentState = 'preparing' | 'prepared' | 'delivered';
|
|
4
|
+
export type RefreshSendIntent = {
|
|
5
|
+
intentKey: string;
|
|
6
|
+
issuerProfileId: string;
|
|
7
|
+
requestDigest: string;
|
|
8
|
+
state: RefreshSendIntentState;
|
|
9
|
+
claimToken: string;
|
|
10
|
+
boostUri?: string;
|
|
11
|
+
credentialId?: string;
|
|
12
|
+
refreshId?: string;
|
|
13
|
+
holderDid?: string;
|
|
14
|
+
pendingReceipt?: ManagedCredentialRefreshReceipt;
|
|
15
|
+
pendingActivityId?: string;
|
|
16
|
+
result?: SendBoostResponse;
|
|
17
|
+
updatedAt: string;
|
|
18
|
+
};
|
|
19
|
+
export type ClaimRefreshSendIntentResult = {
|
|
20
|
+
kind: 'owned';
|
|
21
|
+
intent: RefreshSendIntent;
|
|
22
|
+
} | {
|
|
23
|
+
kind: 'prepared';
|
|
24
|
+
intent: RefreshSendIntent;
|
|
25
|
+
} | {
|
|
26
|
+
kind: 'delivered';
|
|
27
|
+
intent: RefreshSendIntent;
|
|
28
|
+
};
|
|
29
|
+
export declare const computeRefreshSendRequestDigest: (request: {
|
|
30
|
+
recipientProfileId: string;
|
|
31
|
+
holderDid: string;
|
|
32
|
+
templateUri?: string;
|
|
33
|
+
template?: unknown;
|
|
34
|
+
contractUri?: string;
|
|
35
|
+
templateData?: Record<string, unknown>;
|
|
36
|
+
integrationId?: string;
|
|
37
|
+
credentialId?: string;
|
|
38
|
+
}) => string;
|
|
39
|
+
export declare const getRefreshSendIntent: (issuerProfileId: string, idempotencyKey: string) => Promise<RefreshSendIntent | null>;
|
|
40
|
+
export declare const claimRefreshSendIntent: (params: {
|
|
41
|
+
issuerProfileId: string;
|
|
42
|
+
idempotencyKey: string;
|
|
43
|
+
requestDigest: string;
|
|
44
|
+
}) => Promise<ClaimRefreshSendIntentResult>;
|
|
45
|
+
export declare const recordRefreshSendIntent: (intent: RefreshSendIntent, fields: Partial<Pick<RefreshSendIntent, "boostUri" | "credentialId" | "refreshId" | "holderDid">> & {
|
|
46
|
+
state?: "prepared";
|
|
47
|
+
}) => Promise<RefreshSendIntent>;
|
|
48
|
+
export declare const recordRefreshSendIntentPending: (intent: RefreshSendIntent, pendingReceipt: ManagedCredentialRefreshReceipt, pendingActivityId?: string) => Promise<void>;
|
|
49
|
+
export declare const markRefreshSendIntentDelivered: (intent: RefreshSendIntent, result: SendBoostResponse) => Promise<void>;
|
|
50
|
+
export declare const reconcileBoundRefreshSendIntent: (intent: RefreshSendIntent, domain: string) => Promise<SendBoostResponse | null>;
|
|
51
|
+
//# sourceMappingURL=refresh-send-intent.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refresh-send-intent.helpers.d.ts","sourceRoot":"","sources":["../../src/helpers/refresh-send-intent.helpers.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,+BAA+B,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAQ3F,eAAO,MAAM,4BAA4B,QAAa,CAAC;AAEvD,MAAM,MAAM,sBAAsB,GAAG,WAAW,GAAG,UAAU,GAAG,WAAW,CAAC;AAM5E,MAAM,MAAM,iBAAiB,GAAG;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;IACxB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,sBAAsB,CAAC;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,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,OAAO,CACX,IAAI,CAAC,iBAAiB,EAAE,UAAU,GAAG,cAAc,GAAG,WAAW,GAAG,WAAW,CAAC,CACnF,GAAG;IAAE,KAAK,CAAC,EAAE,UAAU,CAAA;CAAE,KAC3B,OAAO,CAAC,iBAAiB,CAmB3B,CAAC;AAGF,eAAO,MAAM,8BAA8B,GACvC,QAAQ,iBAAiB,EACzB,gBAAgB,+BAA+B,EAC/C,oBAAoB,MAAM,KAC3B,OAAO,CAAC,IAAI,CAkBd,CAAC;AAEF,eAAO,MAAM,8BAA8B,GACvC,QAAQ,iBAAiB,EACzB,QAAQ,iBAAiB,KAC1B,OAAO,CAAC,IAAI,CAiBd,CAAC;AAOF,eAAO,MAAM,+BAA+B,GACxC,QAAQ,iBAAiB,EACzB,QAAQ,MAAM,KACf,OAAO,CAAC,iBAAiB,GAAG,IAAI,CAmBlC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ShareContentTokenSigner } from './types';
|
|
2
|
+
export declare const createDidWebLearnCardTokenSigner: (dependencies?: {
|
|
3
|
+
getLearnCard?: () => Promise<{
|
|
4
|
+
invoke: {
|
|
5
|
+
issuePresentation: (...args: unknown[]) => unknown;
|
|
6
|
+
};
|
|
7
|
+
}>;
|
|
8
|
+
getSignerDid?: () => string;
|
|
9
|
+
}) => ShareContentTokenSigner;
|
|
10
|
+
//# sourceMappingURL=adapters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"adapters.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/adapters.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAgBvD,eAAO,MAAM,gCAAgC,GAAI,eAAe;IAC5D,YAAY,CAAC,EAAE,MAAM,OAAO,CAAC;QACzB,MAAM,EAAE;YAAE,iBAAiB,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,CAAA;SAAE,CAAC;KAClE,CAAC,CAAC;IACH,YAAY,CAAC,EAAE,MAAM,MAAM,CAAC;CAC/B,KAAG,uBA+BH,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { canonicalizeShareContentRequestBody, DEFAULT_MAX_CANONICAL_BYTES, DEFAULT_MAX_CANONICAL_DEPTH, ShareContentCanonicalizationError, } from '@learncard/helpers';
|
|
2
|
+
export declare const computeShareContentRequestBodyHash: (body: unknown, options?: {
|
|
3
|
+
maxBytes?: number;
|
|
4
|
+
maxDepth?: number;
|
|
5
|
+
}) => string;
|
|
6
|
+
export declare const isSha256Hex: (value: unknown) => value is string;
|
|
7
|
+
//# sourceMappingURL=canonical.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"canonical.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/canonical.ts"],"names":[],"mappings":"AAGA,OAAO,EACH,mCAAmC,EACnC,2BAA2B,EAC3B,2BAA2B,EAC3B,iCAAiC,GACpC,MAAM,oBAAoB,CAAC;AAM5B,eAAO,MAAM,kCAAkC,GAC3C,MAAM,OAAO,EACb,UAAS;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAO,KACvD,MAGmB,CAAC;AAGvB,eAAO,MAAM,WAAW,GAAI,OAAO,OAAO,KAAG,KAAK,IAAI,MACO,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type ShareContentClient, type ShareContentClientConfig, type ShareContentContentProjection, type ShareContentDeleteValue, type ShareContentPutValue, type ShareContentRecoveryProjection, type ShareContentStatValue } from './types';
|
|
2
|
+
export declare const createShareContentClient: (config: ShareContentClientConfig) => ShareContentClient;
|
|
3
|
+
export type { ShareContentClient, ShareContentClientConfig };
|
|
4
|
+
export type { ShareContentContentProjection, ShareContentDeleteValue, ShareContentPutValue, ShareContentRecoveryProjection, ShareContentStatValue, };
|
|
5
|
+
//# sourceMappingURL=client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/client.ts"],"names":[],"mappings":"AAWA,OAAO,EAMH,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EAG7B,KAAK,6BAA6B,EAClC,KAAK,uBAAuB,EAI5B,KAAK,oBAAoB,EACzB,KAAK,8BAA8B,EACnC,KAAK,qBAAqB,EAE7B,MAAM,SAAS,CAAC;AAgIjB,eAAO,MAAM,wBAAwB,GAAI,QAAQ,wBAAwB,KAAG,kBAgR3E,CAAC;AAEF,YAAY,EAAE,kBAAkB,EAAE,wBAAwB,EAAE,CAAC;AAC7D,YAAY,EACR,6BAA6B,EAC7B,uBAAuB,EACvB,oBAAoB,EACpB,8BAA8B,EAC9B,qBAAqB,GACxB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type ShareContentClientConfig } from './types';
|
|
2
|
+
export declare const DISABLED_SHARE_CONTENT_CLIENT_CONFIG: ShareContentClientConfig;
|
|
3
|
+
export declare const validateShareContentOrigin: (origin: unknown, allowInsecureLoopback: boolean) => {
|
|
4
|
+
ok: true;
|
|
5
|
+
origin: string;
|
|
6
|
+
} | {
|
|
7
|
+
ok: false;
|
|
8
|
+
reason: string;
|
|
9
|
+
};
|
|
10
|
+
export declare const resolveShareContentClientConfig: (raw: unknown) => ShareContentClientConfig;
|
|
11
|
+
//# sourceMappingURL=config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAQH,KAAK,wBAAwB,EAEhC,MAAM,SAAS,CAAC;AAmBjB,eAAO,MAAM,oCAAoC,EAAE,wBAgBrB,CAAC;AAmB/B,eAAO,MAAM,0BAA0B,GACnC,QAAQ,OAAO,EACf,uBAAuB,OAAO,KAC/B;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GAAG;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAuC5D,CAAC;AAGF,eAAO,MAAM,+BAA+B,GAAI,KAAK,OAAO,KAAG,wBA+E9D,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export * from './types';
|
|
2
|
+
export { canonicalizeShareContentRequestBody, computeShareContentRequestBodyHash, isSha256Hex, ShareContentCanonicalizationError, } from './canonical';
|
|
3
|
+
export { DISABLED_SHARE_CONTENT_CLIENT_CONFIG, resolveShareContentClientConfig, validateShareContentOrigin, } from './config';
|
|
4
|
+
export { createShareContentClient } from './client';
|
|
5
|
+
export { parseShareContentActiveSummary, parseShareContentContentProjection, parseShareContentDeleteValue, parseShareContentPutValue, parseShareContentRecoveryProjection, parseShareContentResponseEnvelope, parseShareContentStatValue, parseShareContentTombstoneSummary, } from './responses';
|
|
6
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,OAAO,EACH,mCAAmC,EACnC,kCAAkC,EAClC,WAAW,EACX,iCAAiC,GACpC,MAAM,aAAa,CAAC;AACrB,OAAO,EACH,oCAAoC,EACpC,+BAA+B,EAC/B,0BAA0B,GAC7B,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,wBAAwB,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EACH,8BAA8B,EAC9B,kCAAkC,EAClC,4BAA4B,EAC5B,yBAAyB,EACzB,mCAAmC,EACnC,iCAAiC,EACjC,0BAA0B,EAC1B,iCAAiC,GACpC,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { ShareContentActiveSummary, ShareContentContentProjection, ShareContentDeleteValue, ShareContentPutValue, ShareContentRecoveryProjection, ShareContentStatValue, ShareContentTombstoneSummary } from './types';
|
|
2
|
+
export declare const parseShareContentActiveSummary: (value: unknown) => ShareContentActiveSummary | null;
|
|
3
|
+
export declare const parseShareContentTombstoneSummary: (value: unknown) => ShareContentTombstoneSummary | null;
|
|
4
|
+
export declare const parseShareContentStatValue: (value: unknown) => ShareContentStatValue | null;
|
|
5
|
+
export declare const parseShareContentDeleteValue: (value: unknown) => ShareContentDeleteValue | null;
|
|
6
|
+
export declare const parseShareContentPutValue: (value: unknown) => ShareContentPutValue | null;
|
|
7
|
+
export declare const parseShareContentContentProjection: (value: unknown) => ShareContentContentProjection | null;
|
|
8
|
+
export declare const parseShareContentRecoveryProjection: (value: unknown) => ShareContentRecoveryProjection | null;
|
|
9
|
+
export declare const parseShareContentResponseEnvelope: (parsed: unknown) => {
|
|
10
|
+
ok: true;
|
|
11
|
+
value: unknown;
|
|
12
|
+
} | {
|
|
13
|
+
ok: false;
|
|
14
|
+
error: string;
|
|
15
|
+
} | null;
|
|
16
|
+
//# sourceMappingURL=responses.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"responses.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/responses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,yBAAyB,EACzB,6BAA6B,EAC7B,uBAAuB,EAGvB,oBAAoB,EACpB,8BAA8B,EAC9B,qBAAqB,EACrB,4BAA4B,EAC/B,MAAM,SAAS,CAAC;AA6IjB,eAAO,MAAM,8BAA8B,UAtER,OAAO,KAAG,yBAAyB,GAAG,IAsET,CAAC;AACjE,eAAO,MAAM,iCAAiC,UAhCR,OAAO,KAAG,4BAA4B,GAAG,IAgCT,CAAC;AAEvE,eAAO,MAAM,0BAA0B,GAAI,OAAO,OAAO,KAAG,qBAAqB,GAAG,IACvB,CAAC;AAE9D,eAAO,MAAM,4BAA4B,GAAI,OAAO,OAAO,KAAG,uBAAuB,GAAG,IACxD,CAAC;AAEjC,eAAO,MAAM,yBAAyB,GAAI,OAAO,OAAO,KAAG,oBAAoB,GAAG,IASjF,CAAC;AAEF,eAAO,MAAM,kCAAkC,GAC3C,OAAO,OAAO,KACf,6BAA6B,GAAG,IAqClC,CAAC;AAEF,eAAO,MAAM,mCAAmC,GAC5C,OAAO,OAAO,KACf,8BAA8B,GAAG,IAqCnC,CAAC;AAGF,eAAO,MAAM,iCAAiC,GAC1C,QAAQ,OAAO,KAChB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,GAAG;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GAAG,IAgBhE,CAAC"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
export declare const SHARE_CONTENT_OPERATIONS: readonly ["put", "get", "stat", "delete", "readRecovery"];
|
|
2
|
+
export type ShareContentOperation = (typeof SHARE_CONTENT_OPERATIONS)[number];
|
|
3
|
+
export declare const SHARE_CONTENT_AUTH_PURPOSE: "lc-share-content/v1";
|
|
4
|
+
export declare const DEFAULT_MAX_SHARE_CONTENT_REQUEST_BYTES: number;
|
|
5
|
+
export declare const DEFAULT_MAX_SHARE_CONTENT_RESPONSE_BYTES: number;
|
|
6
|
+
export declare const MAX_SHARE_CONTENT_TOKEN_TTL_SECONDS = 60;
|
|
7
|
+
export declare const DEFAULT_SHARE_CONTENT_REQUEST_TIMEOUT_MS = 10000;
|
|
8
|
+
export declare const DEFAULT_SHARE_CONTENT_MAX_ATTEMPTS = 3;
|
|
9
|
+
export declare const DEFAULT_SHARE_CONTENT_RETRY_BACKOFF_MS = 200;
|
|
10
|
+
export declare const MAX_SHARE_CONTENT_RETRY_BACKOFF_MS = 5000;
|
|
11
|
+
export type ShareContentEnvelope = {
|
|
12
|
+
v: 1;
|
|
13
|
+
alg: 'A256GCM';
|
|
14
|
+
iv: string;
|
|
15
|
+
ct: string;
|
|
16
|
+
};
|
|
17
|
+
export type ShareContentOwnerRecovery = Record<string, unknown>;
|
|
18
|
+
export type ShareContentTuple = {
|
|
19
|
+
namespace: string;
|
|
20
|
+
ownerProfileId: string;
|
|
21
|
+
shareId: string;
|
|
22
|
+
contentVersion: number;
|
|
23
|
+
objectId: string;
|
|
24
|
+
operationId: string;
|
|
25
|
+
};
|
|
26
|
+
export type ShareContentPutRequest = ShareContentTuple & {
|
|
27
|
+
envelope: ShareContentEnvelope;
|
|
28
|
+
ownerEncryptedRecovery: ShareContentOwnerRecovery;
|
|
29
|
+
};
|
|
30
|
+
export type ShareContentAuthorizationClaims = {
|
|
31
|
+
iss: string;
|
|
32
|
+
aud: string;
|
|
33
|
+
purpose: typeof SHARE_CONTENT_AUTH_PURPOSE;
|
|
34
|
+
namespace: string;
|
|
35
|
+
op: ShareContentOperation;
|
|
36
|
+
shareId: string;
|
|
37
|
+
contentVersion: number;
|
|
38
|
+
ownerProfileId: string;
|
|
39
|
+
objectId: string;
|
|
40
|
+
operationId: string;
|
|
41
|
+
requestHash: string;
|
|
42
|
+
iat: number;
|
|
43
|
+
exp: number;
|
|
44
|
+
jti: string;
|
|
45
|
+
};
|
|
46
|
+
export type ShareContentTokenSigner = (claims: ShareContentAuthorizationClaims) => Promise<string>;
|
|
47
|
+
export type ShareContentActiveSummary = {
|
|
48
|
+
kind: 'active';
|
|
49
|
+
namespace: string;
|
|
50
|
+
ownerProfileId: string;
|
|
51
|
+
shareId: string;
|
|
52
|
+
contentVersion: number;
|
|
53
|
+
objectId: string;
|
|
54
|
+
operationId: string;
|
|
55
|
+
contentHash: string;
|
|
56
|
+
payloadHash: string;
|
|
57
|
+
ciphertextBytes: number;
|
|
58
|
+
recoveryBytes: number;
|
|
59
|
+
createdAt: string;
|
|
60
|
+
};
|
|
61
|
+
export type ShareContentTombstoneSummary = {
|
|
62
|
+
kind: 'tombstone';
|
|
63
|
+
namespace: string;
|
|
64
|
+
ownerProfileId: string;
|
|
65
|
+
shareId: string;
|
|
66
|
+
contentVersion: number;
|
|
67
|
+
objectId: string;
|
|
68
|
+
operationId: string;
|
|
69
|
+
contentHash?: string;
|
|
70
|
+
deletedAt: string;
|
|
71
|
+
};
|
|
72
|
+
export type ShareContentStatValue = ShareContentActiveSummary | ShareContentTombstoneSummary;
|
|
73
|
+
export type ShareContentPutValue = {
|
|
74
|
+
status: 'created' | 'idempotent';
|
|
75
|
+
record: ShareContentActiveSummary;
|
|
76
|
+
};
|
|
77
|
+
export type ShareContentContentProjection = {
|
|
78
|
+
kind: 'active';
|
|
79
|
+
namespace: string;
|
|
80
|
+
ownerProfileId: string;
|
|
81
|
+
shareId: string;
|
|
82
|
+
contentVersion: number;
|
|
83
|
+
objectId: string;
|
|
84
|
+
operationId: string;
|
|
85
|
+
contentHash: string;
|
|
86
|
+
payloadHash: string;
|
|
87
|
+
envelope: ShareContentEnvelope;
|
|
88
|
+
ciphertextBytes: number;
|
|
89
|
+
createdAt: string;
|
|
90
|
+
};
|
|
91
|
+
export type ShareContentRecoveryProjection = {
|
|
92
|
+
kind: 'active';
|
|
93
|
+
namespace: string;
|
|
94
|
+
ownerProfileId: string;
|
|
95
|
+
shareId: string;
|
|
96
|
+
contentVersion: number;
|
|
97
|
+
objectId: string;
|
|
98
|
+
operationId: string;
|
|
99
|
+
contentHash: string;
|
|
100
|
+
payloadHash: string;
|
|
101
|
+
ownerEncryptedRecovery: ShareContentOwnerRecovery;
|
|
102
|
+
recoveryBytes: number;
|
|
103
|
+
createdAt: string;
|
|
104
|
+
};
|
|
105
|
+
export type ShareContentDeleteValue = ShareContentTombstoneSummary;
|
|
106
|
+
export type ShareContentClientErrorCode = 'DISABLED' | 'INVALID_INPUT' | 'UNAUTHORIZED' | 'NOT_FOUND' | 'CONFLICT' | 'PAYLOAD_TOO_LARGE' | 'UNAVAILABLE' | 'UNEXPECTED_STATUS' | 'MALFORMED_RESPONSE' | 'RESPONSE_TOO_LARGE' | 'RESPONSE_TUPLE_MISMATCH' | 'REDIRECT_REJECTED' | 'TIMEOUT' | 'NETWORK_ERROR' | 'SIGNING_FAILED';
|
|
107
|
+
export type ShareContentClientResult<T> = {
|
|
108
|
+
ok: true;
|
|
109
|
+
value: T;
|
|
110
|
+
} | {
|
|
111
|
+
ok: false;
|
|
112
|
+
error: ShareContentClientErrorCode;
|
|
113
|
+
};
|
|
114
|
+
export declare const TRANSIENT_SHARE_CONTENT_ERRORS: readonly ShareContentClientErrorCode[];
|
|
115
|
+
export declare const isTransientShareContentError: (code: ShareContentClientErrorCode) => boolean;
|
|
116
|
+
export declare class ShareContentClientConfigurationError extends Error {
|
|
117
|
+
readonly code = "SHARE_CONTENT_CLIENT_CONFIGURATION_ERROR";
|
|
118
|
+
constructor(message: string);
|
|
119
|
+
}
|
|
120
|
+
export type ShareContentClientConfig = {
|
|
121
|
+
enabled: boolean;
|
|
122
|
+
origin: string;
|
|
123
|
+
namespace: string;
|
|
124
|
+
audience: string;
|
|
125
|
+
signerDid: string;
|
|
126
|
+
allowInsecureLoopback: boolean;
|
|
127
|
+
signer: ShareContentTokenSigner;
|
|
128
|
+
requestTimeoutMs: number;
|
|
129
|
+
maxAttempts: number;
|
|
130
|
+
retryBackoffMs: number;
|
|
131
|
+
maxRequestBytes: number;
|
|
132
|
+
maxResponseBytes: number;
|
|
133
|
+
now: () => number;
|
|
134
|
+
sleep: (ms: number) => Promise<void>;
|
|
135
|
+
fetchImpl: typeof fetch;
|
|
136
|
+
};
|
|
137
|
+
export type ShareContentClient = {
|
|
138
|
+
readonly config: ShareContentClientConfig;
|
|
139
|
+
put: (request: ShareContentPutRequest) => Promise<ShareContentClientResult<ShareContentPutValue>>;
|
|
140
|
+
get: (request: ShareContentTuple) => Promise<ShareContentClientResult<ShareContentContentProjection>>;
|
|
141
|
+
stat: (request: ShareContentTuple) => Promise<ShareContentClientResult<ShareContentStatValue>>;
|
|
142
|
+
delete: (request: ShareContentTuple) => Promise<ShareContentClientResult<ShareContentDeleteValue>>;
|
|
143
|
+
readRecovery: (request: ShareContentTuple) => Promise<ShareContentClientResult<ShareContentRecoveryProjection>>;
|
|
144
|
+
};
|
|
145
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-content-client/types.ts"],"names":[],"mappings":"AAkBA,eAAO,MAAM,wBAAwB,2DAA4D,CAAC;AAElG,MAAM,MAAM,qBAAqB,GAAG,CAAC,OAAO,wBAAwB,CAAC,CAAC,MAAM,CAAC,CAAC;AAG9E,eAAO,MAAM,0BAA0B,EAAG,qBAA8B,CAAC;AAGzE,eAAO,MAAM,uCAAuC,QAAc,CAAC;AAEnE,eAAO,MAAM,wCAAwC,QAAkB,CAAC;AAExE,eAAO,MAAM,mCAAmC,KAAK,CAAC;AACtD,eAAO,MAAM,wCAAwC,QAAS,CAAC;AAC/D,eAAO,MAAM,kCAAkC,IAAI,CAAC;AACpD,eAAO,MAAM,sCAAsC,MAAM,CAAC;AAC1D,eAAO,MAAM,kCAAkC,OAAQ,CAAC;AAGxD,MAAM,MAAM,oBAAoB,GAAG;IAC/B,CAAC,EAAE,CAAC,CAAC;IACL,GAAG,EAAE,SAAS,CAAC;IACf,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;CACd,CAAC;AAGF,MAAM,MAAM,yBAAyB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAMhE,MAAM,MAAM,iBAAiB,GAAG;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,MAAM,CAAC;IAChB,cAAc,EAAE,MAAM,CAAC;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG,iBAAiB,GAAG;IACrD,QAAQ,EAAE,oBAAoB,CAAC;IAC/B,sBAAsB,EAAE,yBAAyB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ACD,OAAO,EAAE,sBAAsB,KAC9B,OAAO,CAAC,wBAAwB,CAAC,oBAAoB,CAAC,CAAC,CAAC;IAC7D,GAAG,EAAE,CACD,OAAO,EAAE,iBAAiB,KACzB,OAAO,CAAC,wBAAwB,CAAC,6BAA6B,CAAC,CAAC,CAAC;IACtE,IAAI,EAAE,CAAC,OAAO,EAAE,iBAAiB,KAAK,OAAO,CAAC,wBAAwB,CAAC,qBAAqB,CAAC,CAAC,CAAC;IAC/F,MAAM,EAAE,CACJ,OAAO,EAAE,iBAAiB,KACzB,OAAO,CAAC,wBAAwB,CAAC,uBAAuB,CAAC,CAAC,CAAC;IAChE,YAAY,EAAE,CACV,OAAO,EAAE,iBAAiB,KACzB,OAAO,CAAC,wBAAwB,CAAC,8BAA8B,CAAC,CAAC,CAAC;CAC1E,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { MaintenanceBudget } from './types';
|
|
2
|
+
export declare const budgetHasUnitReserve: (budget: MaintenanceBudget | undefined) => boolean;
|
|
3
|
+
export declare const budgetAllows: (budget: MaintenanceBudget | undefined, costMs: number) => boolean;
|
|
4
|
+
export declare const boundTransactionTimeout: (configuredTimeoutMs: number | undefined, budget: MaintenanceBudget | undefined) => number | undefined;
|
|
5
|
+
//# sourceMappingURL=budget-helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"budget-helpers.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-link-coordinator/budget-helpers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAOjD,eAAO,MAAM,oBAAoB,GAAI,QAAQ,iBAAiB,GAAG,SAAS,KAAG,OACX,CAAC;AAUnE,eAAO,MAAM,YAAY,GAAI,QAAQ,iBAAiB,GAAG,SAAS,EAAE,QAAQ,MAAM,KAAG,OAWpF,CAAC;AAQF,eAAO,MAAM,uBAAuB,GAChC,qBAAqB,MAAM,GAAG,SAAS,EACvC,QAAQ,iBAAiB,GAAG,SAAS,KACtC,MAAM,GAAG,SAYX,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cleanup-runner.d.ts","sourceRoot":"","sources":["../../../src/helpers/share-link-coordinator/cleanup-runner.ts"],"names":[],"mappings":"AAQA,OAAO,EAEH,KAAK,yBAAyB,EAC9B,KAAK,iBAAiB,EAEzB,MAAM,SAAS,CAAC;AAqGjB,eAAO,MAAM,0BAA0B,GACnC,cAAc,yBAAyB,KACxC,OAAO,CAAC,iBAAiB,CAiI3B,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type PendingShareContentOperation, type ShareLinkCoordinator, type ShareLinkCoordinatorDependencies } from './types';
|
|
2
|
+
export declare const createShareLinkCoordinator: (dependencies: ShareLinkCoordinatorDependencies) => ShareLinkCoordinator;
|
|
3
|
+
export type { PendingShareContentOperation };
|
|
4
|
+
//# sourceMappingURL=coordinator.d.ts.map
|