@strimz/shared-types 0.15.0 → 0.16.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/events.d.ts CHANGED
@@ -912,7 +912,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
912
912
  amount: z.ZodString;
913
913
  currency: z.ZodEnum<["USDC", "EURC"]>;
914
914
  status: z.ZodEnum<["pending", "in_flight", "succeeded", "failed", "retrying", "abandoned"]>;
915
- outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped"]>>;
915
+ outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped", "token_not_allowed"]>>;
916
916
  attemptNumber: z.ZodNumber;
917
917
  scheduledAt: z.ZodString;
918
918
  executedAt: z.ZodNullable<z.ZodString>;
@@ -934,7 +934,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
934
934
  chargeAttemptId: string;
935
935
  periodStartAt: string;
936
936
  periodEndAt: string;
937
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
937
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
938
938
  attemptNumber: number;
939
939
  scheduledAt: string;
940
940
  executedAt: string | null;
@@ -952,7 +952,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
952
952
  chargeAttemptId: string;
953
953
  periodStartAt: string;
954
954
  periodEndAt: string;
955
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
955
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
956
956
  attemptNumber: number;
957
957
  scheduledAt: string;
958
958
  executedAt: string | null;
@@ -1076,7 +1076,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
1076
1076
  chargeAttemptId: string;
1077
1077
  periodStartAt: string;
1078
1078
  periodEndAt: string;
1079
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1079
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1080
1080
  attemptNumber: number;
1081
1081
  scheduledAt: string;
1082
1082
  executedAt: string | null;
@@ -1139,7 +1139,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
1139
1139
  chargeAttemptId: string;
1140
1140
  periodStartAt: string;
1141
1141
  periodEndAt: string;
1142
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1142
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1143
1143
  attemptNumber: number;
1144
1144
  scheduledAt: string;
1145
1145
  executedAt: string | null;
@@ -1206,7 +1206,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
1206
1206
  chargeAttemptId: string;
1207
1207
  periodStartAt: string;
1208
1208
  periodEndAt: string;
1209
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1209
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1210
1210
  attemptNumber: number;
1211
1211
  scheduledAt: string;
1212
1212
  executedAt: string | null;
@@ -1276,7 +1276,7 @@ declare const subscriptionChargedEventSchema: z.ZodObject<{
1276
1276
  chargeAttemptId: string;
1277
1277
  periodStartAt: string;
1278
1278
  periodEndAt: string;
1279
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1279
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1280
1280
  attemptNumber: number;
1281
1281
  scheduledAt: string;
1282
1282
  executedAt: string | null;
@@ -1367,7 +1367,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1367
1367
  amount: z.ZodString;
1368
1368
  currency: z.ZodEnum<["USDC", "EURC"]>;
1369
1369
  status: z.ZodEnum<["pending", "in_flight", "succeeded", "failed", "retrying", "abandoned"]>;
1370
- outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped"]>>;
1370
+ outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped", "token_not_allowed"]>>;
1371
1371
  attemptNumber: z.ZodNumber;
1372
1372
  scheduledAt: z.ZodString;
1373
1373
  executedAt: z.ZodNullable<z.ZodString>;
@@ -1389,7 +1389,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1389
1389
  chargeAttemptId: string;
1390
1390
  periodStartAt: string;
1391
1391
  periodEndAt: string;
1392
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1392
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1393
1393
  attemptNumber: number;
1394
1394
  scheduledAt: string;
1395
1395
  executedAt: string | null;
@@ -1407,7 +1407,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1407
1407
  chargeAttemptId: string;
1408
1408
  periodStartAt: string;
1409
1409
  periodEndAt: string;
1410
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1410
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1411
1411
  attemptNumber: number;
1412
1412
  scheduledAt: string;
1413
1413
  executedAt: string | null;
@@ -1449,7 +1449,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1449
1449
  chargeAttemptId: string;
1450
1450
  periodStartAt: string;
1451
1451
  periodEndAt: string;
1452
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1452
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1453
1453
  attemptNumber: number;
1454
1454
  scheduledAt: string;
1455
1455
  executedAt: string | null;
@@ -1491,7 +1491,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1491
1491
  chargeAttemptId: string;
1492
1492
  periodStartAt: string;
1493
1493
  periodEndAt: string;
1494
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1494
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1495
1495
  attemptNumber: number;
1496
1496
  scheduledAt: string;
1497
1497
  executedAt: string | null;
@@ -1537,7 +1537,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1537
1537
  chargeAttemptId: string;
1538
1538
  periodStartAt: string;
1539
1539
  periodEndAt: string;
1540
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1540
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1541
1541
  attemptNumber: number;
1542
1542
  scheduledAt: string;
1543
1543
  executedAt: string | null;
@@ -1586,7 +1586,7 @@ declare const subscriptionChargeFailedEventSchema: z.ZodObject<{
1586
1586
  chargeAttemptId: string;
1587
1587
  periodStartAt: string;
1588
1588
  periodEndAt: string;
1589
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
1589
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
1590
1590
  attemptNumber: number;
1591
1591
  scheduledAt: string;
1592
1592
  executedAt: string | null;
@@ -2034,6 +2034,133 @@ declare const subscriptionLapsedEventSchema: z.ZodObject<{
2034
2034
  createdAt: string;
2035
2035
  apiVersion: string;
2036
2036
  }>;
2037
+ declare const subscriptionReactivatedEventSchema: z.ZodObject<{
2038
+ id: z.ZodString;
2039
+ type: z.ZodLiteral<"subscription.reactivated">;
2040
+ apiVersion: z.ZodString;
2041
+ mode: z.ZodEnum<["test", "live"]>;
2042
+ createdAt: z.ZodString;
2043
+ data: z.ZodObject<{
2044
+ id: z.ZodString;
2045
+ onchainSubscriptionId: z.ZodNullable<z.ZodNumber>;
2046
+ merchantId: z.ZodString;
2047
+ customerId: z.ZodString;
2048
+ planId: z.ZodString;
2049
+ status: z.ZodEnum<["trialing", "active", "at_risk", "paused", "cancelled", "lapsed"]>;
2050
+ payerAddress: z.ZodEffects<z.ZodString, string, string>;
2051
+ currency: z.ZodEnum<["USDC", "EURC"]>;
2052
+ amount: z.ZodString;
2053
+ interval: z.ZodEnum<["daily", "weekly", "monthly", "quarterly", "yearly"]>;
2054
+ intervalCount: z.ZodNumber;
2055
+ trialEndsAt: z.ZodNullable<z.ZodString>;
2056
+ currentPeriodStartAt: z.ZodString;
2057
+ currentPeriodEndAt: z.ZodString;
2058
+ nextChargeAt: z.ZodNullable<z.ZodString>;
2059
+ gracePeriodHours: z.ZodNumber;
2060
+ cancelledAt: z.ZodNullable<z.ZodString>;
2061
+ metadata: z.ZodDefault<z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>, Record<string, string | number | boolean | null>, Record<string, string | number | boolean | null>>>;
2062
+ createdAt: z.ZodString;
2063
+ updatedAt: z.ZodString;
2064
+ }, "strip", z.ZodTypeAny, {
2065
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
2066
+ amount: string;
2067
+ currency: "USDC" | "EURC";
2068
+ customerId: string;
2069
+ merchantId: string;
2070
+ id: string;
2071
+ createdAt: string;
2072
+ updatedAt: string;
2073
+ metadata: Record<string, string | number | boolean | null>;
2074
+ payerAddress: string;
2075
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
2076
+ intervalCount: number;
2077
+ planId: string;
2078
+ onchainSubscriptionId: number | null;
2079
+ trialEndsAt: string | null;
2080
+ currentPeriodStartAt: string;
2081
+ currentPeriodEndAt: string;
2082
+ nextChargeAt: string | null;
2083
+ gracePeriodHours: number;
2084
+ cancelledAt: string | null;
2085
+ }, {
2086
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
2087
+ amount: string;
2088
+ currency: "USDC" | "EURC";
2089
+ customerId: string;
2090
+ merchantId: string;
2091
+ id: string;
2092
+ createdAt: string;
2093
+ updatedAt: string;
2094
+ payerAddress: string;
2095
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
2096
+ intervalCount: number;
2097
+ planId: string;
2098
+ onchainSubscriptionId: number | null;
2099
+ trialEndsAt: string | null;
2100
+ currentPeriodStartAt: string;
2101
+ currentPeriodEndAt: string;
2102
+ nextChargeAt: string | null;
2103
+ gracePeriodHours: number;
2104
+ cancelledAt: string | null;
2105
+ metadata?: Record<string, string | number | boolean | null> | undefined;
2106
+ }>;
2107
+ }, "strip", z.ZodTypeAny, {
2108
+ type: "subscription.reactivated";
2109
+ mode: "test" | "live";
2110
+ data: {
2111
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
2112
+ amount: string;
2113
+ currency: "USDC" | "EURC";
2114
+ customerId: string;
2115
+ merchantId: string;
2116
+ id: string;
2117
+ createdAt: string;
2118
+ updatedAt: string;
2119
+ metadata: Record<string, string | number | boolean | null>;
2120
+ payerAddress: string;
2121
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
2122
+ intervalCount: number;
2123
+ planId: string;
2124
+ onchainSubscriptionId: number | null;
2125
+ trialEndsAt: string | null;
2126
+ currentPeriodStartAt: string;
2127
+ currentPeriodEndAt: string;
2128
+ nextChargeAt: string | null;
2129
+ gracePeriodHours: number;
2130
+ cancelledAt: string | null;
2131
+ };
2132
+ id: string;
2133
+ createdAt: string;
2134
+ apiVersion: string;
2135
+ }, {
2136
+ type: "subscription.reactivated";
2137
+ mode: "test" | "live";
2138
+ data: {
2139
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
2140
+ amount: string;
2141
+ currency: "USDC" | "EURC";
2142
+ customerId: string;
2143
+ merchantId: string;
2144
+ id: string;
2145
+ createdAt: string;
2146
+ updatedAt: string;
2147
+ payerAddress: string;
2148
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
2149
+ intervalCount: number;
2150
+ planId: string;
2151
+ onchainSubscriptionId: number | null;
2152
+ trialEndsAt: string | null;
2153
+ currentPeriodStartAt: string;
2154
+ currentPeriodEndAt: string;
2155
+ nextChargeAt: string | null;
2156
+ gracePeriodHours: number;
2157
+ cancelledAt: string | null;
2158
+ metadata?: Record<string, string | number | boolean | null> | undefined;
2159
+ };
2160
+ id: string;
2161
+ createdAt: string;
2162
+ apiVersion: string;
2163
+ }>;
2037
2164
  declare const refundCreatedEventSchema: z.ZodObject<{
2038
2165
  id: z.ZodString;
2039
2166
  type: z.ZodLiteral<"refund.created">;
@@ -4449,7 +4576,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4449
4576
  amount: z.ZodString;
4450
4577
  currency: z.ZodEnum<["USDC", "EURC"]>;
4451
4578
  status: z.ZodEnum<["pending", "in_flight", "succeeded", "failed", "retrying", "abandoned"]>;
4452
- outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped"]>>;
4579
+ outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped", "token_not_allowed"]>>;
4453
4580
  attemptNumber: z.ZodNumber;
4454
4581
  scheduledAt: z.ZodString;
4455
4582
  executedAt: z.ZodNullable<z.ZodString>;
@@ -4471,7 +4598,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4471
4598
  chargeAttemptId: string;
4472
4599
  periodStartAt: string;
4473
4600
  periodEndAt: string;
4474
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
4601
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4475
4602
  attemptNumber: number;
4476
4603
  scheduledAt: string;
4477
4604
  executedAt: string | null;
@@ -4489,7 +4616,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4489
4616
  chargeAttemptId: string;
4490
4617
  periodStartAt: string;
4491
4618
  periodEndAt: string;
4492
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
4619
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4493
4620
  attemptNumber: number;
4494
4621
  scheduledAt: string;
4495
4622
  executedAt: string | null;
@@ -4613,7 +4740,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4613
4740
  chargeAttemptId: string;
4614
4741
  periodStartAt: string;
4615
4742
  periodEndAt: string;
4616
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
4743
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4617
4744
  attemptNumber: number;
4618
4745
  scheduledAt: string;
4619
4746
  executedAt: string | null;
@@ -4676,7 +4803,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4676
4803
  chargeAttemptId: string;
4677
4804
  periodStartAt: string;
4678
4805
  periodEndAt: string;
4679
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
4806
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4680
4807
  attemptNumber: number;
4681
4808
  scheduledAt: string;
4682
4809
  executedAt: string | null;
@@ -4743,7 +4870,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4743
4870
  chargeAttemptId: string;
4744
4871
  periodStartAt: string;
4745
4872
  periodEndAt: string;
4746
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
4873
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4747
4874
  attemptNumber: number;
4748
4875
  scheduledAt: string;
4749
4876
  executedAt: string | null;
@@ -4813,7 +4940,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4813
4940
  chargeAttemptId: string;
4814
4941
  periodStartAt: string;
4815
4942
  periodEndAt: string;
4816
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
4943
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4817
4944
  attemptNumber: number;
4818
4945
  scheduledAt: string;
4819
4946
  executedAt: string | null;
@@ -4903,7 +5030,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4903
5030
  amount: z.ZodString;
4904
5031
  currency: z.ZodEnum<["USDC", "EURC"]>;
4905
5032
  status: z.ZodEnum<["pending", "in_flight", "succeeded", "failed", "retrying", "abandoned"]>;
4906
- outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped"]>>;
5033
+ outcome: z.ZodNullable<z.ZodEnum<["charged", "insufficient_funds", "revoked_approval", "cancelled", "not_due", "ended", "duplicate", "unknown", "merchant_inactive", "transfer_failed", "skipped", "token_not_allowed"]>>;
4907
5034
  attemptNumber: z.ZodNumber;
4908
5035
  scheduledAt: z.ZodString;
4909
5036
  executedAt: z.ZodNullable<z.ZodString>;
@@ -4925,7 +5052,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4925
5052
  chargeAttemptId: string;
4926
5053
  periodStartAt: string;
4927
5054
  periodEndAt: string;
4928
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
5055
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4929
5056
  attemptNumber: number;
4930
5057
  scheduledAt: string;
4931
5058
  executedAt: string | null;
@@ -4943,7 +5070,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4943
5070
  chargeAttemptId: string;
4944
5071
  periodStartAt: string;
4945
5072
  periodEndAt: string;
4946
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
5073
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4947
5074
  attemptNumber: number;
4948
5075
  scheduledAt: string;
4949
5076
  executedAt: string | null;
@@ -4985,7 +5112,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4985
5112
  chargeAttemptId: string;
4986
5113
  periodStartAt: string;
4987
5114
  periodEndAt: string;
4988
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
5115
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
4989
5116
  attemptNumber: number;
4990
5117
  scheduledAt: string;
4991
5118
  executedAt: string | null;
@@ -5027,7 +5154,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
5027
5154
  chargeAttemptId: string;
5028
5155
  periodStartAt: string;
5029
5156
  periodEndAt: string;
5030
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
5157
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
5031
5158
  attemptNumber: number;
5032
5159
  scheduledAt: string;
5033
5160
  executedAt: string | null;
@@ -5073,7 +5200,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
5073
5200
  chargeAttemptId: string;
5074
5201
  periodStartAt: string;
5075
5202
  periodEndAt: string;
5076
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
5203
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
5077
5204
  attemptNumber: number;
5078
5205
  scheduledAt: string;
5079
5206
  executedAt: string | null;
@@ -5122,7 +5249,7 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
5122
5249
  chargeAttemptId: string;
5123
5250
  periodStartAt: string;
5124
5251
  periodEndAt: string;
5125
- outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | null;
5252
+ outcome: "unknown" | "cancelled" | "charged" | "insufficient_funds" | "revoked_approval" | "not_due" | "ended" | "duplicate" | "merchant_inactive" | "transfer_failed" | "skipped" | "token_not_allowed" | null;
5126
5253
  attemptNumber: number;
5127
5254
  scheduledAt: string;
5128
5255
  executedAt: string | null;
@@ -5566,6 +5693,132 @@ declare const webhookEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
5566
5693
  id: string;
5567
5694
  createdAt: string;
5568
5695
  apiVersion: string;
5696
+ }>, z.ZodObject<{
5697
+ id: z.ZodString;
5698
+ type: z.ZodLiteral<"subscription.reactivated">;
5699
+ apiVersion: z.ZodString;
5700
+ mode: z.ZodEnum<["test", "live"]>;
5701
+ createdAt: z.ZodString;
5702
+ data: z.ZodObject<{
5703
+ id: z.ZodString;
5704
+ onchainSubscriptionId: z.ZodNullable<z.ZodNumber>;
5705
+ merchantId: z.ZodString;
5706
+ customerId: z.ZodString;
5707
+ planId: z.ZodString;
5708
+ status: z.ZodEnum<["trialing", "active", "at_risk", "paused", "cancelled", "lapsed"]>;
5709
+ payerAddress: z.ZodEffects<z.ZodString, string, string>;
5710
+ currency: z.ZodEnum<["USDC", "EURC"]>;
5711
+ amount: z.ZodString;
5712
+ interval: z.ZodEnum<["daily", "weekly", "monthly", "quarterly", "yearly"]>;
5713
+ intervalCount: z.ZodNumber;
5714
+ trialEndsAt: z.ZodNullable<z.ZodString>;
5715
+ currentPeriodStartAt: z.ZodString;
5716
+ currentPeriodEndAt: z.ZodString;
5717
+ nextChargeAt: z.ZodNullable<z.ZodString>;
5718
+ gracePeriodHours: z.ZodNumber;
5719
+ cancelledAt: z.ZodNullable<z.ZodString>;
5720
+ metadata: z.ZodDefault<z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>, Record<string, string | number | boolean | null>, Record<string, string | number | boolean | null>>>;
5721
+ createdAt: z.ZodString;
5722
+ updatedAt: z.ZodString;
5723
+ }, "strip", z.ZodTypeAny, {
5724
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
5725
+ amount: string;
5726
+ currency: "USDC" | "EURC";
5727
+ customerId: string;
5728
+ merchantId: string;
5729
+ id: string;
5730
+ createdAt: string;
5731
+ updatedAt: string;
5732
+ metadata: Record<string, string | number | boolean | null>;
5733
+ payerAddress: string;
5734
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
5735
+ intervalCount: number;
5736
+ planId: string;
5737
+ onchainSubscriptionId: number | null;
5738
+ trialEndsAt: string | null;
5739
+ currentPeriodStartAt: string;
5740
+ currentPeriodEndAt: string;
5741
+ nextChargeAt: string | null;
5742
+ gracePeriodHours: number;
5743
+ cancelledAt: string | null;
5744
+ }, {
5745
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
5746
+ amount: string;
5747
+ currency: "USDC" | "EURC";
5748
+ customerId: string;
5749
+ merchantId: string;
5750
+ id: string;
5751
+ createdAt: string;
5752
+ updatedAt: string;
5753
+ payerAddress: string;
5754
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
5755
+ intervalCount: number;
5756
+ planId: string;
5757
+ onchainSubscriptionId: number | null;
5758
+ trialEndsAt: string | null;
5759
+ currentPeriodStartAt: string;
5760
+ currentPeriodEndAt: string;
5761
+ nextChargeAt: string | null;
5762
+ gracePeriodHours: number;
5763
+ cancelledAt: string | null;
5764
+ metadata?: Record<string, string | number | boolean | null> | undefined;
5765
+ }>;
5766
+ }, "strip", z.ZodTypeAny, {
5767
+ type: "subscription.reactivated";
5768
+ mode: "test" | "live";
5769
+ data: {
5770
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
5771
+ amount: string;
5772
+ currency: "USDC" | "EURC";
5773
+ customerId: string;
5774
+ merchantId: string;
5775
+ id: string;
5776
+ createdAt: string;
5777
+ updatedAt: string;
5778
+ metadata: Record<string, string | number | boolean | null>;
5779
+ payerAddress: string;
5780
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
5781
+ intervalCount: number;
5782
+ planId: string;
5783
+ onchainSubscriptionId: number | null;
5784
+ trialEndsAt: string | null;
5785
+ currentPeriodStartAt: string;
5786
+ currentPeriodEndAt: string;
5787
+ nextChargeAt: string | null;
5788
+ gracePeriodHours: number;
5789
+ cancelledAt: string | null;
5790
+ };
5791
+ id: string;
5792
+ createdAt: string;
5793
+ apiVersion: string;
5794
+ }, {
5795
+ type: "subscription.reactivated";
5796
+ mode: "test" | "live";
5797
+ data: {
5798
+ status: "cancelled" | "trialing" | "active" | "at_risk" | "paused" | "lapsed";
5799
+ amount: string;
5800
+ currency: "USDC" | "EURC";
5801
+ customerId: string;
5802
+ merchantId: string;
5803
+ id: string;
5804
+ createdAt: string;
5805
+ updatedAt: string;
5806
+ payerAddress: string;
5807
+ interval: "daily" | "weekly" | "monthly" | "quarterly" | "yearly";
5808
+ intervalCount: number;
5809
+ planId: string;
5810
+ onchainSubscriptionId: number | null;
5811
+ trialEndsAt: string | null;
5812
+ currentPeriodStartAt: string;
5813
+ currentPeriodEndAt: string;
5814
+ nextChargeAt: string | null;
5815
+ gracePeriodHours: number;
5816
+ cancelledAt: string | null;
5817
+ metadata?: Record<string, string | number | boolean | null> | undefined;
5818
+ };
5819
+ id: string;
5820
+ createdAt: string;
5821
+ apiVersion: string;
5569
5822
  }>, z.ZodObject<{
5570
5823
  id: z.ZodString;
5571
5824
  type: z.ZodLiteral<"refund.created">;
@@ -7087,6 +7340,7 @@ type SubscriptionChargeFailedEvent = z.infer<typeof subscriptionChargeFailedEven
7087
7340
  type SubscriptionRecoveryAttemptEvent = z.infer<typeof subscriptionRecoveryAttemptEventSchema>;
7088
7341
  type SubscriptionCancelledEvent = z.infer<typeof subscriptionCancelledEventSchema>;
7089
7342
  type SubscriptionLapsedEvent = z.infer<typeof subscriptionLapsedEventSchema>;
7343
+ type SubscriptionReactivatedEvent = z.infer<typeof subscriptionReactivatedEventSchema>;
7090
7344
  type RefundCreatedEvent = z.infer<typeof refundCreatedEventSchema>;
7091
7345
  type RefundCompletedEvent = z.infer<typeof refundCompletedEventSchema>;
7092
7346
  type InvoiceCreatedEvent = z.infer<typeof invoiceCreatedEventSchema>;
@@ -7098,4 +7352,4 @@ type AgentJobDisputedEvent = z.infer<typeof agentJobDisputedEventSchema>;
7098
7352
  type ComplianceWalletFlaggedEvent = z.infer<typeof complianceWalletFlaggedEventSchema>;
7099
7353
  type ComplianceWalletBlockedEvent = z.infer<typeof complianceWalletBlockedEventSchema>;
7100
7354
 
7101
- export { type AgentJobCompletedEvent, type AgentJobDisputedEvent, type AgentJobProposedEvent, type ComplianceWalletBlockedEvent, type ComplianceWalletFlaggedEvent, type InvoiceCreatedEvent, type InvoiceOverdueEvent, type InvoicePaidEvent, type PaymentCompletedEvent, type PaymentCreatedEvent, type PaymentFailedEvent, type RefundCompletedEvent, type RefundCreatedEvent, type StrimzWebhookEvent, type SubscriptionCancelledEvent, type SubscriptionChargeFailedEvent, type SubscriptionChargedEvent, type SubscriptionCreatedEvent, type SubscriptionLapsedEvent, type SubscriptionRecoveryAttemptEvent, agentJobCompletedEventSchema, agentJobDisputedEventSchema, agentJobProposedEventSchema, complianceWalletBlockedEventSchema, complianceWalletFlaggedEventSchema, invoiceCreatedEventSchema, invoiceOverdueEventSchema, invoicePaidEventSchema, paymentCompletedEventSchema, paymentCreatedEventSchema, paymentFailedEventSchema, refundCompletedEventSchema, refundCreatedEventSchema, subscriptionCancelledEventSchema, subscriptionChargeFailedEventSchema, subscriptionChargedEventSchema, subscriptionCreatedEventSchema, subscriptionLapsedEventSchema, subscriptionRecoveryAttemptEventSchema, webhookEventSchema };
7355
+ export { type AgentJobCompletedEvent, type AgentJobDisputedEvent, type AgentJobProposedEvent, type ComplianceWalletBlockedEvent, type ComplianceWalletFlaggedEvent, type InvoiceCreatedEvent, type InvoiceOverdueEvent, type InvoicePaidEvent, type PaymentCompletedEvent, type PaymentCreatedEvent, type PaymentFailedEvent, type RefundCompletedEvent, type RefundCreatedEvent, type StrimzWebhookEvent, type SubscriptionCancelledEvent, type SubscriptionChargeFailedEvent, type SubscriptionChargedEvent, type SubscriptionCreatedEvent, type SubscriptionLapsedEvent, type SubscriptionReactivatedEvent, type SubscriptionRecoveryAttemptEvent, agentJobCompletedEventSchema, agentJobDisputedEventSchema, agentJobProposedEventSchema, complianceWalletBlockedEventSchema, complianceWalletFlaggedEventSchema, invoiceCreatedEventSchema, invoiceOverdueEventSchema, invoicePaidEventSchema, paymentCompletedEventSchema, paymentCreatedEventSchema, paymentFailedEventSchema, refundCompletedEventSchema, refundCreatedEventSchema, subscriptionCancelledEventSchema, subscriptionChargeFailedEventSchema, subscriptionChargedEventSchema, subscriptionCreatedEventSchema, subscriptionLapsedEventSchema, subscriptionReactivatedEventSchema, subscriptionRecoveryAttemptEventSchema, webhookEventSchema };
package/dist/events.js CHANGED
@@ -119,6 +119,7 @@ var checkoutResultErrorCodes = [
119
119
  "load_failed",
120
120
  "merchant_not_ready",
121
121
  "payment_reverted",
122
+ // No longer sent: smart-contract wallets can pay since the #142 redeploy.
122
123
  "unsupported_wallet"
123
124
  ];
124
125
  var checkoutResultErrorCodeSchema = z.enum(checkoutResultErrorCodes);
@@ -309,7 +310,8 @@ var subscriptionChargeOutcomeSchema = z.enum([
309
310
  "unknown",
310
311
  "merchant_inactive",
311
312
  "transfer_failed",
312
- "skipped"
313
+ "skipped",
314
+ "token_not_allowed"
313
315
  ]);
314
316
  var subscriptionChargeStatusSchema = z.enum([
315
317
  "pending",
@@ -589,6 +591,7 @@ var webhookEventNameSchema = z.enum([
589
591
  "subscription.recovery_attempt",
590
592
  "subscription.cancelled",
591
593
  "subscription.lapsed",
594
+ "subscription.reactivated",
592
595
  "refund.created",
593
596
  "refund.completed",
594
597
  "invoice.created",
@@ -695,6 +698,10 @@ var subscriptionCancelledEventSchema = envelope(
695
698
  subscriptionSchema
696
699
  );
697
700
  var subscriptionLapsedEventSchema = envelope("subscription.lapsed", subscriptionSchema);
701
+ var subscriptionReactivatedEventSchema = envelope(
702
+ "subscription.reactivated",
703
+ subscriptionSchema
704
+ );
698
705
  var refundCreatedEventSchema = envelope("refund.created", refundSchema);
699
706
  var refundCompletedEventSchema = envelope(
700
707
  "refund.completed",
@@ -727,6 +734,7 @@ var webhookEventSchema = z.discriminatedUnion("type", [
727
734
  subscriptionRecoveryAttemptEventSchema,
728
735
  subscriptionCancelledEventSchema,
729
736
  subscriptionLapsedEventSchema,
737
+ subscriptionReactivatedEventSchema,
730
738
  refundCreatedEventSchema,
731
739
  refundCompletedEventSchema,
732
740
  invoiceCreatedEventSchema,
@@ -739,6 +747,6 @@ var webhookEventSchema = z.discriminatedUnion("type", [
739
747
  complianceWalletBlockedEventSchema
740
748
  ]);
741
749
 
742
- export { agentJobCompletedEventSchema, agentJobDisputedEventSchema, agentJobProposedEventSchema, complianceWalletBlockedEventSchema, complianceWalletFlaggedEventSchema, invoiceCreatedEventSchema, invoiceOverdueEventSchema, invoicePaidEventSchema, paymentCompletedEventSchema, paymentCreatedEventSchema, paymentFailedEventSchema, refundCompletedEventSchema, refundCreatedEventSchema, subscriptionCancelledEventSchema, subscriptionChargeFailedEventSchema, subscriptionChargedEventSchema, subscriptionCreatedEventSchema, subscriptionLapsedEventSchema, subscriptionRecoveryAttemptEventSchema, webhookEventNameSchema, webhookEventSchema };
750
+ export { agentJobCompletedEventSchema, agentJobDisputedEventSchema, agentJobProposedEventSchema, complianceWalletBlockedEventSchema, complianceWalletFlaggedEventSchema, invoiceCreatedEventSchema, invoiceOverdueEventSchema, invoicePaidEventSchema, paymentCompletedEventSchema, paymentCreatedEventSchema, paymentFailedEventSchema, refundCompletedEventSchema, refundCreatedEventSchema, subscriptionCancelledEventSchema, subscriptionChargeFailedEventSchema, subscriptionChargedEventSchema, subscriptionCreatedEventSchema, subscriptionLapsedEventSchema, subscriptionReactivatedEventSchema, subscriptionRecoveryAttemptEventSchema, webhookEventNameSchema, webhookEventSchema };
743
751
  //# sourceMappingURL=events.js.map
744
752
  //# sourceMappingURL=events.js.map