@seamapi/http 1.73.0 → 1.75.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.
Files changed (78) hide show
  1. package/dist/connect.cjs +478 -5
  2. package/dist/connect.cjs.map +1 -1
  3. package/dist/connect.d.cts +169 -3
  4. package/dist/index.cjs +486 -5
  5. package/dist/index.cjs.map +1 -1
  6. package/dist/index.d.cts +1 -1
  7. package/lib/seam/connect/routes/access-grants/access-grants.d.ts +2 -0
  8. package/lib/seam/connect/routes/access-grants/access-grants.js +4 -0
  9. package/lib/seam/connect/routes/access-grants/access-grants.js.map +1 -1
  10. package/lib/seam/connect/routes/access-grants/index.d.ts +1 -0
  11. package/lib/seam/connect/routes/access-grants/index.js +1 -0
  12. package/lib/seam/connect/routes/access-grants/index.js.map +1 -1
  13. package/lib/seam/connect/routes/access-grants/unmanaged/index.d.ts +1 -0
  14. package/lib/seam/connect/routes/access-grants/unmanaged/index.js +6 -0
  15. package/lib/seam/connect/routes/access-grants/unmanaged/index.js.map +1 -0
  16. package/lib/seam/connect/routes/access-grants/unmanaged/unmanaged.d.ts +47 -0
  17. package/lib/seam/connect/routes/access-grants/unmanaged/unmanaged.js +107 -0
  18. package/lib/seam/connect/routes/access-grants/unmanaged/unmanaged.js.map +1 -0
  19. package/lib/seam/connect/routes/access-methods/access-methods.d.ts +2 -0
  20. package/lib/seam/connect/routes/access-methods/access-methods.js +4 -0
  21. package/lib/seam/connect/routes/access-methods/access-methods.js.map +1 -1
  22. package/lib/seam/connect/routes/access-methods/index.d.ts +1 -0
  23. package/lib/seam/connect/routes/access-methods/index.js +1 -0
  24. package/lib/seam/connect/routes/access-methods/index.js.map +1 -1
  25. package/lib/seam/connect/routes/access-methods/unmanaged/index.d.ts +1 -0
  26. package/lib/seam/connect/routes/access-methods/unmanaged/index.js +6 -0
  27. package/lib/seam/connect/routes/access-methods/unmanaged/index.js.map +1 -0
  28. package/lib/seam/connect/routes/access-methods/unmanaged/unmanaged.d.ts +47 -0
  29. package/lib/seam/connect/routes/access-methods/unmanaged/unmanaged.js +107 -0
  30. package/lib/seam/connect/routes/access-methods/unmanaged/unmanaged.js.map +1 -0
  31. package/lib/seam/connect/routes/seam/customer/v1/index.d.ts +1 -0
  32. package/lib/seam/connect/routes/seam/customer/v1/index.js +1 -0
  33. package/lib/seam/connect/routes/seam/customer/v1/index.js.map +1 -1
  34. package/lib/seam/connect/routes/seam/customer/v1/spaces/index.d.ts +1 -0
  35. package/lib/seam/connect/routes/seam/customer/v1/spaces/index.js +6 -0
  36. package/lib/seam/connect/routes/seam/customer/v1/spaces/index.js.map +1 -0
  37. package/lib/seam/connect/routes/seam/customer/v1/spaces/spaces.d.ts +34 -0
  38. package/lib/seam/connect/routes/seam/customer/v1/spaces/spaces.js +98 -0
  39. package/lib/seam/connect/routes/seam/customer/v1/spaces/spaces.js.map +1 -0
  40. package/lib/seam/connect/routes/seam/customer/v1/v1.d.ts +2 -0
  41. package/lib/seam/connect/routes/seam/customer/v1/v1.js +4 -3
  42. package/lib/seam/connect/routes/seam/customer/v1/v1.js.map +1 -1
  43. package/lib/seam/connect/routes/seam-http-endpoints.d.ts +13 -2
  44. package/lib/seam/connect/routes/seam-http-endpoints.js +53 -0
  45. package/lib/seam/connect/routes/seam-http-endpoints.js.map +1 -1
  46. package/lib/seam/connect/routes/user-identities/index.d.ts +1 -0
  47. package/lib/seam/connect/routes/user-identities/index.js +1 -0
  48. package/lib/seam/connect/routes/user-identities/index.js.map +1 -1
  49. package/lib/seam/connect/routes/user-identities/unmanaged/index.d.ts +1 -0
  50. package/lib/seam/connect/routes/user-identities/unmanaged/index.js +6 -0
  51. package/lib/seam/connect/routes/user-identities/unmanaged/index.js.map +1 -0
  52. package/lib/seam/connect/routes/user-identities/unmanaged/unmanaged.d.ts +47 -0
  53. package/lib/seam/connect/routes/user-identities/unmanaged/unmanaged.js +107 -0
  54. package/lib/seam/connect/routes/user-identities/unmanaged/unmanaged.js.map +1 -0
  55. package/lib/seam/connect/routes/user-identities/user-identities.d.ts +2 -0
  56. package/lib/seam/connect/routes/user-identities/user-identities.js +4 -0
  57. package/lib/seam/connect/routes/user-identities/user-identities.js.map +1 -1
  58. package/lib/version.d.ts +1 -1
  59. package/lib/version.js +1 -1
  60. package/package.json +3 -3
  61. package/src/lib/seam/connect/routes/access-grants/access-grants.ts +6 -0
  62. package/src/lib/seam/connect/routes/access-grants/index.ts +1 -0
  63. package/src/lib/seam/connect/routes/access-grants/unmanaged/index.ts +6 -0
  64. package/src/lib/seam/connect/routes/access-grants/unmanaged/unmanaged.ts +236 -0
  65. package/src/lib/seam/connect/routes/access-methods/access-methods.ts +6 -0
  66. package/src/lib/seam/connect/routes/access-methods/index.ts +1 -0
  67. package/src/lib/seam/connect/routes/access-methods/unmanaged/index.ts +6 -0
  68. package/src/lib/seam/connect/routes/access-methods/unmanaged/unmanaged.ts +237 -0
  69. package/src/lib/seam/connect/routes/seam/customer/v1/index.ts +1 -0
  70. package/src/lib/seam/connect/routes/seam/customer/v1/spaces/index.ts +6 -0
  71. package/src/lib/seam/connect/routes/seam/customer/v1/spaces/spaces.ts +201 -0
  72. package/src/lib/seam/connect/routes/seam/customer/v1/v1.ts +5 -5
  73. package/src/lib/seam/connect/routes/seam-http-endpoints.ts +131 -0
  74. package/src/lib/seam/connect/routes/user-identities/index.ts +1 -0
  75. package/src/lib/seam/connect/routes/user-identities/unmanaged/index.ts +6 -0
  76. package/src/lib/seam/connect/routes/user-identities/unmanaged/unmanaged.ts +240 -0
  77. package/src/lib/seam/connect/routes/user-identities/user-identities.ts +8 -0
  78. package/src/lib/version.ts +1 -1
package/dist/index.cjs CHANGED
@@ -57,7 +57,9 @@ __export(index_exports, {
57
57
  SeamHttpAccessCodesSimulate: () => SeamHttpAccessCodesSimulate,
58
58
  SeamHttpAccessCodesUnmanaged: () => SeamHttpAccessCodesUnmanaged,
59
59
  SeamHttpAccessGrants: () => SeamHttpAccessGrants,
60
+ SeamHttpAccessGrantsUnmanaged: () => SeamHttpAccessGrantsUnmanaged,
60
61
  SeamHttpAccessMethods: () => SeamHttpAccessMethods,
62
+ SeamHttpAccessMethodsUnmanaged: () => SeamHttpAccessMethodsUnmanaged,
61
63
  SeamHttpAcs: () => SeamHttpAcs,
62
64
  SeamHttpAcsAccessGroups: () => SeamHttpAcsAccessGroups,
63
65
  SeamHttpAcsAccessGroupsUnmanaged: () => SeamHttpAcsAccessGroupsUnmanaged,
@@ -107,6 +109,7 @@ __export(index_exports, {
107
109
  SeamHttpSeamCustomerV1Portals: () => SeamHttpSeamCustomerV1Portals,
108
110
  SeamHttpSeamCustomerV1Reservations: () => SeamHttpSeamCustomerV1Reservations,
109
111
  SeamHttpSeamCustomerV1Settings: () => SeamHttpSeamCustomerV1Settings,
112
+ SeamHttpSeamCustomerV1Spaces: () => SeamHttpSeamCustomerV1Spaces,
110
113
  SeamHttpSeamPartnerV1BuildingBlocks: () => SeamHttpSeamPartnerV1BuildingBlocks,
111
114
  SeamHttpSeamPartnerV1BuildingBlocksSpaces: () => SeamHttpSeamPartnerV1BuildingBlocksSpaces,
112
115
  SeamHttpSpaces: () => SeamHttpSpaces,
@@ -119,6 +122,7 @@ __export(index_exports, {
119
122
  SeamHttpUnstablePartnerBuildingBlocks: () => SeamHttpUnstablePartnerBuildingBlocks,
120
123
  SeamHttpUserIdentities: () => SeamHttpUserIdentities,
121
124
  SeamHttpUserIdentitiesEnrollmentAutomations: () => SeamHttpUserIdentitiesEnrollmentAutomations,
125
+ SeamHttpUserIdentitiesUnmanaged: () => SeamHttpUserIdentitiesUnmanaged,
122
126
  SeamHttpWebhooks: () => SeamHttpWebhooks,
123
127
  SeamHttpWithoutWorkspace: () => SeamHttpWithoutWorkspace,
124
128
  SeamHttpWithoutWorkspaceInvalidOptionsError: () => SeamHttpWithoutWorkspaceInvalidOptionsError,
@@ -159,7 +163,9 @@ __export(connect_exports, {
159
163
  SeamHttpAccessCodesSimulate: () => SeamHttpAccessCodesSimulate,
160
164
  SeamHttpAccessCodesUnmanaged: () => SeamHttpAccessCodesUnmanaged,
161
165
  SeamHttpAccessGrants: () => SeamHttpAccessGrants,
166
+ SeamHttpAccessGrantsUnmanaged: () => SeamHttpAccessGrantsUnmanaged,
162
167
  SeamHttpAccessMethods: () => SeamHttpAccessMethods,
168
+ SeamHttpAccessMethodsUnmanaged: () => SeamHttpAccessMethodsUnmanaged,
163
169
  SeamHttpAcs: () => SeamHttpAcs,
164
170
  SeamHttpAcsAccessGroups: () => SeamHttpAcsAccessGroups,
165
171
  SeamHttpAcsAccessGroupsUnmanaged: () => SeamHttpAcsAccessGroupsUnmanaged,
@@ -209,6 +215,7 @@ __export(connect_exports, {
209
215
  SeamHttpSeamCustomerV1Portals: () => SeamHttpSeamCustomerV1Portals,
210
216
  SeamHttpSeamCustomerV1Reservations: () => SeamHttpSeamCustomerV1Reservations,
211
217
  SeamHttpSeamCustomerV1Settings: () => SeamHttpSeamCustomerV1Settings,
218
+ SeamHttpSeamCustomerV1Spaces: () => SeamHttpSeamCustomerV1Spaces,
212
219
  SeamHttpSeamPartnerV1BuildingBlocks: () => SeamHttpSeamPartnerV1BuildingBlocks,
213
220
  SeamHttpSeamPartnerV1BuildingBlocksSpaces: () => SeamHttpSeamPartnerV1BuildingBlocksSpaces,
214
221
  SeamHttpSpaces: () => SeamHttpSpaces,
@@ -221,6 +228,7 @@ __export(connect_exports, {
221
228
  SeamHttpUnstablePartnerBuildingBlocks: () => SeamHttpUnstablePartnerBuildingBlocks,
222
229
  SeamHttpUserIdentities: () => SeamHttpUserIdentities,
223
230
  SeamHttpUserIdentitiesEnrollmentAutomations: () => SeamHttpUserIdentitiesEnrollmentAutomations,
231
+ SeamHttpUserIdentitiesUnmanaged: () => SeamHttpUserIdentitiesUnmanaged,
224
232
  SeamHttpWebhooks: () => SeamHttpWebhooks,
225
233
  SeamHttpWithoutWorkspace: () => SeamHttpWithoutWorkspace,
226
234
  SeamHttpWithoutWorkspaceInvalidOptionsError: () => SeamHttpWithoutWorkspaceInvalidOptionsError,
@@ -1633,6 +1641,110 @@ var SeamHttpAccessCodes = class _SeamHttpAccessCodes {
1633
1641
  }
1634
1642
  };
1635
1643
 
1644
+ // src/lib/seam/connect/routes/access-grants/unmanaged/unmanaged.ts
1645
+ var SeamHttpAccessGrantsUnmanaged = class _SeamHttpAccessGrantsUnmanaged {
1646
+ client;
1647
+ defaults;
1648
+ ltsVersion = seamApiLtsVersion;
1649
+ static ltsVersion = seamApiLtsVersion;
1650
+ constructor(apiKeyOrOptions = {}) {
1651
+ const options = parseOptions(apiKeyOrOptions);
1652
+ this.client = "client" in options ? options.client : createClient(options);
1653
+ this.defaults = limitToSeamHttpRequestOptions(options);
1654
+ }
1655
+ static fromClient(client, options = {}) {
1656
+ const constructorOptions = { ...options, client };
1657
+ if (!isSeamHttpOptionsWithClient(constructorOptions)) {
1658
+ throw new SeamHttpInvalidOptionsError("Missing client");
1659
+ }
1660
+ return new _SeamHttpAccessGrantsUnmanaged(constructorOptions);
1661
+ }
1662
+ static fromApiKey(apiKey, options = {}) {
1663
+ const constructorOptions = { ...options, apiKey };
1664
+ if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {
1665
+ throw new SeamHttpInvalidOptionsError("Missing apiKey");
1666
+ }
1667
+ return new _SeamHttpAccessGrantsUnmanaged(constructorOptions);
1668
+ }
1669
+ static fromClientSessionToken(clientSessionToken, options = {}) {
1670
+ const constructorOptions = { ...options, clientSessionToken };
1671
+ if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {
1672
+ throw new SeamHttpInvalidOptionsError("Missing clientSessionToken");
1673
+ }
1674
+ return new _SeamHttpAccessGrantsUnmanaged(constructorOptions);
1675
+ }
1676
+ static async fromPublishableKey(publishableKey, userIdentifierKey, options = {}) {
1677
+ warnOnInsecureuserIdentifierKey(userIdentifierKey);
1678
+ const clientOptions = parseOptions({ ...options, publishableKey });
1679
+ if (isSeamHttpOptionsWithClient(clientOptions)) {
1680
+ throw new SeamHttpInvalidOptionsError(
1681
+ "The client option cannot be used with SeamHttpAccessGrantsUnmanaged.fromPublishableKey"
1682
+ );
1683
+ }
1684
+ const client = createClient(clientOptions);
1685
+ const clientSessions = SeamHttpClientSessions.fromClient(client);
1686
+ const { token } = await clientSessions.getOrCreate({
1687
+ user_identifier_key: userIdentifierKey
1688
+ });
1689
+ return _SeamHttpAccessGrantsUnmanaged.fromClientSessionToken(token, options);
1690
+ }
1691
+ static fromConsoleSessionToken(consoleSessionToken, workspaceId, options = {}) {
1692
+ const constructorOptions = { ...options, consoleSessionToken, workspaceId };
1693
+ if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {
1694
+ throw new SeamHttpInvalidOptionsError(
1695
+ "Missing consoleSessionToken or workspaceId"
1696
+ );
1697
+ }
1698
+ return new _SeamHttpAccessGrantsUnmanaged(constructorOptions);
1699
+ }
1700
+ static fromPersonalAccessToken(personalAccessToken, workspaceId, options = {}) {
1701
+ const constructorOptions = { ...options, personalAccessToken, workspaceId };
1702
+ if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {
1703
+ throw new SeamHttpInvalidOptionsError(
1704
+ "Missing personalAccessToken or workspaceId"
1705
+ );
1706
+ }
1707
+ return new _SeamHttpAccessGrantsUnmanaged(constructorOptions);
1708
+ }
1709
+ createPaginator(request) {
1710
+ return new SeamPaginator(this, request);
1711
+ }
1712
+ async updateClientSessionToken(clientSessionToken) {
1713
+ const { headers } = this.client.defaults;
1714
+ const authHeaders = getAuthHeadersForClientSessionToken({
1715
+ clientSessionToken
1716
+ });
1717
+ for (const key of Object.keys(authHeaders)) {
1718
+ if (headers[key] == null) {
1719
+ throw new Error(
1720
+ "Cannot update a clientSessionToken on a client created without a clientSessionToken"
1721
+ );
1722
+ }
1723
+ }
1724
+ this.client.defaults.headers = { ...headers, ...authHeaders };
1725
+ const clientSessions = SeamHttpClientSessions.fromClient(this.client);
1726
+ await clientSessions.get();
1727
+ }
1728
+ get(parameters, options = {}) {
1729
+ return new SeamHttpRequest(this, {
1730
+ pathname: "/access_grants/unmanaged/get",
1731
+ method: "POST",
1732
+ body: parameters,
1733
+ responseKey: "access_grant",
1734
+ options
1735
+ });
1736
+ }
1737
+ list(parameters, options = {}) {
1738
+ return new SeamHttpRequest(this, {
1739
+ pathname: "/access_grants/unmanaged/list",
1740
+ method: "POST",
1741
+ body: parameters,
1742
+ responseKey: "access_grants",
1743
+ options
1744
+ });
1745
+ }
1746
+ };
1747
+
1636
1748
  // src/lib/seam/connect/routes/access-grants/access-grants.ts
1637
1749
  var SeamHttpAccessGrants = class _SeamHttpAccessGrants {
1638
1750
  client;
@@ -1717,6 +1829,9 @@ var SeamHttpAccessGrants = class _SeamHttpAccessGrants {
1717
1829
  const clientSessions = SeamHttpClientSessions.fromClient(this.client);
1718
1830
  await clientSessions.get();
1719
1831
  }
1832
+ get unmanaged() {
1833
+ return SeamHttpAccessGrantsUnmanaged.fromClient(this.client, this.defaults);
1834
+ }
1720
1835
  create(parameters, options = {}) {
1721
1836
  return new SeamHttpRequest(this, {
1722
1837
  pathname: "/access_grants/create",
@@ -1773,6 +1888,110 @@ var SeamHttpAccessGrants = class _SeamHttpAccessGrants {
1773
1888
  }
1774
1889
  };
1775
1890
 
1891
+ // src/lib/seam/connect/routes/access-methods/unmanaged/unmanaged.ts
1892
+ var SeamHttpAccessMethodsUnmanaged = class _SeamHttpAccessMethodsUnmanaged {
1893
+ client;
1894
+ defaults;
1895
+ ltsVersion = seamApiLtsVersion;
1896
+ static ltsVersion = seamApiLtsVersion;
1897
+ constructor(apiKeyOrOptions = {}) {
1898
+ const options = parseOptions(apiKeyOrOptions);
1899
+ this.client = "client" in options ? options.client : createClient(options);
1900
+ this.defaults = limitToSeamHttpRequestOptions(options);
1901
+ }
1902
+ static fromClient(client, options = {}) {
1903
+ const constructorOptions = { ...options, client };
1904
+ if (!isSeamHttpOptionsWithClient(constructorOptions)) {
1905
+ throw new SeamHttpInvalidOptionsError("Missing client");
1906
+ }
1907
+ return new _SeamHttpAccessMethodsUnmanaged(constructorOptions);
1908
+ }
1909
+ static fromApiKey(apiKey, options = {}) {
1910
+ const constructorOptions = { ...options, apiKey };
1911
+ if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {
1912
+ throw new SeamHttpInvalidOptionsError("Missing apiKey");
1913
+ }
1914
+ return new _SeamHttpAccessMethodsUnmanaged(constructorOptions);
1915
+ }
1916
+ static fromClientSessionToken(clientSessionToken, options = {}) {
1917
+ const constructorOptions = { ...options, clientSessionToken };
1918
+ if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {
1919
+ throw new SeamHttpInvalidOptionsError("Missing clientSessionToken");
1920
+ }
1921
+ return new _SeamHttpAccessMethodsUnmanaged(constructorOptions);
1922
+ }
1923
+ static async fromPublishableKey(publishableKey, userIdentifierKey, options = {}) {
1924
+ warnOnInsecureuserIdentifierKey(userIdentifierKey);
1925
+ const clientOptions = parseOptions({ ...options, publishableKey });
1926
+ if (isSeamHttpOptionsWithClient(clientOptions)) {
1927
+ throw new SeamHttpInvalidOptionsError(
1928
+ "The client option cannot be used with SeamHttpAccessMethodsUnmanaged.fromPublishableKey"
1929
+ );
1930
+ }
1931
+ const client = createClient(clientOptions);
1932
+ const clientSessions = SeamHttpClientSessions.fromClient(client);
1933
+ const { token } = await clientSessions.getOrCreate({
1934
+ user_identifier_key: userIdentifierKey
1935
+ });
1936
+ return _SeamHttpAccessMethodsUnmanaged.fromClientSessionToken(token, options);
1937
+ }
1938
+ static fromConsoleSessionToken(consoleSessionToken, workspaceId, options = {}) {
1939
+ const constructorOptions = { ...options, consoleSessionToken, workspaceId };
1940
+ if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {
1941
+ throw new SeamHttpInvalidOptionsError(
1942
+ "Missing consoleSessionToken or workspaceId"
1943
+ );
1944
+ }
1945
+ return new _SeamHttpAccessMethodsUnmanaged(constructorOptions);
1946
+ }
1947
+ static fromPersonalAccessToken(personalAccessToken, workspaceId, options = {}) {
1948
+ const constructorOptions = { ...options, personalAccessToken, workspaceId };
1949
+ if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {
1950
+ throw new SeamHttpInvalidOptionsError(
1951
+ "Missing personalAccessToken or workspaceId"
1952
+ );
1953
+ }
1954
+ return new _SeamHttpAccessMethodsUnmanaged(constructorOptions);
1955
+ }
1956
+ createPaginator(request) {
1957
+ return new SeamPaginator(this, request);
1958
+ }
1959
+ async updateClientSessionToken(clientSessionToken) {
1960
+ const { headers } = this.client.defaults;
1961
+ const authHeaders = getAuthHeadersForClientSessionToken({
1962
+ clientSessionToken
1963
+ });
1964
+ for (const key of Object.keys(authHeaders)) {
1965
+ if (headers[key] == null) {
1966
+ throw new Error(
1967
+ "Cannot update a clientSessionToken on a client created without a clientSessionToken"
1968
+ );
1969
+ }
1970
+ }
1971
+ this.client.defaults.headers = { ...headers, ...authHeaders };
1972
+ const clientSessions = SeamHttpClientSessions.fromClient(this.client);
1973
+ await clientSessions.get();
1974
+ }
1975
+ get(parameters, options = {}) {
1976
+ return new SeamHttpRequest(this, {
1977
+ pathname: "/access_methods/unmanaged/get",
1978
+ method: "POST",
1979
+ body: parameters,
1980
+ responseKey: "access_method",
1981
+ options
1982
+ });
1983
+ }
1984
+ list(parameters, options = {}) {
1985
+ return new SeamHttpRequest(this, {
1986
+ pathname: "/access_methods/unmanaged/list",
1987
+ method: "POST",
1988
+ body: parameters,
1989
+ responseKey: "access_methods",
1990
+ options
1991
+ });
1992
+ }
1993
+ };
1994
+
1776
1995
  // src/lib/seam/connect/routes/access-methods/access-methods.ts
1777
1996
  var SeamHttpAccessMethods = class _SeamHttpAccessMethods {
1778
1997
  client;
@@ -1857,6 +2076,9 @@ var SeamHttpAccessMethods = class _SeamHttpAccessMethods {
1857
2076
  const clientSessions = SeamHttpClientSessions.fromClient(this.client);
1858
2077
  await clientSessions.get();
1859
2078
  }
2079
+ get unmanaged() {
2080
+ return SeamHttpAccessMethodsUnmanaged.fromClient(this.client, this.defaults);
2081
+ }
1860
2082
  delete(parameters, options = {}) {
1861
2083
  return new SeamHttpRequest(this, {
1862
2084
  pathname: "/access_methods/delete",
@@ -6563,19 +6785,109 @@ var SeamHttpSeamCustomerV1Settings = class _SeamHttpSeamCustomerV1Settings {
6563
6785
  }
6564
6786
  };
6565
6787
 
6566
- // src/lib/seam/connect/routes/seam/customer/v1/v1.ts
6567
- var SeamHttpSeamCustomerV1 = class _SeamHttpSeamCustomerV1 {
6788
+ // src/lib/seam/connect/routes/seam/customer/v1/spaces/spaces.ts
6789
+ var SeamHttpSeamCustomerV1Spaces = class _SeamHttpSeamCustomerV1Spaces {
6568
6790
  client;
6569
6791
  defaults;
6570
6792
  ltsVersion = seamApiLtsVersion;
6571
6793
  static ltsVersion = seamApiLtsVersion;
6572
6794
  constructor(apiKeyOrOptions = {}) {
6573
6795
  const options = parseOptions(apiKeyOrOptions);
6574
- if (!options.isUndocumentedApiEnabled) {
6575
- throw new Error(
6576
- "Cannot use undocumented API without isUndocumentedApiEnabled"
6796
+ this.client = "client" in options ? options.client : createClient(options);
6797
+ this.defaults = limitToSeamHttpRequestOptions(options);
6798
+ }
6799
+ static fromClient(client, options = {}) {
6800
+ const constructorOptions = { ...options, client };
6801
+ if (!isSeamHttpOptionsWithClient(constructorOptions)) {
6802
+ throw new SeamHttpInvalidOptionsError("Missing client");
6803
+ }
6804
+ return new _SeamHttpSeamCustomerV1Spaces(constructorOptions);
6805
+ }
6806
+ static fromApiKey(apiKey, options = {}) {
6807
+ const constructorOptions = { ...options, apiKey };
6808
+ if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {
6809
+ throw new SeamHttpInvalidOptionsError("Missing apiKey");
6810
+ }
6811
+ return new _SeamHttpSeamCustomerV1Spaces(constructorOptions);
6812
+ }
6813
+ static fromClientSessionToken(clientSessionToken, options = {}) {
6814
+ const constructorOptions = { ...options, clientSessionToken };
6815
+ if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {
6816
+ throw new SeamHttpInvalidOptionsError("Missing clientSessionToken");
6817
+ }
6818
+ return new _SeamHttpSeamCustomerV1Spaces(constructorOptions);
6819
+ }
6820
+ static async fromPublishableKey(publishableKey, userIdentifierKey, options = {}) {
6821
+ warnOnInsecureuserIdentifierKey(userIdentifierKey);
6822
+ const clientOptions = parseOptions({ ...options, publishableKey });
6823
+ if (isSeamHttpOptionsWithClient(clientOptions)) {
6824
+ throw new SeamHttpInvalidOptionsError(
6825
+ "The client option cannot be used with SeamHttpSeamCustomerV1Spaces.fromPublishableKey"
6826
+ );
6827
+ }
6828
+ const client = createClient(clientOptions);
6829
+ const clientSessions = SeamHttpClientSessions.fromClient(client);
6830
+ const { token } = await clientSessions.getOrCreate({
6831
+ user_identifier_key: userIdentifierKey
6832
+ });
6833
+ return _SeamHttpSeamCustomerV1Spaces.fromClientSessionToken(token, options);
6834
+ }
6835
+ static fromConsoleSessionToken(consoleSessionToken, workspaceId, options = {}) {
6836
+ const constructorOptions = { ...options, consoleSessionToken, workspaceId };
6837
+ if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {
6838
+ throw new SeamHttpInvalidOptionsError(
6839
+ "Missing consoleSessionToken or workspaceId"
6577
6840
  );
6578
6841
  }
6842
+ return new _SeamHttpSeamCustomerV1Spaces(constructorOptions);
6843
+ }
6844
+ static fromPersonalAccessToken(personalAccessToken, workspaceId, options = {}) {
6845
+ const constructorOptions = { ...options, personalAccessToken, workspaceId };
6846
+ if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {
6847
+ throw new SeamHttpInvalidOptionsError(
6848
+ "Missing personalAccessToken or workspaceId"
6849
+ );
6850
+ }
6851
+ return new _SeamHttpSeamCustomerV1Spaces(constructorOptions);
6852
+ }
6853
+ createPaginator(request) {
6854
+ return new SeamPaginator(this, request);
6855
+ }
6856
+ async updateClientSessionToken(clientSessionToken) {
6857
+ const { headers } = this.client.defaults;
6858
+ const authHeaders = getAuthHeadersForClientSessionToken({
6859
+ clientSessionToken
6860
+ });
6861
+ for (const key of Object.keys(authHeaders)) {
6862
+ if (headers[key] == null) {
6863
+ throw new Error(
6864
+ "Cannot update a clientSessionToken on a client created without a clientSessionToken"
6865
+ );
6866
+ }
6867
+ }
6868
+ this.client.defaults.headers = { ...headers, ...authHeaders };
6869
+ const clientSessions = SeamHttpClientSessions.fromClient(this.client);
6870
+ await clientSessions.get();
6871
+ }
6872
+ create(parameters, options = {}) {
6873
+ return new SeamHttpRequest(this, {
6874
+ pathname: "/seam/customer/v1/spaces/create",
6875
+ method: "POST",
6876
+ body: parameters,
6877
+ responseKey: "space",
6878
+ options
6879
+ });
6880
+ }
6881
+ };
6882
+
6883
+ // src/lib/seam/connect/routes/seam/customer/v1/v1.ts
6884
+ var SeamHttpSeamCustomerV1 = class _SeamHttpSeamCustomerV1 {
6885
+ client;
6886
+ defaults;
6887
+ ltsVersion = seamApiLtsVersion;
6888
+ static ltsVersion = seamApiLtsVersion;
6889
+ constructor(apiKeyOrOptions = {}) {
6890
+ const options = parseOptions(apiKeyOrOptions);
6579
6891
  this.client = "client" in options ? options.client : createClient(options);
6580
6892
  this.defaults = limitToSeamHttpRequestOptions(options);
6581
6893
  }
@@ -6679,6 +6991,9 @@ var SeamHttpSeamCustomerV1 = class _SeamHttpSeamCustomerV1 {
6679
6991
  get settings() {
6680
6992
  return SeamHttpSeamCustomerV1Settings.fromClient(this.client, this.defaults);
6681
6993
  }
6994
+ get spaces() {
6995
+ return SeamHttpSeamCustomerV1Spaces.fromClient(this.client, this.defaults);
6996
+ }
6682
6997
  };
6683
6998
 
6684
6999
  // src/lib/seam/connect/routes/seam/partner/v1/building-blocks/spaces/spaces.ts
@@ -8051,6 +8366,113 @@ var SeamHttpUserIdentitiesEnrollmentAutomations = class _SeamHttpUserIdentitiesE
8051
8366
  }
8052
8367
  };
8053
8368
 
8369
+ // src/lib/seam/connect/routes/user-identities/unmanaged/unmanaged.ts
8370
+ var SeamHttpUserIdentitiesUnmanaged = class _SeamHttpUserIdentitiesUnmanaged {
8371
+ client;
8372
+ defaults;
8373
+ ltsVersion = seamApiLtsVersion;
8374
+ static ltsVersion = seamApiLtsVersion;
8375
+ constructor(apiKeyOrOptions = {}) {
8376
+ const options = parseOptions(apiKeyOrOptions);
8377
+ this.client = "client" in options ? options.client : createClient(options);
8378
+ this.defaults = limitToSeamHttpRequestOptions(options);
8379
+ }
8380
+ static fromClient(client, options = {}) {
8381
+ const constructorOptions = { ...options, client };
8382
+ if (!isSeamHttpOptionsWithClient(constructorOptions)) {
8383
+ throw new SeamHttpInvalidOptionsError("Missing client");
8384
+ }
8385
+ return new _SeamHttpUserIdentitiesUnmanaged(constructorOptions);
8386
+ }
8387
+ static fromApiKey(apiKey, options = {}) {
8388
+ const constructorOptions = { ...options, apiKey };
8389
+ if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {
8390
+ throw new SeamHttpInvalidOptionsError("Missing apiKey");
8391
+ }
8392
+ return new _SeamHttpUserIdentitiesUnmanaged(constructorOptions);
8393
+ }
8394
+ static fromClientSessionToken(clientSessionToken, options = {}) {
8395
+ const constructorOptions = { ...options, clientSessionToken };
8396
+ if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {
8397
+ throw new SeamHttpInvalidOptionsError("Missing clientSessionToken");
8398
+ }
8399
+ return new _SeamHttpUserIdentitiesUnmanaged(constructorOptions);
8400
+ }
8401
+ static async fromPublishableKey(publishableKey, userIdentifierKey, options = {}) {
8402
+ warnOnInsecureuserIdentifierKey(userIdentifierKey);
8403
+ const clientOptions = parseOptions({ ...options, publishableKey });
8404
+ if (isSeamHttpOptionsWithClient(clientOptions)) {
8405
+ throw new SeamHttpInvalidOptionsError(
8406
+ "The client option cannot be used with SeamHttpUserIdentitiesUnmanaged.fromPublishableKey"
8407
+ );
8408
+ }
8409
+ const client = createClient(clientOptions);
8410
+ const clientSessions = SeamHttpClientSessions.fromClient(client);
8411
+ const { token } = await clientSessions.getOrCreate({
8412
+ user_identifier_key: userIdentifierKey
8413
+ });
8414
+ return _SeamHttpUserIdentitiesUnmanaged.fromClientSessionToken(
8415
+ token,
8416
+ options
8417
+ );
8418
+ }
8419
+ static fromConsoleSessionToken(consoleSessionToken, workspaceId, options = {}) {
8420
+ const constructorOptions = { ...options, consoleSessionToken, workspaceId };
8421
+ if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {
8422
+ throw new SeamHttpInvalidOptionsError(
8423
+ "Missing consoleSessionToken or workspaceId"
8424
+ );
8425
+ }
8426
+ return new _SeamHttpUserIdentitiesUnmanaged(constructorOptions);
8427
+ }
8428
+ static fromPersonalAccessToken(personalAccessToken, workspaceId, options = {}) {
8429
+ const constructorOptions = { ...options, personalAccessToken, workspaceId };
8430
+ if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {
8431
+ throw new SeamHttpInvalidOptionsError(
8432
+ "Missing personalAccessToken or workspaceId"
8433
+ );
8434
+ }
8435
+ return new _SeamHttpUserIdentitiesUnmanaged(constructorOptions);
8436
+ }
8437
+ createPaginator(request) {
8438
+ return new SeamPaginator(this, request);
8439
+ }
8440
+ async updateClientSessionToken(clientSessionToken) {
8441
+ const { headers } = this.client.defaults;
8442
+ const authHeaders = getAuthHeadersForClientSessionToken({
8443
+ clientSessionToken
8444
+ });
8445
+ for (const key of Object.keys(authHeaders)) {
8446
+ if (headers[key] == null) {
8447
+ throw new Error(
8448
+ "Cannot update a clientSessionToken on a client created without a clientSessionToken"
8449
+ );
8450
+ }
8451
+ }
8452
+ this.client.defaults.headers = { ...headers, ...authHeaders };
8453
+ const clientSessions = SeamHttpClientSessions.fromClient(this.client);
8454
+ await clientSessions.get();
8455
+ }
8456
+ get(parameters, options = {}) {
8457
+ return new SeamHttpRequest(this, {
8458
+ pathname: "/user_identities/unmanaged/get",
8459
+ method: "POST",
8460
+ body: parameters,
8461
+ responseKey: "user_identity",
8462
+ options
8463
+ });
8464
+ }
8465
+ list(parameters, options = {}) {
8466
+ return new SeamHttpRequest(this, {
8467
+ pathname: "/user_identities/unmanaged/list",
8468
+ method: "POST",
8469
+ body: parameters,
8470
+ responseKey: "user_identities",
8471
+ options
8472
+ });
8473
+ }
8474
+ };
8475
+
8054
8476
  // src/lib/seam/connect/routes/user-identities/user-identities.ts
8055
8477
  var SeamHttpUserIdentities = class _SeamHttpUserIdentities {
8056
8478
  client;
@@ -8141,6 +8563,12 @@ var SeamHttpUserIdentities = class _SeamHttpUserIdentities {
8141
8563
  this.defaults
8142
8564
  );
8143
8565
  }
8566
+ get unmanaged() {
8567
+ return SeamHttpUserIdentitiesUnmanaged.fromClient(
8568
+ this.client,
8569
+ this.defaults
8570
+ );
8571
+ }
8144
8572
  addAcsUser(parameters, options = {}) {
8145
8573
  return new SeamHttpRequest(this, {
8146
8574
  pathname: "/user_identities/add_acs_user",
@@ -9096,6 +9524,20 @@ var SeamHttpEndpoints = class _SeamHttpEndpoints {
9096
9524
  return seam.update(...args);
9097
9525
  };
9098
9526
  }
9527
+ get "/access_grants/unmanaged/get"() {
9528
+ const { client, defaults } = this;
9529
+ return function accessGrantsUnmanagedGet(...args) {
9530
+ const seam = SeamHttpAccessGrantsUnmanaged.fromClient(client, defaults);
9531
+ return seam.get(...args);
9532
+ };
9533
+ }
9534
+ get "/access_grants/unmanaged/list"() {
9535
+ const { client, defaults } = this;
9536
+ return function accessGrantsUnmanagedList(...args) {
9537
+ const seam = SeamHttpAccessGrantsUnmanaged.fromClient(client, defaults);
9538
+ return seam.list(...args);
9539
+ };
9540
+ }
9099
9541
  get "/access_methods/delete"() {
9100
9542
  const { client, defaults } = this;
9101
9543
  return function accessMethodsDelete(...args) {
@@ -9131,6 +9573,20 @@ var SeamHttpEndpoints = class _SeamHttpEndpoints {
9131
9573
  return seam.list(...args);
9132
9574
  };
9133
9575
  }
9576
+ get "/access_methods/unmanaged/get"() {
9577
+ const { client, defaults } = this;
9578
+ return function accessMethodsUnmanagedGet(...args) {
9579
+ const seam = SeamHttpAccessMethodsUnmanaged.fromClient(client, defaults);
9580
+ return seam.get(...args);
9581
+ };
9582
+ }
9583
+ get "/access_methods/unmanaged/list"() {
9584
+ const { client, defaults } = this;
9585
+ return function accessMethodsUnmanagedList(...args) {
9586
+ const seam = SeamHttpAccessMethodsUnmanaged.fromClient(client, defaults);
9587
+ return seam.list(...args);
9588
+ };
9589
+ }
9134
9590
  get "/acs/access_groups/add_user"() {
9135
9591
  const { client, defaults } = this;
9136
9592
  return function acsAccessGroupsAddUser(...args) {
@@ -10127,6 +10583,13 @@ var SeamHttpEndpoints = class _SeamHttpEndpoints {
10127
10583
  return seam.update(...args);
10128
10584
  };
10129
10585
  }
10586
+ get "/seam/customer/v1/spaces/create"() {
10587
+ const { client, defaults } = this;
10588
+ return function seamCustomerV1SpacesCreate(...args) {
10589
+ const seam = SeamHttpSeamCustomerV1Spaces.fromClient(client, defaults);
10590
+ return seam.create(...args);
10591
+ };
10592
+ }
10130
10593
  get "/seam/partner/v1/building_blocks/spaces/auto_map"() {
10131
10594
  const { client, defaults } = this;
10132
10595
  if (!this.defaults.isUndocumentedApiEnabled) {
@@ -10603,6 +11066,20 @@ var SeamHttpEndpoints = class _SeamHttpEndpoints {
10603
11066
  return seam.list(...args);
10604
11067
  };
10605
11068
  }
11069
+ get "/user_identities/unmanaged/get"() {
11070
+ const { client, defaults } = this;
11071
+ return function userIdentitiesUnmanagedGet(...args) {
11072
+ const seam = SeamHttpUserIdentitiesUnmanaged.fromClient(client, defaults);
11073
+ return seam.get(...args);
11074
+ };
11075
+ }
11076
+ get "/user_identities/unmanaged/list"() {
11077
+ const { client, defaults } = this;
11078
+ return function userIdentitiesUnmanagedList(...args) {
11079
+ const seam = SeamHttpUserIdentitiesUnmanaged.fromClient(client, defaults);
11080
+ return seam.list(...args);
11081
+ };
11082
+ }
10606
11083
  get "/webhooks/create"() {
10607
11084
  const { client, defaults } = this;
10608
11085
  return function webhooksCreate(...args) {
@@ -10878,7 +11355,9 @@ exports.SeamHttpAccessCodes = SeamHttpAccessCodes;
10878
11355
  exports.SeamHttpAccessCodesSimulate = SeamHttpAccessCodesSimulate;
10879
11356
  exports.SeamHttpAccessCodesUnmanaged = SeamHttpAccessCodesUnmanaged;
10880
11357
  exports.SeamHttpAccessGrants = SeamHttpAccessGrants;
11358
+ exports.SeamHttpAccessGrantsUnmanaged = SeamHttpAccessGrantsUnmanaged;
10881
11359
  exports.SeamHttpAccessMethods = SeamHttpAccessMethods;
11360
+ exports.SeamHttpAccessMethodsUnmanaged = SeamHttpAccessMethodsUnmanaged;
10882
11361
  exports.SeamHttpAcs = SeamHttpAcs;
10883
11362
  exports.SeamHttpAcsAccessGroups = SeamHttpAcsAccessGroups;
10884
11363
  exports.SeamHttpAcsAccessGroupsUnmanaged = SeamHttpAcsAccessGroupsUnmanaged;
@@ -10928,6 +11407,7 @@ exports.SeamHttpSeamCustomerV1Events = SeamHttpSeamCustomerV1Events;
10928
11407
  exports.SeamHttpSeamCustomerV1Portals = SeamHttpSeamCustomerV1Portals;
10929
11408
  exports.SeamHttpSeamCustomerV1Reservations = SeamHttpSeamCustomerV1Reservations;
10930
11409
  exports.SeamHttpSeamCustomerV1Settings = SeamHttpSeamCustomerV1Settings;
11410
+ exports.SeamHttpSeamCustomerV1Spaces = SeamHttpSeamCustomerV1Spaces;
10931
11411
  exports.SeamHttpSeamPartnerV1BuildingBlocks = SeamHttpSeamPartnerV1BuildingBlocks;
10932
11412
  exports.SeamHttpSeamPartnerV1BuildingBlocksSpaces = SeamHttpSeamPartnerV1BuildingBlocksSpaces;
10933
11413
  exports.SeamHttpSpaces = SeamHttpSpaces;
@@ -10940,6 +11420,7 @@ exports.SeamHttpUnstablePartner = SeamHttpUnstablePartner;
10940
11420
  exports.SeamHttpUnstablePartnerBuildingBlocks = SeamHttpUnstablePartnerBuildingBlocks;
10941
11421
  exports.SeamHttpUserIdentities = SeamHttpUserIdentities;
10942
11422
  exports.SeamHttpUserIdentitiesEnrollmentAutomations = SeamHttpUserIdentitiesEnrollmentAutomations;
11423
+ exports.SeamHttpUserIdentitiesUnmanaged = SeamHttpUserIdentitiesUnmanaged;
10943
11424
  exports.SeamHttpWebhooks = SeamHttpWebhooks;
10944
11425
  exports.SeamHttpWithoutWorkspace = SeamHttpWithoutWorkspace;
10945
11426
  exports.SeamHttpWithoutWorkspaceInvalidOptionsError = SeamHttpWithoutWorkspaceInvalidOptionsError;