@straion/cli 0.0.2 → 0.0.4
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.
- package/CHANGELOG.md +16 -3
- package/README.md +35 -22
- package/dist/auth/credentials.d.ts +7 -34
- package/dist/auth/credentials.d.ts.map +1 -1
- package/dist/auth/credentials.js +16 -83
- package/dist/auth/credentials.js.map +1 -1
- package/dist/auth/graphql-client.d.ts.map +1 -1
- package/dist/auth/graphql-client.js +3 -0
- package/dist/auth/graphql-client.js.map +1 -1
- package/dist/cli.d.ts +0 -4
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +3 -7
- package/dist/cli.js.map +1 -1
- package/dist/commands/default.d.ts +1 -2
- package/dist/commands/default.d.ts.map +1 -1
- package/dist/commands/default.js +11 -45
- package/dist/commands/default.js.map +1 -1
- package/dist/commands/find-requirements.d.ts.map +1 -1
- package/dist/commands/find-requirements.integration.test.js +17 -56
- package/dist/commands/find-requirements.integration.test.js.map +1 -1
- package/dist/commands/find-requirements.js +20 -32
- package/dist/commands/find-requirements.js.map +1 -1
- package/dist/commands/index.d.ts.map +1 -1
- package/dist/commands/index.js +2 -0
- package/dist/commands/index.js.map +1 -1
- package/dist/commands/login.d.ts.map +1 -1
- package/dist/commands/login.integration.test.js +21 -142
- package/dist/commands/login.integration.test.js.map +1 -1
- package/dist/commands/login.js +15 -8
- package/dist/commands/login.js.map +1 -1
- package/dist/commands/logout.d.ts.map +1 -1
- package/dist/commands/logout.js +13 -27
- package/dist/commands/logout.js.map +1 -1
- package/dist/commands/session-start.d.ts.map +1 -1
- package/dist/commands/session-start.js +1 -8
- package/dist/commands/session-start.js.map +1 -1
- package/dist/commands/setup.d.ts +3 -0
- package/dist/commands/setup.d.ts.map +1 -0
- package/dist/commands/setup.js +23 -0
- package/dist/commands/setup.js.map +1 -0
- package/dist/components/banner.d.ts +3 -0
- package/dist/components/banner.d.ts.map +1 -0
- package/dist/components/banner.js +13 -0
- package/dist/components/banner.js.map +1 -0
- package/dist/components/default-flow.d.ts +11 -0
- package/dist/components/default-flow.d.ts.map +1 -0
- package/dist/components/default-flow.js +64 -0
- package/dist/components/default-flow.js.map +1 -0
- package/dist/components/hero.d.ts.map +1 -1
- package/dist/components/hero.js +23 -34
- package/dist/components/hero.js.map +1 -1
- package/dist/components/login/login-error.d.ts.map +1 -1
- package/dist/components/login/login-error.js +2 -4
- package/dist/components/login/login-error.js.map +1 -1
- package/dist/components/login/login-flow.d.ts +1 -3
- package/dist/components/login/login-flow.d.ts.map +1 -1
- package/dist/components/login/login-flow.js +21 -51
- package/dist/components/login/login-flow.js.map +1 -1
- package/dist/components/login/login-flow.test.js +23 -8
- package/dist/components/login/login-flow.test.js.map +1 -1
- package/dist/components/login/user-settings-link.d.ts +3 -0
- package/dist/components/login/user-settings-link.d.ts.map +1 -0
- package/dist/components/login/user-settings-link.js +8 -0
- package/dist/components/login/user-settings-link.js.map +1 -0
- package/dist/components/multi-select.d.ts +16 -0
- package/dist/components/multi-select.d.ts.map +1 -0
- package/dist/components/multi-select.js +105 -0
- package/dist/components/multi-select.js.map +1 -0
- package/dist/components/org-selector.d.ts.map +1 -1
- package/dist/components/org-selector.js +3 -1
- package/dist/components/org-selector.js.map +1 -1
- package/dist/components/pat-input.js +1 -1
- package/dist/components/pat-input.js.map +1 -1
- package/dist/components/setup/agent-setup.d.ts +9 -0
- package/dist/components/setup/agent-setup.d.ts.map +1 -0
- package/dist/components/setup/agent-setup.js +65 -0
- package/dist/components/setup/agent-setup.js.map +1 -0
- package/dist/components/setup/agents/agent-registry.d.ts +44 -0
- package/dist/components/setup/agents/agent-registry.d.ts.map +1 -0
- package/dist/components/setup/agents/agent-registry.js +64 -0
- package/dist/components/setup/agents/agent-registry.js.map +1 -0
- package/dist/components/setup/agents/command-helpers.d.ts +5 -0
- package/dist/components/setup/agents/command-helpers.d.ts.map +1 -0
- package/dist/components/setup/agents/command-helpers.js +28 -0
- package/dist/components/setup/agents/command-helpers.js.map +1 -0
- package/dist/components/setup/checking-agents.d.ts +16 -0
- package/dist/components/setup/checking-agents.d.ts.map +1 -0
- package/dist/components/setup/checking-agents.js +30 -0
- package/dist/components/setup/checking-agents.js.map +1 -0
- package/dist/components/setup/download-skills-and-plugins.d.ts +9 -0
- package/dist/components/setup/download-skills-and-plugins.d.ts.map +1 -0
- package/dist/components/setup/download-skills-and-plugins.js +29 -0
- package/dist/components/setup/download-skills-and-plugins.js.map +1 -0
- package/dist/components/setup/perform-setup.d.ts +23 -0
- package/dist/components/setup/perform-setup.d.ts.map +1 -0
- package/dist/components/setup/perform-setup.js +45 -0
- package/dist/components/setup/perform-setup.js.map +1 -0
- package/dist/components/spinner.d.ts +6 -2
- package/dist/components/spinner.d.ts.map +1 -1
- package/dist/components/spinner.js +12 -3
- package/dist/components/spinner.js.map +1 -1
- package/dist/hooks/use-credentials.d.ts +13 -0
- package/dist/hooks/use-credentials.d.ts.map +1 -0
- package/dist/hooks/use-credentials.js +33 -0
- package/dist/hooks/use-credentials.js.map +1 -0
- package/dist/lib/graphql.d.ts +57 -41
- package/dist/lib/graphql.d.ts.map +1 -1
- package/dist/lib/graphql.js +7 -0
- package/dist/lib/graphql.js.map +1 -1
- package/dist/lib/ink-render.d.ts +1 -1
- package/dist/lib/ink-render.d.ts.map +1 -1
- package/dist/lib/ink-render.js +1 -1
- package/dist/lib/ink-render.js.map +1 -1
- package/dist/lib/logger.d.ts +13 -8
- package/dist/lib/logger.d.ts.map +1 -1
- package/dist/lib/logger.js +6 -29
- package/dist/lib/logger.js.map +1 -1
- package/dist/lib/login.d.ts.map +1 -1
- package/dist/lib/middleware.d.ts +4 -8
- package/dist/lib/middleware.d.ts.map +1 -1
- package/dist/lib/middleware.js +7 -11
- package/dist/lib/middleware.js.map +1 -1
- package/dist/lib/skills-manager.d.ts +33 -0
- package/dist/lib/skills-manager.d.ts.map +1 -0
- package/dist/lib/skills-manager.js +233 -0
- package/dist/lib/skills-manager.js.map +1 -0
- package/dist/lib/skills-manager.test.d.ts +7 -0
- package/dist/lib/skills-manager.test.d.ts.map +1 -0
- package/dist/lib/skills-manager.test.js +248 -0
- package/dist/lib/skills-manager.test.js.map +1 -0
- package/dist/state/global-config.d.ts +23 -9
- package/dist/state/global-config.d.ts.map +1 -1
- package/dist/state/global-config.js +42 -36
- package/dist/state/global-config.js.map +1 -1
- package/dist/state/session-manager.js +2 -2
- package/dist/state/session-manager.js.map +1 -1
- package/dist/test/integration-helpers.d.ts +0 -5
- package/dist/test/integration-helpers.d.ts.map +1 -1
- package/dist/test/integration-helpers.js +1 -18
- package/dist/test/integration-helpers.js.map +1 -1
- package/package.json +16 -8
- package/dist/lib/output.d.ts +0 -16
- package/dist/lib/output.d.ts.map +0 -1
- package/dist/lib/output.js +0 -14
- package/dist/lib/output.js.map +0 -1
- package/dist/state/directory-config.d.ts +0 -21
- package/dist/state/directory-config.d.ts.map +0 -1
- package/dist/state/directory-config.js +0 -59
- package/dist/state/directory-config.js.map +0 -1
- /package/{LICENSE.txt → LICENSE} +0 -0
|
@@ -1,3 +1,7 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
type SpinnerProps = {
|
|
3
|
+
children?: ReactNode;
|
|
4
|
+
};
|
|
5
|
+
export declare function Spinner({ children }: SpinnerProps): React.JSX.Element;
|
|
6
|
+
export {};
|
|
3
7
|
//# sourceMappingURL=spinner.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spinner.d.ts","sourceRoot":"","sources":["../../src/components/spinner.tsx"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"spinner.d.ts","sourceRoot":"","sources":["../../src/components/spinner.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAuB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAEnE,KAAK,YAAY,GAAG;IAClB,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,CAAC;AA0BF,wBAAgB,OAAO,CAAC,EAAE,QAAQ,EAAE,EAAE,YAAY,qBAUjD"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Text } from 'ink';
|
|
1
|
+
import { Box, Text } from 'ink';
|
|
2
2
|
import React, { useEffect, useState } from 'react';
|
|
3
|
-
|
|
3
|
+
function SpinnerInner() {
|
|
4
4
|
const [frame, setFrame] = useState(0);
|
|
5
5
|
const spinner = { frames: ['·', '✻', '✽', '✶', '✳', '✢'], interval: 80 };
|
|
6
6
|
useEffect(() => {
|
|
@@ -14,6 +14,15 @@ export function Spinner() {
|
|
|
14
14
|
clearInterval(timer);
|
|
15
15
|
};
|
|
16
16
|
}, [spinner]);
|
|
17
|
-
return React.createElement(
|
|
17
|
+
return (React.createElement(Box, { width: 2, justifyContent: "center" },
|
|
18
|
+
React.createElement(Text, { color: frame % 2 === 0 ? 'magenta' : 'magentaBright' }, spinner.frames[frame])));
|
|
19
|
+
}
|
|
20
|
+
export function Spinner({ children }) {
|
|
21
|
+
if (children) {
|
|
22
|
+
return (React.createElement(Box, { gap: 1 },
|
|
23
|
+
React.createElement(SpinnerInner, null),
|
|
24
|
+
typeof children === 'string' ? React.createElement(Text, null, children) : children));
|
|
25
|
+
}
|
|
26
|
+
return React.createElement(SpinnerInner, null);
|
|
18
27
|
}
|
|
19
28
|
//# sourceMappingURL=spinner.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spinner.js","sourceRoot":"","sources":["../../src/components/spinner.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"spinner.js","sourceRoot":"","sources":["../../src/components/spinner.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAkB,MAAM,OAAO,CAAC;AAMnE,SAA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QAAE,QAAQ,CAAQ,CAAC,CAAC,CAAC,QAAQ,CAC9D,CACP,CAAC;IACJ,CAAC;IACD,OAAO,oBAAC,YAAY,OAAG,CAAC;AAC1B,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Logger } from 'pino';
|
|
2
|
+
import type { StoredCredentials } from '../auth/credentials.js';
|
|
3
|
+
import type { OrganizationFragment } from '../lib/graphql.js';
|
|
4
|
+
export declare function useHasValidCredentials({ enabled, credentials, logger, }: {
|
|
5
|
+
enabled?: boolean;
|
|
6
|
+
credentials: StoredCredentials | null;
|
|
7
|
+
logger?: Logger;
|
|
8
|
+
}): {
|
|
9
|
+
hasValidCredentials: boolean;
|
|
10
|
+
organizations: OrganizationFragment[] | null;
|
|
11
|
+
isFinished: boolean;
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=use-credentials.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-credentials.d.ts","sourceRoot":"","sources":["../../src/hooks/use-credentials.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAGnC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAI9D,wBAAgB,sBAAsB,CAAC,EACrC,OAAc,EACd,WAAW,EACX,MAAM,GACP,EAAE;IACD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,WAAW,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;;;;EAoCA"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { useEffect, useState } from 'react';
|
|
2
|
+
import { loginUser } from '../lib/login.js';
|
|
3
|
+
import { resolveOrgForDirectory } from '../state/global-config.js';
|
|
4
|
+
export function useHasValidCredentials({ enabled = true, credentials, logger, }) {
|
|
5
|
+
const [hasValidCredentials, setHasValidCredentials] = useState(false);
|
|
6
|
+
const [isFinished, setIsFinished] = useState(false);
|
|
7
|
+
const [organizations, setOrganizations] = useState(null);
|
|
8
|
+
// Validate existing credentials and resolve org
|
|
9
|
+
useEffect(() => {
|
|
10
|
+
if (!enabled || !credentials) {
|
|
11
|
+
setIsFinished(true);
|
|
12
|
+
return;
|
|
13
|
+
}
|
|
14
|
+
async function validateCredentials() {
|
|
15
|
+
const resolvedOrg = resolveOrgForDirectory(process.cwd());
|
|
16
|
+
try {
|
|
17
|
+
const result = await loginUser(credentials.accessToken);
|
|
18
|
+
const stillHasAccessToOrg = resolvedOrg !== null &&
|
|
19
|
+
result.me.organizations.nodes.some((org) => org.id === resolvedOrg.id);
|
|
20
|
+
setHasValidCredentials(stillHasAccessToOrg);
|
|
21
|
+
setOrganizations(result.me.organizations.nodes);
|
|
22
|
+
}
|
|
23
|
+
catch (error) {
|
|
24
|
+
logger?.error({ error: error instanceof Error ? error.message : String(error) }, 'Error during login or organization resolution');
|
|
25
|
+
setHasValidCredentials(false);
|
|
26
|
+
}
|
|
27
|
+
setIsFinished(true);
|
|
28
|
+
}
|
|
29
|
+
validateCredentials();
|
|
30
|
+
}, [credentials, logger, enabled]);
|
|
31
|
+
return { hasValidCredentials, organizations, isFinished };
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=use-credentials.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-credentials.js","sourceRoot":"","sources":["../../src/hooks/use-credentials.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAI5C,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AAEnE,MAAM,UAAU,sBAAsB,CAAC,EACrC,OAAO,GAAG,IAAI,EACd,WAAW,EACX,MAAM,GAKP;IACC,MAAM,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EAAE,CAAC;IACxB,CAAC,EAAE,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IAEnC,OAAO,EAAE,mBAAmB,EAAE,aAAa,EAAE,UAAU,EAAE,CAAC;AAC5D,CAAC"}
|
package/dist/lib/graphql.d.ts
CHANGED
|
@@ -563,13 +563,6 @@ export type DocumentUpdate = {
|
|
|
563
563
|
organization: Organization;
|
|
564
564
|
updatedAt: Scalars['DateTime']['output'];
|
|
565
565
|
};
|
|
566
|
-
export type DocumentUpdateEdge = {
|
|
567
|
-
__typename?: 'DocumentUpdateEdge';
|
|
568
|
-
/** Base64 encoded cursor representing the position of this node in the dataset. */
|
|
569
|
-
cursor: Scalars['String']['output'];
|
|
570
|
-
/** The actual data node */
|
|
571
|
-
node: DocumentUpdate;
|
|
572
|
-
};
|
|
573
566
|
export type DocumentValidationResult = {
|
|
574
567
|
__typename?: 'DocumentValidationResult';
|
|
575
568
|
action?: Maybe<Scalars['String']['output']>;
|
|
@@ -601,6 +594,23 @@ export declare enum DocumentValidationResultStatus {
|
|
|
601
594
|
NotMet = "not_met",
|
|
602
595
|
Pending = "pending"
|
|
603
596
|
}
|
|
597
|
+
export type ExtractedRequirement = {
|
|
598
|
+
__typename?: 'ExtractedRequirement';
|
|
599
|
+
collectionId: Scalars['String']['output'];
|
|
600
|
+
id: Scalars['String']['output'];
|
|
601
|
+
mandatory: Scalars['Boolean']['output'];
|
|
602
|
+
text: Scalars['String']['output'];
|
|
603
|
+
};
|
|
604
|
+
export type ExtractionSession = {
|
|
605
|
+
__typename?: 'ExtractionSession';
|
|
606
|
+
sessionId: Scalars['String']['output'];
|
|
607
|
+
};
|
|
608
|
+
/** The source type for requirements extraction */
|
|
609
|
+
export declare enum ExtractionSourceType {
|
|
610
|
+
Content = "CONTENT",
|
|
611
|
+
Repository = "REPOSITORY",
|
|
612
|
+
Website = "WEBSITE"
|
|
613
|
+
}
|
|
604
614
|
export type GetPullRequestValidationResultsInput = {
|
|
605
615
|
/** Optional: Filter by specific commit SHA */
|
|
606
616
|
headSha?: InputMaybe<Scalars['String']['input']>;
|
|
@@ -702,7 +712,6 @@ export type Mutation = {
|
|
|
702
712
|
deleteUserFilter: Scalars['Boolean']['output'];
|
|
703
713
|
dismissAnnouncement: Scalars['Boolean']['output'];
|
|
704
714
|
endCollaborationSession: Scalars['Boolean']['output'];
|
|
705
|
-
extractRequirements: RequirementCollection;
|
|
706
715
|
forgotPassword: Scalars['Boolean']['output'];
|
|
707
716
|
getGithubToken: GithubToken;
|
|
708
717
|
inviteUserToOrganization: OrganizationInvite;
|
|
@@ -736,6 +745,8 @@ export type Mutation = {
|
|
|
736
745
|
/** Start a new build for a repository and returns the build id */
|
|
737
746
|
startBuild: Build;
|
|
738
747
|
startCollaborationSession: Scalars['Boolean']['output'];
|
|
748
|
+
/** Start a requirements extraction process and return a session ID for subscription */
|
|
749
|
+
startRequirementExtraction: ExtractionSession;
|
|
739
750
|
storeGithubInstallation: GithubInstallation;
|
|
740
751
|
/** Switches the organization of the user and creates a new pair of accessToken and refreshToken */
|
|
741
752
|
switchOrganization: Token;
|
|
@@ -886,9 +897,6 @@ export type MutationDismissAnnouncementArgs = {
|
|
|
886
897
|
export type MutationEndCollaborationSessionArgs = {
|
|
887
898
|
documentId: Scalars['String']['input'];
|
|
888
899
|
};
|
|
889
|
-
export type MutationExtractRequirementsArgs = {
|
|
890
|
-
body: Scalars['String']['input'];
|
|
891
|
-
};
|
|
892
900
|
export type MutationForgotPasswordArgs = {
|
|
893
901
|
email: Scalars['String']['input'];
|
|
894
902
|
};
|
|
@@ -983,6 +991,9 @@ export type MutationStartCollaborationSessionArgs = {
|
|
|
983
991
|
discussionId?: InputMaybe<Scalars['String']['input']>;
|
|
984
992
|
documentId: Scalars['String']['input'];
|
|
985
993
|
};
|
|
994
|
+
export type MutationStartRequirementExtractionArgs = {
|
|
995
|
+
input: StartExtractionInput;
|
|
996
|
+
};
|
|
986
997
|
export type MutationStoreGithubInstallationArgs = {
|
|
987
998
|
installationId: Scalars['Float']['input'];
|
|
988
999
|
};
|
|
@@ -1215,17 +1226,6 @@ export type PaginatedDocument = {
|
|
|
1215
1226
|
/** The total number of items across all pages. */
|
|
1216
1227
|
totalCount: Scalars['Float']['output'];
|
|
1217
1228
|
};
|
|
1218
|
-
export type PaginatedDocumentUpdate = {
|
|
1219
|
-
__typename?: 'PaginatedDocumentUpdate';
|
|
1220
|
-
/** Edges of the current page, containing nodes and their cursors. */
|
|
1221
|
-
edges?: Maybe<Array<DocumentUpdateEdge>>;
|
|
1222
|
-
/** The actual data node */
|
|
1223
|
-
nodes: Array<DocumentUpdate>;
|
|
1224
|
-
/** Information about the current page state and available navigation. */
|
|
1225
|
-
pageInfo?: Maybe<PageInfo>;
|
|
1226
|
-
/** The total number of items across all pages. */
|
|
1227
|
-
totalCount: Scalars['Float']['output'];
|
|
1228
|
-
};
|
|
1229
1229
|
export type PaginatedOrganization = {
|
|
1230
1230
|
__typename?: 'PaginatedOrganization';
|
|
1231
1231
|
/** Edges of the current page, containing nodes and their cursors. */
|
|
@@ -1336,6 +1336,8 @@ export type Query = {
|
|
|
1336
1336
|
_allOrganizations: PaginatedOrganization;
|
|
1337
1337
|
_organizationExists: Scalars['Boolean']['output'];
|
|
1338
1338
|
_statistics: Statistics;
|
|
1339
|
+
/** Get active extraction sessions for the current user */
|
|
1340
|
+
activeExtractionSessions: Array<RequirementExtractionProgress>;
|
|
1339
1341
|
availableGithubRepos: Array<GithubRepo>;
|
|
1340
1342
|
build: Build;
|
|
1341
1343
|
builds: Array<Build>;
|
|
@@ -1346,11 +1348,8 @@ export type Query = {
|
|
|
1346
1348
|
defaultBranch?: Maybe<GithubBranch>;
|
|
1347
1349
|
discussion: DocumentDiscussion;
|
|
1348
1350
|
document: Document;
|
|
1349
|
-
documentDiffVersion: Scalars['String']['output'];
|
|
1350
1351
|
documentFilters: Array<UserFilter>;
|
|
1351
1352
|
documentValidationResults: Array<DocumentValidationResult>;
|
|
1352
|
-
/** Retrieves a list of document versions by the document's id. */
|
|
1353
|
-
documentVersions: PaginatedDocumentUpdate;
|
|
1354
1353
|
documents: PaginatedDocument;
|
|
1355
1354
|
findAllOrganizationAccessTokens: Array<AccessToken>;
|
|
1356
1355
|
findAllUserAccessTokens: Array<UserAccessToken>;
|
|
@@ -1452,25 +1451,9 @@ export type QueryDocumentArgs = {
|
|
|
1452
1451
|
externalId?: InputMaybe<Scalars['String']['input']>;
|
|
1453
1452
|
id?: InputMaybe<Scalars['String']['input']>;
|
|
1454
1453
|
};
|
|
1455
|
-
export type QueryDocumentDiffVersionArgs = {
|
|
1456
|
-
count?: InputMaybe<Scalars['Int']['input']>;
|
|
1457
|
-
externalId?: InputMaybe<Scalars['String']['input']>;
|
|
1458
|
-
from?: InputMaybe<Scalars['String']['input']>;
|
|
1459
|
-
id?: InputMaybe<Scalars['String']['input']>;
|
|
1460
|
-
to: Scalars['String']['input'];
|
|
1461
|
-
};
|
|
1462
1454
|
export type QueryDocumentValidationResultsArgs = {
|
|
1463
1455
|
documentId: Scalars['String']['input'];
|
|
1464
1456
|
};
|
|
1465
|
-
export type QueryDocumentVersionsArgs = {
|
|
1466
|
-
after?: InputMaybe<Scalars['String']['input']>;
|
|
1467
|
-
before?: InputMaybe<Scalars['String']['input']>;
|
|
1468
|
-
documentId: Scalars['String']['input'];
|
|
1469
|
-
first?: InputMaybe<Scalars['Int']['input']>;
|
|
1470
|
-
last?: InputMaybe<Scalars['Int']['input']>;
|
|
1471
|
-
sort?: InputMaybe<SortDirection>;
|
|
1472
|
-
sortBy?: InputMaybe<Scalars['String']['input']>;
|
|
1473
|
-
};
|
|
1474
1457
|
export type QueryDocumentsArgs = {
|
|
1475
1458
|
after?: InputMaybe<Scalars['String']['input']>;
|
|
1476
1459
|
before?: InputMaybe<Scalars['String']['input']>;
|
|
@@ -1650,6 +1633,26 @@ export type RequirementCollectionEdge = {
|
|
|
1650
1633
|
/** The actual data node */
|
|
1651
1634
|
node: RequirementCollection;
|
|
1652
1635
|
};
|
|
1636
|
+
export type RequirementCollectionPreview = {
|
|
1637
|
+
__typename?: 'RequirementCollectionPreview';
|
|
1638
|
+
description: Scalars['String']['output'];
|
|
1639
|
+
name: Scalars['String']['output'];
|
|
1640
|
+
requirementCount: Scalars['Int']['output'];
|
|
1641
|
+
requirements: Array<ExtractedRequirement>;
|
|
1642
|
+
};
|
|
1643
|
+
export type RequirementExtractionProgress = {
|
|
1644
|
+
__typename?: 'RequirementExtractionProgress';
|
|
1645
|
+
collections?: Maybe<Array<RequirementCollectionPreview>>;
|
|
1646
|
+
currentStep: Scalars['Int']['output'];
|
|
1647
|
+
domainName?: Maybe<Scalars['String']['output']>;
|
|
1648
|
+
errorMessage?: Maybe<Scalars['String']['output']>;
|
|
1649
|
+
estimatedSecondsRemaining?: Maybe<Scalars['Int']['output']>;
|
|
1650
|
+
message: Scalars['String']['output'];
|
|
1651
|
+
phase: Scalars['String']['output'];
|
|
1652
|
+
progressPercent: Scalars['Int']['output'];
|
|
1653
|
+
sessionId: Scalars['String']['output'];
|
|
1654
|
+
totalSteps: Scalars['Int']['output'];
|
|
1655
|
+
};
|
|
1653
1656
|
export type RequirementMatch = {
|
|
1654
1657
|
__typename?: 'RequirementMatch';
|
|
1655
1658
|
collectionId: Scalars['String']['output'];
|
|
@@ -1785,6 +1788,14 @@ export declare enum SortDirection {
|
|
|
1785
1788
|
Asc = "ASC",
|
|
1786
1789
|
Desc = "DESC"
|
|
1787
1790
|
}
|
|
1791
|
+
export type StartExtractionInput = {
|
|
1792
|
+
branch?: InputMaybe<Scalars['String']['input']>;
|
|
1793
|
+
content?: InputMaybe<Scalars['String']['input']>;
|
|
1794
|
+
githubToken?: InputMaybe<Scalars['String']['input']>;
|
|
1795
|
+
repoUrl?: InputMaybe<Scalars['String']['input']>;
|
|
1796
|
+
sourceType: ExtractionSourceType;
|
|
1797
|
+
url?: InputMaybe<Scalars['String']['input']>;
|
|
1798
|
+
};
|
|
1788
1799
|
export type Statistics = {
|
|
1789
1800
|
__typename?: 'Statistics';
|
|
1790
1801
|
documents: Scalars['Int']['output'];
|
|
@@ -1794,6 +1805,8 @@ export type Statistics = {
|
|
|
1794
1805
|
export type Subscription = {
|
|
1795
1806
|
__typename?: 'Subscription';
|
|
1796
1807
|
codeValidationProgress: CodeValidationResult;
|
|
1808
|
+
/** Subscribe to extraction progress updates for a session */
|
|
1809
|
+
extractionProgress: RequirementExtractionProgress;
|
|
1797
1810
|
getBuildTraceLogs: BuildTraceLog;
|
|
1798
1811
|
getBuildTraceSpans: BuildTraceSpan;
|
|
1799
1812
|
getBuildUpdates: Build;
|
|
@@ -1806,6 +1819,9 @@ export type Subscription = {
|
|
|
1806
1819
|
export type SubscriptionCodeValidationProgressArgs = {
|
|
1807
1820
|
sessionId: Scalars['String']['input'];
|
|
1808
1821
|
};
|
|
1822
|
+
export type SubscriptionExtractionProgressArgs = {
|
|
1823
|
+
sessionId: Scalars['String']['input'];
|
|
1824
|
+
};
|
|
1809
1825
|
export type SubscriptionGetBuildTraceLogsArgs = {
|
|
1810
1826
|
buildId: Scalars['String']['input'];
|
|
1811
1827
|
};
|