@wix/auto_sdk_benefit-programs_pools 1.0.68 → 1.0.69

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.
Files changed (49) hide show
  1. package/build/cjs/index.d.ts +3 -19
  2. package/build/cjs/index.js +0 -76
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +5 -115
  5. package/build/cjs/index.typings.js +0 -68
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +6 -61
  8. package/build/cjs/meta.js +0 -47
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/cjs/schemas.d.ts +1 -150
  11. package/build/cjs/schemas.js +0 -256
  12. package/build/cjs/schemas.js.map +1 -1
  13. package/build/es/index.d.mts +3 -19
  14. package/build/es/index.mjs +0 -75
  15. package/build/es/index.mjs.map +1 -1
  16. package/build/es/index.typings.d.mts +5 -115
  17. package/build/es/index.typings.mjs +0 -67
  18. package/build/es/index.typings.mjs.map +1 -1
  19. package/build/es/meta.d.mts +6 -61
  20. package/build/es/meta.mjs +0 -46
  21. package/build/es/meta.mjs.map +1 -1
  22. package/build/es/schemas.d.mts +1 -150
  23. package/build/es/schemas.mjs +0 -254
  24. package/build/es/schemas.mjs.map +1 -1
  25. package/build/internal/cjs/index.d.ts +3 -22
  26. package/build/internal/cjs/index.js +0 -76
  27. package/build/internal/cjs/index.js.map +1 -1
  28. package/build/internal/cjs/index.typings.d.ts +5 -120
  29. package/build/internal/cjs/index.typings.js +0 -68
  30. package/build/internal/cjs/index.typings.js.map +1 -1
  31. package/build/internal/cjs/meta.d.ts +6 -61
  32. package/build/internal/cjs/meta.js +0 -47
  33. package/build/internal/cjs/meta.js.map +1 -1
  34. package/build/internal/cjs/schemas.d.ts +1 -150
  35. package/build/internal/cjs/schemas.js +0 -256
  36. package/build/internal/cjs/schemas.js.map +1 -1
  37. package/build/internal/es/index.d.mts +3 -22
  38. package/build/internal/es/index.mjs +0 -75
  39. package/build/internal/es/index.mjs.map +1 -1
  40. package/build/internal/es/index.typings.d.mts +5 -120
  41. package/build/internal/es/index.typings.mjs +0 -67
  42. package/build/internal/es/index.typings.mjs.map +1 -1
  43. package/build/internal/es/meta.d.mts +6 -61
  44. package/build/internal/es/meta.mjs +0 -46
  45. package/build/internal/es/meta.mjs.map +1 -1
  46. package/build/internal/es/schemas.d.mts +1 -150
  47. package/build/internal/es/schemas.mjs +0 -254
  48. package/build/internal/es/schemas.mjs.map +1 -1
  49. package/package.json +2 -2
@@ -870,154 +870,5 @@ declare const BulkUpdatePoolsResponse: z.ZodObject<{
870
870
  undetailedFailures: z.ZodOptional<z.ZodNumber>;
871
871
  }, z.core.$strip>>;
872
872
  }, z.core.$strip>;
873
- declare const CheckBenefitEligibilityByFilterRequest: z.ZodObject<{
874
- options: z.ZodObject<{
875
- poolFilter: z.ZodOptional<z.ZodObject<{
876
- filter: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>>;
877
- sort: z.ZodOptional<z.ZodArray<z.ZodObject<{
878
- fieldName: z.ZodOptional<z.ZodString>;
879
- order: z.ZodOptional<z.ZodEnum<{
880
- ASC: "ASC";
881
- DESC: "DESC";
882
- }>>;
883
- }, z.core.$strip>>>;
884
- }, z.core.$strip>>;
885
- namespace: z.ZodString;
886
- itemReference: z.ZodObject<{
887
- externalId: z.ZodString;
888
- category: z.ZodOptional<z.ZodString>;
889
- providerAppId: z.ZodString;
890
- }, z.core.$strip>;
891
- count: z.ZodNumber;
892
- targetDate: z.ZodNullable<z.ZodOptional<z.ZodDate>>;
893
- beneficiary: z.ZodOptional<z.ZodIntersection<z.ZodObject<{}, z.core.$strip>, z.ZodXor<readonly [z.ZodObject<{
894
- anonymousVisitorId: z.ZodOptional<z.ZodNever>;
895
- memberId: z.ZodOptional<z.ZodNever>;
896
- wixUserId: z.ZodOptional<z.ZodNever>;
897
- }, z.core.$strip>, z.ZodObject<{
898
- memberId: z.ZodOptional<z.ZodNever>;
899
- wixUserId: z.ZodOptional<z.ZodNever>;
900
- anonymousVisitorId: z.ZodString;
901
- }, z.core.$strip>, z.ZodObject<{
902
- anonymousVisitorId: z.ZodOptional<z.ZodNever>;
903
- wixUserId: z.ZodOptional<z.ZodNever>;
904
- memberId: z.ZodString;
905
- }, z.core.$strip>, z.ZodObject<{
906
- anonymousVisitorId: z.ZodOptional<z.ZodNever>;
907
- memberId: z.ZodOptional<z.ZodNever>;
908
- wixUserId: z.ZodString;
909
- }, z.core.$strip>]>>>;
910
- additionalData: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>>;
911
- }, z.core.$strip>;
912
- }, z.core.$strip>;
913
- declare const CheckBenefitEligibilityByFilterResponse: z.ZodObject<{
914
- results: z.ZodOptional<z.ZodArray<z.ZodObject<{
915
- benefitResults: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodObject<{
916
- type: z.ZodOptional<z.ZodEnum<{
917
- ELIGIBLE_BENEFIT: "ELIGIBLE_BENEFIT";
918
- NOT_ENOUGH_BALANCE: "NOT_ENOUGH_BALANCE";
919
- POOL_NOT_ACTIVE: "POOL_NOT_ACTIVE";
920
- BENEFIT_NOT_FOUND: "BENEFIT_NOT_FOUND";
921
- POOL_NOT_FOUND: "POOL_NOT_FOUND";
922
- }>>;
923
- }, z.core.$strip>, z.ZodXor<readonly [z.ZodObject<{
924
- eligibleBenefitOptions: z.ZodOptional<z.ZodNever>;
925
- notEnoughBalanceOptions: z.ZodOptional<z.ZodNever>;
926
- policyExpressionEvaluatedToFalseOptions: z.ZodOptional<z.ZodNever>;
927
- poolNotActiveOptions: z.ZodOptional<z.ZodNever>;
928
- benefitNotFoundOptions: z.ZodOptional<z.ZodNever>;
929
- poolNotFoundOptions: z.ZodOptional<z.ZodNever>;
930
- }, z.core.$strip>, z.ZodObject<{
931
- notEnoughBalanceOptions: z.ZodOptional<z.ZodNever>;
932
- policyExpressionEvaluatedToFalseOptions: z.ZodOptional<z.ZodNever>;
933
- poolNotActiveOptions: z.ZodOptional<z.ZodNever>;
934
- benefitNotFoundOptions: z.ZodOptional<z.ZodNever>;
935
- poolNotFoundOptions: z.ZodOptional<z.ZodNever>;
936
- eligibleBenefitOptions: z.ZodObject<{
937
- poolId: z.ZodOptional<z.ZodString>;
938
- benefitKey: z.ZodOptional<z.ZodString>;
939
- itemReference: z.ZodOptional<z.ZodObject<{
940
- externalId: z.ZodOptional<z.ZodString>;
941
- category: z.ZodOptional<z.ZodString>;
942
- providerAppId: z.ZodOptional<z.ZodString>;
943
- }, z.core.$strip>>;
944
- price: z.ZodNullable<z.ZodOptional<z.ZodString>>;
945
- }, z.core.$strip>;
946
- }, z.core.$strip>, z.ZodObject<{
947
- eligibleBenefitOptions: z.ZodOptional<z.ZodNever>;
948
- policyExpressionEvaluatedToFalseOptions: z.ZodOptional<z.ZodNever>;
949
- poolNotActiveOptions: z.ZodOptional<z.ZodNever>;
950
- benefitNotFoundOptions: z.ZodOptional<z.ZodNever>;
951
- poolNotFoundOptions: z.ZodOptional<z.ZodNever>;
952
- notEnoughBalanceOptions: z.ZodObject<{
953
- poolId: z.ZodOptional<z.ZodString>;
954
- itemReference: z.ZodOptional<z.ZodObject<{
955
- externalId: z.ZodOptional<z.ZodString>;
956
- category: z.ZodOptional<z.ZodString>;
957
- providerAppId: z.ZodOptional<z.ZodString>;
958
- }, z.core.$strip>>;
959
- availableBalance: z.ZodOptional<z.ZodString>;
960
- requestedBalance: z.ZodOptional<z.ZodString>;
961
- }, z.core.$strip>;
962
- }, z.core.$strip>, z.ZodObject<{
963
- eligibleBenefitOptions: z.ZodOptional<z.ZodNever>;
964
- notEnoughBalanceOptions: z.ZodOptional<z.ZodNever>;
965
- poolNotActiveOptions: z.ZodOptional<z.ZodNever>;
966
- benefitNotFoundOptions: z.ZodOptional<z.ZodNever>;
967
- poolNotFoundOptions: z.ZodOptional<z.ZodNever>;
968
- policyExpressionEvaluatedToFalseOptions: z.ZodObject<{
969
- poolId: z.ZodOptional<z.ZodString>;
970
- itemReference: z.ZodOptional<z.ZodObject<{
971
- externalId: z.ZodOptional<z.ZodString>;
972
- category: z.ZodOptional<z.ZodString>;
973
- providerAppId: z.ZodOptional<z.ZodString>;
974
- }, z.core.$strip>>;
975
- failureDetails: z.ZodOptional<z.ZodArray<z.ZodObject<{
976
- code: z.ZodOptional<z.ZodString>;
977
- message: z.ZodNullable<z.ZodOptional<z.ZodString>>;
978
- policyId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
979
- appId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
980
- errorData: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>>;
981
- }, z.core.$strip>>>;
982
- }, z.core.$strip>;
983
- }, z.core.$strip>, z.ZodObject<{
984
- eligibleBenefitOptions: z.ZodOptional<z.ZodNever>;
985
- notEnoughBalanceOptions: z.ZodOptional<z.ZodNever>;
986
- policyExpressionEvaluatedToFalseOptions: z.ZodOptional<z.ZodNever>;
987
- benefitNotFoundOptions: z.ZodOptional<z.ZodNever>;
988
- poolNotFoundOptions: z.ZodOptional<z.ZodNever>;
989
- poolNotActiveOptions: z.ZodObject<{
990
- poolId: z.ZodOptional<z.ZodString>;
991
- poolStatus: z.ZodOptional<z.ZodEnum<{
992
- ACTIVE: "ACTIVE";
993
- PAUSED: "PAUSED";
994
- ENDED: "ENDED";
995
- PROVISIONING: "PROVISIONING";
996
- RENEWING: "RENEWING";
997
- PENDING: "PENDING";
998
- }>>;
999
- }, z.core.$strip>;
1000
- }, z.core.$strip>, z.ZodObject<{
1001
- eligibleBenefitOptions: z.ZodOptional<z.ZodNever>;
1002
- notEnoughBalanceOptions: z.ZodOptional<z.ZodNever>;
1003
- policyExpressionEvaluatedToFalseOptions: z.ZodOptional<z.ZodNever>;
1004
- poolNotActiveOptions: z.ZodOptional<z.ZodNever>;
1005
- poolNotFoundOptions: z.ZodOptional<z.ZodNever>;
1006
- benefitNotFoundOptions: z.ZodObject<{
1007
- poolId: z.ZodOptional<z.ZodString>;
1008
- benefitKey: z.ZodNullable<z.ZodOptional<z.ZodString>>;
1009
- }, z.core.$strip>;
1010
- }, z.core.$strip>, z.ZodObject<{
1011
- eligibleBenefitOptions: z.ZodOptional<z.ZodNever>;
1012
- notEnoughBalanceOptions: z.ZodOptional<z.ZodNever>;
1013
- policyExpressionEvaluatedToFalseOptions: z.ZodOptional<z.ZodNever>;
1014
- poolNotActiveOptions: z.ZodOptional<z.ZodNever>;
1015
- benefitNotFoundOptions: z.ZodOptional<z.ZodNever>;
1016
- poolNotFoundOptions: z.ZodObject<{
1017
- poolId: z.ZodOptional<z.ZodString>;
1018
- }, z.core.$strip>;
1019
- }, z.core.$strip>]>>>>;
1020
- }, z.core.$strip>>>;
1021
- }, z.core.$strip>;
1022
873
 
1023
- export { BulkCheckBenefitEligibilityRequest, BulkCheckBenefitEligibilityResponse, BulkUpdatePoolsRequest, BulkUpdatePoolsResponse, CheckBenefitEligibilityByFilterRequest, CheckBenefitEligibilityByFilterResponse, CheckBenefitEligibilityRequest, CheckBenefitEligibilityResponse, GetEligibleBenefitsRequest, GetEligibleBenefitsResponse, GetPoolRequest, GetPoolResponse, QueryPoolsRequest, QueryPoolsResponse, RedeemBenefitRequest, RedeemBenefitResponse, UpdatePoolRequest, UpdatePoolResponse };
874
+ export { BulkCheckBenefitEligibilityRequest, BulkCheckBenefitEligibilityResponse, BulkUpdatePoolsRequest, BulkUpdatePoolsResponse, CheckBenefitEligibilityRequest, CheckBenefitEligibilityResponse, GetEligibleBenefitsRequest, GetEligibleBenefitsResponse, GetPoolRequest, GetPoolResponse, QueryPoolsRequest, QueryPoolsResponse, RedeemBenefitRequest, RedeemBenefitResponse, UpdatePoolRequest, UpdatePoolResponse };
@@ -34,8 +34,6 @@ __export(schemas_exports, {
34
34
  BulkCheckBenefitEligibilityResponse: () => BulkCheckBenefitEligibilityResponse,
35
35
  BulkUpdatePoolsRequest: () => BulkUpdatePoolsRequest,
36
36
  BulkUpdatePoolsResponse: () => BulkUpdatePoolsResponse,
37
- CheckBenefitEligibilityByFilterRequest: () => CheckBenefitEligibilityByFilterRequest,
38
- CheckBenefitEligibilityByFilterResponse: () => CheckBenefitEligibilityByFilterResponse,
39
37
  CheckBenefitEligibilityRequest: () => CheckBenefitEligibilityRequest,
40
38
  CheckBenefitEligibilityResponse: () => CheckBenefitEligibilityResponse,
41
39
  GetEligibleBenefitsRequest: () => GetEligibleBenefitsRequest,
@@ -1701,266 +1699,12 @@ var BulkUpdatePoolsResponse = z.object({
1701
1699
  ).optional()
1702
1700
  }).describe("Bulk action metadata.").optional()
1703
1701
  });
1704
- var CheckBenefitEligibilityByFilterRequest = z.object({
1705
- options: z.object({
1706
- poolFilter: z.object({
1707
- filter: z.record(z.string(), z.any()).describe(
1708
- "Filter object. See [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language) for more information.\n\nFor supported filterable and sortable fields, see [Filtering and Sorting](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/pools/filtering-and-sorting)."
1709
- ).optional().nullable(),
1710
- sort: z.array(
1711
- z.object({
1712
- fieldName: z.string().describe("Field to sort by.").max(512).optional(),
1713
- order: z.enum(["ASC", "DESC"]).optional()
1714
- })
1715
- ).max(5).optional()
1716
- }).describe(
1717
- "Defines filtering and sorting criteria used to select pools when checking eligibility.\n\nThe filter selects pools using the same fields supported by Query Pools. For field support, see [Filtering and Sorting](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/pools/filtering-and-sorting).\n\nWhen omitted, eligibility is checked across all pools in the namespace that match the provided `beneficiary`. Combined with `beneficiary` and `namespace`, the filter further narrows which pools are checked."
1718
- ).optional(),
1719
- namespace: z.string().describe(
1720
- "Namespace for your app or site's benefit programs. Namespaces allow you to distinguish between entities that you created and entities that other apps created."
1721
- ).min(1).max(20),
1722
- itemReference: z.object({
1723
- externalId: z.string().describe("External ID of the item.").regex(
1724
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1725
- "Must be a valid GUID"
1726
- ),
1727
- category: z.string().describe("Item category.").max(20).optional(),
1728
- providerAppId: z.string().describe("ID of the app providing the item.").regex(
1729
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1730
- "Must be a valid GUID"
1731
- )
1732
- }).describe("Information about the item to check."),
1733
- count: z.number().int().describe(
1734
- "Number of items to check.\n\nEnsures the balance is high enough to redeem this many items."
1735
- ).min(1),
1736
- targetDate: z.date().describe(
1737
- "Date that the item will be provided to the beneficiary.\n\nThis parameter should be used to manage the potential logistics of providing the item."
1738
- ).optional().nullable(),
1739
- beneficiary: z.intersection(
1740
- z.object({}),
1741
- z.xor([
1742
- z.object({
1743
- anonymousVisitorId: z.never().optional(),
1744
- memberId: z.never().optional(),
1745
- wixUserId: z.never().optional()
1746
- }),
1747
- z.object({
1748
- memberId: z.never().optional(),
1749
- wixUserId: z.never().optional(),
1750
- anonymousVisitorId: z.string().describe(
1751
- "ID of a site visitor that hasn't logged in to the site."
1752
- ).regex(
1753
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1754
- "Must be a valid GUID"
1755
- )
1756
- }),
1757
- z.object({
1758
- anonymousVisitorId: z.never().optional(),
1759
- wixUserId: z.never().optional(),
1760
- memberId: z.string().describe("ID of a site member.").regex(
1761
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1762
- "Must be a valid GUID"
1763
- )
1764
- }),
1765
- z.object({
1766
- anonymousVisitorId: z.never().optional(),
1767
- memberId: z.never().optional(),
1768
- wixUserId: z.string().describe("ID of a Wix user.").regex(
1769
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1770
- "Must be a valid GUID"
1771
- )
1772
- })
1773
- ])
1774
- ).describe(
1775
- "Pool beneficiary. When provided, only the beneficiary's pools that also match `pool_filter` are checked."
1776
- ).optional(),
1777
- additionalData: z.record(z.string(), z.any()).describe("Additional information.").optional().nullable()
1778
- })
1779
- });
1780
- var CheckBenefitEligibilityByFilterResponse = z.object({
1781
- results: z.array(
1782
- z.object({
1783
- benefitResults: z.array(
1784
- z.intersection(
1785
- z.object({
1786
- type: z.enum([
1787
- "ELIGIBLE_BENEFIT",
1788
- "NOT_ENOUGH_BALANCE",
1789
- "POOL_NOT_ACTIVE",
1790
- "BENEFIT_NOT_FOUND",
1791
- "POOL_NOT_FOUND"
1792
- ]).describe("Eligibility status.").optional()
1793
- }),
1794
- z.xor([
1795
- z.object({
1796
- eligibleBenefitOptions: z.never().optional(),
1797
- notEnoughBalanceOptions: z.never().optional(),
1798
- policyExpressionEvaluatedToFalseOptions: z.never().optional(),
1799
- poolNotActiveOptions: z.never().optional(),
1800
- benefitNotFoundOptions: z.never().optional(),
1801
- poolNotFoundOptions: z.never().optional()
1802
- }),
1803
- z.object({
1804
- notEnoughBalanceOptions: z.never().optional(),
1805
- policyExpressionEvaluatedToFalseOptions: z.never().optional(),
1806
- poolNotActiveOptions: z.never().optional(),
1807
- benefitNotFoundOptions: z.never().optional(),
1808
- poolNotFoundOptions: z.never().optional(),
1809
- eligibleBenefitOptions: z.object({
1810
- poolId: z.string().describe("Pool ID.").regex(
1811
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1812
- "Must be a valid GUID"
1813
- ).optional(),
1814
- benefitKey: z.string().describe("Benefit key.").max(64).optional(),
1815
- itemReference: z.object({
1816
- externalId: z.string().describe("External ID of the item.").regex(
1817
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1818
- "Must be a valid GUID"
1819
- ).optional(),
1820
- category: z.string().describe("Item category.").max(20).optional(),
1821
- providerAppId: z.string().describe("ID of the app providing the item.").regex(
1822
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1823
- "Must be a valid GUID"
1824
- ).optional()
1825
- }).describe("Item reference.").optional(),
1826
- price: z.string().describe("Price of the benefit in credits.").optional().nullable()
1827
- }).describe("Returned when item is eligible to be redeemed.")
1828
- }),
1829
- z.object({
1830
- eligibleBenefitOptions: z.never().optional(),
1831
- policyExpressionEvaluatedToFalseOptions: z.never().optional(),
1832
- poolNotActiveOptions: z.never().optional(),
1833
- benefitNotFoundOptions: z.never().optional(),
1834
- poolNotFoundOptions: z.never().optional(),
1835
- notEnoughBalanceOptions: z.object({
1836
- poolId: z.string().describe("Pool ID.").regex(
1837
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1838
- "Must be a valid GUID"
1839
- ).optional(),
1840
- itemReference: z.object({
1841
- externalId: z.string().describe("External ID of the item.").regex(
1842
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1843
- "Must be a valid GUID"
1844
- ).optional(),
1845
- category: z.string().describe("Item category.").max(20).optional(),
1846
- providerAppId: z.string().describe("ID of the app providing the item.").regex(
1847
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1848
- "Must be a valid GUID"
1849
- ).optional()
1850
- }).describe("Item reference.").optional(),
1851
- availableBalance: z.string().describe(
1852
- "Pool's associated balance amount in credits."
1853
- ).optional(),
1854
- requestedBalance: z.string().describe("Price of the item in credits.").optional()
1855
- }).describe(
1856
- "Returned when the pool's associated balance is lower than the cost of redeeming the items."
1857
- )
1858
- }),
1859
- z.object({
1860
- eligibleBenefitOptions: z.never().optional(),
1861
- notEnoughBalanceOptions: z.never().optional(),
1862
- poolNotActiveOptions: z.never().optional(),
1863
- benefitNotFoundOptions: z.never().optional(),
1864
- poolNotFoundOptions: z.never().optional(),
1865
- policyExpressionEvaluatedToFalseOptions: z.object({
1866
- poolId: z.string().describe("Pool ID.").regex(
1867
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1868
- "Must be a valid GUID"
1869
- ).optional(),
1870
- itemReference: z.object({
1871
- externalId: z.string().describe("External ID of the item.").regex(
1872
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1873
- "Must be a valid GUID"
1874
- ).optional(),
1875
- category: z.string().describe("Item category.").max(20).optional(),
1876
- providerAppId: z.string().describe("ID of the app providing the item.").regex(
1877
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1878
- "Must be a valid GUID"
1879
- ).optional()
1880
- }).describe("Item reference.").optional(),
1881
- failureDetails: z.array(
1882
- z.object({
1883
- code: z.string().describe("Failure code").min(1).max(64).optional(),
1884
- message: z.string().describe("Failure message").max(256).optional().nullable(),
1885
- policyId: z.string().describe("Policy id").regex(
1886
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1887
- "Must be a valid GUID"
1888
- ).optional().nullable(),
1889
- appId: z.string().describe("App that owns the policy").regex(
1890
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1891
- "Must be a valid GUID"
1892
- ).optional().nullable(),
1893
- errorData: z.record(z.string(), z.any()).describe("Information provided by the policy").optional().nullable()
1894
- })
1895
- ).max(10).optional()
1896
- }).describe("Returned when the policy is false.")
1897
- }),
1898
- z.object({
1899
- eligibleBenefitOptions: z.never().optional(),
1900
- notEnoughBalanceOptions: z.never().optional(),
1901
- policyExpressionEvaluatedToFalseOptions: z.never().optional(),
1902
- benefitNotFoundOptions: z.never().optional(),
1903
- poolNotFoundOptions: z.never().optional(),
1904
- poolNotActiveOptions: z.object({
1905
- poolId: z.string().describe("Pool ID.").regex(
1906
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1907
- "Must be a valid GUID"
1908
- ).optional(),
1909
- poolStatus: z.enum([
1910
- "ACTIVE",
1911
- "PAUSED",
1912
- "ENDED",
1913
- "PROVISIONING",
1914
- "RENEWING",
1915
- "PENDING"
1916
- ]).describe("Pool status.").optional()
1917
- }).describe("Returned when the pool isn't active.")
1918
- }),
1919
- z.object({
1920
- eligibleBenefitOptions: z.never().optional(),
1921
- notEnoughBalanceOptions: z.never().optional(),
1922
- policyExpressionEvaluatedToFalseOptions: z.never().optional(),
1923
- poolNotActiveOptions: z.never().optional(),
1924
- poolNotFoundOptions: z.never().optional(),
1925
- benefitNotFoundOptions: z.object({
1926
- poolId: z.string().describe("Pool ID.").regex(
1927
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1928
- "Must be a valid GUID"
1929
- ).optional(),
1930
- benefitKey: z.string().describe("Specified benefit key.").max(64).optional().nullable()
1931
- }).describe(
1932
- "Returned when invalid benefit details are provided."
1933
- )
1934
- }),
1935
- z.object({
1936
- eligibleBenefitOptions: z.never().optional(),
1937
- notEnoughBalanceOptions: z.never().optional(),
1938
- policyExpressionEvaluatedToFalseOptions: z.never().optional(),
1939
- poolNotActiveOptions: z.never().optional(),
1940
- benefitNotFoundOptions: z.never().optional(),
1941
- poolNotFoundOptions: z.object({
1942
- poolId: z.string().describe("Pool ID.").regex(
1943
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1944
- "Must be a valid GUID"
1945
- ).optional()
1946
- }).describe(
1947
- "Returned when invalid pool details are provided."
1948
- )
1949
- })
1950
- ])
1951
- )
1952
- ).max(10).optional()
1953
- })
1954
- ).max(100).optional()
1955
- });
1956
1702
  // Annotate the CommonJS export names for ESM import in node:
1957
1703
  0 && (module.exports = {
1958
1704
  BulkCheckBenefitEligibilityRequest,
1959
1705
  BulkCheckBenefitEligibilityResponse,
1960
1706
  BulkUpdatePoolsRequest,
1961
1707
  BulkUpdatePoolsResponse,
1962
- CheckBenefitEligibilityByFilterRequest,
1963
- CheckBenefitEligibilityByFilterResponse,
1964
1708
  CheckBenefitEligibilityRequest,
1965
1709
  CheckBenefitEligibilityResponse,
1966
1710
  GetEligibleBenefitsRequest,