@fern-api/venus-api-sdk 11.5.0 → 11.7.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 (64) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/apiKeys/client/Client.d.ts +9 -0
  3. package/dist/cjs/api/resources/apiKeys/client/Client.js +14 -2
  4. package/dist/cjs/api/resources/apiKeys/client/requests/RevokeTokenByIdApiKeysRevokeTokenIdPostRequest.d.ts +1 -0
  5. package/dist/cjs/api/resources/organization/client/Client.d.ts +37 -1
  6. package/dist/cjs/api/resources/organization/client/Client.js +165 -1
  7. package/dist/cjs/api/resources/organization/client/getPostmanTeamDocs.d.ts +25 -0
  8. package/dist/cjs/api/resources/organization/client/getPostmanTeamDocs.js +66 -0
  9. package/dist/cjs/api/resources/organization/client/index.d.ts +2 -0
  10. package/dist/cjs/api/resources/organization/client/index.js +3 -1
  11. package/dist/cjs/api/resources/organization/client/requests/GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest.d.ts +9 -0
  12. package/dist/cjs/api/resources/organization/client/requests/GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest.js +3 -0
  13. package/dist/cjs/api/resources/organization/client/requests/SetDocsUrlRequest.d.ts +11 -0
  14. package/dist/cjs/api/resources/organization/client/requests/SetDocsUrlRequest.js +3 -0
  15. package/dist/cjs/api/resources/organization/client/requests/index.d.ts +2 -0
  16. package/dist/cjs/api/resources/organization/client/setDocsUrl.d.ts +25 -0
  17. package/dist/cjs/api/resources/organization/client/setDocsUrl.js +66 -0
  18. package/dist/cjs/api/types/PostmanTeamDocsResponse.d.ts +6 -0
  19. package/dist/cjs/api/types/PostmanTeamDocsResponse.js +3 -0
  20. package/dist/cjs/api/types/index.d.ts +1 -0
  21. package/dist/cjs/api/types/index.js +1 -0
  22. package/dist/cjs/serialization/resources/organization/client/requests/SetDocsUrlRequest.d.ts +9 -0
  23. package/dist/cjs/serialization/resources/organization/client/requests/SetDocsUrlRequest.js +41 -0
  24. package/dist/cjs/serialization/resources/organization/client/requests/index.d.ts +1 -0
  25. package/dist/cjs/serialization/resources/organization/client/requests/index.js +3 -1
  26. package/dist/cjs/serialization/types/PostmanTeamDocsResponse.d.ts +12 -0
  27. package/dist/cjs/serialization/types/PostmanTeamDocsResponse.js +44 -0
  28. package/dist/cjs/serialization/types/index.d.ts +1 -0
  29. package/dist/cjs/serialization/types/index.js +1 -0
  30. package/dist/cjs/version.d.ts +1 -1
  31. package/dist/cjs/version.js +1 -1
  32. package/dist/esm/BaseClient.mjs +2 -2
  33. package/dist/esm/api/resources/apiKeys/client/Client.d.mts +9 -0
  34. package/dist/esm/api/resources/apiKeys/client/Client.mjs +14 -2
  35. package/dist/esm/api/resources/apiKeys/client/requests/RevokeTokenByIdApiKeysRevokeTokenIdPostRequest.d.mts +1 -0
  36. package/dist/esm/api/resources/organization/client/Client.d.mts +37 -1
  37. package/dist/esm/api/resources/organization/client/Client.mjs +165 -1
  38. package/dist/esm/api/resources/organization/client/getPostmanTeamDocs.d.mts +25 -0
  39. package/dist/esm/api/resources/organization/client/getPostmanTeamDocs.mjs +30 -0
  40. package/dist/esm/api/resources/organization/client/index.d.mts +2 -0
  41. package/dist/esm/api/resources/organization/client/index.mjs +2 -0
  42. package/dist/esm/api/resources/organization/client/requests/GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest.d.mts +9 -0
  43. package/dist/esm/api/resources/organization/client/requests/GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest.mjs +2 -0
  44. package/dist/esm/api/resources/organization/client/requests/SetDocsUrlRequest.d.mts +11 -0
  45. package/dist/esm/api/resources/organization/client/requests/SetDocsUrlRequest.mjs +2 -0
  46. package/dist/esm/api/resources/organization/client/requests/index.d.mts +2 -0
  47. package/dist/esm/api/resources/organization/client/setDocsUrl.d.mts +25 -0
  48. package/dist/esm/api/resources/organization/client/setDocsUrl.mjs +30 -0
  49. package/dist/esm/api/types/PostmanTeamDocsResponse.d.mts +6 -0
  50. package/dist/esm/api/types/PostmanTeamDocsResponse.mjs +2 -0
  51. package/dist/esm/api/types/index.d.mts +1 -0
  52. package/dist/esm/api/types/index.mjs +1 -0
  53. package/dist/esm/serialization/resources/organization/client/requests/SetDocsUrlRequest.d.mts +9 -0
  54. package/dist/esm/serialization/resources/organization/client/requests/SetDocsUrlRequest.mjs +5 -0
  55. package/dist/esm/serialization/resources/organization/client/requests/index.d.mts +1 -0
  56. package/dist/esm/serialization/resources/organization/client/requests/index.mjs +1 -0
  57. package/dist/esm/serialization/types/PostmanTeamDocsResponse.d.mts +12 -0
  58. package/dist/esm/serialization/types/PostmanTeamDocsResponse.mjs +8 -0
  59. package/dist/esm/serialization/types/index.d.mts +1 -0
  60. package/dist/esm/serialization/types/index.mjs +1 -0
  61. package/dist/esm/version.d.mts +1 -1
  62. package/dist/esm/version.mjs +1 -1
  63. package/package.json +1 -1
  64. package/reference.md +174 -1
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
43
43
  const headers = (0, headers_js_1.mergeHeaders)({
44
44
  "X-Fern-Language": "JavaScript",
45
45
  "X-Fern-SDK-Name": "@fern-api/venus-api-sdk",
46
- "X-Fern-SDK-Version": "11.5.0",
47
- "User-Agent": "@fern-api/venus-api-sdk/11.5.0",
46
+ "X-Fern-SDK-Version": "11.7.0",
47
+ "User-Agent": "@fern-api/venus-api-sdk/11.7.0",
48
48
  "X-Fern-Runtime": core.RUNTIME.type,
49
49
  "X-Fern-Runtime-Version": core.RUNTIME.version,
50
50
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -37,6 +37,10 @@ export declare class ApiKeysClient {
37
37
  getTokenMetadata(request: FernVenusApi.GetTokenMetadataRequest, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.TokenMetadata, FernVenusApi.apiKeys.getTokenMetadata.Error>>;
38
38
  private __getTokenMetadata;
39
39
  /**
40
+ * Lists an organization's API keys. Called with the provisioner token, it
41
+ * only works for an unclaimed organization that was created with that
42
+ * token, and returns 403 for any other.
43
+ *
40
44
  * @param {FernVenusApi.GetTokensForOrganizationApiKeysOrganizationOrganizationIdGetRequest} request
41
45
  * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
42
46
  *
@@ -48,6 +52,11 @@ export declare class ApiKeysClient {
48
52
  getTokensForOrganization(request: FernVenusApi.GetTokensForOrganizationApiKeysOrganizationOrganizationIdGetRequest, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.TokenMetadata[], FernVenusApi.apiKeys.getTokensForOrganization.Error>>;
49
53
  private __getTokensForOrganization;
50
54
  /**
55
+ * Revokes an API key by its ID. Called with the provisioner token,
56
+ * organizationId is required and must be an unclaimed organization that
57
+ * was created with that token (403 otherwise), and the key must be that
58
+ * organization's (401 otherwise). Other callers don't need organizationId.
59
+ *
51
60
  * @param {FernVenusApi.RevokeTokenByIdApiKeysRevokeTokenIdPostRequest} request
52
61
  * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
53
62
  *
@@ -229,6 +229,10 @@ class ApiKeysClient {
229
229
  });
230
230
  }
231
231
  /**
232
+ * Lists an organization's API keys. Called with the provisioner token, it
233
+ * only works for an unclaimed organization that was created with that
234
+ * token, and returns 403 for any other.
235
+ *
232
236
  * @param {FernVenusApi.GetTokensForOrganizationApiKeysOrganizationOrganizationIdGetRequest} request
233
237
  * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
234
238
  *
@@ -304,6 +308,11 @@ class ApiKeysClient {
304
308
  });
305
309
  }
306
310
  /**
311
+ * Revokes an API key by its ID. Called with the provisioner token,
312
+ * organizationId is required and must be an unclaimed organization that
313
+ * was created with that token (403 otherwise), and the key must be that
314
+ * organization's (401 otherwise). Other callers don't need organizationId.
315
+ *
307
316
  * @param {FernVenusApi.RevokeTokenByIdApiKeysRevokeTokenIdPostRequest} request
308
317
  * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
309
318
  *
@@ -318,14 +327,17 @@ class ApiKeysClient {
318
327
  __revokeTokenById(request, requestOptions) {
319
328
  return __awaiter(this, void 0, void 0, function* () {
320
329
  var _a, _b, _c, _d, _e, _f, _g, _h;
321
- const { tokenId } = request;
330
+ const { tokenId, organizationId } = request;
331
+ const _queryParams = {
332
+ organizationId,
333
+ };
322
334
  const _authRequest = yield this._options.authProvider.getAuthRequest();
323
335
  const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
324
336
  const _response = yield core.fetcher({
325
337
  url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `api-keys/revoke/${core.url.encodePathParam(tokenId)}`),
326
338
  method: "POST",
327
339
  headers: _headers,
328
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
340
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
329
341
  timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
330
342
  maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
331
343
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -6,4 +6,5 @@
6
6
  */
7
7
  export interface RevokeTokenByIdApiKeysRevokeTokenIdPostRequest {
8
8
  tokenId: string;
9
+ organizationId?: string | null;
9
10
  }
@@ -52,6 +52,9 @@ export declare class OrganizationClient {
52
52
  private __get;
53
53
  /**
54
54
  * Deletes an organization. Only users with admin role can delete organizations.
55
+ * Called with the provisioner token, it only works for an unclaimed
56
+ * organization that was created with that token, and returns 403 for any
57
+ * other. It also revokes that organization's API keys.
55
58
  *
56
59
  * @param {FernVenusApi.DeleteOrganizationsOrgIdDeleteRequest} request
57
60
  * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -76,6 +79,22 @@ export declare class OrganizationClient {
76
79
  */
77
80
  getOrgIdsByPostmanTeamId(request: FernVenusApi.GetOrgIdsByPostmanTeamIdOrganizationsPostmanTeamPostmanTeamIdGetRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.Organization, FernVenusApi.organization.getOrgIdsByPostmanTeamId.Error>>;
78
81
  private __getOrgIdsByPostmanTeamId;
82
+ /**
83
+ * The claimable organization linked to a Postman team, with its claim
84
+ * status and the address of its docs site. Only Postman's integration
85
+ * service token can call it. 404 when the team has no claimable
86
+ * organization, or its docs address isn't set.
87
+ *
88
+ * @param {FernVenusApi.GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest} request
89
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
90
+ *
91
+ * @example
92
+ * await client.organization.getPostmanTeamDocs({
93
+ * postmanTeamId: "postman_team_id"
94
+ * })
95
+ */
96
+ getPostmanTeamDocs(request: FernVenusApi.GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.PostmanTeamDocsResponse, FernVenusApi.organization.getPostmanTeamDocs.Error>>;
97
+ private __getPostmanTeamDocs;
79
98
  /**
80
99
  * Get the Postman team ID associated with an organization ID.
81
100
  *
@@ -106,7 +125,8 @@ export declare class OrganizationClient {
106
125
  private __getClaimStatus;
107
126
  /**
108
127
  * Issues a claim link for an unclaimed organization, bound to one Postman
109
- * user and valid for 15 minutes. Only the provisioner token can call it.
128
+ * user and valid for 15 minutes. Only the provisioner token and Postman's
129
+ * integration service token can call it.
110
130
  *
111
131
  * @param {FernVenusApi.CreateClaimTokenRequest} request
112
132
  * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -119,6 +139,22 @@ export declare class OrganizationClient {
119
139
  */
120
140
  createClaimToken(request: FernVenusApi.CreateClaimTokenRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.ClaimTokenResponse, FernVenusApi.organization.createClaimToken.Error>>;
121
141
  private __createClaimToken;
142
+ /**
143
+ * Sets the address of an unclaimed organization's docs site, which the
144
+ * team docs lookup returns. Only the provisioner token can call it, and
145
+ * only until the organization is claimed.
146
+ *
147
+ * @param {FernVenusApi.SetDocsUrlRequest} request
148
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
149
+ *
150
+ * @example
151
+ * await client.organization.setDocsUrl({
152
+ * orgId: "org_id",
153
+ * docsUrl: "docsUrl"
154
+ * })
155
+ */
156
+ setDocsUrl(request: FernVenusApi.SetDocsUrlRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<void, FernVenusApi.organization.setDocsUrl.Error>>;
157
+ private __setDocsUrl;
122
158
  /**
123
159
  * Redeems a claim link. The caller, signed in as the Postman user the link
124
160
  * is for, becomes the admin of the organization. The first claim wins, and
@@ -306,6 +306,9 @@ class OrganizationClient {
306
306
  }
307
307
  /**
308
308
  * Deletes an organization. Only users with admin role can delete organizations.
309
+ * Called with the provisioner token, it only works for an unclaimed
310
+ * organization that was created with that token, and returns 403 for any
311
+ * other. It also revokes that organization's API keys.
309
312
  *
310
313
  * @param {FernVenusApi.DeleteOrganizationsOrgIdDeleteRequest} request
311
314
  * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -452,6 +455,86 @@ class OrganizationClient {
452
455
  };
453
456
  });
454
457
  }
458
+ /**
459
+ * The claimable organization linked to a Postman team, with its claim
460
+ * status and the address of its docs site. Only Postman's integration
461
+ * service token can call it. 404 when the team has no claimable
462
+ * organization, or its docs address isn't set.
463
+ *
464
+ * @param {FernVenusApi.GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest} request
465
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
466
+ *
467
+ * @example
468
+ * await client.organization.getPostmanTeamDocs({
469
+ * postmanTeamId: "postman_team_id"
470
+ * })
471
+ */
472
+ getPostmanTeamDocs(request, requestOptions) {
473
+ return core.HttpResponsePromise.fromPromise(this.__getPostmanTeamDocs(request, requestOptions));
474
+ }
475
+ __getPostmanTeamDocs(request, requestOptions) {
476
+ return __awaiter(this, void 0, void 0, function* () {
477
+ var _a, _b, _c, _d, _e, _f, _g, _h;
478
+ const { postmanTeamId } = request;
479
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
480
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
481
+ const _response = yield core.fetcher({
482
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `organizations/postman-team/${core.url.encodePathParam(postmanTeamId)}/docs`),
483
+ method: "GET",
484
+ headers: _headers,
485
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
486
+ timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
487
+ maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
488
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
489
+ fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
490
+ logging: this._options.logging,
491
+ });
492
+ if (_response.ok) {
493
+ return {
494
+ data: {
495
+ ok: true,
496
+ body: serializers.PostmanTeamDocsResponse.parseOrThrow(_response.body, {
497
+ unrecognizedObjectKeys: "passthrough",
498
+ allowUnrecognizedUnionMembers: true,
499
+ allowUnrecognizedEnumValues: true,
500
+ skipValidation: true,
501
+ breadcrumbsPrefix: ["response"],
502
+ }),
503
+ headers: _response.headers,
504
+ rawResponse: _response.rawResponse,
505
+ },
506
+ rawResponse: _response.rawResponse,
507
+ };
508
+ }
509
+ if (_response.error.reason === "status-code") {
510
+ switch (_response.error.statusCode) {
511
+ case 422:
512
+ return {
513
+ data: {
514
+ ok: false,
515
+ error: FernVenusApi.organization.getPostmanTeamDocs.Error.unprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
516
+ unrecognizedObjectKeys: "passthrough",
517
+ allowUnrecognizedUnionMembers: true,
518
+ allowUnrecognizedEnumValues: true,
519
+ skipValidation: true,
520
+ breadcrumbsPrefix: ["response"],
521
+ })),
522
+ rawResponse: _response.rawResponse,
523
+ },
524
+ rawResponse: _response.rawResponse,
525
+ };
526
+ }
527
+ }
528
+ return {
529
+ data: {
530
+ ok: false,
531
+ error: FernVenusApi.organization.getPostmanTeamDocs.Error._unknown(_response.error),
532
+ rawResponse: _response.rawResponse,
533
+ },
534
+ rawResponse: _response.rawResponse,
535
+ };
536
+ });
537
+ }
455
538
  /**
456
539
  * Get the Postman team ID associated with an organization ID.
457
540
  *
@@ -610,7 +693,8 @@ class OrganizationClient {
610
693
  }
611
694
  /**
612
695
  * Issues a claim link for an unclaimed organization, bound to one Postman
613
- * user and valid for 15 minutes. Only the provisioner token can call it.
696
+ * user and valid for 15 minutes. Only the provisioner token and Postman's
697
+ * integration service token can call it.
614
698
  *
615
699
  * @param {FernVenusApi.CreateClaimTokenRequest} request
616
700
  * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -693,6 +777,86 @@ class OrganizationClient {
693
777
  };
694
778
  });
695
779
  }
780
+ /**
781
+ * Sets the address of an unclaimed organization's docs site, which the
782
+ * team docs lookup returns. Only the provisioner token can call it, and
783
+ * only until the organization is claimed.
784
+ *
785
+ * @param {FernVenusApi.SetDocsUrlRequest} request
786
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
787
+ *
788
+ * @example
789
+ * await client.organization.setDocsUrl({
790
+ * orgId: "org_id",
791
+ * docsUrl: "docsUrl"
792
+ * })
793
+ */
794
+ setDocsUrl(request, requestOptions) {
795
+ return core.HttpResponsePromise.fromPromise(this.__setDocsUrl(request, requestOptions));
796
+ }
797
+ __setDocsUrl(request, requestOptions) {
798
+ return __awaiter(this, void 0, void 0, function* () {
799
+ var _a, _b, _c, _d, _e, _f, _g, _h;
800
+ const { orgId } = request, _body = __rest(request, ["orgId"]);
801
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
802
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
803
+ const _response = yield core.fetcher({
804
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `organizations/${core.url.encodePathParam(orgId)}/docs-url`),
805
+ method: "POST",
806
+ headers: _headers,
807
+ contentType: "application/json",
808
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
809
+ requestType: "json",
810
+ body: serializers.SetDocsUrlRequest.jsonOrThrow(_body, {
811
+ unrecognizedObjectKeys: "strip",
812
+ omitUndefined: true,
813
+ }),
814
+ timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
815
+ maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
816
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
817
+ fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
818
+ logging: this._options.logging,
819
+ });
820
+ if (_response.ok) {
821
+ return {
822
+ data: {
823
+ ok: true,
824
+ body: undefined,
825
+ headers: _response.headers,
826
+ rawResponse: _response.rawResponse,
827
+ },
828
+ rawResponse: _response.rawResponse,
829
+ };
830
+ }
831
+ if (_response.error.reason === "status-code") {
832
+ switch (_response.error.statusCode) {
833
+ case 422:
834
+ return {
835
+ data: {
836
+ ok: false,
837
+ error: FernVenusApi.organization.setDocsUrl.Error.unprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
838
+ unrecognizedObjectKeys: "passthrough",
839
+ allowUnrecognizedUnionMembers: true,
840
+ allowUnrecognizedEnumValues: true,
841
+ skipValidation: true,
842
+ breadcrumbsPrefix: ["response"],
843
+ })),
844
+ rawResponse: _response.rawResponse,
845
+ },
846
+ rawResponse: _response.rawResponse,
847
+ };
848
+ }
849
+ }
850
+ return {
851
+ data: {
852
+ ok: false,
853
+ error: FernVenusApi.organization.setDocsUrl.Error._unknown(_response.error),
854
+ rawResponse: _response.rawResponse,
855
+ },
856
+ rawResponse: _response.rawResponse,
857
+ };
858
+ });
859
+ }
696
860
  /**
697
861
  * Redeems a claim link. The caller, signed in as the Postman user the link
698
862
  * is for, becomes the admin of the organization. The first claim wins, and
@@ -0,0 +1,25 @@
1
+ import type * as core from "../../../../core/index.js";
2
+ import * as FernVenusApi from "../../../index.js";
3
+ export type Error = FernVenusApi.organization.getPostmanTeamDocs.Error.UnprocessableEntityError | FernVenusApi.organization.getPostmanTeamDocs.Error._Unknown;
4
+ export declare namespace Error {
5
+ interface UnprocessableEntityError extends _Utils {
6
+ statusCode: 422;
7
+ content: FernVenusApi.HttpValidationError;
8
+ }
9
+ interface _Unknown extends _Utils {
10
+ statusCode: void;
11
+ content: core.Fetcher.Error;
12
+ }
13
+ interface _Utils {
14
+ _visit: <_Result>(visitor: FernVenusApi.organization.getPostmanTeamDocs.Error._Visitor<_Result>) => _Result;
15
+ }
16
+ interface _Visitor<_Result> {
17
+ unprocessableEntityError: (value: FernVenusApi.HttpValidationError) => _Result;
18
+ _other: (value: core.Fetcher.Error) => _Result;
19
+ }
20
+ }
21
+ export declare const Error: {
22
+ readonly unprocessableEntityError: (value: FernVenusApi.HttpValidationError) => FernVenusApi.organization.getPostmanTeamDocs.Error.UnprocessableEntityError;
23
+ readonly _unknown: (fetcherError: core.Fetcher.Error) => FernVenusApi.organization.getPostmanTeamDocs.Error._Unknown;
24
+ readonly _visit: <_Result>(value: FernVenusApi.organization.getPostmanTeamDocs.Error, visitor: FernVenusApi.organization.getPostmanTeamDocs.Error._Visitor<_Result>) => _Result;
25
+ };
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
+ if (k2 === undefined) k2 = k;
5
+ var desc = Object.getOwnPropertyDescriptor(m, k);
6
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
+ desc = { enumerable: true, get: function() { return m[k]; } };
8
+ }
9
+ Object.defineProperty(o, k2, desc);
10
+ }) : (function(o, m, k, k2) {
11
+ if (k2 === undefined) k2 = k;
12
+ o[k2] = m[k];
13
+ }));
14
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
15
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
16
+ }) : function(o, v) {
17
+ o["default"] = v;
18
+ });
19
+ var __importStar = (this && this.__importStar) || (function () {
20
+ var ownKeys = function(o) {
21
+ ownKeys = Object.getOwnPropertyNames || function (o) {
22
+ var ar = [];
23
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
24
+ return ar;
25
+ };
26
+ return ownKeys(o);
27
+ };
28
+ return function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
35
+ })();
36
+ Object.defineProperty(exports, "__esModule", { value: true });
37
+ exports.Error = void 0;
38
+ const FernVenusApi = __importStar(require("../../../index.js"));
39
+ exports.Error = {
40
+ unprocessableEntityError: (value) => {
41
+ return {
42
+ content: value,
43
+ statusCode: 422,
44
+ _visit: function (visitor) {
45
+ return FernVenusApi.organization.getPostmanTeamDocs.Error._visit(this, visitor);
46
+ },
47
+ };
48
+ },
49
+ _unknown: (fetcherError) => {
50
+ return {
51
+ statusCode: undefined,
52
+ content: fetcherError,
53
+ _visit: function (visitor) {
54
+ return FernVenusApi.organization.getPostmanTeamDocs.Error._visit(this, visitor);
55
+ },
56
+ };
57
+ },
58
+ _visit: (value, visitor) => {
59
+ switch (value.statusCode) {
60
+ case 422:
61
+ return visitor.unprocessableEntityError(value.content);
62
+ default:
63
+ return visitor._other(value.content);
64
+ }
65
+ },
66
+ };
@@ -8,10 +8,12 @@ export * as getClaimStatus from "./getClaimStatus.js";
8
8
  export * as getMyOrganizationFromScopedToken from "./getMyOrganizationFromScopedToken.js";
9
9
  export * as getOrgIdsByPostmanTeamId from "./getOrgIdsByPostmanTeamId.js";
10
10
  export * as getOrgIdsFromToken from "./getOrgIdsFromToken.js";
11
+ export * as getPostmanTeamDocs from "./getPostmanTeamDocs.js";
11
12
  export * as getPostmanTeamIdByOrgId from "./getPostmanTeamIdByOrgId.js";
12
13
  export * as inviteUser from "./inviteUser.js";
13
14
  export * as isMember from "./isMember.js";
14
15
  export * as previewClaim from "./previewClaim.js";
15
16
  export * as removeUser from "./removeUser.js";
16
17
  export * from "./requests/index.js";
18
+ export * as setDocsUrl from "./setDocsUrl.js";
17
19
  export * as update from "./update.js";
@@ -36,7 +36,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
36
36
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
37
37
  };
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.update = exports.removeUser = exports.previewClaim = exports.isMember = exports.inviteUser = exports.getPostmanTeamIdByOrgId = exports.getOrgIdsFromToken = exports.getOrgIdsByPostmanTeamId = exports.getMyOrganizationFromScopedToken = exports.getClaimStatus = exports.get = exports.delete = exports.createClaimToken = exports.create = exports.claim = exports.addUser = void 0;
39
+ exports.update = exports.setDocsUrl = exports.removeUser = exports.previewClaim = exports.isMember = exports.inviteUser = exports.getPostmanTeamIdByOrgId = exports.getPostmanTeamDocs = exports.getOrgIdsFromToken = exports.getOrgIdsByPostmanTeamId = exports.getMyOrganizationFromScopedToken = exports.getClaimStatus = exports.get = exports.delete = exports.createClaimToken = exports.create = exports.claim = exports.addUser = void 0;
40
40
  exports.addUser = __importStar(require("./addUser.js"));
41
41
  exports.claim = __importStar(require("./claim.js"));
42
42
  exports.create = __importStar(require("./create.js"));
@@ -47,10 +47,12 @@ exports.getClaimStatus = __importStar(require("./getClaimStatus.js"));
47
47
  exports.getMyOrganizationFromScopedToken = __importStar(require("./getMyOrganizationFromScopedToken.js"));
48
48
  exports.getOrgIdsByPostmanTeamId = __importStar(require("./getOrgIdsByPostmanTeamId.js"));
49
49
  exports.getOrgIdsFromToken = __importStar(require("./getOrgIdsFromToken.js"));
50
+ exports.getPostmanTeamDocs = __importStar(require("./getPostmanTeamDocs.js"));
50
51
  exports.getPostmanTeamIdByOrgId = __importStar(require("./getPostmanTeamIdByOrgId.js"));
51
52
  exports.inviteUser = __importStar(require("./inviteUser.js"));
52
53
  exports.isMember = __importStar(require("./isMember.js"));
53
54
  exports.previewClaim = __importStar(require("./previewClaim.js"));
54
55
  exports.removeUser = __importStar(require("./removeUser.js"));
55
56
  __exportStar(require("./requests/index.js"), exports);
57
+ exports.setDocsUrl = __importStar(require("./setDocsUrl.js"));
56
58
  exports.update = __importStar(require("./update.js"));
@@ -0,0 +1,9 @@
1
+ /**
2
+ * @example
3
+ * {
4
+ * postmanTeamId: "postman_team_id"
5
+ * }
6
+ */
7
+ export interface GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest {
8
+ postmanTeamId: string;
9
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ /**
2
+ * @example
3
+ * {
4
+ * orgId: "org_id",
5
+ * docsUrl: "docsUrl"
6
+ * }
7
+ */
8
+ export interface SetDocsUrlRequest {
9
+ orgId: string;
10
+ docsUrl: string;
11
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -6,8 +6,10 @@ export type { GetClaimStatusOrganizationsOrgIdClaimStatusGetRequest } from "./Ge
6
6
  export type { GetMyOrganizationFromScopedTokenOrganizationsMyselfPostRequest } from "./GetMyOrganizationFromScopedTokenOrganizationsMyselfPostRequest.js";
7
7
  export type { GetOrganizationsOrgIdGetRequest } from "./GetOrganizationsOrgIdGetRequest.js";
8
8
  export type { GetOrgIdsByPostmanTeamIdOrganizationsPostmanTeamPostmanTeamIdGetRequest } from "./GetOrgIdsByPostmanTeamIdOrganizationsPostmanTeamPostmanTeamIdGetRequest.js";
9
+ export type { GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest } from "./GetPostmanTeamDocsOrganizationsPostmanTeamPostmanTeamIdDocsGetRequest.js";
9
10
  export type { GetPostmanTeamIdByOrgIdOrganizationsOrgIdPostmanTeamIdGetRequest } from "./GetPostmanTeamIdByOrgIdOrganizationsOrgIdPostmanTeamIdGetRequest.js";
10
11
  export type { InviteUserToOrgRequest } from "./InviteUserToOrgRequest.js";
11
12
  export type { IsMemberOrganizationsBelongsToOrganizationOrganizationIdPostRequest } from "./IsMemberOrganizationsBelongsToOrganizationOrganizationIdPostRequest.js";
12
13
  export type { RemoveUserFromOrgRequest } from "./RemoveUserFromOrgRequest.js";
14
+ export type { SetDocsUrlRequest } from "./SetDocsUrlRequest.js";
13
15
  export type { UpdateOrganizationRequest } from "./UpdateOrganizationRequest.js";
@@ -0,0 +1,25 @@
1
+ import type * as core from "../../../../core/index.js";
2
+ import * as FernVenusApi from "../../../index.js";
3
+ export type Error = FernVenusApi.organization.setDocsUrl.Error.UnprocessableEntityError | FernVenusApi.organization.setDocsUrl.Error._Unknown;
4
+ export declare namespace Error {
5
+ interface UnprocessableEntityError extends _Utils {
6
+ statusCode: 422;
7
+ content: FernVenusApi.HttpValidationError;
8
+ }
9
+ interface _Unknown extends _Utils {
10
+ statusCode: void;
11
+ content: core.Fetcher.Error;
12
+ }
13
+ interface _Utils {
14
+ _visit: <_Result>(visitor: FernVenusApi.organization.setDocsUrl.Error._Visitor<_Result>) => _Result;
15
+ }
16
+ interface _Visitor<_Result> {
17
+ unprocessableEntityError: (value: FernVenusApi.HttpValidationError) => _Result;
18
+ _other: (value: core.Fetcher.Error) => _Result;
19
+ }
20
+ }
21
+ export declare const Error: {
22
+ readonly unprocessableEntityError: (value: FernVenusApi.HttpValidationError) => FernVenusApi.organization.setDocsUrl.Error.UnprocessableEntityError;
23
+ readonly _unknown: (fetcherError: core.Fetcher.Error) => FernVenusApi.organization.setDocsUrl.Error._Unknown;
24
+ readonly _visit: <_Result>(value: FernVenusApi.organization.setDocsUrl.Error, visitor: FernVenusApi.organization.setDocsUrl.Error._Visitor<_Result>) => _Result;
25
+ };
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
+ if (k2 === undefined) k2 = k;
5
+ var desc = Object.getOwnPropertyDescriptor(m, k);
6
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
+ desc = { enumerable: true, get: function() { return m[k]; } };
8
+ }
9
+ Object.defineProperty(o, k2, desc);
10
+ }) : (function(o, m, k, k2) {
11
+ if (k2 === undefined) k2 = k;
12
+ o[k2] = m[k];
13
+ }));
14
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
15
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
16
+ }) : function(o, v) {
17
+ o["default"] = v;
18
+ });
19
+ var __importStar = (this && this.__importStar) || (function () {
20
+ var ownKeys = function(o) {
21
+ ownKeys = Object.getOwnPropertyNames || function (o) {
22
+ var ar = [];
23
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
24
+ return ar;
25
+ };
26
+ return ownKeys(o);
27
+ };
28
+ return function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
35
+ })();
36
+ Object.defineProperty(exports, "__esModule", { value: true });
37
+ exports.Error = void 0;
38
+ const FernVenusApi = __importStar(require("../../../index.js"));
39
+ exports.Error = {
40
+ unprocessableEntityError: (value) => {
41
+ return {
42
+ content: value,
43
+ statusCode: 422,
44
+ _visit: function (visitor) {
45
+ return FernVenusApi.organization.setDocsUrl.Error._visit(this, visitor);
46
+ },
47
+ };
48
+ },
49
+ _unknown: (fetcherError) => {
50
+ return {
51
+ statusCode: undefined,
52
+ content: fetcherError,
53
+ _visit: function (visitor) {
54
+ return FernVenusApi.organization.setDocsUrl.Error._visit(this, visitor);
55
+ },
56
+ };
57
+ },
58
+ _visit: (value, visitor) => {
59
+ switch (value.statusCode) {
60
+ case 422:
61
+ return visitor.unprocessableEntityError(value.content);
62
+ default:
63
+ return visitor._other(value.content);
64
+ }
65
+ },
66
+ };
@@ -0,0 +1,6 @@
1
+ import type * as FernVenusApi from "../index.js";
2
+ export interface PostmanTeamDocsResponse {
3
+ organizationId: string;
4
+ claimStatus: FernVenusApi.ClaimStatus;
5
+ docsUrl: string;
6
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -20,6 +20,7 @@ export * from "./Npm.js";
20
20
  export * from "./NpmRegistryToken.js";
21
21
  export * from "./Organization.js";
22
22
  export * from "./OrganizationsPage.js";
23
+ export * from "./PostmanTeamDocsResponse.js";
23
24
  export * from "./Pypi.js";
24
25
  export * from "./PypiRegistryToken.js";
25
26
  export * from "./RegistryToken.js";
@@ -36,6 +36,7 @@ __exportStar(require("./Npm.js"), exports);
36
36
  __exportStar(require("./NpmRegistryToken.js"), exports);
37
37
  __exportStar(require("./Organization.js"), exports);
38
38
  __exportStar(require("./OrganizationsPage.js"), exports);
39
+ __exportStar(require("./PostmanTeamDocsResponse.js"), exports);
39
40
  __exportStar(require("./Pypi.js"), exports);
40
41
  __exportStar(require("./PypiRegistryToken.js"), exports);
41
42
  __exportStar(require("./RegistryToken.js"), exports);