@seamapi/http 1.118.0 → 1.119.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 (30) hide show
  1. package/dist/connect.cjs +217 -0
  2. package/dist/connect.cjs.map +1 -1
  3. package/dist/connect.d.cts +76 -3
  4. package/dist/index.cjs +219 -0
  5. package/dist/index.cjs.map +1 -1
  6. package/dist/index.d.cts +1 -1
  7. package/lib/seam/connect/routes/seam/console/v1/index.d.ts +1 -0
  8. package/lib/seam/connect/routes/seam/console/v1/index.js +1 -0
  9. package/lib/seam/connect/routes/seam/console/v1/index.js.map +1 -1
  10. package/lib/seam/connect/routes/seam/console/v1/lynx-migration/index.d.ts +1 -0
  11. package/lib/seam/connect/routes/seam/console/v1/lynx-migration/index.js +6 -0
  12. package/lib/seam/connect/routes/seam/console/v1/lynx-migration/index.js.map +1 -0
  13. package/lib/seam/connect/routes/seam/console/v1/lynx-migration/lynx-migration.d.ts +73 -0
  14. package/lib/seam/connect/routes/seam/console/v1/lynx-migration/lynx-migration.js +140 -0
  15. package/lib/seam/connect/routes/seam/console/v1/lynx-migration/lynx-migration.js.map +1 -0
  16. package/lib/seam/connect/routes/seam/console/v1/v1.d.ts +2 -0
  17. package/lib/seam/connect/routes/seam/console/v1/v1.js +4 -0
  18. package/lib/seam/connect/routes/seam/console/v1/v1.js.map +1 -1
  19. package/lib/seam/connect/routes/seam-http-endpoints.d.ts +7 -2
  20. package/lib/seam/connect/routes/seam-http-endpoints.js +41 -0
  21. package/lib/seam/connect/routes/seam-http-endpoints.js.map +1 -1
  22. package/lib/version.d.ts +1 -1
  23. package/lib/version.js +1 -1
  24. package/package.json +3 -3
  25. package/src/lib/seam/connect/routes/seam/console/v1/index.ts +1 -0
  26. package/src/lib/seam/connect/routes/seam/console/v1/lynx-migration/index.ts +6 -0
  27. package/src/lib/seam/connect/routes/seam/console/v1/lynx-migration/lynx-migration.ts +350 -0
  28. package/src/lib/seam/connect/routes/seam/console/v1/v1.ts +8 -0
  29. package/src/lib/seam/connect/routes/seam-http-endpoints.ts +115 -0
  30. package/src/lib/version.ts +1 -1
package/dist/connect.cjs CHANGED
@@ -5850,6 +5850,156 @@ var SeamHttpPhones = class _SeamHttpPhones {
5850
5850
  }
5851
5851
  };
5852
5852
 
5853
+ // src/lib/seam/connect/routes/seam/console/v1/lynx-migration/lynx-migration.ts
5854
+ var SeamHttpSeamConsoleV1LynxMigration = class _SeamHttpSeamConsoleV1LynxMigration {
5855
+ client;
5856
+ defaults;
5857
+ ltsVersion = seamApiLtsVersion;
5858
+ static ltsVersion = seamApiLtsVersion;
5859
+ constructor(apiKeyOrOptions = {}) {
5860
+ const options = parseOptions(apiKeyOrOptions);
5861
+ if (!options.isUndocumentedApiEnabled) {
5862
+ throw new Error(
5863
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
5864
+ );
5865
+ }
5866
+ this.client = "client" in options ? options.client : createClient(options);
5867
+ this.defaults = limitToSeamHttpRequestOptions(options);
5868
+ }
5869
+ static fromClient(client, options = {}) {
5870
+ const constructorOptions = { ...options, client };
5871
+ if (!isSeamHttpOptionsWithClient(constructorOptions)) {
5872
+ throw new SeamHttpInvalidOptionsError("Missing client");
5873
+ }
5874
+ return new _SeamHttpSeamConsoleV1LynxMigration(constructorOptions);
5875
+ }
5876
+ static fromApiKey(apiKey, options = {}) {
5877
+ const constructorOptions = { ...options, apiKey };
5878
+ if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {
5879
+ throw new SeamHttpInvalidOptionsError("Missing apiKey");
5880
+ }
5881
+ return new _SeamHttpSeamConsoleV1LynxMigration(constructorOptions);
5882
+ }
5883
+ static fromClientSessionToken(clientSessionToken, options = {}) {
5884
+ const constructorOptions = { ...options, clientSessionToken };
5885
+ if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {
5886
+ throw new SeamHttpInvalidOptionsError("Missing clientSessionToken");
5887
+ }
5888
+ return new _SeamHttpSeamConsoleV1LynxMigration(constructorOptions);
5889
+ }
5890
+ static async fromPublishableKey(publishableKey, userIdentifierKey, options = {}) {
5891
+ warnOnInsecureuserIdentifierKey(userIdentifierKey);
5892
+ const clientOptions = parseOptions({ ...options, publishableKey });
5893
+ if (isSeamHttpOptionsWithClient(clientOptions)) {
5894
+ throw new SeamHttpInvalidOptionsError(
5895
+ "The client option cannot be used with SeamHttpSeamConsoleV1LynxMigration.fromPublishableKey"
5896
+ );
5897
+ }
5898
+ const client = createClient(clientOptions);
5899
+ const clientSessions = SeamHttpClientSessions.fromClient(client);
5900
+ const { token } = await clientSessions.getOrCreate({
5901
+ user_identifier_key: userIdentifierKey
5902
+ });
5903
+ return _SeamHttpSeamConsoleV1LynxMigration.fromClientSessionToken(
5904
+ token,
5905
+ options
5906
+ );
5907
+ }
5908
+ static fromConsoleSessionToken(consoleSessionToken, workspaceId, options = {}) {
5909
+ const constructorOptions = { ...options, consoleSessionToken, workspaceId };
5910
+ if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {
5911
+ throw new SeamHttpInvalidOptionsError(
5912
+ "Missing consoleSessionToken or workspaceId"
5913
+ );
5914
+ }
5915
+ return new _SeamHttpSeamConsoleV1LynxMigration(constructorOptions);
5916
+ }
5917
+ static fromPersonalAccessToken(personalAccessToken, workspaceId, options = {}) {
5918
+ const constructorOptions = { ...options, personalAccessToken, workspaceId };
5919
+ if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {
5920
+ throw new SeamHttpInvalidOptionsError(
5921
+ "Missing personalAccessToken or workspaceId"
5922
+ );
5923
+ }
5924
+ return new _SeamHttpSeamConsoleV1LynxMigration(constructorOptions);
5925
+ }
5926
+ createPaginator(request) {
5927
+ return new SeamPaginator(this, request);
5928
+ }
5929
+ async updateClientSessionToken(clientSessionToken) {
5930
+ const { headers } = this.client.defaults;
5931
+ const authHeaders = getAuthHeadersForClientSessionToken({
5932
+ clientSessionToken
5933
+ });
5934
+ for (const key of Object.keys(authHeaders)) {
5935
+ if (headers[key] == null) {
5936
+ throw new Error(
5937
+ "Cannot update a clientSessionToken on a client created without a clientSessionToken"
5938
+ );
5939
+ }
5940
+ }
5941
+ this.client.defaults.headers = { ...headers, ...authHeaders };
5942
+ const clientSessions = SeamHttpClientSessions.fromClient(this.client);
5943
+ await clientSessions.get();
5944
+ }
5945
+ getPropertyMigrationStatus(parameters, options = {}) {
5946
+ if (!this.defaults.isUndocumentedApiEnabled) {
5947
+ throw new Error(
5948
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
5949
+ );
5950
+ }
5951
+ return new SeamHttpRequest(this, {
5952
+ pathname: "/seam/console/v1/lynx_migration/get_property_migration_status",
5953
+ method: "POST",
5954
+ body: parameters,
5955
+ responseKey: "lynx_migration_property_run",
5956
+ options
5957
+ });
5958
+ }
5959
+ getReservationMigrationStatus(parameters, options = {}) {
5960
+ if (!this.defaults.isUndocumentedApiEnabled) {
5961
+ throw new Error(
5962
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
5963
+ );
5964
+ }
5965
+ return new SeamHttpRequest(this, {
5966
+ pathname: "/seam/console/v1/lynx_migration/get_reservation_migration_status",
5967
+ method: "POST",
5968
+ body: parameters,
5969
+ responseKey: "lynx_migration_reservation_run",
5970
+ options
5971
+ });
5972
+ }
5973
+ listPropertyReservations(parameters, options = {}) {
5974
+ if (!this.defaults.isUndocumentedApiEnabled) {
5975
+ throw new Error(
5976
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
5977
+ );
5978
+ }
5979
+ return new SeamHttpRequest(this, {
5980
+ pathname: "/seam/console/v1/lynx_migration/list_property_reservations",
5981
+ method: "POST",
5982
+ body: parameters,
5983
+ responseKey: "lynx_migration_property_plan",
5984
+ options
5985
+ });
5986
+ }
5987
+ migrateProperty(parameters, options = {}) {
5988
+ if (!this.defaults.isUndocumentedApiEnabled) {
5989
+ throw new Error(
5990
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
5991
+ );
5992
+ }
5993
+ return new SeamHttpRequest(this, {
5994
+ pathname: "/seam/console/v1/lynx_migration/migrate_property",
5995
+ method: "POST",
5996
+ body: parameters,
5997
+ responseKey: "lynx_migration_property_run",
5998
+ options
5999
+ });
6000
+ }
6001
+ };
6002
+
5853
6003
  // src/lib/seam/connect/routes/seam/console/v1/sites/sites.ts
5854
6004
  var SeamHttpSeamConsoleV1Sites = class _SeamHttpSeamConsoleV1Sites {
5855
6005
  client;
@@ -6191,6 +6341,12 @@ var SeamHttpSeamConsoleV1 = class _SeamHttpSeamConsoleV1 {
6191
6341
  const clientSessions = SeamHttpClientSessions.fromClient(this.client);
6192
6342
  await clientSessions.get();
6193
6343
  }
6344
+ get lynxMigration() {
6345
+ return SeamHttpSeamConsoleV1LynxMigration.fromClient(
6346
+ this.client,
6347
+ this.defaults
6348
+ );
6349
+ }
6194
6350
  get sites() {
6195
6351
  return SeamHttpSeamConsoleV1Sites.fromClient(this.client, this.defaults);
6196
6352
  }
@@ -12287,6 +12443,66 @@ var SeamHttpEndpoints = class _SeamHttpEndpoints {
12287
12443
  return seam.getResourceLocator(...args);
12288
12444
  };
12289
12445
  }
12446
+ get "/seam/console/v1/lynx_migration/get_property_migration_status"() {
12447
+ const { client, defaults } = this;
12448
+ if (!this.defaults.isUndocumentedApiEnabled) {
12449
+ throw new Error(
12450
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
12451
+ );
12452
+ }
12453
+ return function seamConsoleV1LynxMigrationGetPropertyMigrationStatus(...args) {
12454
+ const seam = SeamHttpSeamConsoleV1LynxMigration.fromClient(
12455
+ client,
12456
+ defaults
12457
+ );
12458
+ return seam.getPropertyMigrationStatus(...args);
12459
+ };
12460
+ }
12461
+ get "/seam/console/v1/lynx_migration/get_reservation_migration_status"() {
12462
+ const { client, defaults } = this;
12463
+ if (!this.defaults.isUndocumentedApiEnabled) {
12464
+ throw new Error(
12465
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
12466
+ );
12467
+ }
12468
+ return function seamConsoleV1LynxMigrationGetReservationMigrationStatus(...args) {
12469
+ const seam = SeamHttpSeamConsoleV1LynxMigration.fromClient(
12470
+ client,
12471
+ defaults
12472
+ );
12473
+ return seam.getReservationMigrationStatus(...args);
12474
+ };
12475
+ }
12476
+ get "/seam/console/v1/lynx_migration/list_property_reservations"() {
12477
+ const { client, defaults } = this;
12478
+ if (!this.defaults.isUndocumentedApiEnabled) {
12479
+ throw new Error(
12480
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
12481
+ );
12482
+ }
12483
+ return function seamConsoleV1LynxMigrationListPropertyReservations(...args) {
12484
+ const seam = SeamHttpSeamConsoleV1LynxMigration.fromClient(
12485
+ client,
12486
+ defaults
12487
+ );
12488
+ return seam.listPropertyReservations(...args);
12489
+ };
12490
+ }
12491
+ get "/seam/console/v1/lynx_migration/migrate_property"() {
12492
+ const { client, defaults } = this;
12493
+ if (!this.defaults.isUndocumentedApiEnabled) {
12494
+ throw new Error(
12495
+ "Cannot use undocumented API without isUndocumentedApiEnabled"
12496
+ );
12497
+ }
12498
+ return function seamConsoleV1LynxMigrationMigrateProperty(...args) {
12499
+ const seam = SeamHttpSeamConsoleV1LynxMigration.fromClient(
12500
+ client,
12501
+ defaults
12502
+ );
12503
+ return seam.migrateProperty(...args);
12504
+ };
12505
+ }
12290
12506
  get "/seam/console/v1/sites/create"() {
12291
12507
  const { client, defaults } = this;
12292
12508
  if (!this.defaults.isUndocumentedApiEnabled) {
@@ -13702,6 +13918,7 @@ exports.SeamHttpPhonesSimulate = SeamHttpPhonesSimulate;
13702
13918
  exports.SeamHttpRequest = SeamHttpRequest;
13703
13919
  exports.SeamHttpSeamConsole = SeamHttpSeamConsole;
13704
13920
  exports.SeamHttpSeamConsoleV1 = SeamHttpSeamConsoleV1;
13921
+ exports.SeamHttpSeamConsoleV1LynxMigration = SeamHttpSeamConsoleV1LynxMigration;
13705
13922
  exports.SeamHttpSeamConsoleV1Sites = SeamHttpSeamConsoleV1Sites;
13706
13923
  exports.SeamHttpSeamConsoleV1Timelines = SeamHttpSeamConsoleV1Timelines;
13707
13924
  exports.SeamHttpSeamCustomerV1 = SeamHttpSeamCustomerV1;