@delopay/sdk 0.67.0 → 0.69.0
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/dist/{chunk-2DNFEA5T.js → chunk-XIRQPEI6.js} +25 -1
- package/dist/chunk-XIRQPEI6.js.map +1 -0
- package/dist/index.cjs +24 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +101 -4
- package/dist/index.d.ts +101 -4
- package/dist/index.js +1 -1
- package/dist/internal.cjs +35 -0
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +9 -3
- package/dist/internal.d.ts +9 -3
- package/dist/internal.js +12 -1
- package/dist/internal.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunk-2DNFEA5T.js.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -440,6 +440,56 @@ interface PaymentAttemptsListResponse {
|
|
|
440
440
|
/** Every attempt made on this payment, including failed retries across connectors. */
|
|
441
441
|
data: PaymentAttemptResponse[];
|
|
442
442
|
}
|
|
443
|
+
/** Which entity a status-history event belongs to. */
|
|
444
|
+
type PaymentStatusHistoryEntityType = 'payment' | 'attempt' | 'refund' | 'dispute';
|
|
445
|
+
/**
|
|
446
|
+
* One event on a payment's status timeline: the creation of, or a status
|
|
447
|
+
* transition on, the payment intent or one of its attempts / refunds /
|
|
448
|
+
* disputes.
|
|
449
|
+
*/
|
|
450
|
+
interface PaymentStatusHistoryEvent {
|
|
451
|
+
entity_type: PaymentStatusHistoryEntityType;
|
|
452
|
+
/** Id of the attempt / refund / dispute the event belongs to (absent for intent-level events). */
|
|
453
|
+
entity_id?: string | null;
|
|
454
|
+
/** The attempt this event is associated with, where known. */
|
|
455
|
+
attempt_id?: string | null;
|
|
456
|
+
/** The status before this event. Absent on creation events and derived events. */
|
|
457
|
+
previous_status?: string | null;
|
|
458
|
+
/**
|
|
459
|
+
* The status after this event. Absent only on a derived creation event,
|
|
460
|
+
* where the initial status was not recorded.
|
|
461
|
+
*/
|
|
462
|
+
status?: string | null;
|
|
463
|
+
/** Connector involved in the event, where known. */
|
|
464
|
+
connector?: string | null;
|
|
465
|
+
error_code?: string | null;
|
|
466
|
+
error_message?: string | null;
|
|
467
|
+
/** `true` when this event records the creation of the entity. */
|
|
468
|
+
is_creation: boolean;
|
|
469
|
+
/**
|
|
470
|
+
* `true` when this event was reconstructed from current records (payments
|
|
471
|
+
* predating the persisted status log) — its timestamp is approximate and
|
|
472
|
+
* intermediate transitions may be missing.
|
|
473
|
+
*/
|
|
474
|
+
derived: boolean;
|
|
475
|
+
/** ISO-8601 timestamp of the event. */
|
|
476
|
+
timestamp: string;
|
|
477
|
+
[key: string]: unknown;
|
|
478
|
+
}
|
|
479
|
+
/** Response body for `payments.listStatusHistory` — the status timeline of a payment. */
|
|
480
|
+
interface PaymentStatusHistoryResponse {
|
|
481
|
+
/** The payment this timeline belongs to. */
|
|
482
|
+
payment_id: string;
|
|
483
|
+
/**
|
|
484
|
+
* `true` when every event comes from the persisted status-transition log;
|
|
485
|
+
* `false` when any event had to be reconstructed from current records.
|
|
486
|
+
*/
|
|
487
|
+
complete: boolean;
|
|
488
|
+
/** The number of events returned. */
|
|
489
|
+
count: number;
|
|
490
|
+
/** All recorded events, oldest first. */
|
|
491
|
+
events: PaymentStatusHistoryEvent[];
|
|
492
|
+
}
|
|
443
493
|
/**
|
|
444
494
|
* Parameters for creating a refund.
|
|
445
495
|
*
|
|
@@ -2917,9 +2967,9 @@ interface AnalyticsScopeRequest {
|
|
|
2917
2967
|
* a standalone widget (e.g. a pinned card) skips the query/fold work it
|
|
2918
2968
|
* doesn't need. Tokens: `series` (current daily series — KPI values + chart),
|
|
2919
2969
|
* `previous` (the equal-length prior window — period-over-period deltas),
|
|
2920
|
-
* `connectors` (processor donut)
|
|
2921
|
-
* donut). Omit for the full dashboard
|
|
2922
|
-
* back as empty arrays.
|
|
2970
|
+
* `connectors` (processor donut), `children` (breakdown table + merchant
|
|
2971
|
+
* donut) and `methods` (payment-method donut). Omit for the full dashboard
|
|
2972
|
+
* (all blocks). Unrequested blocks come back as empty arrays.
|
|
2923
2973
|
*/
|
|
2924
2974
|
sections?: string | null;
|
|
2925
2975
|
/**
|
|
@@ -2963,6 +3013,9 @@ interface AnalyticsConnectorDay {
|
|
|
2963
3013
|
success: number;
|
|
2964
3014
|
failed: number;
|
|
2965
3015
|
open: number;
|
|
3016
|
+
/** Timed-out-unpaid volume, reported separately from `failed` (absent on
|
|
3017
|
+
* older backends, where it is folded into `failed`). */
|
|
3018
|
+
expired?: number;
|
|
2966
3019
|
}
|
|
2967
3020
|
/** One processor's daily, status-split volume series over the window. */
|
|
2968
3021
|
interface AnalyticsConnectorSeries {
|
|
@@ -2981,6 +3034,26 @@ interface AnalyticsChild {
|
|
|
2981
3034
|
/** Aggregate of the child's activity over the current window (USD). */
|
|
2982
3035
|
totals: AnalyticsDayBucket;
|
|
2983
3036
|
}
|
|
3037
|
+
/**
|
|
3038
|
+
* One payment method's status-split volume totals over the current window
|
|
3039
|
+
* (USD major units), for the "volume by payment method" donut. `method` is the
|
|
3040
|
+
* attempt's high-level `payment_method` (`card`, `wallet`, …) and
|
|
3041
|
+
* `method_type` its narrower `payment_method_type` (`credit`, `apple_pay`,
|
|
3042
|
+
* `ideal`, …); both are null for intents that never reached an attempt
|
|
3043
|
+
* (typically abandoned open volume).
|
|
3044
|
+
*/
|
|
3045
|
+
interface AnalyticsMethodSlice {
|
|
3046
|
+
/** Processor that handled the volume (`"Direct"` when the attempt carried no
|
|
3047
|
+
* connector), matching the `connectors` block's naming — so the method donut
|
|
3048
|
+
* can be filtered per processor. */
|
|
3049
|
+
connector: string;
|
|
3050
|
+
method?: string | null;
|
|
3051
|
+
method_type?: string | null;
|
|
3052
|
+
success: number;
|
|
3053
|
+
failed: number;
|
|
3054
|
+
open: number;
|
|
3055
|
+
expired?: number;
|
|
3056
|
+
}
|
|
2984
3057
|
/**
|
|
2985
3058
|
* One drill level of the analytics dashboard: the scope's own daily series +
|
|
2986
3059
|
* processor mix and its direct children's series. Range / metric / donut
|
|
@@ -3014,6 +3087,12 @@ interface AnalyticsScopeResponse {
|
|
|
3014
3087
|
previous_series: AnalyticsDayBucket[];
|
|
3015
3088
|
connectors: AnalyticsConnectorSeries[];
|
|
3016
3089
|
children: AnalyticsChild[];
|
|
3090
|
+
/**
|
|
3091
|
+
* Per-payment-method window totals for the method donut. Empty unless the
|
|
3092
|
+
* `methods` section is requested (or `sections` is omitted); absent on
|
|
3093
|
+
* backends that predate the method dimension.
|
|
3094
|
+
*/
|
|
3095
|
+
methods?: AnalyticsMethodSlice[];
|
|
3017
3096
|
}
|
|
3018
3097
|
|
|
3019
3098
|
/** Create and manage API keys for a merchant account. */
|
|
@@ -3837,6 +3916,24 @@ declare class Payments {
|
|
|
3837
3916
|
* ```
|
|
3838
3917
|
*/
|
|
3839
3918
|
listAttempts(paymentId: string, options?: RequestExtras): Promise<PaymentAttemptsListResponse>;
|
|
3919
|
+
/**
|
|
3920
|
+
* The status timeline of a payment: every recorded creation / status
|
|
3921
|
+
* transition of the intent and its attempts, refunds and disputes, oldest
|
|
3922
|
+
* first. `complete: false` marks timelines partially reconstructed from
|
|
3923
|
+
* current records (payments created before the status log existed).
|
|
3924
|
+
*
|
|
3925
|
+
* @param paymentId - The payment intent ID.
|
|
3926
|
+
* @returns The ordered status-history events.
|
|
3927
|
+
*
|
|
3928
|
+
* @example
|
|
3929
|
+
* ```typescript
|
|
3930
|
+
* const { events, complete } = await delopay.payments.listStatusHistory('pay_abc123');
|
|
3931
|
+
* for (const event of events) {
|
|
3932
|
+
* console.log(event.timestamp, event.entity_type, event.status);
|
|
3933
|
+
* }
|
|
3934
|
+
* ```
|
|
3935
|
+
*/
|
|
3936
|
+
listStatusHistory(paymentId: string, options?: RequestExtras): Promise<PaymentStatusHistoryResponse>;
|
|
3840
3937
|
/**
|
|
3841
3938
|
* Update an existing payment intent before it is confirmed.
|
|
3842
3939
|
*
|
|
@@ -5646,4 +5743,4 @@ declare function parseImportedBranding(raw: unknown): CheckoutBranding;
|
|
|
5646
5743
|
declare function applyBrandingVariables(el: HTMLElement, b: CheckoutBranding): void;
|
|
5647
5744
|
declare function shadowFor(style: SurfaceStyle): string;
|
|
5648
5745
|
|
|
5649
|
-
export { type AddUserRequest, type AddUserResponse, type Address, type AddressDetails, type AllocationListResponse, type AllocationResponse, type AllocationTransferRequest, type AllocationTransferResponse, Analytics, type AnalyticsChild, type AnalyticsConnectorDay, type AnalyticsConnectorSeries, AnalyticsDashboard, type AnalyticsDayBucket, type AnalyticsScopeRequest, type AnalyticsScopeResponse, type ApiKeyCreateRequest, type ApiKeyCreateResponse, type ApiKeyExpiration, type ApiKeyListConstraints, type ApiKeyResponse, type ApiKeyRevokeResponse, type ApiKeyUpdateRequest, type ApplePayVerificationRequest, type ApplePayVerificationResponse, type ApplePayVerifiedDomainsResponse, type AttemptStatus, type AuthResponse, type AuthenticationCreateRequest, type AuthenticationResponse, type AuthenticationStatus, type AuthenticationType, type AutoRechargeConfig, type AutoRechargeUpdateRequest, type AvailabilityOverrideCreateRequest, type AvailabilityOverrideResponse, AvailabilityOverrides, type AvailabilityPreviewMethod, type AvailabilityPreviewParams, type AvailabilityPreviewResponse, BRANDING_EXPORT_FORMAT, BRANDING_EXPORT_VERSION, type BillingCompleteSetupRequest, type BillingProfileResponse, type BillingSetupRequest, type BillingSetupResponse, type BlockedAttempt, type BlockedAttemptListParams, type BlockedAttemptListResponse, type BlocklistAddRequest, type BlocklistDataKind, type BlocklistResponse, type BrandingExport, type BrandingSource, type BuiltInRegionGroupResponse, type BusinessPaymentLinkConfig, CUSTOM_CSS_MAX_LENGTH, type CancelSubscriptionRequest, type CancelSubscriptionResponse, type CaptureMethod, type CardDetail, type CardDetailFromLocker, Cards, type ChangePasswordRequest, type CheckoutBranding, type ConditionNode, type ConfirmSubscriptionPaymentDetails, type ConfirmSubscriptionRequest, type ConfirmSubscriptionResponse, type Connector, type ConnectorCloneRequest, type ConnectorCreateRequest, type ConnectorListResponse, type ConnectorResponse, type ConnectorSelection, type ConnectorType, type ConnectorUpdateRequest, type ConnectorVolumeSplit, type ConnectorWebhookEntry, type ConnectorWebhookEventType, type ConnectorWebhookListResponse, type ConnectorWebhookRegisterRequest, type ConnectorWebhookRegisterResponse, type CornerRadius, type CreateAndConfirmSubscriptionRequest, type CreateSubscriptionPaymentDetails, type CreateSubscriptionRequest, type Currency, type CurrencyRevenue, type CustomerCreateRequest, type CustomerListParams, type CustomerPaymentMethodsListParams, type CustomerPaymentMethodsListResponse, type CustomerResponse, type CustomerUpdateRequest, DEFAULT_BADGES, DEFAULT_BADGES_DARK, DEFAULT_BRANDING, DEFAULT_BRANDING_DARK, type DeleteAccountRequest, type DeleteUserRoleRequest, Delopay, DelopayAuthenticationError, DelopayError, type DelopayLogger, type DelopayOptions, type DisputeEvidenceRequest, type DisputeListParams, type DisputeResponse, type DisputeStage, type DisputeStatus, type EncodedBranding, type EphemeralKeyCreateRequest, type EphemeralKeyCreateResponse, type EuclidComparison, type EuclidComparisonType, type EuclidIfStatement, type EuclidValue, type EventClass, type EventDeliveryAttemptResponse, type EventDetailResponse, type EventListParams, type EventListResponse, type EventResponse, type EventType, Export, FeatureMatrix, type FeeOwner, FeeProgramBuilder, type FeeRuleConditions, type FeeRuleInput, type FeeRulePreviewRequest, type FeeRulePreviewResponse, type FeeScheduleCreateRequest, type FeeScheduleResponse, type FeeScheduleUpdateRequest, type FeeSpecInput, type FeeType, Files, type FontFamily, type FontWeight, Forex, type ForgotPasswordRequest, type FromEmailRequest, type FutureUsage, type GatewayConnectRequest, type GatewayResponse, type GetSubscriptionItemsParams, type GetSubscriptionItemsResponse, type GlobalSearchRequest, type GroupNode, type ImpersonateEmployeeRequest, type IntentStatus, type InviteUsersRequest, type InviteUsersResponse, type InvoiceStatus, type LabelStyle, type LayoutStyle, type LeafNode, type LedgerEntry, type LedgerListParams, type LedgerResponse, type LinkedRoutingConfigRetrieveResponse, type ListInvitableRolesParams, type ListUsersInLineageParams, type LoginHistoryEntry, type LoginHistoryParams, type LoginHistoryResponse, type LogoShape, type LogoSize, type MandateListParams, type MandateResponse, type MandateRevokedResponse, type MandateStatus, type MandateType, type MerchantAccountCreateRequest, type MerchantAccountResponse, type MerchantAccountType, type MerchantAccountUpdateRequest, type MerchantOverviewResponse, type MerchantOverviewStat, type MerchantRoutingAlgorithm, type MethodSurcharge, type MinimalRoleInfo, type NonPillRadius, type OverrideAction, type OverrideScope, type ParentGroup, type ParentGroupInfo, type PauseSubscriptionRequest, type PauseSubscriptionResponse, type PaymentAttemptResponse, type PaymentAttemptsListResponse, type PaymentCancelRequest, type PaymentCaptureRequest, type PaymentConfirmRequest, type PaymentCreateRequest, type PaymentErrorDetails, type PaymentExperience, type PaymentIdFormatConfig, type PaymentIdStyle, type PaymentLayout, type PaymentLinkBackgroundImageConfig, type PaymentLinkConfigRequest, type PaymentLinkListParams, type PaymentLinkListResponse, type PaymentLinkResponse, type PaymentLinkTransactionDetails, type PaymentListParams, type PaymentListResponse, type PaymentMethod, type PaymentMethodCreateRequest, type PaymentMethodDeleteResponse, type PaymentMethodListParams, type PaymentMethodResponse, type PaymentMethodType, type PaymentMethodUpdateRequest, type PaymentResponse, type PaymentRetrieveOptions, type PaymentUpdateRequest, type PayoutCreateRequest, type PayoutListParams, type PayoutListResponse, type PayoutResponse, type PayoutStatus, type PayoutType, type PayoutUpdateRequest, type PerMethodSurchargeItem, type PermissionScope, type PhoneDetails, type PhoneOtpRequest, type PhoneOtpResponse, type PhoneOtpVerifyRequest, type PhoneOtpVerifyResponse, type PlatformFeeKind, type PlatformFeeOutput, type PlatformFeeProgram, type PlatformFeeRule, type PlatformFeeRuleInput, type PlatformFeeRuleOutput, type PlatformFeeRuleRecord, type PlatformFeeRuleRequest, type PollStatus, type PollStatusResponse, type ProfileAcquirerCreateRequest, type ProfileAcquirerResponse, type ProfileAcquirerUpdateRequest, type ProfileCreateRequest, type ProfileDefaultRoutingConfig, type ProfileDeniedConnectorsResponse, type ProfileLogoUploadResponse, type ProfileResponse, type ProfileUpdateRequest, type ProgramConnectorSelection, type ProjectCreateRequest, type ProjectResponse, type ProjectStats, type ProjectStatsResponse, type ProjectUpdateRequest, type RecoveryCodesResponse, type RefundCreateRequest, type RefundListParams, type RefundListResponse, type RefundResponse, type RefundStatus, type RefundType, type RefundUpdateRequest, type RegionCountriesResponse, type RegionCreateRequest, type RegionResponse, type RegionSetCountriesRequest, type RegionUpdateRequest, Regions, type RelayRequest, type RelayResponse, type RelayStatus, type RelayType, type RequestExtras, type RequestFn, type RequestOptions, type ResetPasswordRequest, type ResumeSubscriptionRequest, type ResumeSubscriptionResponse, type RoutableConnectorChoice, type RoutingActivatePayload, type RoutingConfigCreateRequest, type RoutingConfigResponse, type RoutingDeactivateRequest, type RoutingDictionary, type RoutingDictionaryRecord, type RuleConnectorSelection, Search, type SearchGroupResponse, type SearchIndex, type SearchStatus, type ShopCreateRequest, type ShopResponse, type ShopStats, type ShopStatsResponse, type ShopUpdateRequest, type SignInRequest, type SignUpRequest, type SignUpWithMerchantIdRequest, type SignUpWithMerchantRequest, type SizeScale, type SpacingScale, type StaticRoutingAlgorithm, type StatsPeriod, type StripeConnectAccountRequest, type StripeConnectAccountResponse, type StripeConnectLinkRequest, type StripeConnectLinkResponse, type SubscriptionEstimateParams, type SubscriptionEstimateResponse, type SubscriptionInvoice, type SubscriptionItem, type SubscriptionItemPrice, type SubscriptionItemType, type SubscriptionLineItem, type SubscriptionListParams, type SubscriptionPaymentData, type SubscriptionPaymentDetails, type SubscriptionPeriodUnit, type SubscriptionResponse, type SubscriptionStatus, Subscriptions, type SummaryPosition, type SurchargeRuleRequest, type SurchargeRuleResponse, type SurfaceStyle, type SwitchMerchantRequest, type SwitchProfileRequest, type Terminate2faQueryParams, type ThreeDSDecision, type ThreeDsRuleExecuteRequest, type ThreeDsRuleResponse, type TierSummary, type TokenPurpose, type TokenResponse, type TopupRequest, type TopupResponse, type TotpResponse, type TransactionType, type TrustBadge, type UpdateSubscriptionRequest, type UpdateUserDetailsRequest, type UpdateUserRoleRequest, type UserInLineage, type UserResponse, type UserSessionEntry, type UserSessionListResponse, type UserSessionRevokeResponse, type VerifyTotpRequest, type WebhookDeliveryAttempt, type WebhookEvent, type WebhookRegistrationEnvironment, Webhooks, allOf, anyOf, applyBrandingVariables, buildBrandingExport, buttonPadValue, cloneBranding, decodeBadges, decodeBranding, defaultBranding, encodeBadges, encodeBranding, feeProgram, fontStack, fontWeightValue, inputPadValue, isDarkSurface, isHexColor, leaf, logoDimensions, parseImportedBranding, programToTree, radiusValue, ruleMatchToTree, sanitizeCustomCss, shadowFor, surfacePadValue, verticalGapValue };
|
|
5746
|
+
export { type AddUserRequest, type AddUserResponse, type Address, type AddressDetails, type AllocationListResponse, type AllocationResponse, type AllocationTransferRequest, type AllocationTransferResponse, Analytics, type AnalyticsChild, type AnalyticsConnectorDay, type AnalyticsConnectorSeries, AnalyticsDashboard, type AnalyticsDayBucket, type AnalyticsMethodSlice, type AnalyticsScopeRequest, type AnalyticsScopeResponse, type ApiKeyCreateRequest, type ApiKeyCreateResponse, type ApiKeyExpiration, type ApiKeyListConstraints, type ApiKeyResponse, type ApiKeyRevokeResponse, type ApiKeyUpdateRequest, type ApplePayVerificationRequest, type ApplePayVerificationResponse, type ApplePayVerifiedDomainsResponse, type AttemptStatus, type AuthResponse, type AuthenticationCreateRequest, type AuthenticationResponse, type AuthenticationStatus, type AuthenticationType, type AutoRechargeConfig, type AutoRechargeUpdateRequest, type AvailabilityOverrideCreateRequest, type AvailabilityOverrideResponse, AvailabilityOverrides, type AvailabilityPreviewMethod, type AvailabilityPreviewParams, type AvailabilityPreviewResponse, BRANDING_EXPORT_FORMAT, BRANDING_EXPORT_VERSION, type BillingCompleteSetupRequest, type BillingProfileResponse, type BillingSetupRequest, type BillingSetupResponse, type BlockedAttempt, type BlockedAttemptListParams, type BlockedAttemptListResponse, type BlocklistAddRequest, type BlocklistDataKind, type BlocklistResponse, type BrandingExport, type BrandingSource, type BuiltInRegionGroupResponse, type BusinessPaymentLinkConfig, CUSTOM_CSS_MAX_LENGTH, type CancelSubscriptionRequest, type CancelSubscriptionResponse, type CaptureMethod, type CardDetail, type CardDetailFromLocker, Cards, type ChangePasswordRequest, type CheckoutBranding, type ConditionNode, type ConfirmSubscriptionPaymentDetails, type ConfirmSubscriptionRequest, type ConfirmSubscriptionResponse, type Connector, type ConnectorCloneRequest, type ConnectorCreateRequest, type ConnectorListResponse, type ConnectorResponse, type ConnectorSelection, type ConnectorType, type ConnectorUpdateRequest, type ConnectorVolumeSplit, type ConnectorWebhookEntry, type ConnectorWebhookEventType, type ConnectorWebhookListResponse, type ConnectorWebhookRegisterRequest, type ConnectorWebhookRegisterResponse, type CornerRadius, type CreateAndConfirmSubscriptionRequest, type CreateSubscriptionPaymentDetails, type CreateSubscriptionRequest, type Currency, type CurrencyRevenue, type CustomerCreateRequest, type CustomerListParams, type CustomerPaymentMethodsListParams, type CustomerPaymentMethodsListResponse, type CustomerResponse, type CustomerUpdateRequest, DEFAULT_BADGES, DEFAULT_BADGES_DARK, DEFAULT_BRANDING, DEFAULT_BRANDING_DARK, type DeleteAccountRequest, type DeleteUserRoleRequest, Delopay, DelopayAuthenticationError, DelopayError, type DelopayLogger, type DelopayOptions, type DisputeEvidenceRequest, type DisputeListParams, type DisputeResponse, type DisputeStage, type DisputeStatus, type EncodedBranding, type EphemeralKeyCreateRequest, type EphemeralKeyCreateResponse, type EuclidComparison, type EuclidComparisonType, type EuclidIfStatement, type EuclidValue, type EventClass, type EventDeliveryAttemptResponse, type EventDetailResponse, type EventListParams, type EventListResponse, type EventResponse, type EventType, Export, FeatureMatrix, type FeeOwner, FeeProgramBuilder, type FeeRuleConditions, type FeeRuleInput, type FeeRulePreviewRequest, type FeeRulePreviewResponse, type FeeScheduleCreateRequest, type FeeScheduleResponse, type FeeScheduleUpdateRequest, type FeeSpecInput, type FeeType, Files, type FontFamily, type FontWeight, Forex, type ForgotPasswordRequest, type FromEmailRequest, type FutureUsage, type GatewayConnectRequest, type GatewayResponse, type GetSubscriptionItemsParams, type GetSubscriptionItemsResponse, type GlobalSearchRequest, type GroupNode, type ImpersonateEmployeeRequest, type IntentStatus, type InviteUsersRequest, type InviteUsersResponse, type InvoiceStatus, type LabelStyle, type LayoutStyle, type LeafNode, type LedgerEntry, type LedgerListParams, type LedgerResponse, type LinkedRoutingConfigRetrieveResponse, type ListInvitableRolesParams, type ListUsersInLineageParams, type LoginHistoryEntry, type LoginHistoryParams, type LoginHistoryResponse, type LogoShape, type LogoSize, type MandateListParams, type MandateResponse, type MandateRevokedResponse, type MandateStatus, type MandateType, type MerchantAccountCreateRequest, type MerchantAccountResponse, type MerchantAccountType, type MerchantAccountUpdateRequest, type MerchantOverviewResponse, type MerchantOverviewStat, type MerchantRoutingAlgorithm, type MethodSurcharge, type MinimalRoleInfo, type NonPillRadius, type OverrideAction, type OverrideScope, type ParentGroup, type ParentGroupInfo, type PauseSubscriptionRequest, type PauseSubscriptionResponse, type PaymentAttemptResponse, type PaymentAttemptsListResponse, type PaymentCancelRequest, type PaymentCaptureRequest, type PaymentConfirmRequest, type PaymentCreateRequest, type PaymentErrorDetails, type PaymentExperience, type PaymentIdFormatConfig, type PaymentIdStyle, type PaymentLayout, type PaymentLinkBackgroundImageConfig, type PaymentLinkConfigRequest, type PaymentLinkListParams, type PaymentLinkListResponse, type PaymentLinkResponse, type PaymentLinkTransactionDetails, type PaymentListParams, type PaymentListResponse, type PaymentMethod, type PaymentMethodCreateRequest, type PaymentMethodDeleteResponse, type PaymentMethodListParams, type PaymentMethodResponse, type PaymentMethodType, type PaymentMethodUpdateRequest, type PaymentResponse, type PaymentRetrieveOptions, type PaymentStatusHistoryEntityType, type PaymentStatusHistoryEvent, type PaymentStatusHistoryResponse, type PaymentUpdateRequest, type PayoutCreateRequest, type PayoutListParams, type PayoutListResponse, type PayoutResponse, type PayoutStatus, type PayoutType, type PayoutUpdateRequest, type PerMethodSurchargeItem, type PermissionScope, type PhoneDetails, type PhoneOtpRequest, type PhoneOtpResponse, type PhoneOtpVerifyRequest, type PhoneOtpVerifyResponse, type PlatformFeeKind, type PlatformFeeOutput, type PlatformFeeProgram, type PlatformFeeRule, type PlatformFeeRuleInput, type PlatformFeeRuleOutput, type PlatformFeeRuleRecord, type PlatformFeeRuleRequest, type PollStatus, type PollStatusResponse, type ProfileAcquirerCreateRequest, type ProfileAcquirerResponse, type ProfileAcquirerUpdateRequest, type ProfileCreateRequest, type ProfileDefaultRoutingConfig, type ProfileDeniedConnectorsResponse, type ProfileLogoUploadResponse, type ProfileResponse, type ProfileUpdateRequest, type ProgramConnectorSelection, type ProjectCreateRequest, type ProjectResponse, type ProjectStats, type ProjectStatsResponse, type ProjectUpdateRequest, type RecoveryCodesResponse, type RefundCreateRequest, type RefundListParams, type RefundListResponse, type RefundResponse, type RefundStatus, type RefundType, type RefundUpdateRequest, type RegionCountriesResponse, type RegionCreateRequest, type RegionResponse, type RegionSetCountriesRequest, type RegionUpdateRequest, Regions, type RelayRequest, type RelayResponse, type RelayStatus, type RelayType, type RequestExtras, type RequestFn, type RequestOptions, type ResetPasswordRequest, type ResumeSubscriptionRequest, type ResumeSubscriptionResponse, type RoutableConnectorChoice, type RoutingActivatePayload, type RoutingConfigCreateRequest, type RoutingConfigResponse, type RoutingDeactivateRequest, type RoutingDictionary, type RoutingDictionaryRecord, type RuleConnectorSelection, Search, type SearchGroupResponse, type SearchIndex, type SearchStatus, type ShopCreateRequest, type ShopResponse, type ShopStats, type ShopStatsResponse, type ShopUpdateRequest, type SignInRequest, type SignUpRequest, type SignUpWithMerchantIdRequest, type SignUpWithMerchantRequest, type SizeScale, type SpacingScale, type StaticRoutingAlgorithm, type StatsPeriod, type StripeConnectAccountRequest, type StripeConnectAccountResponse, type StripeConnectLinkRequest, type StripeConnectLinkResponse, type SubscriptionEstimateParams, type SubscriptionEstimateResponse, type SubscriptionInvoice, type SubscriptionItem, type SubscriptionItemPrice, type SubscriptionItemType, type SubscriptionLineItem, type SubscriptionListParams, type SubscriptionPaymentData, type SubscriptionPaymentDetails, type SubscriptionPeriodUnit, type SubscriptionResponse, type SubscriptionStatus, Subscriptions, type SummaryPosition, type SurchargeRuleRequest, type SurchargeRuleResponse, type SurfaceStyle, type SwitchMerchantRequest, type SwitchProfileRequest, type Terminate2faQueryParams, type ThreeDSDecision, type ThreeDsRuleExecuteRequest, type ThreeDsRuleResponse, type TierSummary, type TokenPurpose, type TokenResponse, type TopupRequest, type TopupResponse, type TotpResponse, type TransactionType, type TrustBadge, type UpdateSubscriptionRequest, type UpdateUserDetailsRequest, type UpdateUserRoleRequest, type UserInLineage, type UserResponse, type UserSessionEntry, type UserSessionListResponse, type UserSessionRevokeResponse, type VerifyTotpRequest, type WebhookDeliveryAttempt, type WebhookEvent, type WebhookRegistrationEnvironment, Webhooks, allOf, anyOf, applyBrandingVariables, buildBrandingExport, buttonPadValue, cloneBranding, decodeBadges, decodeBranding, defaultBranding, encodeBadges, encodeBranding, feeProgram, fontStack, fontWeightValue, inputPadValue, isDarkSurface, isHexColor, leaf, logoDimensions, parseImportedBranding, programToTree, radiusValue, ruleMatchToTree, sanitizeCustomCss, shadowFor, surfacePadValue, verticalGapValue };
|
package/dist/index.d.ts
CHANGED
|
@@ -440,6 +440,56 @@ interface PaymentAttemptsListResponse {
|
|
|
440
440
|
/** Every attempt made on this payment, including failed retries across connectors. */
|
|
441
441
|
data: PaymentAttemptResponse[];
|
|
442
442
|
}
|
|
443
|
+
/** Which entity a status-history event belongs to. */
|
|
444
|
+
type PaymentStatusHistoryEntityType = 'payment' | 'attempt' | 'refund' | 'dispute';
|
|
445
|
+
/**
|
|
446
|
+
* One event on a payment's status timeline: the creation of, or a status
|
|
447
|
+
* transition on, the payment intent or one of its attempts / refunds /
|
|
448
|
+
* disputes.
|
|
449
|
+
*/
|
|
450
|
+
interface PaymentStatusHistoryEvent {
|
|
451
|
+
entity_type: PaymentStatusHistoryEntityType;
|
|
452
|
+
/** Id of the attempt / refund / dispute the event belongs to (absent for intent-level events). */
|
|
453
|
+
entity_id?: string | null;
|
|
454
|
+
/** The attempt this event is associated with, where known. */
|
|
455
|
+
attempt_id?: string | null;
|
|
456
|
+
/** The status before this event. Absent on creation events and derived events. */
|
|
457
|
+
previous_status?: string | null;
|
|
458
|
+
/**
|
|
459
|
+
* The status after this event. Absent only on a derived creation event,
|
|
460
|
+
* where the initial status was not recorded.
|
|
461
|
+
*/
|
|
462
|
+
status?: string | null;
|
|
463
|
+
/** Connector involved in the event, where known. */
|
|
464
|
+
connector?: string | null;
|
|
465
|
+
error_code?: string | null;
|
|
466
|
+
error_message?: string | null;
|
|
467
|
+
/** `true` when this event records the creation of the entity. */
|
|
468
|
+
is_creation: boolean;
|
|
469
|
+
/**
|
|
470
|
+
* `true` when this event was reconstructed from current records (payments
|
|
471
|
+
* predating the persisted status log) — its timestamp is approximate and
|
|
472
|
+
* intermediate transitions may be missing.
|
|
473
|
+
*/
|
|
474
|
+
derived: boolean;
|
|
475
|
+
/** ISO-8601 timestamp of the event. */
|
|
476
|
+
timestamp: string;
|
|
477
|
+
[key: string]: unknown;
|
|
478
|
+
}
|
|
479
|
+
/** Response body for `payments.listStatusHistory` — the status timeline of a payment. */
|
|
480
|
+
interface PaymentStatusHistoryResponse {
|
|
481
|
+
/** The payment this timeline belongs to. */
|
|
482
|
+
payment_id: string;
|
|
483
|
+
/**
|
|
484
|
+
* `true` when every event comes from the persisted status-transition log;
|
|
485
|
+
* `false` when any event had to be reconstructed from current records.
|
|
486
|
+
*/
|
|
487
|
+
complete: boolean;
|
|
488
|
+
/** The number of events returned. */
|
|
489
|
+
count: number;
|
|
490
|
+
/** All recorded events, oldest first. */
|
|
491
|
+
events: PaymentStatusHistoryEvent[];
|
|
492
|
+
}
|
|
443
493
|
/**
|
|
444
494
|
* Parameters for creating a refund.
|
|
445
495
|
*
|
|
@@ -2917,9 +2967,9 @@ interface AnalyticsScopeRequest {
|
|
|
2917
2967
|
* a standalone widget (e.g. a pinned card) skips the query/fold work it
|
|
2918
2968
|
* doesn't need. Tokens: `series` (current daily series — KPI values + chart),
|
|
2919
2969
|
* `previous` (the equal-length prior window — period-over-period deltas),
|
|
2920
|
-
* `connectors` (processor donut)
|
|
2921
|
-
* donut). Omit for the full dashboard
|
|
2922
|
-
* back as empty arrays.
|
|
2970
|
+
* `connectors` (processor donut), `children` (breakdown table + merchant
|
|
2971
|
+
* donut) and `methods` (payment-method donut). Omit for the full dashboard
|
|
2972
|
+
* (all blocks). Unrequested blocks come back as empty arrays.
|
|
2923
2973
|
*/
|
|
2924
2974
|
sections?: string | null;
|
|
2925
2975
|
/**
|
|
@@ -2963,6 +3013,9 @@ interface AnalyticsConnectorDay {
|
|
|
2963
3013
|
success: number;
|
|
2964
3014
|
failed: number;
|
|
2965
3015
|
open: number;
|
|
3016
|
+
/** Timed-out-unpaid volume, reported separately from `failed` (absent on
|
|
3017
|
+
* older backends, where it is folded into `failed`). */
|
|
3018
|
+
expired?: number;
|
|
2966
3019
|
}
|
|
2967
3020
|
/** One processor's daily, status-split volume series over the window. */
|
|
2968
3021
|
interface AnalyticsConnectorSeries {
|
|
@@ -2981,6 +3034,26 @@ interface AnalyticsChild {
|
|
|
2981
3034
|
/** Aggregate of the child's activity over the current window (USD). */
|
|
2982
3035
|
totals: AnalyticsDayBucket;
|
|
2983
3036
|
}
|
|
3037
|
+
/**
|
|
3038
|
+
* One payment method's status-split volume totals over the current window
|
|
3039
|
+
* (USD major units), for the "volume by payment method" donut. `method` is the
|
|
3040
|
+
* attempt's high-level `payment_method` (`card`, `wallet`, …) and
|
|
3041
|
+
* `method_type` its narrower `payment_method_type` (`credit`, `apple_pay`,
|
|
3042
|
+
* `ideal`, …); both are null for intents that never reached an attempt
|
|
3043
|
+
* (typically abandoned open volume).
|
|
3044
|
+
*/
|
|
3045
|
+
interface AnalyticsMethodSlice {
|
|
3046
|
+
/** Processor that handled the volume (`"Direct"` when the attempt carried no
|
|
3047
|
+
* connector), matching the `connectors` block's naming — so the method donut
|
|
3048
|
+
* can be filtered per processor. */
|
|
3049
|
+
connector: string;
|
|
3050
|
+
method?: string | null;
|
|
3051
|
+
method_type?: string | null;
|
|
3052
|
+
success: number;
|
|
3053
|
+
failed: number;
|
|
3054
|
+
open: number;
|
|
3055
|
+
expired?: number;
|
|
3056
|
+
}
|
|
2984
3057
|
/**
|
|
2985
3058
|
* One drill level of the analytics dashboard: the scope's own daily series +
|
|
2986
3059
|
* processor mix and its direct children's series. Range / metric / donut
|
|
@@ -3014,6 +3087,12 @@ interface AnalyticsScopeResponse {
|
|
|
3014
3087
|
previous_series: AnalyticsDayBucket[];
|
|
3015
3088
|
connectors: AnalyticsConnectorSeries[];
|
|
3016
3089
|
children: AnalyticsChild[];
|
|
3090
|
+
/**
|
|
3091
|
+
* Per-payment-method window totals for the method donut. Empty unless the
|
|
3092
|
+
* `methods` section is requested (or `sections` is omitted); absent on
|
|
3093
|
+
* backends that predate the method dimension.
|
|
3094
|
+
*/
|
|
3095
|
+
methods?: AnalyticsMethodSlice[];
|
|
3017
3096
|
}
|
|
3018
3097
|
|
|
3019
3098
|
/** Create and manage API keys for a merchant account. */
|
|
@@ -3837,6 +3916,24 @@ declare class Payments {
|
|
|
3837
3916
|
* ```
|
|
3838
3917
|
*/
|
|
3839
3918
|
listAttempts(paymentId: string, options?: RequestExtras): Promise<PaymentAttemptsListResponse>;
|
|
3919
|
+
/**
|
|
3920
|
+
* The status timeline of a payment: every recorded creation / status
|
|
3921
|
+
* transition of the intent and its attempts, refunds and disputes, oldest
|
|
3922
|
+
* first. `complete: false` marks timelines partially reconstructed from
|
|
3923
|
+
* current records (payments created before the status log existed).
|
|
3924
|
+
*
|
|
3925
|
+
* @param paymentId - The payment intent ID.
|
|
3926
|
+
* @returns The ordered status-history events.
|
|
3927
|
+
*
|
|
3928
|
+
* @example
|
|
3929
|
+
* ```typescript
|
|
3930
|
+
* const { events, complete } = await delopay.payments.listStatusHistory('pay_abc123');
|
|
3931
|
+
* for (const event of events) {
|
|
3932
|
+
* console.log(event.timestamp, event.entity_type, event.status);
|
|
3933
|
+
* }
|
|
3934
|
+
* ```
|
|
3935
|
+
*/
|
|
3936
|
+
listStatusHistory(paymentId: string, options?: RequestExtras): Promise<PaymentStatusHistoryResponse>;
|
|
3840
3937
|
/**
|
|
3841
3938
|
* Update an existing payment intent before it is confirmed.
|
|
3842
3939
|
*
|
|
@@ -5646,4 +5743,4 @@ declare function parseImportedBranding(raw: unknown): CheckoutBranding;
|
|
|
5646
5743
|
declare function applyBrandingVariables(el: HTMLElement, b: CheckoutBranding): void;
|
|
5647
5744
|
declare function shadowFor(style: SurfaceStyle): string;
|
|
5648
5745
|
|
|
5649
|
-
export { type AddUserRequest, type AddUserResponse, type Address, type AddressDetails, type AllocationListResponse, type AllocationResponse, type AllocationTransferRequest, type AllocationTransferResponse, Analytics, type AnalyticsChild, type AnalyticsConnectorDay, type AnalyticsConnectorSeries, AnalyticsDashboard, type AnalyticsDayBucket, type AnalyticsScopeRequest, type AnalyticsScopeResponse, type ApiKeyCreateRequest, type ApiKeyCreateResponse, type ApiKeyExpiration, type ApiKeyListConstraints, type ApiKeyResponse, type ApiKeyRevokeResponse, type ApiKeyUpdateRequest, type ApplePayVerificationRequest, type ApplePayVerificationResponse, type ApplePayVerifiedDomainsResponse, type AttemptStatus, type AuthResponse, type AuthenticationCreateRequest, type AuthenticationResponse, type AuthenticationStatus, type AuthenticationType, type AutoRechargeConfig, type AutoRechargeUpdateRequest, type AvailabilityOverrideCreateRequest, type AvailabilityOverrideResponse, AvailabilityOverrides, type AvailabilityPreviewMethod, type AvailabilityPreviewParams, type AvailabilityPreviewResponse, BRANDING_EXPORT_FORMAT, BRANDING_EXPORT_VERSION, type BillingCompleteSetupRequest, type BillingProfileResponse, type BillingSetupRequest, type BillingSetupResponse, type BlockedAttempt, type BlockedAttemptListParams, type BlockedAttemptListResponse, type BlocklistAddRequest, type BlocklistDataKind, type BlocklistResponse, type BrandingExport, type BrandingSource, type BuiltInRegionGroupResponse, type BusinessPaymentLinkConfig, CUSTOM_CSS_MAX_LENGTH, type CancelSubscriptionRequest, type CancelSubscriptionResponse, type CaptureMethod, type CardDetail, type CardDetailFromLocker, Cards, type ChangePasswordRequest, type CheckoutBranding, type ConditionNode, type ConfirmSubscriptionPaymentDetails, type ConfirmSubscriptionRequest, type ConfirmSubscriptionResponse, type Connector, type ConnectorCloneRequest, type ConnectorCreateRequest, type ConnectorListResponse, type ConnectorResponse, type ConnectorSelection, type ConnectorType, type ConnectorUpdateRequest, type ConnectorVolumeSplit, type ConnectorWebhookEntry, type ConnectorWebhookEventType, type ConnectorWebhookListResponse, type ConnectorWebhookRegisterRequest, type ConnectorWebhookRegisterResponse, type CornerRadius, type CreateAndConfirmSubscriptionRequest, type CreateSubscriptionPaymentDetails, type CreateSubscriptionRequest, type Currency, type CurrencyRevenue, type CustomerCreateRequest, type CustomerListParams, type CustomerPaymentMethodsListParams, type CustomerPaymentMethodsListResponse, type CustomerResponse, type CustomerUpdateRequest, DEFAULT_BADGES, DEFAULT_BADGES_DARK, DEFAULT_BRANDING, DEFAULT_BRANDING_DARK, type DeleteAccountRequest, type DeleteUserRoleRequest, Delopay, DelopayAuthenticationError, DelopayError, type DelopayLogger, type DelopayOptions, type DisputeEvidenceRequest, type DisputeListParams, type DisputeResponse, type DisputeStage, type DisputeStatus, type EncodedBranding, type EphemeralKeyCreateRequest, type EphemeralKeyCreateResponse, type EuclidComparison, type EuclidComparisonType, type EuclidIfStatement, type EuclidValue, type EventClass, type EventDeliveryAttemptResponse, type EventDetailResponse, type EventListParams, type EventListResponse, type EventResponse, type EventType, Export, FeatureMatrix, type FeeOwner, FeeProgramBuilder, type FeeRuleConditions, type FeeRuleInput, type FeeRulePreviewRequest, type FeeRulePreviewResponse, type FeeScheduleCreateRequest, type FeeScheduleResponse, type FeeScheduleUpdateRequest, type FeeSpecInput, type FeeType, Files, type FontFamily, type FontWeight, Forex, type ForgotPasswordRequest, type FromEmailRequest, type FutureUsage, type GatewayConnectRequest, type GatewayResponse, type GetSubscriptionItemsParams, type GetSubscriptionItemsResponse, type GlobalSearchRequest, type GroupNode, type ImpersonateEmployeeRequest, type IntentStatus, type InviteUsersRequest, type InviteUsersResponse, type InvoiceStatus, type LabelStyle, type LayoutStyle, type LeafNode, type LedgerEntry, type LedgerListParams, type LedgerResponse, type LinkedRoutingConfigRetrieveResponse, type ListInvitableRolesParams, type ListUsersInLineageParams, type LoginHistoryEntry, type LoginHistoryParams, type LoginHistoryResponse, type LogoShape, type LogoSize, type MandateListParams, type MandateResponse, type MandateRevokedResponse, type MandateStatus, type MandateType, type MerchantAccountCreateRequest, type MerchantAccountResponse, type MerchantAccountType, type MerchantAccountUpdateRequest, type MerchantOverviewResponse, type MerchantOverviewStat, type MerchantRoutingAlgorithm, type MethodSurcharge, type MinimalRoleInfo, type NonPillRadius, type OverrideAction, type OverrideScope, type ParentGroup, type ParentGroupInfo, type PauseSubscriptionRequest, type PauseSubscriptionResponse, type PaymentAttemptResponse, type PaymentAttemptsListResponse, type PaymentCancelRequest, type PaymentCaptureRequest, type PaymentConfirmRequest, type PaymentCreateRequest, type PaymentErrorDetails, type PaymentExperience, type PaymentIdFormatConfig, type PaymentIdStyle, type PaymentLayout, type PaymentLinkBackgroundImageConfig, type PaymentLinkConfigRequest, type PaymentLinkListParams, type PaymentLinkListResponse, type PaymentLinkResponse, type PaymentLinkTransactionDetails, type PaymentListParams, type PaymentListResponse, type PaymentMethod, type PaymentMethodCreateRequest, type PaymentMethodDeleteResponse, type PaymentMethodListParams, type PaymentMethodResponse, type PaymentMethodType, type PaymentMethodUpdateRequest, type PaymentResponse, type PaymentRetrieveOptions, type PaymentUpdateRequest, type PayoutCreateRequest, type PayoutListParams, type PayoutListResponse, type PayoutResponse, type PayoutStatus, type PayoutType, type PayoutUpdateRequest, type PerMethodSurchargeItem, type PermissionScope, type PhoneDetails, type PhoneOtpRequest, type PhoneOtpResponse, type PhoneOtpVerifyRequest, type PhoneOtpVerifyResponse, type PlatformFeeKind, type PlatformFeeOutput, type PlatformFeeProgram, type PlatformFeeRule, type PlatformFeeRuleInput, type PlatformFeeRuleOutput, type PlatformFeeRuleRecord, type PlatformFeeRuleRequest, type PollStatus, type PollStatusResponse, type ProfileAcquirerCreateRequest, type ProfileAcquirerResponse, type ProfileAcquirerUpdateRequest, type ProfileCreateRequest, type ProfileDefaultRoutingConfig, type ProfileDeniedConnectorsResponse, type ProfileLogoUploadResponse, type ProfileResponse, type ProfileUpdateRequest, type ProgramConnectorSelection, type ProjectCreateRequest, type ProjectResponse, type ProjectStats, type ProjectStatsResponse, type ProjectUpdateRequest, type RecoveryCodesResponse, type RefundCreateRequest, type RefundListParams, type RefundListResponse, type RefundResponse, type RefundStatus, type RefundType, type RefundUpdateRequest, type RegionCountriesResponse, type RegionCreateRequest, type RegionResponse, type RegionSetCountriesRequest, type RegionUpdateRequest, Regions, type RelayRequest, type RelayResponse, type RelayStatus, type RelayType, type RequestExtras, type RequestFn, type RequestOptions, type ResetPasswordRequest, type ResumeSubscriptionRequest, type ResumeSubscriptionResponse, type RoutableConnectorChoice, type RoutingActivatePayload, type RoutingConfigCreateRequest, type RoutingConfigResponse, type RoutingDeactivateRequest, type RoutingDictionary, type RoutingDictionaryRecord, type RuleConnectorSelection, Search, type SearchGroupResponse, type SearchIndex, type SearchStatus, type ShopCreateRequest, type ShopResponse, type ShopStats, type ShopStatsResponse, type ShopUpdateRequest, type SignInRequest, type SignUpRequest, type SignUpWithMerchantIdRequest, type SignUpWithMerchantRequest, type SizeScale, type SpacingScale, type StaticRoutingAlgorithm, type StatsPeriod, type StripeConnectAccountRequest, type StripeConnectAccountResponse, type StripeConnectLinkRequest, type StripeConnectLinkResponse, type SubscriptionEstimateParams, type SubscriptionEstimateResponse, type SubscriptionInvoice, type SubscriptionItem, type SubscriptionItemPrice, type SubscriptionItemType, type SubscriptionLineItem, type SubscriptionListParams, type SubscriptionPaymentData, type SubscriptionPaymentDetails, type SubscriptionPeriodUnit, type SubscriptionResponse, type SubscriptionStatus, Subscriptions, type SummaryPosition, type SurchargeRuleRequest, type SurchargeRuleResponse, type SurfaceStyle, type SwitchMerchantRequest, type SwitchProfileRequest, type Terminate2faQueryParams, type ThreeDSDecision, type ThreeDsRuleExecuteRequest, type ThreeDsRuleResponse, type TierSummary, type TokenPurpose, type TokenResponse, type TopupRequest, type TopupResponse, type TotpResponse, type TransactionType, type TrustBadge, type UpdateSubscriptionRequest, type UpdateUserDetailsRequest, type UpdateUserRoleRequest, type UserInLineage, type UserResponse, type UserSessionEntry, type UserSessionListResponse, type UserSessionRevokeResponse, type VerifyTotpRequest, type WebhookDeliveryAttempt, type WebhookEvent, type WebhookRegistrationEnvironment, Webhooks, allOf, anyOf, applyBrandingVariables, buildBrandingExport, buttonPadValue, cloneBranding, decodeBadges, decodeBranding, defaultBranding, encodeBadges, encodeBranding, feeProgram, fontStack, fontWeightValue, inputPadValue, isDarkSurface, isHexColor, leaf, logoDimensions, parseImportedBranding, programToTree, radiusValue, ruleMatchToTree, sanitizeCustomCss, shadowFor, surfacePadValue, verticalGapValue };
|
|
5746
|
+
export { type AddUserRequest, type AddUserResponse, type Address, type AddressDetails, type AllocationListResponse, type AllocationResponse, type AllocationTransferRequest, type AllocationTransferResponse, Analytics, type AnalyticsChild, type AnalyticsConnectorDay, type AnalyticsConnectorSeries, AnalyticsDashboard, type AnalyticsDayBucket, type AnalyticsMethodSlice, type AnalyticsScopeRequest, type AnalyticsScopeResponse, type ApiKeyCreateRequest, type ApiKeyCreateResponse, type ApiKeyExpiration, type ApiKeyListConstraints, type ApiKeyResponse, type ApiKeyRevokeResponse, type ApiKeyUpdateRequest, type ApplePayVerificationRequest, type ApplePayVerificationResponse, type ApplePayVerifiedDomainsResponse, type AttemptStatus, type AuthResponse, type AuthenticationCreateRequest, type AuthenticationResponse, type AuthenticationStatus, type AuthenticationType, type AutoRechargeConfig, type AutoRechargeUpdateRequest, type AvailabilityOverrideCreateRequest, type AvailabilityOverrideResponse, AvailabilityOverrides, type AvailabilityPreviewMethod, type AvailabilityPreviewParams, type AvailabilityPreviewResponse, BRANDING_EXPORT_FORMAT, BRANDING_EXPORT_VERSION, type BillingCompleteSetupRequest, type BillingProfileResponse, type BillingSetupRequest, type BillingSetupResponse, type BlockedAttempt, type BlockedAttemptListParams, type BlockedAttemptListResponse, type BlocklistAddRequest, type BlocklistDataKind, type BlocklistResponse, type BrandingExport, type BrandingSource, type BuiltInRegionGroupResponse, type BusinessPaymentLinkConfig, CUSTOM_CSS_MAX_LENGTH, type CancelSubscriptionRequest, type CancelSubscriptionResponse, type CaptureMethod, type CardDetail, type CardDetailFromLocker, Cards, type ChangePasswordRequest, type CheckoutBranding, type ConditionNode, type ConfirmSubscriptionPaymentDetails, type ConfirmSubscriptionRequest, type ConfirmSubscriptionResponse, type Connector, type ConnectorCloneRequest, type ConnectorCreateRequest, type ConnectorListResponse, type ConnectorResponse, type ConnectorSelection, type ConnectorType, type ConnectorUpdateRequest, type ConnectorVolumeSplit, type ConnectorWebhookEntry, type ConnectorWebhookEventType, type ConnectorWebhookListResponse, type ConnectorWebhookRegisterRequest, type ConnectorWebhookRegisterResponse, type CornerRadius, type CreateAndConfirmSubscriptionRequest, type CreateSubscriptionPaymentDetails, type CreateSubscriptionRequest, type Currency, type CurrencyRevenue, type CustomerCreateRequest, type CustomerListParams, type CustomerPaymentMethodsListParams, type CustomerPaymentMethodsListResponse, type CustomerResponse, type CustomerUpdateRequest, DEFAULT_BADGES, DEFAULT_BADGES_DARK, DEFAULT_BRANDING, DEFAULT_BRANDING_DARK, type DeleteAccountRequest, type DeleteUserRoleRequest, Delopay, DelopayAuthenticationError, DelopayError, type DelopayLogger, type DelopayOptions, type DisputeEvidenceRequest, type DisputeListParams, type DisputeResponse, type DisputeStage, type DisputeStatus, type EncodedBranding, type EphemeralKeyCreateRequest, type EphemeralKeyCreateResponse, type EuclidComparison, type EuclidComparisonType, type EuclidIfStatement, type EuclidValue, type EventClass, type EventDeliveryAttemptResponse, type EventDetailResponse, type EventListParams, type EventListResponse, type EventResponse, type EventType, Export, FeatureMatrix, type FeeOwner, FeeProgramBuilder, type FeeRuleConditions, type FeeRuleInput, type FeeRulePreviewRequest, type FeeRulePreviewResponse, type FeeScheduleCreateRequest, type FeeScheduleResponse, type FeeScheduleUpdateRequest, type FeeSpecInput, type FeeType, Files, type FontFamily, type FontWeight, Forex, type ForgotPasswordRequest, type FromEmailRequest, type FutureUsage, type GatewayConnectRequest, type GatewayResponse, type GetSubscriptionItemsParams, type GetSubscriptionItemsResponse, type GlobalSearchRequest, type GroupNode, type ImpersonateEmployeeRequest, type IntentStatus, type InviteUsersRequest, type InviteUsersResponse, type InvoiceStatus, type LabelStyle, type LayoutStyle, type LeafNode, type LedgerEntry, type LedgerListParams, type LedgerResponse, type LinkedRoutingConfigRetrieveResponse, type ListInvitableRolesParams, type ListUsersInLineageParams, type LoginHistoryEntry, type LoginHistoryParams, type LoginHistoryResponse, type LogoShape, type LogoSize, type MandateListParams, type MandateResponse, type MandateRevokedResponse, type MandateStatus, type MandateType, type MerchantAccountCreateRequest, type MerchantAccountResponse, type MerchantAccountType, type MerchantAccountUpdateRequest, type MerchantOverviewResponse, type MerchantOverviewStat, type MerchantRoutingAlgorithm, type MethodSurcharge, type MinimalRoleInfo, type NonPillRadius, type OverrideAction, type OverrideScope, type ParentGroup, type ParentGroupInfo, type PauseSubscriptionRequest, type PauseSubscriptionResponse, type PaymentAttemptResponse, type PaymentAttemptsListResponse, type PaymentCancelRequest, type PaymentCaptureRequest, type PaymentConfirmRequest, type PaymentCreateRequest, type PaymentErrorDetails, type PaymentExperience, type PaymentIdFormatConfig, type PaymentIdStyle, type PaymentLayout, type PaymentLinkBackgroundImageConfig, type PaymentLinkConfigRequest, type PaymentLinkListParams, type PaymentLinkListResponse, type PaymentLinkResponse, type PaymentLinkTransactionDetails, type PaymentListParams, type PaymentListResponse, type PaymentMethod, type PaymentMethodCreateRequest, type PaymentMethodDeleteResponse, type PaymentMethodListParams, type PaymentMethodResponse, type PaymentMethodType, type PaymentMethodUpdateRequest, type PaymentResponse, type PaymentRetrieveOptions, type PaymentStatusHistoryEntityType, type PaymentStatusHistoryEvent, type PaymentStatusHistoryResponse, type PaymentUpdateRequest, type PayoutCreateRequest, type PayoutListParams, type PayoutListResponse, type PayoutResponse, type PayoutStatus, type PayoutType, type PayoutUpdateRequest, type PerMethodSurchargeItem, type PermissionScope, type PhoneDetails, type PhoneOtpRequest, type PhoneOtpResponse, type PhoneOtpVerifyRequest, type PhoneOtpVerifyResponse, type PlatformFeeKind, type PlatformFeeOutput, type PlatformFeeProgram, type PlatformFeeRule, type PlatformFeeRuleInput, type PlatformFeeRuleOutput, type PlatformFeeRuleRecord, type PlatformFeeRuleRequest, type PollStatus, type PollStatusResponse, type ProfileAcquirerCreateRequest, type ProfileAcquirerResponse, type ProfileAcquirerUpdateRequest, type ProfileCreateRequest, type ProfileDefaultRoutingConfig, type ProfileDeniedConnectorsResponse, type ProfileLogoUploadResponse, type ProfileResponse, type ProfileUpdateRequest, type ProgramConnectorSelection, type ProjectCreateRequest, type ProjectResponse, type ProjectStats, type ProjectStatsResponse, type ProjectUpdateRequest, type RecoveryCodesResponse, type RefundCreateRequest, type RefundListParams, type RefundListResponse, type RefundResponse, type RefundStatus, type RefundType, type RefundUpdateRequest, type RegionCountriesResponse, type RegionCreateRequest, type RegionResponse, type RegionSetCountriesRequest, type RegionUpdateRequest, Regions, type RelayRequest, type RelayResponse, type RelayStatus, type RelayType, type RequestExtras, type RequestFn, type RequestOptions, type ResetPasswordRequest, type ResumeSubscriptionRequest, type ResumeSubscriptionResponse, type RoutableConnectorChoice, type RoutingActivatePayload, type RoutingConfigCreateRequest, type RoutingConfigResponse, type RoutingDeactivateRequest, type RoutingDictionary, type RoutingDictionaryRecord, type RuleConnectorSelection, Search, type SearchGroupResponse, type SearchIndex, type SearchStatus, type ShopCreateRequest, type ShopResponse, type ShopStats, type ShopStatsResponse, type ShopUpdateRequest, type SignInRequest, type SignUpRequest, type SignUpWithMerchantIdRequest, type SignUpWithMerchantRequest, type SizeScale, type SpacingScale, type StaticRoutingAlgorithm, type StatsPeriod, type StripeConnectAccountRequest, type StripeConnectAccountResponse, type StripeConnectLinkRequest, type StripeConnectLinkResponse, type SubscriptionEstimateParams, type SubscriptionEstimateResponse, type SubscriptionInvoice, type SubscriptionItem, type SubscriptionItemPrice, type SubscriptionItemType, type SubscriptionLineItem, type SubscriptionListParams, type SubscriptionPaymentData, type SubscriptionPaymentDetails, type SubscriptionPeriodUnit, type SubscriptionResponse, type SubscriptionStatus, Subscriptions, type SummaryPosition, type SurchargeRuleRequest, type SurchargeRuleResponse, type SurfaceStyle, type SwitchMerchantRequest, type SwitchProfileRequest, type Terminate2faQueryParams, type ThreeDSDecision, type ThreeDsRuleExecuteRequest, type ThreeDsRuleResponse, type TierSummary, type TokenPurpose, type TokenResponse, type TopupRequest, type TopupResponse, type TotpResponse, type TransactionType, type TrustBadge, type UpdateSubscriptionRequest, type UpdateUserDetailsRequest, type UpdateUserRoleRequest, type UserInLineage, type UserResponse, type UserSessionEntry, type UserSessionListResponse, type UserSessionRevokeResponse, type VerifyTotpRequest, type WebhookDeliveryAttempt, type WebhookEvent, type WebhookRegistrationEnvironment, Webhooks, allOf, anyOf, applyBrandingVariables, buildBrandingExport, buttonPadValue, cloneBranding, decodeBadges, decodeBranding, defaultBranding, encodeBadges, encodeBranding, feeProgram, fontStack, fontWeightValue, inputPadValue, isDarkSurface, isHexColor, leaf, logoDimensions, parseImportedBranding, programToTree, radiusValue, ruleMatchToTree, sanitizeCustomCss, shadowFor, surfacePadValue, verticalGapValue };
|
package/dist/index.js
CHANGED
package/dist/internal.cjs
CHANGED
|
@@ -1309,6 +1309,30 @@ var Payments = class {
|
|
|
1309
1309
|
async listAttempts(paymentId, options) {
|
|
1310
1310
|
return this.request("GET", `/payments/${encodeURIComponent(paymentId)}/attempts`, options);
|
|
1311
1311
|
}
|
|
1312
|
+
/**
|
|
1313
|
+
* The status timeline of a payment: every recorded creation / status
|
|
1314
|
+
* transition of the intent and its attempts, refunds and disputes, oldest
|
|
1315
|
+
* first. `complete: false` marks timelines partially reconstructed from
|
|
1316
|
+
* current records (payments created before the status log existed).
|
|
1317
|
+
*
|
|
1318
|
+
* @param paymentId - The payment intent ID.
|
|
1319
|
+
* @returns The ordered status-history events.
|
|
1320
|
+
*
|
|
1321
|
+
* @example
|
|
1322
|
+
* ```typescript
|
|
1323
|
+
* const { events, complete } = await delopay.payments.listStatusHistory('pay_abc123');
|
|
1324
|
+
* for (const event of events) {
|
|
1325
|
+
* console.log(event.timestamp, event.entity_type, event.status);
|
|
1326
|
+
* }
|
|
1327
|
+
* ```
|
|
1328
|
+
*/
|
|
1329
|
+
async listStatusHistory(paymentId, options) {
|
|
1330
|
+
return this.request(
|
|
1331
|
+
"GET",
|
|
1332
|
+
`/payments/${encodeURIComponent(paymentId)}/status-history`,
|
|
1333
|
+
options
|
|
1334
|
+
);
|
|
1335
|
+
}
|
|
1312
1336
|
/**
|
|
1313
1337
|
* Update an existing payment intent before it is confirmed.
|
|
1314
1338
|
*
|
|
@@ -4449,6 +4473,17 @@ var AdminPortal = class {
|
|
|
4449
4473
|
`/admin-portal/transactions/${encodeURIComponent(paymentId)}/attempts`
|
|
4450
4474
|
);
|
|
4451
4475
|
}
|
|
4476
|
+
/**
|
|
4477
|
+
* Status timeline (intent / attempt / refund / dispute transitions) for a
|
|
4478
|
+
* single transaction of ANY merchant. `complete: false` marks timelines
|
|
4479
|
+
* partially reconstructed from current records.
|
|
4480
|
+
*/
|
|
4481
|
+
async getTransactionStatusHistory(paymentId) {
|
|
4482
|
+
return this.request(
|
|
4483
|
+
"GET",
|
|
4484
|
+
`/admin-portal/transactions/${encodeURIComponent(paymentId)}/status-history`
|
|
4485
|
+
);
|
|
4486
|
+
}
|
|
4452
4487
|
/**
|
|
4453
4488
|
* Refunds for a single transaction of ANY merchant.
|
|
4454
4489
|
*/
|