@capxul/sdk 3.2.0 → 4.0.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/README.md +2 -2
- package/dist/{OAuthBearerAuthClient-8F_kyVP5.mjs → OAuthBearerAuthClient-BHvDR8_0.mjs} +1 -1
- package/dist/{OAuthBearerAuthClient-CsOgeeZa.d.mts → OAuthBearerAuthClient-D-DLYlKj.d.mts} +1 -1
- package/dist/{clock-CWpcQlLy.mjs → clock-C2AUlq1V.mjs} +34 -1
- package/dist/{create-capxul-client-BCq08ppe.mjs → create-capxul-client-5Bk0PS0R.mjs} +1047 -552
- package/dist/index.d.mts +21 -20
- package/dist/index.mjs +44 -9
- package/dist/node/index.d.mts +2 -2
- package/dist/node/index.mjs +2 -2
- package/dist/{observation-B76zFxd6.d.mts → observation-DtzTdv20.d.mts} +75 -71
- package/dist/{signer-DOqb8M1Y.d.mts → signer-C0hZ6Kiy.d.mts} +9 -2
- package/dist/testing/index.d.mts +1 -1
- package/dist/testing/index.mjs +6 -6
- package/package.json +6 -6
package/dist/index.d.mts
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
|
-
import { E as Address,
|
|
2
|
-
import { $ as OrganizationPaymentsMethods, $t as
|
|
3
|
-
import "./OAuthBearerAuthClient-
|
|
1
|
+
import { B as EVM_ADDRESS_RE, Ct as RevertSummary, E as Address, G as OrgId, I as CountryCode, J as PayrollGroupId, K as PartyId, M as AuthUserId, P as BudgetId, St as FailureMode, T as AccountId, U as Handle, W as Money, Y as PayrollRunId, _t as isCapxulError, a as SignerStatusStore, bt as ChainUpstream, c as AccountProviderSource, ct as toHandle, d as eip1193AccountProvider, dt as CAPXUL_ERROR_CODES, et as RoleKey, f as localPrivateKeyAccountProvider, ft as CapxulError, g as SmartAccount, h as Session, ht as Errors, i as SignerStatus, j as AuthSession, l as AccountRequirement, lt as toPartyId, m as Profile, mt as CapxulErrorDetails, n as CapxulSigner, o as injectedWalletSigner, ot as toAddress, p as CapxulResult, pt as CapxulErrorCode, r as Eip1193RequestProvider, rt as TesterKind, s as AccountProvider, st as toCountryCode, t as CapxulDigestSigner, u as Eip1193Provider, ut as CAPXUL_PAYMENTS_V2_ADDRESS, vt as CHAIN_UPSTREAMS, w as Account, xt as FAILURE_MODES, yt as ChainCause } from "./signer-C0hZ6Kiy.mjs";
|
|
2
|
+
import { $ as OrganizationPaymentsMethods, $n as TelemetryPort, $t as DestinationListInput, A as OrgView, An as TargetsMethods, At as AddressBookMethods, B as PayrollGroupInput, Bn as OrgSetupStep, Bt as ActivityListParams, C as DetectPendingOrgInvitationsResult, Cn as PaymentType, Ct as ActorRelationshipMethods, D as OrgMethods, Dn as Ref, Dt as AddressBookAddInput, E as MemberView, En as RecipientResolution, Et as ActorRequestsMethods, F as RoleSpendCap, Fn as CompleteProfileInput, Ft as ActivityAnnotationInput, G as PayrollRun, Gn as InboxStatus, Gt as ActivitySummary, H as PayrollGroupsMethods, Hn as CurrentHoldings, Ht as ActivityPage, I as RoleView, In as IdentityMethods, It as ActivityDetail, J as PayrollRuns, Jn as PaymentStatus$1, Jt as ActorReference, K as PayrollRunItemInput, Kn as PAYMENT_DIRECTIONS, Kt as ActivitySummaryParams, L as AuthorizeRunInput, Ln as SmartAccountMethods, Lt as ActivityFilter, M as OrganizationAuditLogItem, Mn as AccountLifecycle, Mt as InboxItem, N as ResendInviteTokenInput, Nn as AccountSetupStep, Nt as InboxMethods, O as OrgScopedMethods, On as ResolvedTarget, Ot as AddressBookEntry, P as RoleDefinition, Pn as isSettingUpLifecycle, Pt as ActivityAnnotation, Q as OrganizationPaymentItemInput, Qt as DestinationKind, R as PayrollEngagementTerms, Rn as AuthMethods, Rt as ActivityItem, S as CreateOrgInput, Sn as PaymentTiming, St as ActorProfileMethods, T as MemberStatus, Tn as PaymentsPayInput, Tt as ActorRequestIssueInput, U as PayrollMethods, Un as Permission, Ut as ActivityRange, V as PayrollGroupMember, Vn as ActorRef, Vt as ActivityMethods, W as PayrollOptions, Wn as SubmittedPermissionExecution, Wt as ActivityReference, X as OrganizationPaymentBatchInput, Xt as Destination, Y as PayrollTermsUnit, Yn as RequestStatus, Yt as DepositInstructions, Z as OrganizationPaymentInput, Zt as DestinationAddInput, _ as SystemMethods, _n as PaymentDocumentRender, _t as PersonOnboarding, a as SdkFailureObservation, an as MeMethods, ar as StateLabel, at as PermissionReplaceInput, b as CurrentUserContext, bn as PaymentMoney, bt as AccountMethods, c as PostHogObservabilityOptions, cn as OfframpMethods, cr as isRestoring, ct as Budget, d as CreateCapxulClientInput, dn as OfframpStatus, dt as OrgMeOptions, en as DestinationPayload, er as Destination$1, et as PermissionAssignInput, f as IdentityProfileDetails, fn as Payment, ft as AccountsMethods, g as Holding, gn as PaymentDocumentRef, gt as OrganizationOnboardingInput, h as HoldingsMethods, hn as PaymentDocumentKind, ht as OrganizationOnboarding, i as ObservationDelivery, in as FinancialOpsMethods, ir as Readiness, it as PermissionOptions, j as OrganizationAccount, jn as fingerprintPaymentIntent, jt as InboxApproveInput, k as OrgTemplate, kn as TargetReference, kt as AddressBookLabelInput, l as postHogObservability, ln as OfframpQuote, lr as IdentityTransition, lt as OrgMe, m as IdentityRuntimeSendResult, mn as PaymentDirection, mt as OnboardingMethods, n as ObservationAdapter, nn as DestinationRemoveInput, nr as IdentityState, nt as PermissionCreateInput, o as HostObservability, on as MeProfile, or as destination, ot as PermissionRevokeInput, p as IdentityRuntime, pn as PaymentActivityEvidence, pt as CompletedPersonProfile, q as PayrollRunStatus, qn as PAYMENT_STATUSES, qt as ActivitySummaryTotal, r as ObservationContext, rn as DestinationsMethods, rr as OrgLane, rt as PermissionMethods, s as PostHogObservabilityClient, sn as MovementActivityEvidence, sr as isClaimed, st as PermissionReadResult, t as CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, tn as DestinationRail, tr as IdentityEvent, tt as PermissionChangeInput, u as CapxulClient, un as OfframpQuoteInput, ur as InvocationControls, ut as OrgMeMethod, v as SystemHealth, vn as PaymentDocumentVerification, vt as PersonOnboardingInput, w as InviteMemberInput, wn as PaymentsMethods, wt as ActorRequest, x as CurrentUserMethods, xn as PaymentStatus, xt as ActorProfile, y as MediaMethods, yn as PaymentDocumentsMethods, yt as ReadyAccountLifecycle, z as PayrollGroup, zn as OrgLifecycle, zt as ActivityKind } from "./observation-DtzTdv20.mjs";
|
|
3
|
+
import "./OAuthBearerAuthClient-D-DLYlKj.mjs";
|
|
4
4
|
import { Context, Effect, Layer } from "effect";
|
|
5
5
|
import { Hex } from "viem";
|
|
6
6
|
import { FunctionReference } from "convex/server";
|
|
7
|
+
//#region ../errors/src/index.d.ts
|
|
8
|
+
/** Canonical handle syntax shared by validation and branded constructors. */
|
|
9
|
+
declare const HANDLE_RE: RegExp;
|
|
10
|
+
//#endregion
|
|
7
11
|
//#region ../observability/src/operations.d.ts
|
|
8
12
|
declare const CAPXUL_OPERATIONS: {
|
|
9
13
|
readonly account: {
|
|
@@ -107,9 +111,6 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
107
111
|
readonly current: "holdings.current";
|
|
108
112
|
readonly primary: "holdings.primary";
|
|
109
113
|
};
|
|
110
|
-
readonly handles: {
|
|
111
|
-
readonly resolve: "handles.resolve";
|
|
112
|
-
};
|
|
113
114
|
readonly identity: {
|
|
114
115
|
readonly accountAt: "identity.AccountAt";
|
|
115
116
|
readonly accountClaimed: "identity.AccountClaimed";
|
|
@@ -124,6 +125,7 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
124
125
|
readonly createOrganization: "identity.CreateOrganization";
|
|
125
126
|
readonly ensureAccount: "identity.EnsureAccount";
|
|
126
127
|
readonly leaveOrganization: "identity.LeaveOrganization";
|
|
128
|
+
readonly loadByAuthUserId: "identity.loadByAuthUserId";
|
|
127
129
|
readonly loadCurrent: "identity.loadCurrent";
|
|
128
130
|
readonly orgAt: "identity.OrgAt";
|
|
129
131
|
readonly orgFailed: "identity.OrgFailed";
|
|
@@ -145,7 +147,7 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
145
147
|
readonly signOut: "identity.SignOut";
|
|
146
148
|
readonly signOutFailed: "identity.SignOutFailed";
|
|
147
149
|
readonly update: "identity.update";
|
|
148
|
-
readonly
|
|
150
|
+
readonly handleAvailable: "identity.handleAvailable";
|
|
149
151
|
readonly verified: "identity.Verified";
|
|
150
152
|
readonly verifyFailed: "identity.VerifyFailed";
|
|
151
153
|
readonly verifyOtp: "identity.VerifyOtp";
|
|
@@ -161,10 +163,12 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
161
163
|
readonly get: "me.get";
|
|
162
164
|
};
|
|
163
165
|
readonly moneyExecution: {
|
|
166
|
+
readonly abandonPaymentExecution: "moneyExecution.abandonPaymentExecution";
|
|
164
167
|
readonly prepareOrganizationPaymentExecution: "moneyExecution.prepareOrganizationPaymentExecution";
|
|
165
168
|
readonly preparePaymentExecution: "moneyExecution.preparePaymentExecution";
|
|
166
169
|
readonly preparePaymentLifecycleExecution: "moneyExecution.preparePaymentLifecycleExecution";
|
|
167
170
|
readonly preparePermissionExecution: "moneyExecution.preparePermissionExecution";
|
|
171
|
+
readonly recoverSubmissionClaims: "moneyExecution.recoverSubmissionClaims";
|
|
168
172
|
readonly submit: "moneyExecution.submit";
|
|
169
173
|
readonly submitPaymentCommandExecution: "moneyExecution.submitPaymentCommandExecution";
|
|
170
174
|
readonly submitPaymentExecution: "moneyExecution.submitPaymentExecution";
|
|
@@ -184,12 +188,15 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
184
188
|
readonly status: "offramp.status";
|
|
185
189
|
};
|
|
186
190
|
readonly onboarding: {
|
|
191
|
+
readonly completeOrganization: "onboarding.completeOrganization";
|
|
187
192
|
readonly completePerson: "onboarding.completePerson";
|
|
188
193
|
};
|
|
189
194
|
readonly org: {
|
|
195
|
+
readonly acceptInvitations: "org.acceptInvitations";
|
|
190
196
|
readonly account: {
|
|
191
197
|
readonly get: "org.account.get";
|
|
192
198
|
};
|
|
199
|
+
readonly activateMember: "org.activateMember";
|
|
193
200
|
readonly auditLog: "org.auditLog";
|
|
194
201
|
readonly confirmBootstrap: "org.confirmBootstrap";
|
|
195
202
|
readonly createOrg: "org.createOrg";
|
|
@@ -200,6 +207,7 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
200
207
|
readonly getProofReceipt: "org.getProofReceipt";
|
|
201
208
|
readonly invite: "org.invite";
|
|
202
209
|
readonly inviteMember: "org.inviteMember";
|
|
210
|
+
readonly list: "org.list";
|
|
203
211
|
readonly load: "org.load";
|
|
204
212
|
readonly me: "org.me";
|
|
205
213
|
readonly members: "org.members";
|
|
@@ -275,6 +283,7 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
275
283
|
readonly pay: "organizationPayments.pay";
|
|
276
284
|
readonly payBatch: "organizationPayments.payBatch";
|
|
277
285
|
readonly prepareExecution: "organizationPayments.prepareExecution";
|
|
286
|
+
readonly retry: "organizationPayments.retry";
|
|
278
287
|
};
|
|
279
288
|
readonly organizationSetup: {
|
|
280
289
|
readonly getProofReceipt: "organizationSetup.getProofReceipt";
|
|
@@ -293,6 +302,7 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
293
302
|
readonly prepareExecution: "payments.prepareExecution";
|
|
294
303
|
readonly prepareLifecycleExecution: "payments.prepareLifecycleExecution";
|
|
295
304
|
readonly redirect: "payments.redirect";
|
|
305
|
+
readonly retry: "payments.retry";
|
|
296
306
|
readonly submitCommandExecution: "payments.submitCommandExecution";
|
|
297
307
|
readonly submitExecution: "payments.submitExecution";
|
|
298
308
|
};
|
|
@@ -300,10 +310,8 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
300
310
|
readonly render: "paymentDocuments.render";
|
|
301
311
|
readonly verify: "paymentDocuments.verify";
|
|
302
312
|
};
|
|
303
|
-
readonly
|
|
304
|
-
readonly
|
|
305
|
-
readonly get: "payees.get";
|
|
306
|
-
readonly resolve: "payees.resolve";
|
|
313
|
+
readonly recipient: {
|
|
314
|
+
readonly resolve: "recipient.resolve";
|
|
307
315
|
};
|
|
308
316
|
readonly payroll: {
|
|
309
317
|
readonly authorizeRun: "payroll.authorizeRun";
|
|
@@ -378,6 +386,7 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
378
386
|
readonly smartAccount: {
|
|
379
387
|
readonly claim: "smartAccount.claim";
|
|
380
388
|
readonly confirmDeployment: "smartAccount.confirmDeployment";
|
|
389
|
+
readonly loadByAuthUserId: "smartAccount.loadByAuthUserId";
|
|
381
390
|
readonly loadCurrent: "smartAccount.loadCurrent";
|
|
382
391
|
readonly provision: "smartAccount.provision";
|
|
383
392
|
};
|
|
@@ -386,14 +395,6 @@ declare const CAPXUL_OPERATIONS: {
|
|
|
386
395
|
readonly ping: "system.ping";
|
|
387
396
|
readonly runtimeChain: "system.runtimeChain";
|
|
388
397
|
};
|
|
389
|
-
readonly targets: {
|
|
390
|
-
readonly resolve: {
|
|
391
|
-
readonly email: "targets.resolve.email";
|
|
392
|
-
readonly handle: "targets.resolve.handle";
|
|
393
|
-
readonly organization: "targets.resolve.organization";
|
|
394
|
-
readonly payee: "targets.resolve.payee";
|
|
395
|
-
};
|
|
396
|
-
};
|
|
397
398
|
readonly testUsdc: {
|
|
398
399
|
readonly mint: "TestUSDC.mint";
|
|
399
400
|
};
|
|
@@ -623,4 +624,4 @@ declare function captureException(telemetry: TelemetryPort, error: unknown, cont
|
|
|
623
624
|
*/
|
|
624
625
|
declare function captureExceptionSync(telemetry: TelemetryPort, error: unknown, context?: HandledErrorReportContext): void;
|
|
625
626
|
//#endregion
|
|
626
|
-
export { type Account, type AccountId, type AccountLifecycle, type AccountMethods, type AccountProvider, type AccountProviderSource, type AccountRequirement, type AccountSetupStep, type AccountsMethods, type ActivityAnnotation, type ActivityAnnotationInput, type ActivityDetail, type ActivityFilter, type ActivityItem, type ActivityKind, type ActivityListParams, type ActivityMethods, type ActivityPage, type ActivityPhase, type ActivityRange, type ActivityReference, type ActivitySummary, type ActivitySummaryParams, type ActivitySummaryTotal, type ActorProfile, type ActorProfileMethods, type ActorRef, type ActorReference, type ActorRelationshipMethods, type ActorRequest, type ActorRequestIssueInput, type ActorRequestsMethods, type Address, type AddressBookAddInput, type AddressBookEntry, type AddressBookLabelInput, type AddressBookMethods, type AuthMethods, type AuthSession, type AuthUserId, type AuthorizeRunInput, type Budget, type BudgetId, CAPXUL_ERROR_CODES, CAPXUL_OPERATIONS, CAPXUL_PAYMENTS_V2_ADDRESS, CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, CHAIN_UPSTREAMS, type CapxulClient, type CapxulClientInput, type CapxulDigestSigner, CapxulError, type CapxulErrorCode, type CapxulErrorDetails, type CapxulOperation, type CapxulResult, type CapxulSigner, type ChainCause, type ChainUpstream, type CompleteProfileInput, type CompletedPersonProfile, type CountryCode, type CreateCapxulClientInput, type CreateOrgInput, type CurrentHoldings, type CurrentUserContext, type CurrentUserMethods, type DepositInstructions, type Destination, type DestinationAddInput, type DestinationKind, type DestinationListInput, type DestinationPayload, type DestinationRail, type DestinationRemoveInput, type DestinationsMethods, type DetectPendingOrgInvitationsResult, type DevPrivateKeySignerInput, type Eip1193Provider, type Eip1193RequestProvider, Errors, FAILURE_MODES, type FailureMode, type FinancialOpsMethods, type
|
|
627
|
+
export { type Account, type AccountId, type AccountLifecycle, type AccountMethods, type AccountProvider, type AccountProviderSource, type AccountRequirement, type AccountSetupStep, type AccountsMethods, type ActivityAnnotation, type ActivityAnnotationInput, type ActivityDetail, type ActivityFilter, type ActivityItem, type ActivityKind, type ActivityListParams, type ActivityMethods, type ActivityPage, type ActivityPhase, type ActivityRange, type ActivityReference, type ActivitySummary, type ActivitySummaryParams, type ActivitySummaryTotal, type ActorProfile, type ActorProfileMethods, type ActorRef, type ActorReference, type ActorRelationshipMethods, type ActorRequest, type ActorRequestIssueInput, type ActorRequestsMethods, type Address, type AddressBookAddInput, type AddressBookEntry, type AddressBookLabelInput, type AddressBookMethods, type AuthMethods, type AuthSession, type AuthUserId, type AuthorizeRunInput, type Budget, type BudgetId, CAPXUL_ERROR_CODES, CAPXUL_OPERATIONS, CAPXUL_PAYMENTS_V2_ADDRESS, CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, CHAIN_UPSTREAMS, type CapxulClient, type CapxulClientInput, type CapxulDigestSigner, CapxulError, type CapxulErrorCode, type CapxulErrorDetails, type CapxulOperation, type CapxulResult, type CapxulSigner, type ChainCause, type ChainUpstream, type CompleteProfileInput, type CompletedPersonProfile, type CountryCode, type CreateCapxulClientInput, type CreateOrgInput, type CurrentHoldings, type CurrentUserContext, type CurrentUserMethods, type DepositInstructions, type Destination, type DestinationAddInput, type DestinationKind, type DestinationListInput, type DestinationPayload, type DestinationRail, type DestinationRemoveInput, type DestinationsMethods, type DetectPendingOrgInvitationsResult, type DevPrivateKeySignerInput, EVM_ADDRESS_RE, type Eip1193Provider, type Eip1193RequestProvider, Errors, FAILURE_MODES, type FailureMode, type FinancialOpsMethods, HANDLE_RE, type Handle, type HandledErrorReportContext, type Holding, type HoldingsMethods, type HostObservability, type Destination$1 as IdentityDestination, type IdentityEvent, type IdentityMethods, type IdentityProfileDetails, type IdentityRuntime, type IdentityRuntimeSendResult, type IdentityState, type IdentityTransition, type InboxApproveInput, type InboxItem, type InboxMethods, type InviteMemberInput, type InvocationControls, type MeMethods, type MeProfile, type MediaMethods, type MemberStatus, type MemberView, type Money, type MoneyParseError, type MoneyParseErrorReason, type MovementActivityEvidence, type NormalizedCapxulOperation, type ObservationAdapter, type ObservationContext, type ObservationDelivery, type OfframpMethods, type OfframpQuote, type OfframpQuoteInput, type OfframpStatus, type OnboardingMethods, type OpenfortEmbeddedSignerInput, type OpenfortEmbeddedWalletApi, type OpenfortEmbeddedWalletPort, type OrgId, type OrgLane, type OrgLifecycle, type OrgMe, type OrgMeMethod, type OrgMeOptions, type OrgMethods, type OrgScopedMethods, type OrgSetupStep, type OrgTemplate, type OrgView, type OrganizationAccount, type OrganizationAuditLogItem, type OrganizationOnboarding, type OrganizationOnboardingInput, type OrganizationPaymentBatchInput, type OrganizationPaymentInput, type OrganizationPaymentItemInput, type OrganizationPaymentsMethods, PAYMENT_DIRECTIONS, PAYMENT_STATUSES, type PartyId, type Payment, type PaymentActivityEvidence, type PaymentDirection, type PaymentDocumentKind, type PaymentDocumentRef, type PaymentDocumentRender, type PaymentDocumentVerification, type PaymentDocumentsMethods, type PaymentMoney, type PaymentStatus, type PaymentTiming, type PaymentType, type PaymentsMethods, type PaymentsPayInput, type PayrollEngagementTerms, type PayrollGroup, type PayrollGroupId, type PayrollGroupInput, type PayrollGroupMember, type PayrollGroupsMethods, type PayrollMethods, type PayrollOptions, type PayrollRun, type PayrollRunId, type PayrollRunItemInput, type PayrollRunStatus, type PayrollRuns, type PayrollTermsUnit, type Permission, type PermissionAssignInput, type PermissionChangeInput, type PermissionCreateInput, type PermissionMethods, type PermissionOptions, type PermissionReadResult, type PermissionReplaceInput, type PermissionRevokeInput, type PersonOnboarding, type PersonOnboardingInput, type PostHogObservabilityClient, type PostHogObservabilityOptions, type Profile, type Readiness, type ReadyAccountLifecycle, type RecipientResolution, type Ref, type ResendInviteTokenInput, type ResolvedTarget, type RevertSummary, type RoleDefinition, type RoleKey, type RoleSpendCap, type RoleView, type SdkFailureObservation, type Session, type SignerStatus, type SignerStatusStore, type SmartAccount, type SmartAccountMethods, type StateLabel, type SubmittedPermissionExecution, type SystemHealth, type SystemMethods, type TargetReference, type TargetsMethods, type TelemetryPort, type TesterKind, captureException, captureExceptionSync, createCapxulClient, deriveDevPrivateKey, devPrivateKeySigner, eip1193AccountProvider, embeddedSigner, fingerprintPaymentIntent, formatMoney, inboxPhase, injectedWalletSigner, isCapxulError, isCapxulOperation, isClaimed, isMoneyParseError, isRestoring, isSettingUpLifecycle, localPrivateKeyAccountProvider, normalizeCapxulOperation, openfortEmbeddedSigner, openfortEmbeddedSignerFromWallet, openfortEmbeddedWalletPort, parseMoney, paymentPhase, postHogObservability, requestPhase, destination as resolveIdentityDestination, toCountryCode, toAddress as toEvmAddress, toHandle, toPartyId };
|
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $ as stampTelemetryEnvelope, A as safeExceptionLabel, B as resolveFailureMode, C as observeFailedResult, D as normalizeExceptionErrorKind, E as SDK_VERSION$1, F as causeChain, G as sanitizeObservationContext, H as readInvocationObservation, I as injectedWalletSigner, J as CAPXUL_FUNCTIONS, K as PAYMENT_DIRECTIONS, L as isSignerNotReadySignal, M as fromWei, N as isSettingUpLifecycle, O as normalizeExceptionOperation, P as formatTraceparent, Q as redactTelemetryProps, R as openfortSignerNotReadyCode, S as observationContextProps, T as EXCEPTION_MESSAGE, U as OBSERVATION_CONTEXT_HEADER, V as copyInvocationObservation, W as encodeObservationContextHeader, X as EngineeringTelemetryBootstrapPolicy, Y as BootstrapEnvelope, _ as fingerprintPaymentIntent, a as AccountReadPortTag, at as isRestoring, b as failureDetail, c as retryIdempotentRead, d as IdentityPortTag, et as CAPXUL_OPERATIONS, f as identityErrorFromCapxul, g as bootstrapErrorFromCapxul, h as BootstrapPortTag, i as smartAccountErrorFromCapxul, it as isClaimed, j as version, k as projectSdkException, l as PRODUCT_INVOCATION, m as convexCallErrorFromCapxul, n as detectAuthCacheAdapter, nt as normalizeCapxulOperation, o as accountReadErrorFromCapxul, p as ConvexCallPortTag, q as PAYMENT_STATUSES, r as SmartAccountPortTag, rt as destination, s as TelemetryPortTag, t as assembleCapxulClient, tt as isCapxulOperation, u as wireChainId, v as toWei, w as postHogFailureObservation, x as failureEvidenceProps, y as CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, z as signerFailure } from "./create-capxul-client-
|
|
2
|
-
import { $ as
|
|
3
|
-
import { n as SystemClockLayer } from "./OAuthBearerAuthClient-
|
|
1
|
+
import { $ as stampTelemetryEnvelope, A as safeExceptionLabel, B as resolveFailureMode, C as observeFailedResult, D as normalizeExceptionErrorKind, E as SDK_VERSION$1, F as causeChain, G as sanitizeObservationContext, H as readInvocationObservation, I as injectedWalletSigner, J as CAPXUL_FUNCTIONS, K as PAYMENT_DIRECTIONS, L as isSignerNotReadySignal, M as fromWei, N as isSettingUpLifecycle, O as normalizeExceptionOperation, P as formatTraceparent, Q as redactTelemetryProps, R as openfortSignerNotReadyCode, S as observationContextProps, T as EXCEPTION_MESSAGE, U as OBSERVATION_CONTEXT_HEADER, V as copyInvocationObservation, W as encodeObservationContextHeader, X as EngineeringTelemetryBootstrapPolicy, Y as BootstrapEnvelope, _ as fingerprintPaymentIntent, a as AccountReadPortTag, at as isRestoring, b as failureDetail, c as retryIdempotentRead, d as IdentityPortTag, et as CAPXUL_OPERATIONS, f as identityErrorFromCapxul, g as bootstrapErrorFromCapxul, h as BootstrapPortTag, i as smartAccountErrorFromCapxul, it as isClaimed, j as version, k as projectSdkException, l as PRODUCT_INVOCATION, m as convexCallErrorFromCapxul, n as detectAuthCacheAdapter, nt as normalizeCapxulOperation, o as accountReadErrorFromCapxul, p as ConvexCallPortTag, q as PAYMENT_STATUSES, r as SmartAccountPortTag, rt as destination, s as TelemetryPortTag, t as assembleCapxulClient, tt as isCapxulOperation, u as wireChainId, v as toWei, w as postHogFailureObservation, x as failureEvidenceProps, y as CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, z as signerFailure } from "./create-capxul-client-5Bk0PS0R.mjs";
|
|
2
|
+
import { $ as CapxulError, A as toAuthUserId, B as toJwtToken, D as toAddress, E as toAccountId, F as toDurationMs, H as toOrgId, I as toEmail, J as toSessionToken, K as toPublishableKey, L as toEpochMs, M as toChainId, N as toCountryCode, O as toAllowedOrigin, P as toCurrencyCode, Q as CAPXUL_ERROR_CODES, R as toEpochSeconds, T as currencySymbolFor, U as toPartyId, V as toKycTier, X as HANDLE_RE, Y as toTesterKind, Z as decodeConvexError, d as AuthClientError, f as AuthClientPortTag, g as BASE_SEPOLIA_CHAIN_ID, h as normalizeBindingEmail, it as FAILURE_MODES, l as ClockPortTag, m as CAPXUL_PAYMENTS_V2_ADDRESS, nt as isCapxulError, q as toRoleKey, rt as CHAIN_UPSTREAMS, s as AuthCachePortTag, tt as Errors, u as authClientPortFromPromiseAdapter, x as EVM_ADDRESS_RE, z as toHandle } from "./clock-C2AUlq1V.mjs";
|
|
3
|
+
import { n as SystemClockLayer } from "./OAuthBearerAuthClient-BHvDR8_0.mjs";
|
|
4
4
|
import { Cause, Context, Data, Duration, Effect, Exit, Layer, Result, Schedule, SchemaIssue, SchemaParser, Scope, Tracer } from "effect";
|
|
5
5
|
import { keccak256, recoverAddress, stringToHex } from "viem";
|
|
6
6
|
import { getFunctionName, makeFunctionReference } from "convex/server";
|
|
@@ -60,7 +60,8 @@ function paymentPhase(status) {
|
|
|
60
60
|
case "pending_claim": return AWAITING_ACTOR;
|
|
61
61
|
case "settled": return COMPLETED;
|
|
62
62
|
case "cancelled": return WITHDRAWN;
|
|
63
|
-
case "failed":
|
|
63
|
+
case "failed":
|
|
64
|
+
case "unresolved": return FAILED;
|
|
64
65
|
default: return unknownStatus(status);
|
|
65
66
|
}
|
|
66
67
|
}
|
|
@@ -1593,6 +1594,7 @@ function makeConnectionId() {
|
|
|
1593
1594
|
//#region src/adapters/convex-call/ConvexCallAdapter.ts
|
|
1594
1595
|
/** Exact floor-first allowlist; every additional handler must migrate its validator first. */
|
|
1595
1596
|
const OBSERVED_CONVEX_ACTIONS = /* @__PURE__ */ new Set([
|
|
1597
|
+
"payroll/actions:authorizeRun",
|
|
1596
1598
|
"account/actions:readBalance",
|
|
1597
1599
|
"holdings/actions:current",
|
|
1598
1600
|
"smartAccount/actions:claim",
|
|
@@ -1601,14 +1603,45 @@ const OBSERVED_CONVEX_ACTIONS = /* @__PURE__ */ new Set([
|
|
|
1601
1603
|
"org/actions:submitBootstrap",
|
|
1602
1604
|
"org/actions:resumeBootstrapSubmission",
|
|
1603
1605
|
"org/actions:confirmBootstrap",
|
|
1604
|
-
"org/actions:readTreasury"
|
|
1606
|
+
"org/actions:readTreasury",
|
|
1607
|
+
"moneyExecution/actions:preparePaymentExecution",
|
|
1608
|
+
"moneyExecution/actions:abandonPaymentExecution",
|
|
1609
|
+
"moneyExecution/actions:submitPaymentExecution",
|
|
1610
|
+
"moneyExecution/paymentCommandActions:preparePaymentLifecycleExecution",
|
|
1611
|
+
"moneyExecution/paymentCommandActions:prepareOrganizationPaymentExecution",
|
|
1612
|
+
"moneyExecution/paymentCommandActions:submitPaymentCommandExecution"
|
|
1605
1613
|
]);
|
|
1606
1614
|
const OBSERVED_CONVEX_QUERIES = /* @__PURE__ */ new Set([
|
|
1615
|
+
"movement/activity:list",
|
|
1616
|
+
"movement/activity:summary",
|
|
1617
|
+
"movement/activity:get",
|
|
1618
|
+
"financialOps/queries:verifyPaymentDocument",
|
|
1619
|
+
"financialOps/queries:renderStoredDocument",
|
|
1620
|
+
"financialOps/addressBook:list",
|
|
1621
|
+
"financialOps/addressBook:get",
|
|
1622
|
+
"financialOps/requestsInbox:list",
|
|
1623
|
+
"financialOps/requestsInbox:get",
|
|
1624
|
+
"financialOps/requestsInbox:inboxList",
|
|
1625
|
+
"payroll/queries:runs",
|
|
1626
|
+
"payroll/queries:groups",
|
|
1627
|
+
"payroll/queries:terms",
|
|
1628
|
+
"financialOps/queries:resolveRecipient",
|
|
1607
1629
|
"identity/queries:loadByAuthUserId",
|
|
1608
1630
|
"smartAccount/queries:loadByAuthUserId",
|
|
1609
1631
|
"org/lifecycle:load"
|
|
1610
1632
|
]);
|
|
1611
1633
|
const OBSERVED_CONVEX_MUTATIONS = /* @__PURE__ */ new Set([
|
|
1634
|
+
"movement/activity:annotate",
|
|
1635
|
+
"financialOps/addressBook:add",
|
|
1636
|
+
"financialOps/addressBook:hide",
|
|
1637
|
+
"financialOps/addressBook:unhide",
|
|
1638
|
+
"financialOps/addressBook:label",
|
|
1639
|
+
"financialOps/requestsInbox:issue",
|
|
1640
|
+
"financialOps/requestsInbox:cancel",
|
|
1641
|
+
"financialOps/requestsInbox:approve",
|
|
1642
|
+
"financialOps/requestsInbox:decline",
|
|
1643
|
+
"payroll/mutations:saveGroup",
|
|
1644
|
+
"payroll/mutations:removeGroup",
|
|
1612
1645
|
"identity/mutations:create",
|
|
1613
1646
|
"identity/mutations:update",
|
|
1614
1647
|
"identity/mutations:completeOnboarding",
|
|
@@ -1677,7 +1710,7 @@ var ConvexCallAdapter = class {
|
|
|
1677
1710
|
const carriedContext = sanitizeObservationContext(args.observationContext);
|
|
1678
1711
|
let hostContext;
|
|
1679
1712
|
const invocationSnapshot = readInvocationObservation(args);
|
|
1680
|
-
if (invocationSnapshot !== void 0) hostContext = invocationSnapshot.context;
|
|
1713
|
+
if (invocationSnapshot !== void 0) hostContext = invocationSnapshot.active ? invocationSnapshot.context : void 0;
|
|
1681
1714
|
else {
|
|
1682
1715
|
const resolveContext = this.#observation?.resolveContext;
|
|
1683
1716
|
if (resolveContext !== void 0) try {
|
|
@@ -1834,12 +1867,13 @@ function ConvexIdentityLayer() {
|
|
|
1834
1867
|
function brandProfile(raw) {
|
|
1835
1868
|
return {
|
|
1836
1869
|
authUserId: toAuthUserId(raw.authUserId),
|
|
1870
|
+
...raw.testerKind === void 0 ? {} : { testerKind: toTesterKind(raw.testerKind) },
|
|
1837
1871
|
email: toEmail(raw.email),
|
|
1838
1872
|
displayName: raw.displayName,
|
|
1839
1873
|
country: raw.country === null ? null : toCountryCode(raw.country),
|
|
1840
1874
|
onboarded: raw.onboarded ?? false,
|
|
1841
1875
|
withdrawalAddress: raw.withdrawalAddress === null || raw.withdrawalAddress === void 0 ? null : toAddress(raw.withdrawalAddress),
|
|
1842
|
-
|
|
1876
|
+
handle: raw.handle === null || raw.handle === void 0 ? null : toHandle(raw.handle),
|
|
1843
1877
|
imageUrl: raw.imageUrl ?? null,
|
|
1844
1878
|
kycTier: toKycTier(raw.kycTier),
|
|
1845
1879
|
createdAt: toEpochMs(raw.createdAt),
|
|
@@ -2012,8 +2046,9 @@ var OrgPortTag = class extends Context.Service()("@capxul/sdk/ports/OrgPort") {}
|
|
|
2012
2046
|
function brandOrgView(wire, treasury, viewerRole) {
|
|
2013
2047
|
return {
|
|
2014
2048
|
id: toOrgId(wire.orgId),
|
|
2049
|
+
...wire.creationSource === void 0 ? {} : { creationSource: toTesterKind(wire.creationSource) },
|
|
2015
2050
|
name: wire.name,
|
|
2016
|
-
handle: wire.
|
|
2051
|
+
handle: wire.handle,
|
|
2017
2052
|
safeAddress: toAddress(wire.safeAddress.toLowerCase()),
|
|
2018
2053
|
role: viewerRole,
|
|
2019
2054
|
treasury,
|
|
@@ -3818,4 +3853,4 @@ function captureExceptionSync(telemetry, error, context) {
|
|
|
3818
3853
|
} catch {}
|
|
3819
3854
|
}
|
|
3820
3855
|
//#endregion
|
|
3821
|
-
export { CAPXUL_ERROR_CODES, CAPXUL_OPERATIONS, CAPXUL_PAYMENTS_V2_ADDRESS, CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, CHAIN_UPSTREAMS, CapxulError, Errors, FAILURE_MODES, PAYMENT_DIRECTIONS, PAYMENT_STATUSES, captureException, captureExceptionSync, createCapxulClient, deriveDevPrivateKey, devPrivateKeySigner, eip1193AccountProvider, embeddedSigner, fingerprintPaymentIntent, formatMoney, inboxPhase, injectedWalletSigner, isCapxulError, isCapxulOperation, isClaimed, isMoneyParseError, isRestoring, isSettingUpLifecycle, localPrivateKeyAccountProvider, normalizeCapxulOperation, openfortEmbeddedSigner, openfortEmbeddedSignerFromWallet, openfortEmbeddedWalletPort, parseMoney, paymentPhase, postHogObservability, requestPhase, destination as resolveIdentityDestination, toCountryCode, toAddress as toEvmAddress };
|
|
3856
|
+
export { CAPXUL_ERROR_CODES, CAPXUL_OPERATIONS, CAPXUL_PAYMENTS_V2_ADDRESS, CAPXUL_SDK_EXPECTED_OUTCOME_EVENT, CHAIN_UPSTREAMS, CapxulError, EVM_ADDRESS_RE, Errors, FAILURE_MODES, HANDLE_RE, PAYMENT_DIRECTIONS, PAYMENT_STATUSES, captureException, captureExceptionSync, createCapxulClient, deriveDevPrivateKey, devPrivateKeySigner, eip1193AccountProvider, embeddedSigner, fingerprintPaymentIntent, formatMoney, inboxPhase, injectedWalletSigner, isCapxulError, isCapxulOperation, isClaimed, isMoneyParseError, isRestoring, isSettingUpLifecycle, localPrivateKeyAccountProvider, normalizeCapxulOperation, openfortEmbeddedSigner, openfortEmbeddedSignerFromWallet, openfortEmbeddedWalletPort, parseMoney, paymentPhase, postHogObservability, requestPhase, destination as resolveIdentityDestination, toCountryCode, toAddress as toEvmAddress, toHandle, toPartyId };
|
package/dist/node/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CachedJwt, S as AuthCachePortTag, b as AuthCacheError, j as AuthSession, n as CapxulSigner, x as AuthCachePort } from "../signer-
|
|
2
|
-
import { n as oauthBearerAuthClient, t as OAuthBearerAuthClientInput } from "../OAuthBearerAuthClient-
|
|
1
|
+
import { C as CachedJwt, S as AuthCachePortTag, b as AuthCacheError, j as AuthSession, n as CapxulSigner, x as AuthCachePort } from "../signer-C0hZ6Kiy.mjs";
|
|
2
|
+
import { n as oauthBearerAuthClient, t as OAuthBearerAuthClientInput } from "../OAuthBearerAuthClient-D-DLYlKj.mjs";
|
|
3
3
|
import { Effect, FileSystem, Layer, Path } from "effect";
|
|
4
4
|
import { Hex } from "viem";
|
|
5
5
|
//#region src/adapters/auth-cache/FileSystemAuthCacheAdapter.d.ts
|
package/dist/node/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as oauthBearerAuthClient } from "../OAuthBearerAuthClient-
|
|
1
|
+
import { D as toAddress, a as parseCachedJwt, i as parseAuthSession, n as InMemoryAuthCacheAdapter, o as AuthCacheError, r as BrowserAuthCacheAdapter, s as AuthCachePortTag } from "../clock-C2AUlq1V.mjs";
|
|
2
|
+
import { t as oauthBearerAuthClient } from "../OAuthBearerAuthClient-BHvDR8_0.mjs";
|
|
3
3
|
import { Effect, FileSystem, Layer, Path } from "effect";
|
|
4
4
|
import { privateKeyToAccount } from "viem/accounts";
|
|
5
5
|
import * as os from "node:os";
|