@fern-api/venus-api-sdk 15.0.0 → 15.2.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 (72) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/organization/client/Client.d.ts +38 -1
  3. package/dist/cjs/api/resources/organization/client/Client.js +176 -1
  4. package/dist/cjs/api/resources/organization/client/claimGithub.d.ts +25 -0
  5. package/dist/cjs/api/resources/organization/client/claimGithub.js +66 -0
  6. package/dist/cjs/api/resources/organization/client/index.d.ts +2 -0
  7. package/dist/cjs/api/resources/organization/client/index.js +3 -1
  8. package/dist/cjs/api/resources/organization/client/previewGithubClaim.d.ts +25 -0
  9. package/dist/cjs/api/resources/organization/client/previewGithubClaim.js +66 -0
  10. package/dist/cjs/api/resources/organization/client/requests/ClaimGithubOrganizationRequest.d.ts +11 -0
  11. package/dist/cjs/api/resources/organization/client/requests/ClaimGithubOrganizationRequest.js +3 -0
  12. package/dist/cjs/api/resources/organization/client/requests/GithubClaimPreviewRequest.d.ts +9 -0
  13. package/dist/cjs/api/resources/organization/client/requests/GithubClaimPreviewRequest.js +3 -0
  14. package/dist/cjs/api/resources/organization/client/requests/index.d.ts +2 -0
  15. package/dist/cjs/api/types/GithubClaimPreviewResponse.d.ts +7 -0
  16. package/dist/cjs/api/types/GithubClaimPreviewResponse.js +3 -0
  17. package/dist/cjs/api/types/Publisher.d.ts +4 -3
  18. package/dist/cjs/api/types/PublisherType.d.ts +1 -0
  19. package/dist/cjs/api/types/PublisherType.js +1 -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/ClaimGithubOrganizationRequest.d.ts +10 -0
  23. package/dist/cjs/serialization/resources/organization/client/requests/ClaimGithubOrganizationRequest.js +42 -0
  24. package/dist/cjs/serialization/resources/organization/client/requests/GithubClaimPreviewRequest.d.ts +9 -0
  25. package/dist/cjs/serialization/resources/organization/client/requests/GithubClaimPreviewRequest.js +41 -0
  26. package/dist/cjs/serialization/resources/organization/client/requests/index.d.ts +2 -0
  27. package/dist/cjs/serialization/resources/organization/client/requests/index.js +5 -1
  28. package/dist/cjs/serialization/types/GithubClaimPreviewResponse.d.ts +13 -0
  29. package/dist/cjs/serialization/types/GithubClaimPreviewResponse.js +45 -0
  30. package/dist/cjs/serialization/types/PublisherType.d.ts +1 -1
  31. package/dist/cjs/serialization/types/PublisherType.js +1 -1
  32. package/dist/cjs/serialization/types/index.d.ts +1 -0
  33. package/dist/cjs/serialization/types/index.js +1 -0
  34. package/dist/cjs/version.d.ts +1 -1
  35. package/dist/cjs/version.js +1 -1
  36. package/dist/esm/BaseClient.mjs +2 -2
  37. package/dist/esm/api/resources/organization/client/Client.d.mts +38 -1
  38. package/dist/esm/api/resources/organization/client/Client.mjs +176 -1
  39. package/dist/esm/api/resources/organization/client/claimGithub.d.mts +25 -0
  40. package/dist/esm/api/resources/organization/client/claimGithub.mjs +30 -0
  41. package/dist/esm/api/resources/organization/client/index.d.mts +2 -0
  42. package/dist/esm/api/resources/organization/client/index.mjs +2 -0
  43. package/dist/esm/api/resources/organization/client/previewGithubClaim.d.mts +25 -0
  44. package/dist/esm/api/resources/organization/client/previewGithubClaim.mjs +30 -0
  45. package/dist/esm/api/resources/organization/client/requests/ClaimGithubOrganizationRequest.d.mts +11 -0
  46. package/dist/esm/api/resources/organization/client/requests/ClaimGithubOrganizationRequest.mjs +2 -0
  47. package/dist/esm/api/resources/organization/client/requests/GithubClaimPreviewRequest.d.mts +9 -0
  48. package/dist/esm/api/resources/organization/client/requests/GithubClaimPreviewRequest.mjs +2 -0
  49. package/dist/esm/api/resources/organization/client/requests/index.d.mts +2 -0
  50. package/dist/esm/api/types/GithubClaimPreviewResponse.d.mts +7 -0
  51. package/dist/esm/api/types/GithubClaimPreviewResponse.mjs +2 -0
  52. package/dist/esm/api/types/Publisher.d.mts +4 -3
  53. package/dist/esm/api/types/PublisherType.d.mts +1 -0
  54. package/dist/esm/api/types/PublisherType.mjs +1 -0
  55. package/dist/esm/api/types/index.d.mts +1 -0
  56. package/dist/esm/api/types/index.mjs +1 -0
  57. package/dist/esm/serialization/resources/organization/client/requests/ClaimGithubOrganizationRequest.d.mts +10 -0
  58. package/dist/esm/serialization/resources/organization/client/requests/ClaimGithubOrganizationRequest.mjs +6 -0
  59. package/dist/esm/serialization/resources/organization/client/requests/GithubClaimPreviewRequest.d.mts +9 -0
  60. package/dist/esm/serialization/resources/organization/client/requests/GithubClaimPreviewRequest.mjs +5 -0
  61. package/dist/esm/serialization/resources/organization/client/requests/index.d.mts +2 -0
  62. package/dist/esm/serialization/resources/organization/client/requests/index.mjs +2 -0
  63. package/dist/esm/serialization/types/GithubClaimPreviewResponse.d.mts +13 -0
  64. package/dist/esm/serialization/types/GithubClaimPreviewResponse.mjs +9 -0
  65. package/dist/esm/serialization/types/PublisherType.d.mts +1 -1
  66. package/dist/esm/serialization/types/PublisherType.mjs +1 -1
  67. package/dist/esm/serialization/types/index.d.mts +1 -0
  68. package/dist/esm/serialization/types/index.mjs +1 -0
  69. package/dist/esm/version.d.mts +1 -1
  70. package/dist/esm/version.mjs +1 -1
  71. package/package.json +1 -1
  72. package/reference.md +142 -1
@@ -0,0 +1,7 @@
1
+ import type * as FernVenusApi from "../index.mjs";
2
+ export interface GithubClaimPreviewResponse {
3
+ organizationId: string;
4
+ displayName: string;
5
+ claimStatus: FernVenusApi.ClaimStatus;
6
+ repositoryId: string;
7
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -1,8 +1,9 @@
1
1
  import type * as FernVenusApi from "../index.mjs";
2
2
  /**
3
- * Who an unclaimed organization is held for: a Postman team, or a single
4
- * Postman user. Whoever the calling service verifies as the publisher can
5
- * get a claim link for it.
3
+ * Who an unclaimed organization is held for: a Postman team, a single
4
+ * Postman user, or a GitHub repository. Whoever the calling service verifies
5
+ * as a Postman publisher can get a claim link for it. A GitHub repository's
6
+ * organization can't be claimed yet.
6
7
  */
7
8
  export interface Publisher {
8
9
  type: FernVenusApi.PublisherType;
@@ -1,5 +1,6 @@
1
1
  export declare const PublisherType: {
2
2
  readonly PostmanTeam: "postman_team";
3
3
  readonly PostmanUser: "postman_user";
4
+ readonly GithubRepo: "github_repo";
4
5
  };
5
6
  export type PublisherType = (typeof PublisherType)[keyof typeof PublisherType];
@@ -2,4 +2,5 @@
2
2
  export const PublisherType = {
3
3
  PostmanTeam: "postman_team",
4
4
  PostmanUser: "postman_user",
5
+ GithubRepo: "github_repo",
5
6
  };
@@ -15,6 +15,7 @@ export * from "./DeleteGuestSessionResponseStatus.mjs";
15
15
  export * from "./Expired.mjs";
16
16
  export * from "./GetGuestSessionResponse.mjs";
17
17
  export * from "./GetGuestSessionResponseStatus.mjs";
18
+ export * from "./GithubClaimPreviewResponse.mjs";
18
19
  export * from "./GoneErrorBody.mjs";
19
20
  export * from "./GoneErrorBodyContent.mjs";
20
21
  export * from "./GoneErrorBodyContentCode.mjs";
@@ -15,6 +15,7 @@ export * from "./DeleteGuestSessionResponseStatus.mjs";
15
15
  export * from "./Expired.mjs";
16
16
  export * from "./GetGuestSessionResponse.mjs";
17
17
  export * from "./GetGuestSessionResponseStatus.mjs";
18
+ export * from "./GithubClaimPreviewResponse.mjs";
18
19
  export * from "./GoneErrorBody.mjs";
19
20
  export * from "./GoneErrorBodyContent.mjs";
20
21
  export * from "./GoneErrorBodyContentCode.mjs";
@@ -0,0 +1,10 @@
1
+ import type * as FernVenusApi from "../../../../../api/index.mjs";
2
+ import * as core from "../../../../../core/index.mjs";
3
+ import type * as serializers from "../../../../index.mjs";
4
+ export declare const ClaimGithubOrganizationRequest: core.serialization.Schema<serializers.ClaimGithubOrganizationRequest.Raw, FernVenusApi.ClaimGithubOrganizationRequest>;
5
+ export declare namespace ClaimGithubOrganizationRequest {
6
+ interface Raw {
7
+ organizationId: string;
8
+ githubToken: string;
9
+ }
10
+ }
@@ -0,0 +1,6 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ import * as core from "../../../../../core/index.mjs";
3
+ export const ClaimGithubOrganizationRequest = core.serialization.object({
4
+ organizationId: core.serialization.string(),
5
+ githubToken: core.serialization.string(),
6
+ });
@@ -0,0 +1,9 @@
1
+ import type * as FernVenusApi from "../../../../../api/index.mjs";
2
+ import * as core from "../../../../../core/index.mjs";
3
+ import type * as serializers from "../../../../index.mjs";
4
+ export declare const GithubClaimPreviewRequest: core.serialization.Schema<serializers.GithubClaimPreviewRequest.Raw, FernVenusApi.GithubClaimPreviewRequest>;
5
+ export declare namespace GithubClaimPreviewRequest {
6
+ interface Raw {
7
+ organizationId: string;
8
+ }
9
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ import * as core from "../../../../../core/index.mjs";
3
+ export const GithubClaimPreviewRequest = core.serialization.object({
4
+ organizationId: core.serialization.string(),
5
+ });
@@ -1,6 +1,8 @@
1
1
  export { AddUserToOrgRequest } from "./AddUserToOrgRequest.mjs";
2
+ export { ClaimGithubOrganizationRequest } from "./ClaimGithubOrganizationRequest.mjs";
2
3
  export { CreateClaimTokenRequest } from "./CreateClaimTokenRequest.mjs";
3
4
  export { CreateOrganizationRequest } from "./CreateOrganizationRequest.mjs";
5
+ export { GithubClaimPreviewRequest } from "./GithubClaimPreviewRequest.mjs";
4
6
  export { InviteUserToOrgRequest } from "./InviteUserToOrgRequest.mjs";
5
7
  export { RemoveUserFromOrgRequest } from "./RemoveUserFromOrgRequest.mjs";
6
8
  export { SetDocsUrlRequest } from "./SetDocsUrlRequest.mjs";
@@ -1,6 +1,8 @@
1
1
  export { AddUserToOrgRequest } from "./AddUserToOrgRequest.mjs";
2
+ export { ClaimGithubOrganizationRequest } from "./ClaimGithubOrganizationRequest.mjs";
2
3
  export { CreateClaimTokenRequest } from "./CreateClaimTokenRequest.mjs";
3
4
  export { CreateOrganizationRequest } from "./CreateOrganizationRequest.mjs";
5
+ export { GithubClaimPreviewRequest } from "./GithubClaimPreviewRequest.mjs";
4
6
  export { InviteUserToOrgRequest } from "./InviteUserToOrgRequest.mjs";
5
7
  export { RemoveUserFromOrgRequest } from "./RemoveUserFromOrgRequest.mjs";
6
8
  export { SetDocsUrlRequest } from "./SetDocsUrlRequest.mjs";
@@ -0,0 +1,13 @@
1
+ import type * as FernVenusApi from "../../api/index.mjs";
2
+ import * as core from "../../core/index.mjs";
3
+ import type * as serializers from "../index.mjs";
4
+ import { ClaimStatus } from "./ClaimStatus.mjs";
5
+ export declare const GithubClaimPreviewResponse: core.serialization.ObjectSchema<serializers.GithubClaimPreviewResponse.Raw, FernVenusApi.GithubClaimPreviewResponse>;
6
+ export declare namespace GithubClaimPreviewResponse {
7
+ interface Raw {
8
+ organizationId: string;
9
+ displayName: string;
10
+ claimStatus: ClaimStatus.Raw;
11
+ repositoryId: string;
12
+ }
13
+ }
@@ -0,0 +1,9 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ import * as core from "../../core/index.mjs";
3
+ import { ClaimStatus } from "./ClaimStatus.mjs";
4
+ export const GithubClaimPreviewResponse = core.serialization.object({
5
+ organizationId: core.serialization.string(),
6
+ displayName: core.serialization.string(),
7
+ claimStatus: ClaimStatus,
8
+ repositoryId: core.serialization.string(),
9
+ });
@@ -3,5 +3,5 @@ import * as core from "../../core/index.mjs";
3
3
  import type * as serializers from "../index.mjs";
4
4
  export declare const PublisherType: core.serialization.Schema<serializers.PublisherType.Raw, FernVenusApi.PublisherType>;
5
5
  export declare namespace PublisherType {
6
- type Raw = "postman_team" | "postman_user";
6
+ type Raw = "postman_team" | "postman_user" | "github_repo";
7
7
  }
@@ -1,3 +1,3 @@
1
1
  // This file was auto-generated by Fern from our API Definition.
2
2
  import * as core from "../../core/index.mjs";
3
- export const PublisherType = core.serialization.enum_(["postman_team", "postman_user"]);
3
+ export const PublisherType = core.serialization.enum_(["postman_team", "postman_user", "github_repo"]);
@@ -15,6 +15,7 @@ export * from "./DeleteGuestSessionResponseStatus.mjs";
15
15
  export * from "./Expired.mjs";
16
16
  export * from "./GetGuestSessionResponse.mjs";
17
17
  export * from "./GetGuestSessionResponseStatus.mjs";
18
+ export * from "./GithubClaimPreviewResponse.mjs";
18
19
  export * from "./GoneErrorBody.mjs";
19
20
  export * from "./GoneErrorBodyContent.mjs";
20
21
  export * from "./GoneErrorBodyContentCode.mjs";
@@ -15,6 +15,7 @@ export * from "./DeleteGuestSessionResponseStatus.mjs";
15
15
  export * from "./Expired.mjs";
16
16
  export * from "./GetGuestSessionResponse.mjs";
17
17
  export * from "./GetGuestSessionResponseStatus.mjs";
18
+ export * from "./GithubClaimPreviewResponse.mjs";
18
19
  export * from "./GoneErrorBody.mjs";
19
20
  export * from "./GoneErrorBodyContent.mjs";
20
21
  export * from "./GoneErrorBodyContentCode.mjs";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "15.0.0";
1
+ export declare const SDK_VERSION = "15.2.0";
@@ -1 +1 @@
1
- export const SDK_VERSION = "15.0.0";
1
+ export const SDK_VERSION = "15.2.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fern-api/venus-api-sdk",
3
- "version": "15.0.0",
3
+ "version": "15.2.0",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
package/reference.md CHANGED
@@ -1577,7 +1577,10 @@ Issues a claim link for an unclaimed organization, bound to one Postman
1577
1577
  user and valid for 15 minutes. Only the provisioner token and Postman's
1578
1578
  integration service token can call it. For an organization held for a
1579
1579
  Postman user, the caller must name that user as the publisher, or gets
1580
- 403 PublisherMismatchError.
1580
+ 403 PublisherMismatchError. An organization held for a GitHub
1581
+ repository always gets 403 PublisherMismatchError: a link is redeemed
1582
+ with a Postman sign-in, which says nothing about who owns the
1583
+ repository.
1581
1584
  </dd>
1582
1585
  </dl>
1583
1586
  </dd>
@@ -1904,6 +1907,144 @@ await client.organization.claimFromDocsSite({
1904
1907
  </dl>
1905
1908
 
1906
1909
 
1910
+ </dd>
1911
+ </dl>
1912
+ </details>
1913
+
1914
+ <details><summary><code>client.organization.<a href="/src/api/resources/organization/client/Client.ts">claimGithub</a>({ ...params }) -> core.APIResponse&lt;FernVenusApi.ClaimOrganizationResponse, FernVenusApi.organization.claimGithub.Error&gt;</code></summary>
1915
+ <dl>
1916
+ <dd>
1917
+
1918
+ #### 📝 Description
1919
+
1920
+ <dl>
1921
+ <dd>
1922
+
1923
+ <dl>
1924
+ <dd>
1925
+
1926
+ Claims an organization held for a GitHub repo. The caller, signed in to
1927
+ Fern, sends a GitHub token of theirs; Venus asks GitHub with it about the
1928
+ repo and claims the organization for the caller only if GitHub says they
1929
+ are an admin of it. They become the organization's admin. The token is
1930
+ used for that one request and never stored. The first claim wins, and a
1931
+ retry by the same user finishes a claim that failed partway.
1932
+ </dd>
1933
+ </dl>
1934
+ </dd>
1935
+ </dl>
1936
+
1937
+ #### 🔌 Usage
1938
+
1939
+ <dl>
1940
+ <dd>
1941
+
1942
+ <dl>
1943
+ <dd>
1944
+
1945
+ ```typescript
1946
+ await client.organization.claimGithub({
1947
+ organizationId: "organizationId",
1948
+ githubToken: "githubToken"
1949
+ });
1950
+
1951
+ ```
1952
+ </dd>
1953
+ </dl>
1954
+ </dd>
1955
+ </dl>
1956
+
1957
+ #### ⚙️ Parameters
1958
+
1959
+ <dl>
1960
+ <dd>
1961
+
1962
+ <dl>
1963
+ <dd>
1964
+
1965
+ **request:** `FernVenusApi.ClaimGithubOrganizationRequest`
1966
+
1967
+ </dd>
1968
+ </dl>
1969
+
1970
+ <dl>
1971
+ <dd>
1972
+
1973
+ **requestOptions:** `OrganizationClient.RequestOptions`
1974
+
1975
+ </dd>
1976
+ </dl>
1977
+ </dd>
1978
+ </dl>
1979
+
1980
+
1981
+ </dd>
1982
+ </dl>
1983
+ </details>
1984
+
1985
+ <details><summary><code>client.organization.<a href="/src/api/resources/organization/client/Client.ts">previewGithubClaim</a>({ ...params }) -> core.APIResponse&lt;FernVenusApi.GithubClaimPreviewResponse, FernVenusApi.organization.previewGithubClaim.Error&gt;</code></summary>
1986
+ <dl>
1987
+ <dd>
1988
+
1989
+ #### 📝 Description
1990
+
1991
+ <dl>
1992
+ <dd>
1993
+
1994
+ <dl>
1995
+ <dd>
1996
+
1997
+ What an organization held for a GitHub repo is, and whether it has been
1998
+ claimed, so the dashboard can show it before the user signs in. Public:
1999
+ the organization's docs site already names the repo.
2000
+ </dd>
2001
+ </dl>
2002
+ </dd>
2003
+ </dl>
2004
+
2005
+ #### 🔌 Usage
2006
+
2007
+ <dl>
2008
+ <dd>
2009
+
2010
+ <dl>
2011
+ <dd>
2012
+
2013
+ ```typescript
2014
+ await client.organization.previewGithubClaim({
2015
+ organizationId: "organizationId"
2016
+ });
2017
+
2018
+ ```
2019
+ </dd>
2020
+ </dl>
2021
+ </dd>
2022
+ </dl>
2023
+
2024
+ #### ⚙️ Parameters
2025
+
2026
+ <dl>
2027
+ <dd>
2028
+
2029
+ <dl>
2030
+ <dd>
2031
+
2032
+ **request:** `FernVenusApi.GithubClaimPreviewRequest`
2033
+
2034
+ </dd>
2035
+ </dl>
2036
+
2037
+ <dl>
2038
+ <dd>
2039
+
2040
+ **requestOptions:** `OrganizationClient.RequestOptions`
2041
+
2042
+ </dd>
2043
+ </dl>
2044
+ </dd>
2045
+ </dl>
2046
+
2047
+
1907
2048
  </dd>
1908
2049
  </dl>
1909
2050
  </details>