@klappay/types 3.3.0 → 3.4.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/index.d.mts +38 -38
- package/dist/index.d.ts +38 -38
- package/dist/index.js +14 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +14 -6
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1564,11 +1564,11 @@ declare const METRICS_QUERY_DEFAULT_ROW_LIMIT = 100;
|
|
|
1564
1564
|
declare const METRICS_QUERY_MAX_GROUP_BY = 3;
|
|
1565
1565
|
declare const METRICS_QUERY_MAX_FILTERS = 20;
|
|
1566
1566
|
declare const METRICS_QUERY_MAX_METRICS = 10;
|
|
1567
|
-
declare const ChargesQueryFieldSchema: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef"]>;
|
|
1567
|
+
declare const ChargesQueryFieldSchema: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef", "escrowReleaserAddress"]>;
|
|
1568
1568
|
type ChargesQueryField = z.infer<typeof ChargesQueryFieldSchema>;
|
|
1569
|
-
declare const ChargesMetricFieldSchema: z.ZodEnum<["amount", "amountReceived", "feePercent"]>;
|
|
1569
|
+
declare const ChargesMetricFieldSchema: z.ZodEnum<["amount", "amountReceived", "feePercent", "escrowFeePercent"]>;
|
|
1570
1570
|
type ChargesMetricField = z.infer<typeof ChargesMetricFieldSchema>;
|
|
1571
|
-
declare const ChargesDateFieldSchema: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]>;
|
|
1571
|
+
declare const ChargesDateFieldSchema: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]>;
|
|
1572
1572
|
type ChargesDateField = z.infer<typeof ChargesDateFieldSchema>;
|
|
1573
1573
|
declare const TransactionsQueryFieldSchema: z.ZodEnum<["network", "token", "source", "causedTransition"]>;
|
|
1574
1574
|
type TransactionsQueryField = z.infer<typeof TransactionsQueryFieldSchema>;
|
|
@@ -1586,64 +1586,64 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1586
1586
|
resource: z.ZodLiteral<"charges">;
|
|
1587
1587
|
environment: z.ZodEnum<["live", "test"]>;
|
|
1588
1588
|
dateRange: z.ZodObject<{
|
|
1589
|
-
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]>;
|
|
1589
|
+
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]>;
|
|
1590
1590
|
from: z.ZodString;
|
|
1591
1591
|
to: z.ZodString;
|
|
1592
1592
|
}, "strip", z.ZodTypeAny, {
|
|
1593
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1593
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1594
1594
|
from: string;
|
|
1595
1595
|
to: string;
|
|
1596
1596
|
}, {
|
|
1597
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1597
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1598
1598
|
from: string;
|
|
1599
1599
|
to: string;
|
|
1600
1600
|
}>;
|
|
1601
1601
|
groupBy: z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodObject<{
|
|
1602
1602
|
type: z.ZodLiteral<"field">;
|
|
1603
|
-
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef"]>;
|
|
1603
|
+
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef", "escrowReleaserAddress"]>;
|
|
1604
1604
|
}, "strip", z.ZodTypeAny, {
|
|
1605
1605
|
type: "field";
|
|
1606
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1606
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1607
1607
|
}, {
|
|
1608
1608
|
type: "field";
|
|
1609
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1609
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1610
1610
|
}>, z.ZodObject<{
|
|
1611
1611
|
type: z.ZodLiteral<"date_bucket">;
|
|
1612
|
-
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]>;
|
|
1612
|
+
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]>;
|
|
1613
1613
|
granularity: z.ZodEnum<["day", "week", "month", "year"]>;
|
|
1614
1614
|
}, "strip", z.ZodTypeAny, {
|
|
1615
1615
|
type: "date_bucket";
|
|
1616
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1616
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1617
1617
|
granularity: "day" | "week" | "month" | "year";
|
|
1618
1618
|
}, {
|
|
1619
1619
|
type: "date_bucket";
|
|
1620
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1620
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1621
1621
|
granularity: "day" | "week" | "month" | "year";
|
|
1622
1622
|
}>]>, "many">>;
|
|
1623
1623
|
metrics: z.ZodArray<z.ZodObject<{
|
|
1624
1624
|
aggregation: z.ZodEnum<["count", "sum", "avg", "min", "max"]>;
|
|
1625
|
-
field: z.ZodOptional<z.ZodEnum<["amount", "amountReceived", "feePercent"]>>;
|
|
1625
|
+
field: z.ZodOptional<z.ZodEnum<["amount", "amountReceived", "feePercent", "escrowFeePercent"]>>;
|
|
1626
1626
|
alias: z.ZodOptional<z.ZodString>;
|
|
1627
1627
|
}, "strip", z.ZodTypeAny, {
|
|
1628
1628
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1629
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1629
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1630
1630
|
alias?: string | undefined;
|
|
1631
1631
|
}, {
|
|
1632
1632
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1633
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1633
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1634
1634
|
alias?: string | undefined;
|
|
1635
1635
|
}>, "many">;
|
|
1636
1636
|
filters: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
1637
|
-
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef"]>;
|
|
1637
|
+
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef", "escrowReleaserAddress"]>;
|
|
1638
1638
|
operator: z.ZodEnum<["eq", "neq", "in", "gt", "gte", "lt", "lte"]>;
|
|
1639
1639
|
value: z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber]>, "many">]>;
|
|
1640
1640
|
}, "strip", z.ZodTypeAny, {
|
|
1641
1641
|
value: string | number | boolean | (string | number)[];
|
|
1642
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1642
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1643
1643
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1644
1644
|
}, {
|
|
1645
1645
|
value: string | number | boolean | (string | number)[];
|
|
1646
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1646
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1647
1647
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1648
1648
|
}>, "many">>;
|
|
1649
1649
|
orderBy: z.ZodOptional<z.ZodObject<{
|
|
@@ -1662,26 +1662,26 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1662
1662
|
environment: "live" | "test";
|
|
1663
1663
|
resource: "charges";
|
|
1664
1664
|
dateRange: {
|
|
1665
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1665
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1666
1666
|
from: string;
|
|
1667
1667
|
to: string;
|
|
1668
1668
|
};
|
|
1669
1669
|
groupBy: ({
|
|
1670
1670
|
type: "field";
|
|
1671
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1671
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1672
1672
|
} | {
|
|
1673
1673
|
type: "date_bucket";
|
|
1674
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1674
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1675
1675
|
granularity: "day" | "week" | "month" | "year";
|
|
1676
1676
|
})[];
|
|
1677
1677
|
metrics: {
|
|
1678
1678
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1679
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1679
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1680
1680
|
alias?: string | undefined;
|
|
1681
1681
|
}[];
|
|
1682
1682
|
filters: {
|
|
1683
1683
|
value: string | number | boolean | (string | number)[];
|
|
1684
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1684
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1685
1685
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1686
1686
|
}[];
|
|
1687
1687
|
orderBy?: {
|
|
@@ -1692,27 +1692,27 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1692
1692
|
environment: "live" | "test";
|
|
1693
1693
|
resource: "charges";
|
|
1694
1694
|
dateRange: {
|
|
1695
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1695
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1696
1696
|
from: string;
|
|
1697
1697
|
to: string;
|
|
1698
1698
|
};
|
|
1699
1699
|
metrics: {
|
|
1700
1700
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1701
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1701
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1702
1702
|
alias?: string | undefined;
|
|
1703
1703
|
}[];
|
|
1704
1704
|
limit?: number | undefined;
|
|
1705
1705
|
groupBy?: ({
|
|
1706
1706
|
type: "field";
|
|
1707
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1707
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1708
1708
|
} | {
|
|
1709
1709
|
type: "date_bucket";
|
|
1710
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1710
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1711
1711
|
granularity: "day" | "week" | "month" | "year";
|
|
1712
1712
|
})[] | undefined;
|
|
1713
1713
|
filters?: {
|
|
1714
1714
|
value: string | number | boolean | (string | number)[];
|
|
1715
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1715
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1716
1716
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1717
1717
|
}[] | undefined;
|
|
1718
1718
|
orderBy?: {
|
|
@@ -1998,26 +1998,26 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1998
1998
|
environment: "live" | "test";
|
|
1999
1999
|
resource: "charges";
|
|
2000
2000
|
dateRange: {
|
|
2001
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2001
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2002
2002
|
from: string;
|
|
2003
2003
|
to: string;
|
|
2004
2004
|
};
|
|
2005
2005
|
groupBy: ({
|
|
2006
2006
|
type: "field";
|
|
2007
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2007
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2008
2008
|
} | {
|
|
2009
2009
|
type: "date_bucket";
|
|
2010
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2010
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2011
2011
|
granularity: "day" | "week" | "month" | "year";
|
|
2012
2012
|
})[];
|
|
2013
2013
|
metrics: {
|
|
2014
2014
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
2015
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
2015
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
2016
2016
|
alias?: string | undefined;
|
|
2017
2017
|
}[];
|
|
2018
2018
|
filters: {
|
|
2019
2019
|
value: string | number | boolean | (string | number)[];
|
|
2020
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2020
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2021
2021
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
2022
2022
|
}[];
|
|
2023
2023
|
orderBy?: {
|
|
@@ -2090,27 +2090,27 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
2090
2090
|
environment: "live" | "test";
|
|
2091
2091
|
resource: "charges";
|
|
2092
2092
|
dateRange: {
|
|
2093
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2093
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2094
2094
|
from: string;
|
|
2095
2095
|
to: string;
|
|
2096
2096
|
};
|
|
2097
2097
|
metrics: {
|
|
2098
2098
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
2099
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
2099
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
2100
2100
|
alias?: string | undefined;
|
|
2101
2101
|
}[];
|
|
2102
2102
|
limit?: number | undefined;
|
|
2103
2103
|
groupBy?: ({
|
|
2104
2104
|
type: "field";
|
|
2105
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2105
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2106
2106
|
} | {
|
|
2107
2107
|
type: "date_bucket";
|
|
2108
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2108
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2109
2109
|
granularity: "day" | "week" | "month" | "year";
|
|
2110
2110
|
})[] | undefined;
|
|
2111
2111
|
filters?: {
|
|
2112
2112
|
value: string | number | boolean | (string | number)[];
|
|
2113
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2113
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2114
2114
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
2115
2115
|
}[] | undefined;
|
|
2116
2116
|
orderBy?: {
|
package/dist/index.d.ts
CHANGED
|
@@ -1564,11 +1564,11 @@ declare const METRICS_QUERY_DEFAULT_ROW_LIMIT = 100;
|
|
|
1564
1564
|
declare const METRICS_QUERY_MAX_GROUP_BY = 3;
|
|
1565
1565
|
declare const METRICS_QUERY_MAX_FILTERS = 20;
|
|
1566
1566
|
declare const METRICS_QUERY_MAX_METRICS = 10;
|
|
1567
|
-
declare const ChargesQueryFieldSchema: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef"]>;
|
|
1567
|
+
declare const ChargesQueryFieldSchema: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef", "escrowReleaserAddress"]>;
|
|
1568
1568
|
type ChargesQueryField = z.infer<typeof ChargesQueryFieldSchema>;
|
|
1569
|
-
declare const ChargesMetricFieldSchema: z.ZodEnum<["amount", "amountReceived", "feePercent"]>;
|
|
1569
|
+
declare const ChargesMetricFieldSchema: z.ZodEnum<["amount", "amountReceived", "feePercent", "escrowFeePercent"]>;
|
|
1570
1570
|
type ChargesMetricField = z.infer<typeof ChargesMetricFieldSchema>;
|
|
1571
|
-
declare const ChargesDateFieldSchema: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]>;
|
|
1571
|
+
declare const ChargesDateFieldSchema: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]>;
|
|
1572
1572
|
type ChargesDateField = z.infer<typeof ChargesDateFieldSchema>;
|
|
1573
1573
|
declare const TransactionsQueryFieldSchema: z.ZodEnum<["network", "token", "source", "causedTransition"]>;
|
|
1574
1574
|
type TransactionsQueryField = z.infer<typeof TransactionsQueryFieldSchema>;
|
|
@@ -1586,64 +1586,64 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1586
1586
|
resource: z.ZodLiteral<"charges">;
|
|
1587
1587
|
environment: z.ZodEnum<["live", "test"]>;
|
|
1588
1588
|
dateRange: z.ZodObject<{
|
|
1589
|
-
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]>;
|
|
1589
|
+
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]>;
|
|
1590
1590
|
from: z.ZodString;
|
|
1591
1591
|
to: z.ZodString;
|
|
1592
1592
|
}, "strip", z.ZodTypeAny, {
|
|
1593
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1593
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1594
1594
|
from: string;
|
|
1595
1595
|
to: string;
|
|
1596
1596
|
}, {
|
|
1597
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1597
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1598
1598
|
from: string;
|
|
1599
1599
|
to: string;
|
|
1600
1600
|
}>;
|
|
1601
1601
|
groupBy: z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodObject<{
|
|
1602
1602
|
type: z.ZodLiteral<"field">;
|
|
1603
|
-
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef"]>;
|
|
1603
|
+
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef", "escrowReleaserAddress"]>;
|
|
1604
1604
|
}, "strip", z.ZodTypeAny, {
|
|
1605
1605
|
type: "field";
|
|
1606
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1606
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1607
1607
|
}, {
|
|
1608
1608
|
type: "field";
|
|
1609
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1609
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1610
1610
|
}>, z.ZodObject<{
|
|
1611
1611
|
type: z.ZodLiteral<"date_bucket">;
|
|
1612
|
-
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]>;
|
|
1612
|
+
field: z.ZodEnum<["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]>;
|
|
1613
1613
|
granularity: z.ZodEnum<["day", "week", "month", "year"]>;
|
|
1614
1614
|
}, "strip", z.ZodTypeAny, {
|
|
1615
1615
|
type: "date_bucket";
|
|
1616
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1616
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1617
1617
|
granularity: "day" | "week" | "month" | "year";
|
|
1618
1618
|
}, {
|
|
1619
1619
|
type: "date_bucket";
|
|
1620
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1620
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1621
1621
|
granularity: "day" | "week" | "month" | "year";
|
|
1622
1622
|
}>]>, "many">>;
|
|
1623
1623
|
metrics: z.ZodArray<z.ZodObject<{
|
|
1624
1624
|
aggregation: z.ZodEnum<["count", "sum", "avg", "min", "max"]>;
|
|
1625
|
-
field: z.ZodOptional<z.ZodEnum<["amount", "amountReceived", "feePercent"]>>;
|
|
1625
|
+
field: z.ZodOptional<z.ZodEnum<["amount", "amountReceived", "feePercent", "escrowFeePercent"]>>;
|
|
1626
1626
|
alias: z.ZodOptional<z.ZodString>;
|
|
1627
1627
|
}, "strip", z.ZodTypeAny, {
|
|
1628
1628
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1629
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1629
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1630
1630
|
alias?: string | undefined;
|
|
1631
1631
|
}, {
|
|
1632
1632
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1633
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1633
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1634
1634
|
alias?: string | undefined;
|
|
1635
1635
|
}>, "many">;
|
|
1636
1636
|
filters: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
1637
|
-
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef"]>;
|
|
1637
|
+
field: z.ZodEnum<["status", "source", "apiKeyId", "currency", "isOverpaid", "externalRef", "escrowReleaserAddress"]>;
|
|
1638
1638
|
operator: z.ZodEnum<["eq", "neq", "in", "gt", "gte", "lt", "lte"]>;
|
|
1639
1639
|
value: z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodNumber]>, "many">]>;
|
|
1640
1640
|
}, "strip", z.ZodTypeAny, {
|
|
1641
1641
|
value: string | number | boolean | (string | number)[];
|
|
1642
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1642
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1643
1643
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1644
1644
|
}, {
|
|
1645
1645
|
value: string | number | boolean | (string | number)[];
|
|
1646
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1646
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1647
1647
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1648
1648
|
}>, "many">>;
|
|
1649
1649
|
orderBy: z.ZodOptional<z.ZodObject<{
|
|
@@ -1662,26 +1662,26 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1662
1662
|
environment: "live" | "test";
|
|
1663
1663
|
resource: "charges";
|
|
1664
1664
|
dateRange: {
|
|
1665
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1665
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1666
1666
|
from: string;
|
|
1667
1667
|
to: string;
|
|
1668
1668
|
};
|
|
1669
1669
|
groupBy: ({
|
|
1670
1670
|
type: "field";
|
|
1671
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1671
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1672
1672
|
} | {
|
|
1673
1673
|
type: "date_bucket";
|
|
1674
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1674
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1675
1675
|
granularity: "day" | "week" | "month" | "year";
|
|
1676
1676
|
})[];
|
|
1677
1677
|
metrics: {
|
|
1678
1678
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1679
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1679
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1680
1680
|
alias?: string | undefined;
|
|
1681
1681
|
}[];
|
|
1682
1682
|
filters: {
|
|
1683
1683
|
value: string | number | boolean | (string | number)[];
|
|
1684
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1684
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1685
1685
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1686
1686
|
}[];
|
|
1687
1687
|
orderBy?: {
|
|
@@ -1692,27 +1692,27 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1692
1692
|
environment: "live" | "test";
|
|
1693
1693
|
resource: "charges";
|
|
1694
1694
|
dateRange: {
|
|
1695
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1695
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1696
1696
|
from: string;
|
|
1697
1697
|
to: string;
|
|
1698
1698
|
};
|
|
1699
1699
|
metrics: {
|
|
1700
1700
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
1701
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
1701
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
1702
1702
|
alias?: string | undefined;
|
|
1703
1703
|
}[];
|
|
1704
1704
|
limit?: number | undefined;
|
|
1705
1705
|
groupBy?: ({
|
|
1706
1706
|
type: "field";
|
|
1707
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1707
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1708
1708
|
} | {
|
|
1709
1709
|
type: "date_bucket";
|
|
1710
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
1710
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
1711
1711
|
granularity: "day" | "week" | "month" | "year";
|
|
1712
1712
|
})[] | undefined;
|
|
1713
1713
|
filters?: {
|
|
1714
1714
|
value: string | number | boolean | (string | number)[];
|
|
1715
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
1715
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
1716
1716
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
1717
1717
|
}[] | undefined;
|
|
1718
1718
|
orderBy?: {
|
|
@@ -1998,26 +1998,26 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
1998
1998
|
environment: "live" | "test";
|
|
1999
1999
|
resource: "charges";
|
|
2000
2000
|
dateRange: {
|
|
2001
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2001
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2002
2002
|
from: string;
|
|
2003
2003
|
to: string;
|
|
2004
2004
|
};
|
|
2005
2005
|
groupBy: ({
|
|
2006
2006
|
type: "field";
|
|
2007
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2007
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2008
2008
|
} | {
|
|
2009
2009
|
type: "date_bucket";
|
|
2010
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2010
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2011
2011
|
granularity: "day" | "week" | "month" | "year";
|
|
2012
2012
|
})[];
|
|
2013
2013
|
metrics: {
|
|
2014
2014
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
2015
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
2015
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
2016
2016
|
alias?: string | undefined;
|
|
2017
2017
|
}[];
|
|
2018
2018
|
filters: {
|
|
2019
2019
|
value: string | number | boolean | (string | number)[];
|
|
2020
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2020
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2021
2021
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
2022
2022
|
}[];
|
|
2023
2023
|
orderBy?: {
|
|
@@ -2090,27 +2090,27 @@ declare const MetricsQuerySchema: z.ZodEffects<z.ZodDiscriminatedUnion<"resource
|
|
|
2090
2090
|
environment: "live" | "test";
|
|
2091
2091
|
resource: "charges";
|
|
2092
2092
|
dateRange: {
|
|
2093
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2093
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2094
2094
|
from: string;
|
|
2095
2095
|
to: string;
|
|
2096
2096
|
};
|
|
2097
2097
|
metrics: {
|
|
2098
2098
|
aggregation: "count" | "sum" | "avg" | "min" | "max";
|
|
2099
|
-
field?: "amount" | "amountReceived" | "feePercent" | undefined;
|
|
2099
|
+
field?: "amount" | "amountReceived" | "feePercent" | "escrowFeePercent" | undefined;
|
|
2100
2100
|
alias?: string | undefined;
|
|
2101
2101
|
}[];
|
|
2102
2102
|
limit?: number | undefined;
|
|
2103
2103
|
groupBy?: ({
|
|
2104
2104
|
type: "field";
|
|
2105
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2105
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2106
2106
|
} | {
|
|
2107
2107
|
type: "date_bucket";
|
|
2108
|
-
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt";
|
|
2108
|
+
field: "createdAt" | "expiresAt" | "confirmedAt" | "lastActivityAt" | "escrowReleasedAt";
|
|
2109
2109
|
granularity: "day" | "week" | "month" | "year";
|
|
2110
2110
|
})[] | undefined;
|
|
2111
2111
|
filters?: {
|
|
2112
2112
|
value: string | number | boolean | (string | number)[];
|
|
2113
|
-
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId";
|
|
2113
|
+
field: "status" | "currency" | "externalRef" | "source" | "isOverpaid" | "apiKeyId" | "escrowReleaserAddress";
|
|
2114
2114
|
operator: "eq" | "neq" | "in" | "gt" | "gte" | "lt" | "lte";
|
|
2115
2115
|
}[] | undefined;
|
|
2116
2116
|
orderBy?: {
|
package/dist/index.js
CHANGED
|
@@ -655,14 +655,22 @@ var orderBySchema = import_zod13.z.object({
|
|
|
655
655
|
var limitSchema = import_zod13.z.number().int().min(1).max(METRICS_QUERY_MAX_ROW_LIMIT).default(METRICS_QUERY_DEFAULT_ROW_LIMIT).describe(
|
|
656
656
|
`Max rows to return, ${1}\u2013${METRICS_QUERY_MAX_ROW_LIMIT}, default ${METRICS_QUERY_DEFAULT_ROW_LIMIT}. If more rows matched, \`meta.truncated\` is \`true\` on the response \u2014 narrow the query instead of just raising this.`
|
|
657
657
|
);
|
|
658
|
-
var ChargesQueryFieldSchema = import_zod13.z.enum([
|
|
659
|
-
"
|
|
658
|
+
var ChargesQueryFieldSchema = import_zod13.z.enum([
|
|
659
|
+
"status",
|
|
660
|
+
"source",
|
|
661
|
+
"apiKeyId",
|
|
662
|
+
"currency",
|
|
663
|
+
"isOverpaid",
|
|
664
|
+
"externalRef",
|
|
665
|
+
"escrowReleaserAddress"
|
|
666
|
+
]).describe(
|
|
667
|
+
"A `Charge` field to filter or group by \u2014 see `ChargeStatusSchema` for `status`'s own possible values (charges.md). `source`/`externalRef` are free-form strings your own integration set at creation, not a fixed enum. `escrowReleaserAddress` is `null` for a normal charge \u2014 filter `escrowReleaserAddress` with operator `neq`/value `null` to isolate escrow-configured charges (see `escrow` in charges.md)."
|
|
660
668
|
);
|
|
661
|
-
var ChargesMetricFieldSchema = import_zod13.z.enum(["amount", "amountReceived", "feePercent"]).describe(
|
|
662
|
-
"A `Charge` numeric field to aggregate. `amount`/`amountReceived` are decimal currency amounts (requested vs. actually received \u2014 see `charges.md`). `feePercent` is the platform fee frozen on the charge at creation, e.g. `1.5` means 1.5%."
|
|
669
|
+
var ChargesMetricFieldSchema = import_zod13.z.enum(["amount", "amountReceived", "feePercent", "escrowFeePercent"]).describe(
|
|
670
|
+
"A `Charge` numeric field to aggregate. `amount`/`amountReceived` are decimal currency amounts (requested vs. actually received \u2014 see `charges.md`). `feePercent` is the platform fee frozen on the charge at creation, e.g. `1.5` means 1.5%. `escrowFeePercent` is the additional escrow-specific fee component, only present on escrow-configured charges \u2014 see `docs/payments.md`."
|
|
663
671
|
);
|
|
664
|
-
var ChargesDateFieldSchema = import_zod13.z.enum(["createdAt", "confirmedAt", "lastActivityAt", "expiresAt"]).describe(
|
|
665
|
-
"A `Charge` timestamp to filter/bucket by. `confirmedAt` is `null` until the charge reaches `confirmed` \u2014 a `dateRange`/`date_bucket` on it implicitly excludes every charge that never confirmed. `expiresAt` is always present (set at creation), useful for e.g. finding charges expiring soon or measuring how close to expiry charges typically resolve."
|
|
672
|
+
var ChargesDateFieldSchema = import_zod13.z.enum(["createdAt", "confirmedAt", "lastActivityAt", "expiresAt", "escrowReleasedAt"]).describe(
|
|
673
|
+
"A `Charge` timestamp to filter/bucket by. `confirmedAt` is `null` until the charge reaches `confirmed` \u2014 a `dateRange`/`date_bucket` on it implicitly excludes every charge that never confirmed. `expiresAt` is always present (set at creation), useful for e.g. finding charges expiring soon or measuring how close to expiry charges typically resolve. `escrowReleasedAt` is `null` until an escrow-configured charge is actually released \u2014 same implicit-exclusion behavior as `confirmedAt`, scoped to escrow charges only."
|
|
666
674
|
);
|
|
667
675
|
var ChargesFilterSchema = import_zod13.z.object({
|
|
668
676
|
field: ChargesQueryFieldSchema,
|