@fern-api/venus-api-sdk 11.2.0 → 11.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/organization/client/Client.d.ts +46 -0
  3. package/dist/cjs/api/resources/organization/client/Client.js +254 -0
  4. package/dist/cjs/api/resources/organization/client/claim.d.ts +25 -0
  5. package/dist/cjs/api/resources/organization/client/claim.js +66 -0
  6. package/dist/cjs/api/resources/organization/client/createClaimToken.d.ts +25 -0
  7. package/dist/cjs/api/resources/organization/client/createClaimToken.js +66 -0
  8. package/dist/cjs/api/resources/organization/client/index.d.ts +3 -0
  9. package/dist/cjs/api/resources/organization/client/index.js +4 -1
  10. package/dist/cjs/api/resources/organization/client/previewClaim.d.ts +25 -0
  11. package/dist/cjs/api/resources/organization/client/previewClaim.js +66 -0
  12. package/dist/cjs/api/resources/organization/client/requests/CreateClaimTokenRequest.d.ts +11 -0
  13. package/dist/cjs/api/resources/organization/client/requests/CreateClaimTokenRequest.js +3 -0
  14. package/dist/cjs/api/resources/organization/client/requests/index.d.ts +1 -0
  15. package/dist/cjs/api/types/ClaimOrganizationRequest.d.ts +3 -0
  16. package/dist/cjs/api/types/ClaimOrganizationRequest.js +3 -0
  17. package/dist/cjs/api/types/ClaimOrganizationResponse.d.ts +5 -0
  18. package/dist/cjs/api/types/ClaimOrganizationResponse.js +3 -0
  19. package/dist/cjs/api/types/ClaimPreviewResponse.d.ts +8 -0
  20. package/dist/cjs/api/types/ClaimPreviewResponse.js +3 -0
  21. package/dist/cjs/api/types/ClaimTokenResponse.d.ts +4 -0
  22. package/dist/cjs/api/types/ClaimTokenResponse.js +3 -0
  23. package/dist/cjs/api/types/index.d.ts +4 -0
  24. package/dist/cjs/api/types/index.js +4 -0
  25. package/dist/cjs/serialization/resources/organization/client/requests/CreateClaimTokenRequest.d.ts +9 -0
  26. package/dist/cjs/serialization/resources/organization/client/requests/CreateClaimTokenRequest.js +41 -0
  27. package/dist/cjs/serialization/resources/organization/client/requests/index.d.ts +1 -0
  28. package/dist/cjs/serialization/resources/organization/client/requests/index.js +3 -1
  29. package/dist/cjs/serialization/types/ClaimOrganizationRequest.d.ts +9 -0
  30. package/dist/cjs/serialization/types/ClaimOrganizationRequest.js +41 -0
  31. package/dist/cjs/serialization/types/ClaimOrganizationResponse.d.ts +11 -0
  32. package/dist/cjs/serialization/types/ClaimOrganizationResponse.js +43 -0
  33. package/dist/cjs/serialization/types/ClaimPreviewResponse.d.ts +14 -0
  34. package/dist/cjs/serialization/types/ClaimPreviewResponse.js +46 -0
  35. package/dist/cjs/serialization/types/ClaimTokenResponse.d.ts +10 -0
  36. package/dist/cjs/serialization/types/ClaimTokenResponse.js +42 -0
  37. package/dist/cjs/serialization/types/index.d.ts +4 -0
  38. package/dist/cjs/serialization/types/index.js +4 -0
  39. package/dist/cjs/version.d.ts +1 -1
  40. package/dist/cjs/version.js +1 -1
  41. package/dist/esm/BaseClient.mjs +2 -2
  42. package/dist/esm/api/resources/organization/client/Client.d.mts +46 -0
  43. package/dist/esm/api/resources/organization/client/Client.mjs +254 -0
  44. package/dist/esm/api/resources/organization/client/claim.d.mts +25 -0
  45. package/dist/esm/api/resources/organization/client/claim.mjs +30 -0
  46. package/dist/esm/api/resources/organization/client/createClaimToken.d.mts +25 -0
  47. package/dist/esm/api/resources/organization/client/createClaimToken.mjs +30 -0
  48. package/dist/esm/api/resources/organization/client/index.d.mts +3 -0
  49. package/dist/esm/api/resources/organization/client/index.mjs +3 -0
  50. package/dist/esm/api/resources/organization/client/previewClaim.d.mts +25 -0
  51. package/dist/esm/api/resources/organization/client/previewClaim.mjs +30 -0
  52. package/dist/esm/api/resources/organization/client/requests/CreateClaimTokenRequest.d.mts +11 -0
  53. package/dist/esm/api/resources/organization/client/requests/CreateClaimTokenRequest.mjs +2 -0
  54. package/dist/esm/api/resources/organization/client/requests/index.d.mts +1 -0
  55. package/dist/esm/api/types/ClaimOrganizationRequest.d.mts +3 -0
  56. package/dist/esm/api/types/ClaimOrganizationRequest.mjs +2 -0
  57. package/dist/esm/api/types/ClaimOrganizationResponse.d.mts +5 -0
  58. package/dist/esm/api/types/ClaimOrganizationResponse.mjs +2 -0
  59. package/dist/esm/api/types/ClaimPreviewResponse.d.mts +8 -0
  60. package/dist/esm/api/types/ClaimPreviewResponse.mjs +2 -0
  61. package/dist/esm/api/types/ClaimTokenResponse.d.mts +4 -0
  62. package/dist/esm/api/types/ClaimTokenResponse.mjs +2 -0
  63. package/dist/esm/api/types/index.d.mts +4 -0
  64. package/dist/esm/api/types/index.mjs +4 -0
  65. package/dist/esm/serialization/resources/organization/client/requests/CreateClaimTokenRequest.d.mts +9 -0
  66. package/dist/esm/serialization/resources/organization/client/requests/CreateClaimTokenRequest.mjs +5 -0
  67. package/dist/esm/serialization/resources/organization/client/requests/index.d.mts +1 -0
  68. package/dist/esm/serialization/resources/organization/client/requests/index.mjs +1 -0
  69. package/dist/esm/serialization/types/ClaimOrganizationRequest.d.mts +9 -0
  70. package/dist/esm/serialization/types/ClaimOrganizationRequest.mjs +5 -0
  71. package/dist/esm/serialization/types/ClaimOrganizationResponse.d.mts +11 -0
  72. package/dist/esm/serialization/types/ClaimOrganizationResponse.mjs +7 -0
  73. package/dist/esm/serialization/types/ClaimPreviewResponse.d.mts +14 -0
  74. package/dist/esm/serialization/types/ClaimPreviewResponse.mjs +10 -0
  75. package/dist/esm/serialization/types/ClaimTokenResponse.d.mts +10 -0
  76. package/dist/esm/serialization/types/ClaimTokenResponse.mjs +6 -0
  77. package/dist/esm/serialization/types/index.d.mts +4 -0
  78. package/dist/esm/serialization/types/index.mjs +4 -0
  79. package/dist/esm/version.d.mts +1 -1
  80. package/dist/esm/version.mjs +1 -1
  81. package/package.json +1 -1
  82. package/reference.md +202 -0
@@ -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.2.0",
47
- "User-Agent": "@fern-api/venus-api-sdk/11.2.0",
46
+ "X-Fern-SDK-Version": "11.4.0",
47
+ "User-Agent": "@fern-api/venus-api-sdk/11.4.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);
@@ -104,6 +104,52 @@ export declare class OrganizationClient {
104
104
  */
105
105
  getClaimStatus(request: FernVenusApi.GetClaimStatusOrganizationsOrgIdClaimStatusGetRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.ClaimStatusResponse, FernVenusApi.organization.getClaimStatus.Error>>;
106
106
  private __getClaimStatus;
107
+ /**
108
+ * 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.
110
+ *
111
+ * @param {FernVenusApi.CreateClaimTokenRequest} request
112
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
113
+ *
114
+ * @example
115
+ * await client.organization.createClaimToken({
116
+ * orgId: "org_id",
117
+ * postmanUserId: "postmanUserId"
118
+ * })
119
+ */
120
+ createClaimToken(request: FernVenusApi.CreateClaimTokenRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.ClaimTokenResponse, FernVenusApi.organization.createClaimToken.Error>>;
121
+ private __createClaimToken;
122
+ /**
123
+ * Redeems a claim link. The caller, signed in as the Postman user the link
124
+ * is for, becomes the admin of the organization. The first claim wins, and
125
+ * a retry by the same user finishes a claim that failed partway.
126
+ *
127
+ * @param {FernVenusApi.ClaimOrganizationRequest} request
128
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
129
+ *
130
+ * @example
131
+ * await client.organization.claim({
132
+ * claimToken: "claimToken"
133
+ * })
134
+ */
135
+ claim(request: FernVenusApi.ClaimOrganizationRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.ClaimOrganizationResponse, FernVenusApi.organization.claim.Error>>;
136
+ private __claim;
137
+ /**
138
+ * What a claim link is for, without redeeming it, so the dashboard can show
139
+ * the organization and the link's state before the user signs in. Public:
140
+ * the link is the secret. The token is in the body to keep it out of
141
+ * request logs.
142
+ *
143
+ * @param {FernVenusApi.ClaimOrganizationRequest} request
144
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
145
+ *
146
+ * @example
147
+ * await client.organization.previewClaim({
148
+ * claimToken: "claimToken"
149
+ * })
150
+ */
151
+ previewClaim(request: FernVenusApi.ClaimOrganizationRequest, requestOptions?: OrganizationClient.RequestOptions): core.HttpResponsePromise<core.APIResponse<FernVenusApi.ClaimPreviewResponse, FernVenusApi.organization.previewClaim.Error>>;
152
+ private __previewClaim;
107
153
  /**
108
154
  * @param {FernVenusApi.IsMemberOrganizationsBelongsToOrganizationOrganizationIdPostRequest} request
109
155
  * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -608,6 +608,260 @@ class OrganizationClient {
608
608
  };
609
609
  });
610
610
  }
611
+ /**
612
+ * 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.
614
+ *
615
+ * @param {FernVenusApi.CreateClaimTokenRequest} request
616
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
617
+ *
618
+ * @example
619
+ * await client.organization.createClaimToken({
620
+ * orgId: "org_id",
621
+ * postmanUserId: "postmanUserId"
622
+ * })
623
+ */
624
+ createClaimToken(request, requestOptions) {
625
+ return core.HttpResponsePromise.fromPromise(this.__createClaimToken(request, requestOptions));
626
+ }
627
+ __createClaimToken(request, requestOptions) {
628
+ return __awaiter(this, void 0, void 0, function* () {
629
+ var _a, _b, _c, _d, _e, _f, _g, _h;
630
+ const { orgId } = request, _body = __rest(request, ["orgId"]);
631
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
632
+ 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);
633
+ const _response = yield core.fetcher({
634
+ 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)}/claim-tokens`),
635
+ method: "POST",
636
+ headers: _headers,
637
+ contentType: "application/json",
638
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
639
+ requestType: "json",
640
+ body: serializers.CreateClaimTokenRequest.jsonOrThrow(_body, {
641
+ unrecognizedObjectKeys: "strip",
642
+ omitUndefined: true,
643
+ }),
644
+ 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,
645
+ 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,
646
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
647
+ fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
648
+ logging: this._options.logging,
649
+ });
650
+ if (_response.ok) {
651
+ return {
652
+ data: {
653
+ ok: true,
654
+ body: serializers.ClaimTokenResponse.parseOrThrow(_response.body, {
655
+ unrecognizedObjectKeys: "passthrough",
656
+ allowUnrecognizedUnionMembers: true,
657
+ allowUnrecognizedEnumValues: true,
658
+ skipValidation: true,
659
+ breadcrumbsPrefix: ["response"],
660
+ }),
661
+ headers: _response.headers,
662
+ rawResponse: _response.rawResponse,
663
+ },
664
+ rawResponse: _response.rawResponse,
665
+ };
666
+ }
667
+ if (_response.error.reason === "status-code") {
668
+ switch (_response.error.statusCode) {
669
+ case 422:
670
+ return {
671
+ data: {
672
+ ok: false,
673
+ error: FernVenusApi.organization.createClaimToken.Error.unprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
674
+ unrecognizedObjectKeys: "passthrough",
675
+ allowUnrecognizedUnionMembers: true,
676
+ allowUnrecognizedEnumValues: true,
677
+ skipValidation: true,
678
+ breadcrumbsPrefix: ["response"],
679
+ })),
680
+ rawResponse: _response.rawResponse,
681
+ },
682
+ rawResponse: _response.rawResponse,
683
+ };
684
+ }
685
+ }
686
+ return {
687
+ data: {
688
+ ok: false,
689
+ error: FernVenusApi.organization.createClaimToken.Error._unknown(_response.error),
690
+ rawResponse: _response.rawResponse,
691
+ },
692
+ rawResponse: _response.rawResponse,
693
+ };
694
+ });
695
+ }
696
+ /**
697
+ * Redeems a claim link. The caller, signed in as the Postman user the link
698
+ * is for, becomes the admin of the organization. The first claim wins, and
699
+ * a retry by the same user finishes a claim that failed partway.
700
+ *
701
+ * @param {FernVenusApi.ClaimOrganizationRequest} request
702
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
703
+ *
704
+ * @example
705
+ * await client.organization.claim({
706
+ * claimToken: "claimToken"
707
+ * })
708
+ */
709
+ claim(request, requestOptions) {
710
+ return core.HttpResponsePromise.fromPromise(this.__claim(request, requestOptions));
711
+ }
712
+ __claim(request, requestOptions) {
713
+ return __awaiter(this, void 0, void 0, function* () {
714
+ var _a, _b, _c, _d, _e, _f, _g, _h;
715
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
716
+ 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);
717
+ const _response = yield core.fetcher({
718
+ 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/claim"),
719
+ method: "POST",
720
+ headers: _headers,
721
+ contentType: "application/json",
722
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
723
+ requestType: "json",
724
+ body: serializers.ClaimOrganizationRequest.jsonOrThrow(request, {
725
+ unrecognizedObjectKeys: "strip",
726
+ omitUndefined: true,
727
+ }),
728
+ 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,
729
+ 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,
730
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
731
+ fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
732
+ logging: this._options.logging,
733
+ });
734
+ if (_response.ok) {
735
+ return {
736
+ data: {
737
+ ok: true,
738
+ body: serializers.ClaimOrganizationResponse.parseOrThrow(_response.body, {
739
+ unrecognizedObjectKeys: "passthrough",
740
+ allowUnrecognizedUnionMembers: true,
741
+ allowUnrecognizedEnumValues: true,
742
+ skipValidation: true,
743
+ breadcrumbsPrefix: ["response"],
744
+ }),
745
+ headers: _response.headers,
746
+ rawResponse: _response.rawResponse,
747
+ },
748
+ rawResponse: _response.rawResponse,
749
+ };
750
+ }
751
+ if (_response.error.reason === "status-code") {
752
+ switch (_response.error.statusCode) {
753
+ case 422:
754
+ return {
755
+ data: {
756
+ ok: false,
757
+ error: FernVenusApi.organization.claim.Error.unprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
758
+ unrecognizedObjectKeys: "passthrough",
759
+ allowUnrecognizedUnionMembers: true,
760
+ allowUnrecognizedEnumValues: true,
761
+ skipValidation: true,
762
+ breadcrumbsPrefix: ["response"],
763
+ })),
764
+ rawResponse: _response.rawResponse,
765
+ },
766
+ rawResponse: _response.rawResponse,
767
+ };
768
+ }
769
+ }
770
+ return {
771
+ data: {
772
+ ok: false,
773
+ error: FernVenusApi.organization.claim.Error._unknown(_response.error),
774
+ rawResponse: _response.rawResponse,
775
+ },
776
+ rawResponse: _response.rawResponse,
777
+ };
778
+ });
779
+ }
780
+ /**
781
+ * What a claim link is for, without redeeming it, so the dashboard can show
782
+ * the organization and the link's state before the user signs in. Public:
783
+ * the link is the secret. The token is in the body to keep it out of
784
+ * request logs.
785
+ *
786
+ * @param {FernVenusApi.ClaimOrganizationRequest} request
787
+ * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
788
+ *
789
+ * @example
790
+ * await client.organization.previewClaim({
791
+ * claimToken: "claimToken"
792
+ * })
793
+ */
794
+ previewClaim(request, requestOptions) {
795
+ return core.HttpResponsePromise.fromPromise(this.__previewClaim(request, requestOptions));
796
+ }
797
+ __previewClaim(request, requestOptions) {
798
+ return __awaiter(this, void 0, void 0, function* () {
799
+ var _a, _b, _c, _d, _e, _f, _g, _h;
800
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
801
+ 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);
802
+ const _response = yield core.fetcher({
803
+ 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/claim/preview"),
804
+ method: "POST",
805
+ headers: _headers,
806
+ contentType: "application/json",
807
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
808
+ requestType: "json",
809
+ body: serializers.ClaimOrganizationRequest.jsonOrThrow(request, {
810
+ unrecognizedObjectKeys: "strip",
811
+ omitUndefined: true,
812
+ }),
813
+ 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,
814
+ 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,
815
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
816
+ fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
817
+ logging: this._options.logging,
818
+ });
819
+ if (_response.ok) {
820
+ return {
821
+ data: {
822
+ ok: true,
823
+ body: serializers.ClaimPreviewResponse.parseOrThrow(_response.body, {
824
+ unrecognizedObjectKeys: "passthrough",
825
+ allowUnrecognizedUnionMembers: true,
826
+ allowUnrecognizedEnumValues: true,
827
+ skipValidation: true,
828
+ breadcrumbsPrefix: ["response"],
829
+ }),
830
+ headers: _response.headers,
831
+ rawResponse: _response.rawResponse,
832
+ },
833
+ rawResponse: _response.rawResponse,
834
+ };
835
+ }
836
+ if (_response.error.reason === "status-code") {
837
+ switch (_response.error.statusCode) {
838
+ case 422:
839
+ return {
840
+ data: {
841
+ ok: false,
842
+ error: FernVenusApi.organization.previewClaim.Error.unprocessableEntityError(serializers.HttpValidationError.parseOrThrow(_response.error.body, {
843
+ unrecognizedObjectKeys: "passthrough",
844
+ allowUnrecognizedUnionMembers: true,
845
+ allowUnrecognizedEnumValues: true,
846
+ skipValidation: true,
847
+ breadcrumbsPrefix: ["response"],
848
+ })),
849
+ rawResponse: _response.rawResponse,
850
+ },
851
+ rawResponse: _response.rawResponse,
852
+ };
853
+ }
854
+ }
855
+ return {
856
+ data: {
857
+ ok: false,
858
+ error: FernVenusApi.organization.previewClaim.Error._unknown(_response.error),
859
+ rawResponse: _response.rawResponse,
860
+ },
861
+ rawResponse: _response.rawResponse,
862
+ };
863
+ });
864
+ }
611
865
  /**
612
866
  * @param {FernVenusApi.IsMemberOrganizationsBelongsToOrganizationOrganizationIdPostRequest} request
613
867
  * @param {OrganizationClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -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.claim.Error.UnprocessableEntityError | FernVenusApi.organization.claim.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.claim.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.claim.Error.UnprocessableEntityError;
23
+ readonly _unknown: (fetcherError: core.Fetcher.Error) => FernVenusApi.organization.claim.Error._Unknown;
24
+ readonly _visit: <_Result>(value: FernVenusApi.organization.claim.Error, visitor: FernVenusApi.organization.claim.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.claim.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.claim.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,25 @@
1
+ import type * as core from "../../../../core/index.js";
2
+ import * as FernVenusApi from "../../../index.js";
3
+ export type Error = FernVenusApi.organization.createClaimToken.Error.UnprocessableEntityError | FernVenusApi.organization.createClaimToken.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.createClaimToken.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.createClaimToken.Error.UnprocessableEntityError;
23
+ readonly _unknown: (fetcherError: core.Fetcher.Error) => FernVenusApi.organization.createClaimToken.Error._Unknown;
24
+ readonly _visit: <_Result>(value: FernVenusApi.organization.createClaimToken.Error, visitor: FernVenusApi.organization.createClaimToken.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.createClaimToken.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.createClaimToken.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
+ };
@@ -1,5 +1,7 @@
1
1
  export * as addUser from "./addUser.js";
2
+ export * as claim from "./claim.js";
2
3
  export * as create from "./create.js";
4
+ export * as createClaimToken from "./createClaimToken.js";
3
5
  export * as delete from "./delete.js";
4
6
  export * as get from "./get.js";
5
7
  export * as getClaimStatus from "./getClaimStatus.js";
@@ -9,6 +11,7 @@ export * as getOrgIdsFromToken from "./getOrgIdsFromToken.js";
9
11
  export * as getPostmanTeamIdByOrgId from "./getPostmanTeamIdByOrgId.js";
10
12
  export * as inviteUser from "./inviteUser.js";
11
13
  export * as isMember from "./isMember.js";
14
+ export * as previewClaim from "./previewClaim.js";
12
15
  export * as removeUser from "./removeUser.js";
13
16
  export * from "./requests/index.js";
14
17
  export * as update from "./update.js";
@@ -36,9 +36,11 @@ 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.isMember = exports.inviteUser = exports.getPostmanTeamIdByOrgId = exports.getOrgIdsFromToken = exports.getOrgIdsByPostmanTeamId = exports.getMyOrganizationFromScopedToken = exports.getClaimStatus = exports.get = exports.delete = exports.create = exports.addUser = void 0;
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;
40
40
  exports.addUser = __importStar(require("./addUser.js"));
41
+ exports.claim = __importStar(require("./claim.js"));
41
42
  exports.create = __importStar(require("./create.js"));
43
+ exports.createClaimToken = __importStar(require("./createClaimToken.js"));
42
44
  exports.delete = __importStar(require("./delete.js"));
43
45
  exports.get = __importStar(require("./get.js"));
44
46
  exports.getClaimStatus = __importStar(require("./getClaimStatus.js"));
@@ -48,6 +50,7 @@ exports.getOrgIdsFromToken = __importStar(require("./getOrgIdsFromToken.js"));
48
50
  exports.getPostmanTeamIdByOrgId = __importStar(require("./getPostmanTeamIdByOrgId.js"));
49
51
  exports.inviteUser = __importStar(require("./inviteUser.js"));
50
52
  exports.isMember = __importStar(require("./isMember.js"));
53
+ exports.previewClaim = __importStar(require("./previewClaim.js"));
51
54
  exports.removeUser = __importStar(require("./removeUser.js"));
52
55
  __exportStar(require("./requests/index.js"), exports);
53
56
  exports.update = __importStar(require("./update.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.previewClaim.Error.UnprocessableEntityError | FernVenusApi.organization.previewClaim.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.previewClaim.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.previewClaim.Error.UnprocessableEntityError;
23
+ readonly _unknown: (fetcherError: core.Fetcher.Error) => FernVenusApi.organization.previewClaim.Error._Unknown;
24
+ readonly _visit: <_Result>(value: FernVenusApi.organization.previewClaim.Error, visitor: FernVenusApi.organization.previewClaim.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.previewClaim.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.previewClaim.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,11 @@
1
+ /**
2
+ * @example
3
+ * {
4
+ * orgId: "org_id",
5
+ * postmanUserId: "postmanUserId"
6
+ * }
7
+ */
8
+ export interface CreateClaimTokenRequest {
9
+ orgId: string;
10
+ postmanUserId: 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 });