diff --git a/lunatrace/bsl/backend-cdk/build-containers.sh b/lunatrace/bsl/backend-cdk/build-containers.sh index 73407f7c6..c841cafef 100755 --- a/lunatrace/bsl/backend-cdk/build-containers.sh +++ b/lunatrace/bsl/backend-cdk/build-containers.sh @@ -15,90 +15,73 @@ reset-dir() { change-dir "$saved_dir" } -echo "NOTE: The backend must be running for migrations to be applied successfully" - -# Not working, use docker-compose up to apply metadata -#change-dir ../hasura -#if ! hasura migrate --database-name lunatrace apply ; then -# echo "unable to apply database migrations" -# exit 1 -#fi -#if ! hasura metadata apply ; then -# echo "unable to apply metadata to hasura" -# exit 1 -#fi -#if ! hasura metadata reload ; then -# echo "unable to reload metadata in hasura" -# exit 1 -#fi -#reset-dir - # Make sure generated code is up to date before building Docker containers echo "Making sure generated code is up to date before building Docker containers" -echo "frontend generation start" +echo "frontend generation start" change-dir ../frontend if ! yarn run generate ; then echo "unable to generate code for frontend" exit 1 fi reset-dir - -echo "Frontend generation done" +echo "done" echo "backend generation start" - change-dir ../backend if ! yarn run generate ; then echo "unable to generate code for backend" exit 1 fi reset-dir - -echo "Backend generation done" +echo "done" echo "starting container build. NOTE=You will be asked for your password " echo "building root docker file for repo" -# Build Docker containers change-dir ../../.. if ! sudo docker build . -f lunatrace/bsl/repo-bootstrap.dockerfile -t repo-bootstrap ; then echo "unable to build repo-bootstrap" exit 1 fi reset-dir +echo "done" +echo "building lunatrace-cli" +change-dir ../../.. +if ! sudo docker build . -f lunatrace/cli/docker/lunatrace.dockerfile -t lunatrace-cli ; then + echo "unable to build lunatrace-cli" + exit 1 +fi +reset-dir echo "done" -echo "building docker file for frontend" +echo "building docker file for frontend" change-dir ../frontend if ! sudo docker build . -t lunatrace-frontend ; then echo "unable to build lunatrace-frontend" exit 1 fi reset-dir - - echo "done" -echo "building docker file for backend express server" +echo "building docker file for backend express server" change-dir ../backend if ! sudo docker build --target backend-express-server . -t lunatrace-backend ; then echo "unable to build lunatrace-backend" exit 1 fi reset-dir - - echo "done" -echo "building docker file for backend queue processor" +echo "building docker file for backend queue processor" change-dir ../backend if ! sudo docker build --target backend-queue-processor . -t lunatrace-backend-queue-processor ; then echo "unable to build lunatrace-backend-queue-processor" exit 1 fi reset-dir +echo "done" echo "Saving docker containers to output dir: $OUT_DIR" diff --git a/lunatrace/bsl/backend-cdk/lib/lunatrace-backend-stack.ts b/lunatrace/bsl/backend-cdk/lib/lunatrace-backend-stack.ts index 80e8331a7..2bad479af 100644 --- a/lunatrace/bsl/backend-cdk/lib/lunatrace-backend-stack.ts +++ b/lunatrace/bsl/backend-cdk/lib/lunatrace-backend-stack.ts @@ -32,6 +32,7 @@ import { HostedZone } from '@aws-cdk/aws-route53'; import { Bucket } from '@aws-cdk/aws-s3'; import { Secret } from '@aws-cdk/aws-secretsmanager'; import * as cdk from '@aws-cdk/core'; +import { Duration } from '@aws-cdk/core'; import { StackInputsType } from '../bin/lunatrace-backend'; @@ -320,6 +321,7 @@ export class LunatraceBackendStack extends cdk.Stack { circuitBreaker: { rollback: true, }, + healthCheckGracePeriod: Duration.seconds(5), desiredCount: 2, deploymentController: { type: DeploymentControllerType.ECS, @@ -350,8 +352,11 @@ export class LunatraceBackendStack extends cdk.Stack { }); storageStackStage.sbomBucket.grantReadWrite(loadBalancedFargateService.taskDefinition.taskRole); - oryConfigBucket.grantReadWrite(loadBalancedFargateService.taskDefinition.taskRole); storageStackStage.manifestBucket.grantReadWrite(loadBalancedFargateService.taskDefinition.taskRole); + storageStackStage.processWebhookSqsQueue.grantSendMessages(loadBalancedFargateService.taskDefinition.taskRole); + storageStackStage.processRepositorySqsQueue.grantSendMessages(loadBalancedFargateService.taskDefinition.taskRole); + + oryConfigBucket.grantReadWrite(loadBalancedFargateService.taskDefinition.taskRole); WorkerStack.createWorkerStack(this, { env: props.env, diff --git a/lunatrace/bsl/backend-cdk/lib/worker-stack.ts b/lunatrace/bsl/backend-cdk/lib/worker-stack.ts index e83e13d1c..80f7dce8f 100644 --- a/lunatrace/bsl/backend-cdk/lib/worker-stack.ts +++ b/lunatrace/bsl/backend-cdk/lib/worker-stack.ts @@ -19,7 +19,7 @@ import { ApplicationLoadBalancedFargateService } from '@aws-cdk/aws-ecs-patterns import { ISecret } from '@aws-cdk/aws-secretsmanager'; import { Queue } from '@aws-cdk/aws-sqs'; import * as cdk from '@aws-cdk/core'; -import { Construct } from '@aws-cdk/core'; +import { Construct, Duration } from '@aws-cdk/core'; import { getContainerTarballPath } from './util'; import { WorkerStorageStackState } from './worker-storage-stack'; @@ -79,8 +79,6 @@ export class WorkerStack extends cdk.Stack { throw new Error(`expected non-null storage stack queues: ${inspect(storageStack)}`); } - repositoryQueue.grantSendMessages(props.fargateService.service.taskDefinition.taskRole); - const workerContainerImage = ContainerImage.fromTarball( getContainerTarballPath('lunatrace-backend-queue-processor.tar') ); @@ -109,13 +107,28 @@ export class WorkerStack extends cdk.Stack { { name: 'ProcessRepositoryQueue', queue: repositoryQueue, + visibility: 600, + }, + { + name: 'ProcessWebhookQueue', + queue: webhookQueue, + }, + { + name: 'ProcessManifestQueue', + queue: manifestQueue, + visibility: 300, + }, + { + name: 'ProcessSbomQueue', + queue: sbomQueue, + visibility: 300, }, ]; queueServices.forEach((queueService) => { const queueFargateService = new ecsPatterns.QueueProcessingFargateService( context, - 'ProcessRepositoryQueueService', + queueService.name + 'Service', { cluster: fargateCluster, image: workerContainerImage, @@ -129,10 +142,15 @@ export class WorkerStack extends cdk.Stack { ...(queueService.visibility ? { QUEUE_VISIBILITY: queueService.visibility.toString() } : {}), }, secrets: processQueueCommonSecrets, - containerName: 'ProcessRepositoryQueueContainer', + containerName: queueService.name + 'Container', circuitBreaker: { rollback: true, }, + // healthCheck: { + // // stub command to just see if the container is actually running + // command: ['CMD-SHELL', 'ls || exit 1'], + // startPeriod: Duration.seconds(5), + // }, minScalingCapacity: 2, deploymentController: { type: DeploymentControllerType.ECS, @@ -143,6 +161,7 @@ export class WorkerStack extends cdk.Stack { storageStack.manifestBucket.grantReadWrite(queueFargateService.taskDefinition.taskRole); webhookQueue.grantSendMessages(queueFargateService.taskDefinition.taskRole); webhookQueue.grantConsumeMessages(queueFargateService.taskDefinition.taskRole); + repositoryQueue.grantConsumeMessages(queueFargateService.taskDefinition.taskRole); repositoryQueue.grantSendMessages(queueFargateService.taskDefinition.taskRole); }); diff --git a/lunatrace/bsl/backend/Dockerfile b/lunatrace/bsl/backend/Dockerfile index 509a716fa..6ce2a2088 100644 --- a/lunatrace/bsl/backend/Dockerfile +++ b/lunatrace/bsl/backend/Dockerfile @@ -4,10 +4,8 @@ RUN apt-get update && apt-get install -y wget curl make RUN curl -sSfL https://raw.githubusercontent.com/anchore/grype/main/install.sh | sh -s -- -b /usr/local/bin -# Build the lunatrace CLI -WORKDIR /usr/repo/lunatrace/cli/ -RUN make lunatrace -RUN mv build/lunatrace /usr/local/bin +# copy the lunatrace cli from the locally built container +COPY --from=lunatrace-cli /lunatrace /usr/local/bin WORKDIR /usr/repo/lunatrace/bsl/backend RUN yarn run compile diff --git a/lunatrace/bsl/backend/src/github/webhooks/handlers.ts b/lunatrace/bsl/backend/src/github/webhooks/handlers.ts index d6d1bbcef..1506414ba 100644 --- a/lunatrace/bsl/backend/src/github/webhooks/handlers.ts +++ b/lunatrace/bsl/backend/src/github/webhooks/handlers.ts @@ -92,8 +92,9 @@ async function pullRequestHandler(event: EmitterWebhookEvent<'pull_request'>) { if (actionName === 'synchronize' || actionName === 'opened' || actionName === 'reopened') { if (!event.payload.installation) { - log.error(`no installation found in pull request webhook`); - log.info(event); + log.error(`no installation found in pull request webhook`, { + event, + }); return; } diff --git a/lunatrace/bsl/backend/src/hasura-api/generated.ts b/lunatrace/bsl/backend/src/hasura-api/generated.ts index 9222939ad..c2b02e5c4 100644 --- a/lunatrace/bsl/backend/src/hasura-api/generated.ts +++ b/lunatrace/bsl/backend/src/hasura-api/generated.ts @@ -18,10 +18,8 @@ export type Scalars = { date: any; fix_state_enum: any; jsonb: any; - license_source: any; numeric: any; organization_user_role: any; - package_manager: any; severity_enum: any; timestamp: any; timestamptz: any; @@ -930,11 +928,9 @@ export type Fix_State_Enum_Comparison_Exp = { export type Github_Repositories = { __typename?: 'github_repositories'; authenticated_clone_url?: Maybe; - default_branch?: Maybe; git_url: Scalars['String']; github_id?: Maybe; github_node_id?: Maybe; - id: Scalars['uuid']; /** An object relationship */ project: Projects; project_id: Scalars['uuid']; @@ -984,11 +980,9 @@ export type Github_Repositories_Bool_Exp = { _and?: InputMaybe>; _not?: InputMaybe; _or?: InputMaybe>; - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; - id?: InputMaybe; project?: InputMaybe; project_id?: InputMaybe; traits?: InputMaybe; @@ -1037,21 +1031,17 @@ export type Github_Repositories_Insert_Input = { /** order by max() on columns of table "github_repositories" */ export type Github_Repositories_Max_Order_By = { - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; - id?: InputMaybe; project_id?: InputMaybe; }; /** order by min() on columns of table "github_repositories" */ export type Github_Repositories_Min_Order_By = { - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; - id?: InputMaybe; project_id?: InputMaybe; }; @@ -1080,21 +1070,14 @@ export type Github_Repositories_On_Conflict = { /** Ordering options when selecting data from "github_repositories". */ export type Github_Repositories_Order_By = { - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; - id?: InputMaybe; project?: InputMaybe; project_id?: InputMaybe; traits?: InputMaybe; }; -/** primary key columns input for table: github_repositories */ -export type Github_Repositories_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - /** prepend existing jsonb value of filtered columns with new jsonb value */ export type Github_Repositories_Prepend_Input = { traits?: InputMaybe; @@ -1102,8 +1085,6 @@ export type Github_Repositories_Prepend_Input = { /** select columns of table "github_repositories" */ export enum Github_Repositories_Select_Column { - /** column name */ - DefaultBranch = 'default_branch', /** column name */ GitUrl = 'git_url', /** column name */ @@ -1111,8 +1092,6 @@ export enum Github_Repositories_Select_Column { /** column name */ GithubNodeId = 'github_node_id', /** column name */ - Id = 'id', - /** column name */ ProjectId = 'project_id', /** column name */ Traits = 'traits' @@ -1880,19 +1859,6 @@ export type Jsonb_Comparison_Exp = { _nin?: InputMaybe>; }; -/** Boolean expression to compare columns of type "license_source". All fields are combined with logical 'AND'. */ -export type License_Source_Comparison_Exp = { - _eq?: InputMaybe; - _gt?: InputMaybe; - _gte?: InputMaybe; - _in?: InputMaybe>; - _is_null?: InputMaybe; - _lt?: InputMaybe; - _lte?: InputMaybe; - _neq?: InputMaybe; - _nin?: InputMaybe>; -}; - /** columns and relationships of "manifests" */ export type Manifests = { __typename?: 'manifests'; @@ -2134,34 +2100,6 @@ export type Mutation_Root = { insert_organizations?: Maybe; /** insert a single row into the table: "organizations" */ insert_organizations_one?: Maybe; - /** insert data into the table: "package.package" */ - insert_package?: Maybe; - /** insert data into the table: "package.license" */ - insert_package_license?: Maybe; - /** insert a single row into the table: "package.license" */ - insert_package_license_one?: Maybe; - /** insert data into the table: "package.maintainer" */ - insert_package_maintainer?: Maybe; - /** insert a single row into the table: "package.maintainer" */ - insert_package_maintainer_one?: Maybe; - /** insert a single row into the table: "package.package" */ - insert_package_one?: Maybe; - /** insert data into the table: "package.package_maintainer" */ - insert_package_package_maintainer?: Maybe; - /** insert a single row into the table: "package.package_maintainer" */ - insert_package_package_maintainer_one?: Maybe; - /** insert data into the table: "package.release" */ - insert_package_release?: Maybe; - /** insert data into the table: "package.release_dependency" */ - insert_package_release_dependency?: Maybe; - /** insert a single row into the table: "package.release_dependency" */ - insert_package_release_dependency_one?: Maybe; - /** insert data into the table: "package.release_license" */ - insert_package_release_license?: Maybe; - /** insert a single row into the table: "package.release_license" */ - insert_package_release_license_one?: Maybe; - /** insert a single row into the table: "package.release" */ - insert_package_release_one?: Maybe; /** insert data into the table: "package_versions" */ insert_package_versions?: Maybe; /** insert a single row into the table: "package_versions" */ @@ -2202,8 +2140,6 @@ export type Mutation_Root = { update_findings_by_pk?: Maybe; /** update data of the table: "github_repositories" */ update_github_repositories?: Maybe; - /** update single row of the table: "github_repositories" */ - update_github_repositories_by_pk?: Maybe; /** update data of the table: "guide_related_guides" */ update_guide_related_guides?: Maybe; /** update single row of the table: "guide_related_guides" */ @@ -2226,32 +2162,6 @@ export type Mutation_Root = { update_organizations?: Maybe; /** update single row of the table: "organizations" */ update_organizations_by_pk?: Maybe; - /** update data of the table: "package.package" */ - update_package?: Maybe; - /** update single row of the table: "package.package" */ - update_package_by_pk?: Maybe; - /** update data of the table: "package.license" */ - update_package_license?: Maybe; - /** update single row of the table: "package.license" */ - update_package_license_by_pk?: Maybe; - /** update data of the table: "package.maintainer" */ - update_package_maintainer?: Maybe; - /** update single row of the table: "package.maintainer" */ - update_package_maintainer_by_pk?: Maybe; - /** update data of the table: "package.package_maintainer" */ - update_package_package_maintainer?: Maybe; - /** update data of the table: "package.release" */ - update_package_release?: Maybe; - /** update single row of the table: "package.release" */ - update_package_release_by_pk?: Maybe; - /** update data of the table: "package.release_dependency" */ - update_package_release_dependency?: Maybe; - /** update single row of the table: "package.release_dependency" */ - update_package_release_dependency_by_pk?: Maybe; - /** update data of the table: "package.release_license" */ - update_package_release_license?: Maybe; - /** update single row of the table: "package.release_license" */ - update_package_release_license_by_pk?: Maybe; /** update data of the table: "package_versions" */ update_package_versions?: Maybe; /** update single row of the table: "package_versions" */ @@ -2438,104 +2348,6 @@ export type Mutation_RootInsert_Organizations_OneArgs = { }; -/** mutation root */ -export type Mutation_RootInsert_PackageArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_LicenseArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_License_OneArgs = { - object: Package_License_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_MaintainerArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Maintainer_OneArgs = { - object: Package_Maintainer_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_OneArgs = { - object: Package_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Package_MaintainerArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Package_Maintainer_OneArgs = { - object: Package_Package_Maintainer_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_ReleaseArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Release_DependencyArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Release_Dependency_OneArgs = { - object: Package_Release_Dependency_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Release_LicenseArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Release_License_OneArgs = { - object: Package_Release_License_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootInsert_Package_Release_OneArgs = { - object: Package_Release_Insert_Input; - on_conflict?: InputMaybe; -}; - - /** mutation root */ export type Mutation_RootInsert_Package_VersionsArgs = { objects: Array; @@ -2683,19 +2495,6 @@ export type Mutation_RootUpdate_Github_RepositoriesArgs = { }; -/** mutation root */ -export type Mutation_RootUpdate_Github_Repositories_By_PkArgs = { - _append?: InputMaybe; - _delete_at_path?: InputMaybe; - _delete_elem?: InputMaybe; - _delete_key?: InputMaybe; - _inc?: InputMaybe; - _prepend?: InputMaybe; - _set?: InputMaybe; - pk_columns: Github_Repositories_Pk_Columns_Input; -}; - - /** mutation root */ export type Mutation_RootUpdate_Guide_Related_GuidesArgs = { _set?: InputMaybe; @@ -2781,117 +2580,6 @@ export type Mutation_RootUpdate_Organizations_By_PkArgs = { }; -/** mutation root */ -export type Mutation_RootUpdate_PackageArgs = { - _set?: InputMaybe; - where: Package_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_By_PkArgs = { - _set?: InputMaybe; - pk_columns: Package_Pk_Columns_Input; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_LicenseArgs = { - _set?: InputMaybe; - where: Package_License_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_License_By_PkArgs = { - _set?: InputMaybe; - pk_columns: Package_License_Pk_Columns_Input; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_MaintainerArgs = { - _set?: InputMaybe; - where: Package_Maintainer_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Maintainer_By_PkArgs = { - _set?: InputMaybe; - pk_columns: Package_Maintainer_Pk_Columns_Input; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Package_MaintainerArgs = { - _set?: InputMaybe; - where: Package_Package_Maintainer_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_ReleaseArgs = { - _append?: InputMaybe; - _delete_at_path?: InputMaybe; - _delete_elem?: InputMaybe; - _delete_key?: InputMaybe; - _prepend?: InputMaybe; - _set?: InputMaybe; - where: Package_Release_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Release_By_PkArgs = { - _append?: InputMaybe; - _delete_at_path?: InputMaybe; - _delete_elem?: InputMaybe; - _delete_key?: InputMaybe; - _prepend?: InputMaybe; - _set?: InputMaybe; - pk_columns: Package_Release_Pk_Columns_Input; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Release_DependencyArgs = { - _set?: InputMaybe; - where: Package_Release_Dependency_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Release_Dependency_By_PkArgs = { - _set?: InputMaybe; - pk_columns: Package_Release_Dependency_Pk_Columns_Input; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Release_LicenseArgs = { - _append?: InputMaybe; - _delete_at_path?: InputMaybe; - _delete_elem?: InputMaybe; - _delete_key?: InputMaybe; - _prepend?: InputMaybe; - _set?: InputMaybe; - where: Package_Release_License_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootUpdate_Package_Release_License_By_PkArgs = { - _append?: InputMaybe; - _delete_at_path?: InputMaybe; - _delete_elem?: InputMaybe; - _delete_key?: InputMaybe; - _prepend?: InputMaybe; - _set?: InputMaybe; - pk_columns: Package_Release_License_Pk_Columns_Input; -}; - - /** mutation root */ export type Mutation_RootUpdate_Package_VersionsArgs = { _set?: InputMaybe; @@ -3505,1260 +3193,134 @@ export type Organizations_Variance_Fields = { installation_id?: Maybe; }; -/** columns and relationships of "package.package" */ -export type Package = { - __typename?: 'package'; - custom_registry?: Maybe; - description?: Maybe; - id: Scalars['uuid']; - name: Scalars['String']; - /** An array relationship */ - package_maintainers: Array; - package_manager: Scalars['package_manager']; +/** columns and relationships of "package_versions" */ +export type Package_Versions = { + __typename?: 'package_versions'; + cpes: Scalars['_text']; /** An array relationship */ - releases: Array; + findings: Array; + fix_state: Scalars['String']; + fixed_in_versions: Scalars['_text']; + id: Scalars['uuid']; + pkg_slug: Scalars['String']; + slug: Scalars['String']; + version_constraint: Scalars['String']; + version_format: Scalars['String']; + /** An object relationship */ + vulnerability_package: Vulnerability_Packages; }; -/** columns and relationships of "package.package" */ -export type PackagePackage_MaintainersArgs = { - distinct_on?: InputMaybe>; +/** columns and relationships of "package_versions" */ +export type Package_VersionsFindingsArgs = { + distinct_on?: InputMaybe>; limit?: InputMaybe; offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; }; +/** order by aggregate values of table "package_versions" */ +export type Package_Versions_Aggregate_Order_By = { + count?: InputMaybe; + max?: InputMaybe; + min?: InputMaybe; +}; -/** columns and relationships of "package.package" */ -export type PackageReleasesArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; +/** input type for inserting array relation for remote table "package_versions" */ +export type Package_Versions_Arr_Rel_Insert_Input = { + data: Array; + /** upsert condition */ + on_conflict?: InputMaybe; }; -/** Boolean expression to filter rows from the table "package.package". All fields are combined with a logical 'AND'. */ -export type Package_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - custom_registry?: InputMaybe; - description?: InputMaybe; +/** Boolean expression to filter rows from the table "package_versions". All fields are combined with a logical 'AND'. */ +export type Package_Versions_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + cpes?: InputMaybe<_Text_Comparison_Exp>; + findings?: InputMaybe; + fix_state?: InputMaybe; + fixed_in_versions?: InputMaybe<_Text_Comparison_Exp>; id?: InputMaybe; - name?: InputMaybe; - package_maintainers?: InputMaybe; - package_manager?: InputMaybe; - releases?: InputMaybe; + pkg_slug?: InputMaybe; + slug?: InputMaybe; + version_constraint?: InputMaybe; + version_format?: InputMaybe; + vulnerability_package?: InputMaybe; }; -/** unique or primary key constraints on table "package.package" */ -export enum Package_Constraint { +/** unique or primary key constraints on table "package_versions" */ +export enum Package_Versions_Constraint { /** unique or primary key constraint */ - PackagePackageManagerCustomRegistryNameIdx = 'package_package_manager_custom_registry_name_idx', + PackageVersionsPkey = 'package_versions_pkey', /** unique or primary key constraint */ - PackagePkey = 'package_pkey' + PackageVersionsSlugKey = 'package_versions_slug_key' } -/** input type for inserting data into table "package.package" */ -export type Package_Insert_Input = { - custom_registry?: InputMaybe; - description?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_maintainers?: InputMaybe; - package_manager?: InputMaybe; - releases?: InputMaybe; -}; - -/** columns and relationships of "package.license" */ -export type Package_License = { - __typename?: 'package_license'; - id: Scalars['uuid']; - name: Scalars['String']; - /** An array relationship */ - release_licenses: Array; -}; - - -/** columns and relationships of "package.license" */ -export type Package_LicenseRelease_LicensesArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; +/** input type for inserting data into table "package_versions" */ +export type Package_Versions_Insert_Input = { + findings?: InputMaybe; + slug?: InputMaybe; + vulnerability_package?: InputMaybe; }; -/** Boolean expression to filter rows from the table "package.license". All fields are combined with a logical 'AND'. */ -export type Package_License_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - id?: InputMaybe; - name?: InputMaybe; - release_licenses?: InputMaybe; +/** order by max() on columns of table "package_versions" */ +export type Package_Versions_Max_Order_By = { + fix_state?: InputMaybe; + id?: InputMaybe; + pkg_slug?: InputMaybe; + slug?: InputMaybe; + version_constraint?: InputMaybe; + version_format?: InputMaybe; }; -/** unique or primary key constraints on table "package.license" */ -export enum Package_License_Constraint { - /** unique or primary key constraint */ - LicenseNameIdx = 'license_name_idx', - /** unique or primary key constraint */ - LicensePkey = 'license_pkey' -} - -/** input type for inserting data into table "package.license" */ -export type Package_License_Insert_Input = { - id?: InputMaybe; - name?: InputMaybe; - release_licenses?: InputMaybe; +/** order by min() on columns of table "package_versions" */ +export type Package_Versions_Min_Order_By = { + fix_state?: InputMaybe; + id?: InputMaybe; + pkg_slug?: InputMaybe; + slug?: InputMaybe; + version_constraint?: InputMaybe; + version_format?: InputMaybe; }; -/** response of any mutation on the table "package.license" */ -export type Package_License_Mutation_Response = { - __typename?: 'package_license_mutation_response'; +/** response of any mutation on the table "package_versions" */ +export type Package_Versions_Mutation_Response = { + __typename?: 'package_versions_mutation_response'; /** number of rows affected by the mutation */ affected_rows: Scalars['Int']; /** data from the rows affected by the mutation */ - returning: Array; + returning: Array; }; -/** input type for inserting object relation for remote table "package.license" */ -export type Package_License_Obj_Rel_Insert_Input = { - data: Package_License_Insert_Input; +/** input type for inserting object relation for remote table "package_versions" */ +export type Package_Versions_Obj_Rel_Insert_Input = { + data: Package_Versions_Insert_Input; /** upsert condition */ - on_conflict?: InputMaybe; + on_conflict?: InputMaybe; }; -/** on_conflict condition type for table "package.license" */ -export type Package_License_On_Conflict = { - constraint: Package_License_Constraint; - update_columns?: Array; - where?: InputMaybe; +/** on_conflict condition type for table "package_versions" */ +export type Package_Versions_On_Conflict = { + constraint: Package_Versions_Constraint; + update_columns?: Array; + where?: InputMaybe; }; -/** Ordering options when selecting data from "package.license". */ -export type Package_License_Order_By = { +/** Ordering options when selecting data from "package_versions". */ +export type Package_Versions_Order_By = { + cpes?: InputMaybe; + findings_aggregate?: InputMaybe; + fix_state?: InputMaybe; + fixed_in_versions?: InputMaybe; id?: InputMaybe; - name?: InputMaybe; - release_licenses_aggregate?: InputMaybe; -}; - -/** primary key columns input for table: package_license */ -export type Package_License_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - -/** select columns of table "package.license" */ -export enum Package_License_Select_Column { - /** column name */ - Id = 'id', - /** column name */ - Name = 'name' -} - -/** input type for updating data in table "package.license" */ -export type Package_License_Set_Input = { - id?: InputMaybe; - name?: InputMaybe; -}; - -/** update columns of table "package.license" */ -export enum Package_License_Update_Column { - /** column name */ - Id = 'id', - /** column name */ - Name = 'name' -} - -/** columns and relationships of "package.maintainer" */ -export type Package_Maintainer = { - __typename?: 'package_maintainer'; - email: Scalars['String']; - id: Scalars['uuid']; - name?: Maybe; - /** An array relationship */ - package_maintainers: Array; - package_manager?: Maybe; - /** An array relationship */ - published_releases: Array; -}; - - -/** columns and relationships of "package.maintainer" */ -export type Package_MaintainerPackage_MaintainersArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -/** columns and relationships of "package.maintainer" */ -export type Package_MaintainerPublished_ReleasesArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - -/** Boolean expression to filter rows from the table "package.maintainer". All fields are combined with a logical 'AND'. */ -export type Package_Maintainer_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - email?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_maintainers?: InputMaybe; - package_manager?: InputMaybe; - published_releases?: InputMaybe; -}; - -/** unique or primary key constraints on table "package.maintainer" */ -export enum Package_Maintainer_Constraint { - /** unique or primary key constraint */ - MaintainerPackageManagerEmailIdx = 'maintainer_package_manager_email_idx', - /** unique or primary key constraint */ - MaintainerPkey = 'maintainer_pkey' -} - -/** input type for inserting data into table "package.maintainer" */ -export type Package_Maintainer_Insert_Input = { - email?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_maintainers?: InputMaybe; - package_manager?: InputMaybe; - published_releases?: InputMaybe; -}; - -/** response of any mutation on the table "package.maintainer" */ -export type Package_Maintainer_Mutation_Response = { - __typename?: 'package_maintainer_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** input type for inserting object relation for remote table "package.maintainer" */ -export type Package_Maintainer_Obj_Rel_Insert_Input = { - data: Package_Maintainer_Insert_Input; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** on_conflict condition type for table "package.maintainer" */ -export type Package_Maintainer_On_Conflict = { - constraint: Package_Maintainer_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package.maintainer". */ -export type Package_Maintainer_Order_By = { - email?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_maintainers_aggregate?: InputMaybe; - package_manager?: InputMaybe; - published_releases_aggregate?: InputMaybe; -}; - -/** primary key columns input for table: package_maintainer */ -export type Package_Maintainer_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - -/** select columns of table "package.maintainer" */ -export enum Package_Maintainer_Select_Column { - /** column name */ - Email = 'email', - /** column name */ - Id = 'id', - /** column name */ - Name = 'name', - /** column name */ - PackageManager = 'package_manager' -} - -/** input type for updating data in table "package.maintainer" */ -export type Package_Maintainer_Set_Input = { - email?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_manager?: InputMaybe; -}; - -/** update columns of table "package.maintainer" */ -export enum Package_Maintainer_Update_Column { - /** column name */ - Email = 'email', - /** column name */ - Id = 'id', - /** column name */ - Name = 'name', - /** column name */ - PackageManager = 'package_manager' -} - -/** Boolean expression to compare columns of type "package_manager". All fields are combined with logical 'AND'. */ -export type Package_Manager_Comparison_Exp = { - _eq?: InputMaybe; - _gt?: InputMaybe; - _gte?: InputMaybe; - _in?: InputMaybe>; - _is_null?: InputMaybe; - _lt?: InputMaybe; - _lte?: InputMaybe; - _neq?: InputMaybe; - _nin?: InputMaybe>; -}; - -/** response of any mutation on the table "package.package" */ -export type Package_Mutation_Response = { - __typename?: 'package_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** input type for inserting object relation for remote table "package.package" */ -export type Package_Obj_Rel_Insert_Input = { - data: Package_Insert_Input; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** on_conflict condition type for table "package.package" */ -export type Package_On_Conflict = { - constraint: Package_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package.package". */ -export type Package_Order_By = { - custom_registry?: InputMaybe; - description?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_maintainers_aggregate?: InputMaybe; - package_manager?: InputMaybe; - releases_aggregate?: InputMaybe; -}; - -/** columns and relationships of "package.package_maintainer" */ -export type Package_Package_Maintainer = { - __typename?: 'package_package_maintainer'; - /** An object relationship */ - maintainer?: Maybe; - maintainer_id?: Maybe; - /** An object relationship */ - package?: Maybe; - package_id?: Maybe; -}; - -/** order by aggregate values of table "package.package_maintainer" */ -export type Package_Package_Maintainer_Aggregate_Order_By = { - count?: InputMaybe; - max?: InputMaybe; - min?: InputMaybe; -}; - -/** input type for inserting array relation for remote table "package.package_maintainer" */ -export type Package_Package_Maintainer_Arr_Rel_Insert_Input = { - data: Array; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** Boolean expression to filter rows from the table "package.package_maintainer". All fields are combined with a logical 'AND'. */ -export type Package_Package_Maintainer_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - maintainer?: InputMaybe; - maintainer_id?: InputMaybe; - package?: InputMaybe; - package_id?: InputMaybe; -}; - -/** unique or primary key constraints on table "package.package_maintainer" */ -export enum Package_Package_Maintainer_Constraint { - /** unique or primary key constraint */ - PackageMaintainerPackageIdMaintainerIdIdx = 'package_maintainer_package_id_maintainer_id_idx' -} - -/** input type for inserting data into table "package.package_maintainer" */ -export type Package_Package_Maintainer_Insert_Input = { - maintainer?: InputMaybe; - maintainer_id?: InputMaybe; - package?: InputMaybe; - package_id?: InputMaybe; -}; - -/** order by max() on columns of table "package.package_maintainer" */ -export type Package_Package_Maintainer_Max_Order_By = { - maintainer_id?: InputMaybe; - package_id?: InputMaybe; -}; - -/** order by min() on columns of table "package.package_maintainer" */ -export type Package_Package_Maintainer_Min_Order_By = { - maintainer_id?: InputMaybe; - package_id?: InputMaybe; -}; - -/** response of any mutation on the table "package.package_maintainer" */ -export type Package_Package_Maintainer_Mutation_Response = { - __typename?: 'package_package_maintainer_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** on_conflict condition type for table "package.package_maintainer" */ -export type Package_Package_Maintainer_On_Conflict = { - constraint: Package_Package_Maintainer_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package.package_maintainer". */ -export type Package_Package_Maintainer_Order_By = { - maintainer?: InputMaybe; - maintainer_id?: InputMaybe; - package?: InputMaybe; - package_id?: InputMaybe; -}; - -/** select columns of table "package.package_maintainer" */ -export enum Package_Package_Maintainer_Select_Column { - /** column name */ - MaintainerId = 'maintainer_id', - /** column name */ - PackageId = 'package_id' -} - -/** input type for updating data in table "package.package_maintainer" */ -export type Package_Package_Maintainer_Set_Input = { - maintainer_id?: InputMaybe; - package_id?: InputMaybe; -}; - -/** update columns of table "package.package_maintainer" */ -export enum Package_Package_Maintainer_Update_Column { - /** column name */ - MaintainerId = 'maintainer_id', - /** column name */ - PackageId = 'package_id' -} - -/** primary key columns input for table: package */ -export type Package_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - -/** columns and relationships of "package.release" */ -export type Package_Release = { - __typename?: 'package_release'; - blob_hash?: Maybe; - id: Scalars['uuid']; - mirrored_blob_url?: Maybe; - observed_time: Scalars['timestamptz']; - /** An object relationship */ - package?: Maybe; - package_id?: Maybe; - /** An object relationship */ - publishing_maintainer?: Maybe; - publishing_maintainer_id?: Maybe; - /** An array relationship */ - release_dependencies: Array; - /** An array relationship */ - release_dependents: Array; - /** An array relationship */ - release_licenses: Array; - release_time?: Maybe; - upstream_blob_url?: Maybe; - upstream_data?: Maybe; - version: Scalars['String']; -}; - - -/** columns and relationships of "package.release" */ -export type Package_ReleaseRelease_DependenciesArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -/** columns and relationships of "package.release" */ -export type Package_ReleaseRelease_DependentsArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -/** columns and relationships of "package.release" */ -export type Package_ReleaseRelease_LicensesArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -/** columns and relationships of "package.release" */ -export type Package_ReleaseUpstream_DataArgs = { - path?: InputMaybe; -}; - -/** order by aggregate values of table "package.release" */ -export type Package_Release_Aggregate_Order_By = { - count?: InputMaybe; - max?: InputMaybe; - min?: InputMaybe; -}; - -/** append existing jsonb value of filtered columns with new jsonb value */ -export type Package_Release_Append_Input = { - upstream_data?: InputMaybe; -}; - -/** input type for inserting array relation for remote table "package.release" */ -export type Package_Release_Arr_Rel_Insert_Input = { - data: Array; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** Boolean expression to filter rows from the table "package.release". All fields are combined with a logical 'AND'. */ -export type Package_Release_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - blob_hash?: InputMaybe; - id?: InputMaybe; - mirrored_blob_url?: InputMaybe; - observed_time?: InputMaybe; - package?: InputMaybe; - package_id?: InputMaybe; - publishing_maintainer?: InputMaybe; - publishing_maintainer_id?: InputMaybe; - release_dependencies?: InputMaybe; - release_dependents?: InputMaybe; - release_licenses?: InputMaybe; - release_time?: InputMaybe; - upstream_blob_url?: InputMaybe; - upstream_data?: InputMaybe; - version?: InputMaybe; -}; - -/** unique or primary key constraints on table "package.release" */ -export enum Package_Release_Constraint { - /** unique or primary key constraint */ - ReleasePackageIdVersionIdx = 'release_package_id_version_idx', - /** unique or primary key constraint */ - ReleasePkey = 'release_pkey' -} - -/** delete the field or element with specified path (for JSON arrays, negative integers count from the end) */ -export type Package_Release_Delete_At_Path_Input = { - upstream_data?: InputMaybe>; -}; - -/** delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array */ -export type Package_Release_Delete_Elem_Input = { - upstream_data?: InputMaybe; -}; - -/** delete key/value pair or string element. key/value pairs are matched based on their key value */ -export type Package_Release_Delete_Key_Input = { - upstream_data?: InputMaybe; -}; - -/** columns and relationships of "package.release_dependency" */ -export type Package_Release_Dependency = { - __typename?: 'package_release_dependency'; - /** An object relationship */ - dependency_package?: Maybe; - dependency_package_id?: Maybe; - /** An object relationship */ - dependency_release?: Maybe; - dependency_release_id?: Maybe; - id: Scalars['uuid']; - package_name: Scalars['String']; - package_version_query: Scalars['String']; - /** An object relationship */ - release: Package_Release; - release_id: Scalars['uuid']; -}; - -/** order by aggregate values of table "package.release_dependency" */ -export type Package_Release_Dependency_Aggregate_Order_By = { - count?: InputMaybe; - max?: InputMaybe; - min?: InputMaybe; -}; - -/** input type for inserting array relation for remote table "package.release_dependency" */ -export type Package_Release_Dependency_Arr_Rel_Insert_Input = { - data: Array; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** Boolean expression to filter rows from the table "package.release_dependency". All fields are combined with a logical 'AND'. */ -export type Package_Release_Dependency_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - dependency_package?: InputMaybe; - dependency_package_id?: InputMaybe; - dependency_release?: InputMaybe; - dependency_release_id?: InputMaybe; - id?: InputMaybe; - package_name?: InputMaybe; - package_version_query?: InputMaybe; - release?: InputMaybe; - release_id?: InputMaybe; -}; - -/** unique or primary key constraints on table "package.release_dependency" */ -export enum Package_Release_Dependency_Constraint { - /** unique or primary key constraint */ - ReleaseDependencyPkey = 'release_dependency_pkey', - /** unique or primary key constraint */ - ReleaseDependencyReleaseIdPackageNamePackageVersionIdx = 'release_dependency_release_id_package_name_package_version__idx' -} - -/** input type for inserting data into table "package.release_dependency" */ -export type Package_Release_Dependency_Insert_Input = { - dependency_package?: InputMaybe; - dependency_package_id?: InputMaybe; - dependency_release?: InputMaybe; - dependency_release_id?: InputMaybe; - id?: InputMaybe; - package_name?: InputMaybe; - package_version_query?: InputMaybe; - release?: InputMaybe; - release_id?: InputMaybe; -}; - -/** order by max() on columns of table "package.release_dependency" */ -export type Package_Release_Dependency_Max_Order_By = { - dependency_package_id?: InputMaybe; - dependency_release_id?: InputMaybe; - id?: InputMaybe; - package_name?: InputMaybe; - package_version_query?: InputMaybe; - release_id?: InputMaybe; -}; - -/** order by min() on columns of table "package.release_dependency" */ -export type Package_Release_Dependency_Min_Order_By = { - dependency_package_id?: InputMaybe; - dependency_release_id?: InputMaybe; - id?: InputMaybe; - package_name?: InputMaybe; - package_version_query?: InputMaybe; - release_id?: InputMaybe; -}; - -/** response of any mutation on the table "package.release_dependency" */ -export type Package_Release_Dependency_Mutation_Response = { - __typename?: 'package_release_dependency_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** on_conflict condition type for table "package.release_dependency" */ -export type Package_Release_Dependency_On_Conflict = { - constraint: Package_Release_Dependency_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package.release_dependency". */ -export type Package_Release_Dependency_Order_By = { - dependency_package?: InputMaybe; - dependency_package_id?: InputMaybe; - dependency_release?: InputMaybe; - dependency_release_id?: InputMaybe; - id?: InputMaybe; - package_name?: InputMaybe; - package_version_query?: InputMaybe; - release?: InputMaybe; - release_id?: InputMaybe; -}; - -/** primary key columns input for table: package_release_dependency */ -export type Package_Release_Dependency_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - -/** select columns of table "package.release_dependency" */ -export enum Package_Release_Dependency_Select_Column { - /** column name */ - DependencyPackageId = 'dependency_package_id', - /** column name */ - DependencyReleaseId = 'dependency_release_id', - /** column name */ - Id = 'id', - /** column name */ - PackageName = 'package_name', - /** column name */ - PackageVersionQuery = 'package_version_query', - /** column name */ - ReleaseId = 'release_id' -} - -/** input type for updating data in table "package.release_dependency" */ -export type Package_Release_Dependency_Set_Input = { - dependency_package_id?: InputMaybe; - dependency_release_id?: InputMaybe; - id?: InputMaybe; - package_name?: InputMaybe; - package_version_query?: InputMaybe; - release_id?: InputMaybe; -}; - -/** update columns of table "package.release_dependency" */ -export enum Package_Release_Dependency_Update_Column { - /** column name */ - DependencyPackageId = 'dependency_package_id', - /** column name */ - DependencyReleaseId = 'dependency_release_id', - /** column name */ - Id = 'id', - /** column name */ - PackageName = 'package_name', - /** column name */ - PackageVersionQuery = 'package_version_query', - /** column name */ - ReleaseId = 'release_id' -} - -/** input type for inserting data into table "package.release" */ -export type Package_Release_Insert_Input = { - blob_hash?: InputMaybe; - id?: InputMaybe; - mirrored_blob_url?: InputMaybe; - observed_time?: InputMaybe; - package?: InputMaybe; - package_id?: InputMaybe; - publishing_maintainer?: InputMaybe; - publishing_maintainer_id?: InputMaybe; - release_dependencies?: InputMaybe; - release_dependents?: InputMaybe; - release_licenses?: InputMaybe; - release_time?: InputMaybe; - upstream_blob_url?: InputMaybe; - upstream_data?: InputMaybe; - version?: InputMaybe; -}; - -/** columns and relationships of "package.release_license" */ -export type Package_Release_License = { - __typename?: 'package_release_license'; - id: Scalars['uuid']; - /** An object relationship */ - license: Package_License; - license_id: Scalars['uuid']; - release_id: Scalars['uuid']; - scan_metadata?: Maybe; - scan_time: Scalars['timestamptz']; - source: Scalars['license_source']; -}; - - -/** columns and relationships of "package.release_license" */ -export type Package_Release_LicenseScan_MetadataArgs = { - path?: InputMaybe; -}; - -/** order by aggregate values of table "package.release_license" */ -export type Package_Release_License_Aggregate_Order_By = { - count?: InputMaybe; - max?: InputMaybe; - min?: InputMaybe; -}; - -/** append existing jsonb value of filtered columns with new jsonb value */ -export type Package_Release_License_Append_Input = { - scan_metadata?: InputMaybe; -}; - -/** input type for inserting array relation for remote table "package.release_license" */ -export type Package_Release_License_Arr_Rel_Insert_Input = { - data: Array; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** Boolean expression to filter rows from the table "package.release_license". All fields are combined with a logical 'AND'. */ -export type Package_Release_License_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - id?: InputMaybe; - license?: InputMaybe; - license_id?: InputMaybe; - release_id?: InputMaybe; - scan_metadata?: InputMaybe; - scan_time?: InputMaybe; - source?: InputMaybe; -}; - -/** unique or primary key constraints on table "package.release_license" */ -export enum Package_Release_License_Constraint { - /** unique or primary key constraint */ - ReleaseLicensePkey = 'release_license_pkey' -} - -/** delete the field or element with specified path (for JSON arrays, negative integers count from the end) */ -export type Package_Release_License_Delete_At_Path_Input = { - scan_metadata?: InputMaybe>; -}; - -/** delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array */ -export type Package_Release_License_Delete_Elem_Input = { - scan_metadata?: InputMaybe; -}; - -/** delete key/value pair or string element. key/value pairs are matched based on their key value */ -export type Package_Release_License_Delete_Key_Input = { - scan_metadata?: InputMaybe; -}; - -/** input type for inserting data into table "package.release_license" */ -export type Package_Release_License_Insert_Input = { - id?: InputMaybe; - license?: InputMaybe; - license_id?: InputMaybe; - release_id?: InputMaybe; - scan_metadata?: InputMaybe; - scan_time?: InputMaybe; - source?: InputMaybe; -}; - -/** order by max() on columns of table "package.release_license" */ -export type Package_Release_License_Max_Order_By = { - id?: InputMaybe; - license_id?: InputMaybe; - release_id?: InputMaybe; - scan_time?: InputMaybe; -}; - -/** order by min() on columns of table "package.release_license" */ -export type Package_Release_License_Min_Order_By = { - id?: InputMaybe; - license_id?: InputMaybe; - release_id?: InputMaybe; - scan_time?: InputMaybe; -}; - -/** response of any mutation on the table "package.release_license" */ -export type Package_Release_License_Mutation_Response = { - __typename?: 'package_release_license_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** on_conflict condition type for table "package.release_license" */ -export type Package_Release_License_On_Conflict = { - constraint: Package_Release_License_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package.release_license". */ -export type Package_Release_License_Order_By = { - id?: InputMaybe; - license?: InputMaybe; - license_id?: InputMaybe; - release_id?: InputMaybe; - scan_metadata?: InputMaybe; - scan_time?: InputMaybe; - source?: InputMaybe; -}; - -/** primary key columns input for table: package_release_license */ -export type Package_Release_License_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - -/** prepend existing jsonb value of filtered columns with new jsonb value */ -export type Package_Release_License_Prepend_Input = { - scan_metadata?: InputMaybe; -}; - -/** select columns of table "package.release_license" */ -export enum Package_Release_License_Select_Column { - /** column name */ - Id = 'id', - /** column name */ - LicenseId = 'license_id', - /** column name */ - ReleaseId = 'release_id', - /** column name */ - ScanMetadata = 'scan_metadata', - /** column name */ - ScanTime = 'scan_time', - /** column name */ - Source = 'source' -} - -/** input type for updating data in table "package.release_license" */ -export type Package_Release_License_Set_Input = { - id?: InputMaybe; - license_id?: InputMaybe; - release_id?: InputMaybe; - scan_metadata?: InputMaybe; - scan_time?: InputMaybe; - source?: InputMaybe; -}; - -/** update columns of table "package.release_license" */ -export enum Package_Release_License_Update_Column { - /** column name */ - Id = 'id', - /** column name */ - LicenseId = 'license_id', - /** column name */ - ReleaseId = 'release_id', - /** column name */ - ScanMetadata = 'scan_metadata', - /** column name */ - ScanTime = 'scan_time', - /** column name */ - Source = 'source' -} - -/** order by max() on columns of table "package.release" */ -export type Package_Release_Max_Order_By = { - blob_hash?: InputMaybe; - id?: InputMaybe; - mirrored_blob_url?: InputMaybe; - observed_time?: InputMaybe; - package_id?: InputMaybe; - publishing_maintainer_id?: InputMaybe; - release_time?: InputMaybe; - upstream_blob_url?: InputMaybe; - version?: InputMaybe; -}; - -/** order by min() on columns of table "package.release" */ -export type Package_Release_Min_Order_By = { - blob_hash?: InputMaybe; - id?: InputMaybe; - mirrored_blob_url?: InputMaybe; - observed_time?: InputMaybe; - package_id?: InputMaybe; - publishing_maintainer_id?: InputMaybe; - release_time?: InputMaybe; - upstream_blob_url?: InputMaybe; - version?: InputMaybe; -}; - -/** response of any mutation on the table "package.release" */ -export type Package_Release_Mutation_Response = { - __typename?: 'package_release_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** input type for inserting object relation for remote table "package.release" */ -export type Package_Release_Obj_Rel_Insert_Input = { - data: Package_Release_Insert_Input; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** on_conflict condition type for table "package.release" */ -export type Package_Release_On_Conflict = { - constraint: Package_Release_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package.release". */ -export type Package_Release_Order_By = { - blob_hash?: InputMaybe; - id?: InputMaybe; - mirrored_blob_url?: InputMaybe; - observed_time?: InputMaybe; - package?: InputMaybe; - package_id?: InputMaybe; - publishing_maintainer?: InputMaybe; - publishing_maintainer_id?: InputMaybe; - release_dependencies_aggregate?: InputMaybe; - release_dependents_aggregate?: InputMaybe; - release_licenses_aggregate?: InputMaybe; - release_time?: InputMaybe; - upstream_blob_url?: InputMaybe; - upstream_data?: InputMaybe; - version?: InputMaybe; -}; - -/** primary key columns input for table: package_release */ -export type Package_Release_Pk_Columns_Input = { - id: Scalars['uuid']; -}; - -/** prepend existing jsonb value of filtered columns with new jsonb value */ -export type Package_Release_Prepend_Input = { - upstream_data?: InputMaybe; -}; - -/** select columns of table "package.release" */ -export enum Package_Release_Select_Column { - /** column name */ - BlobHash = 'blob_hash', - /** column name */ - Id = 'id', - /** column name */ - MirroredBlobUrl = 'mirrored_blob_url', - /** column name */ - ObservedTime = 'observed_time', - /** column name */ - PackageId = 'package_id', - /** column name */ - PublishingMaintainerId = 'publishing_maintainer_id', - /** column name */ - ReleaseTime = 'release_time', - /** column name */ - UpstreamBlobUrl = 'upstream_blob_url', - /** column name */ - UpstreamData = 'upstream_data', - /** column name */ - Version = 'version' -} - -/** input type for updating data in table "package.release" */ -export type Package_Release_Set_Input = { - blob_hash?: InputMaybe; - id?: InputMaybe; - mirrored_blob_url?: InputMaybe; - observed_time?: InputMaybe; - package_id?: InputMaybe; - publishing_maintainer_id?: InputMaybe; - release_time?: InputMaybe; - upstream_blob_url?: InputMaybe; - upstream_data?: InputMaybe; - version?: InputMaybe; -}; - -/** update columns of table "package.release" */ -export enum Package_Release_Update_Column { - /** column name */ - BlobHash = 'blob_hash', - /** column name */ - Id = 'id', - /** column name */ - MirroredBlobUrl = 'mirrored_blob_url', - /** column name */ - ObservedTime = 'observed_time', - /** column name */ - PackageId = 'package_id', - /** column name */ - PublishingMaintainerId = 'publishing_maintainer_id', - /** column name */ - ReleaseTime = 'release_time', - /** column name */ - UpstreamBlobUrl = 'upstream_blob_url', - /** column name */ - UpstreamData = 'upstream_data', - /** column name */ - Version = 'version' -} - -/** select columns of table "package.package" */ -export enum Package_Select_Column { - /** column name */ - CustomRegistry = 'custom_registry', - /** column name */ - Description = 'description', - /** column name */ - Id = 'id', - /** column name */ - Name = 'name', - /** column name */ - PackageManager = 'package_manager' -} - -/** input type for updating data in table "package.package" */ -export type Package_Set_Input = { - custom_registry?: InputMaybe; - description?: InputMaybe; - id?: InputMaybe; - name?: InputMaybe; - package_manager?: InputMaybe; -}; - -/** update columns of table "package.package" */ -export enum Package_Update_Column { - /** column name */ - CustomRegistry = 'custom_registry', - /** column name */ - Description = 'description', - /** column name */ - Id = 'id', - /** column name */ - Name = 'name', - /** column name */ - PackageManager = 'package_manager' -} - -/** columns and relationships of "package_versions" */ -export type Package_Versions = { - __typename?: 'package_versions'; - cpes: Scalars['_text']; - /** An array relationship */ - findings: Array; - fix_state: Scalars['String']; - fixed_in_versions: Scalars['_text']; - id: Scalars['uuid']; - pkg_slug: Scalars['String']; - slug: Scalars['String']; - version_constraint: Scalars['String']; - version_format: Scalars['String']; - /** An object relationship */ - vulnerability_package: Vulnerability_Packages; -}; - - -/** columns and relationships of "package_versions" */ -export type Package_VersionsFindingsArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - -/** order by aggregate values of table "package_versions" */ -export type Package_Versions_Aggregate_Order_By = { - count?: InputMaybe; - max?: InputMaybe; - min?: InputMaybe; -}; - -/** input type for inserting array relation for remote table "package_versions" */ -export type Package_Versions_Arr_Rel_Insert_Input = { - data: Array; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** Boolean expression to filter rows from the table "package_versions". All fields are combined with a logical 'AND'. */ -export type Package_Versions_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - cpes?: InputMaybe<_Text_Comparison_Exp>; - findings?: InputMaybe; - fix_state?: InputMaybe; - fixed_in_versions?: InputMaybe<_Text_Comparison_Exp>; - id?: InputMaybe; - pkg_slug?: InputMaybe; - slug?: InputMaybe; - version_constraint?: InputMaybe; - version_format?: InputMaybe; - vulnerability_package?: InputMaybe; -}; - -/** unique or primary key constraints on table "package_versions" */ -export enum Package_Versions_Constraint { - /** unique or primary key constraint */ - PackageVersionsPkey = 'package_versions_pkey', - /** unique or primary key constraint */ - PackageVersionsSlugKey = 'package_versions_slug_key' -} - -/** input type for inserting data into table "package_versions" */ -export type Package_Versions_Insert_Input = { - findings?: InputMaybe; - slug?: InputMaybe; - vulnerability_package?: InputMaybe; -}; - -/** order by max() on columns of table "package_versions" */ -export type Package_Versions_Max_Order_By = { - fix_state?: InputMaybe; - id?: InputMaybe; - pkg_slug?: InputMaybe; - slug?: InputMaybe; - version_constraint?: InputMaybe; - version_format?: InputMaybe; -}; - -/** order by min() on columns of table "package_versions" */ -export type Package_Versions_Min_Order_By = { - fix_state?: InputMaybe; - id?: InputMaybe; - pkg_slug?: InputMaybe; - slug?: InputMaybe; - version_constraint?: InputMaybe; - version_format?: InputMaybe; -}; - -/** response of any mutation on the table "package_versions" */ -export type Package_Versions_Mutation_Response = { - __typename?: 'package_versions_mutation_response'; - /** number of rows affected by the mutation */ - affected_rows: Scalars['Int']; - /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** input type for inserting object relation for remote table "package_versions" */ -export type Package_Versions_Obj_Rel_Insert_Input = { - data: Package_Versions_Insert_Input; - /** upsert condition */ - on_conflict?: InputMaybe; -}; - -/** on_conflict condition type for table "package_versions" */ -export type Package_Versions_On_Conflict = { - constraint: Package_Versions_Constraint; - update_columns?: Array; - where?: InputMaybe; -}; - -/** Ordering options when selecting data from "package_versions". */ -export type Package_Versions_Order_By = { - cpes?: InputMaybe; - findings_aggregate?: InputMaybe; - fix_state?: InputMaybe; - fixed_in_versions?: InputMaybe; - id?: InputMaybe; - pkg_slug?: InputMaybe; - slug?: InputMaybe; - version_constraint?: InputMaybe; - version_format?: InputMaybe; - vulnerability_package?: InputMaybe; + pkg_slug?: InputMaybe; + slug?: InputMaybe; + version_constraint?: InputMaybe; + version_format?: InputMaybe; + vulnerability_package?: InputMaybe; }; /** primary key columns input for table: package_versions */ @@ -5190,8 +3752,6 @@ export type Query_Root = { findings_by_pk?: Maybe; /** An array relationship */ github_repositories: Array; - /** fetch data from the table: "github_repositories" using primary key columns */ - github_repositories_by_pk?: Maybe; /** fetch data from the table: "guide_related_guides" */ guide_related_guides: Array; /** fetch data from the table: "guide_related_guides" using primary key columns */ @@ -5226,32 +3786,6 @@ export type Query_Root = { organizations_aggregate: Organizations_Aggregate; /** fetch data from the table: "organizations" using primary key columns */ organizations_by_pk?: Maybe; - /** fetch data from the table: "package.package" */ - package: Array; - /** fetch data from the table: "package.package" using primary key columns */ - package_by_pk?: Maybe; - /** fetch data from the table: "package.license" */ - package_license: Array; - /** fetch data from the table: "package.license" using primary key columns */ - package_license_by_pk?: Maybe; - /** fetch data from the table: "package.maintainer" */ - package_maintainer: Array; - /** fetch data from the table: "package.maintainer" using primary key columns */ - package_maintainer_by_pk?: Maybe; - /** fetch data from the table: "package.package_maintainer" */ - package_package_maintainer: Array; - /** fetch data from the table: "package.release" */ - package_release: Array; - /** fetch data from the table: "package.release" using primary key columns */ - package_release_by_pk?: Maybe; - /** fetch data from the table: "package.release_dependency" */ - package_release_dependency: Array; - /** fetch data from the table: "package.release_dependency" using primary key columns */ - package_release_dependency_by_pk?: Maybe; - /** fetch data from the table: "package.release_license" */ - package_release_license: Array; - /** fetch data from the table: "package.release_license" using primary key columns */ - package_release_license_by_pk?: Maybe; /** An array relationship */ package_versions: Array; /** fetch data from the table: "package_versions" using primary key columns */ @@ -5353,11 +3887,6 @@ export type Query_RootGithub_RepositoriesArgs = { }; -export type Query_RootGithub_Repositories_By_PkArgs = { - id: Scalars['uuid']; -}; - - export type Query_RootGuide_Related_GuidesArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -5479,99 +4008,6 @@ export type Query_RootOrganizations_By_PkArgs = { }; -export type Query_RootPackageArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Query_RootPackage_LicenseArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_License_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Query_RootPackage_MaintainerArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_Maintainer_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Query_RootPackage_Package_MaintainerArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_ReleaseArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_Release_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Query_RootPackage_Release_DependencyArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_Release_Dependency_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Query_RootPackage_Release_LicenseArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Query_RootPackage_Release_License_By_PkArgs = { - id: Scalars['uuid']; -}; - - export type Query_RootPackage_VersionsArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -6151,8 +4587,6 @@ export type Subscription_Root = { findings_by_pk?: Maybe; /** An array relationship */ github_repositories: Array; - /** fetch data from the table: "github_repositories" using primary key columns */ - github_repositories_by_pk?: Maybe; /** fetch data from the table: "guide_related_guides" */ guide_related_guides: Array; /** fetch data from the table: "guide_related_guides" using primary key columns */ @@ -6187,32 +4621,6 @@ export type Subscription_Root = { organizations_aggregate: Organizations_Aggregate; /** fetch data from the table: "organizations" using primary key columns */ organizations_by_pk?: Maybe; - /** fetch data from the table: "package.package" */ - package: Array; - /** fetch data from the table: "package.package" using primary key columns */ - package_by_pk?: Maybe; - /** fetch data from the table: "package.license" */ - package_license: Array; - /** fetch data from the table: "package.license" using primary key columns */ - package_license_by_pk?: Maybe; - /** fetch data from the table: "package.maintainer" */ - package_maintainer: Array; - /** fetch data from the table: "package.maintainer" using primary key columns */ - package_maintainer_by_pk?: Maybe; - /** fetch data from the table: "package.package_maintainer" */ - package_package_maintainer: Array; - /** fetch data from the table: "package.release" */ - package_release: Array; - /** fetch data from the table: "package.release" using primary key columns */ - package_release_by_pk?: Maybe; - /** fetch data from the table: "package.release_dependency" */ - package_release_dependency: Array; - /** fetch data from the table: "package.release_dependency" using primary key columns */ - package_release_dependency_by_pk?: Maybe; - /** fetch data from the table: "package.release_license" */ - package_release_license: Array; - /** fetch data from the table: "package.release_license" using primary key columns */ - package_release_license_by_pk?: Maybe; /** An array relationship */ package_versions: Array; /** fetch data from the table: "package_versions" using primary key columns */ @@ -6306,11 +4714,6 @@ export type Subscription_RootGithub_RepositoriesArgs = { }; -export type Subscription_RootGithub_Repositories_By_PkArgs = { - id: Scalars['uuid']; -}; - - export type Subscription_RootGuide_Related_GuidesArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; @@ -6432,99 +4835,6 @@ export type Subscription_RootOrganizations_By_PkArgs = { }; -export type Subscription_RootPackageArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Subscription_RootPackage_LicenseArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_License_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Subscription_RootPackage_MaintainerArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_Maintainer_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Subscription_RootPackage_Package_MaintainerArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_ReleaseArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_Release_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Subscription_RootPackage_Release_DependencyArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_Release_Dependency_By_PkArgs = { - id: Scalars['uuid']; -}; - - -export type Subscription_RootPackage_Release_LicenseArgs = { - distinct_on?: InputMaybe>; - limit?: InputMaybe; - offset?: InputMaybe; - order_by?: InputMaybe>; - where?: InputMaybe; -}; - - -export type Subscription_RootPackage_Release_License_By_PkArgs = { - id: Scalars['uuid']; -}; - - export type Subscription_RootPackage_VersionsArgs = { distinct_on?: InputMaybe>; limit?: InputMaybe; diff --git a/lunatrace/bsl/backend/src/workers/activities/process-github-webhook-activity.ts b/lunatrace/bsl/backend/src/workers/activities/process-github-webhook-activity.ts index f816528df..1912db9ce 100644 --- a/lunatrace/bsl/backend/src/workers/activities/process-github-webhook-activity.ts +++ b/lunatrace/bsl/backend/src/workers/activities/process-github-webhook-activity.ts @@ -12,6 +12,8 @@ * */ +import { EmitterWebhookEvent } from '@octokit/webhooks'; + import { WebhookInterceptor } from '../../github/webhooks/interceptor'; import { hasura } from '../../hasura-api'; import { GetWebhookCacheByDeliveryIdQuery } from '../../hasura-api/generated'; @@ -25,7 +27,7 @@ type WebhookHandlerFunc = (message: ProcessGithubWebhookRequest) => Promise> => { - log.info(`Received webhook`, { + log.info(`received webhook`, { delivery_id: req.delivery_id, }); const { delivery_id } = req; @@ -42,16 +44,22 @@ export function processGithubWebhookActivity(webhooks: WebhookInterceptor): Webh ); if (threwError(webhookData)) { - log.error(`Failed to get webhook data for deliveryId ${deliveryId}`); + log.error(`failed to get webhook data for deliveryId ${deliveryId}`); return newError(`Failed to get webhook data for deliveryId ${deliveryId}`); } - await webhooks.receive({ + + const event: EmitterWebhookEvent = { id: deliveryId, // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-ignore name: webhookData.webhook_cache[0].event_type, payload: webhookData.webhook_cache[0].data, + }; + + log.info('processing github webhook event', { + event, }); + await webhooks.receive(event); return newResult(undefined); } catch (e) { diff --git a/lunatrace/bsl/frontend/src/api/generated.ts b/lunatrace/bsl/frontend/src/api/generated.ts index 7da4104fd..5cb8f7f83 100644 --- a/lunatrace/bsl/frontend/src/api/generated.ts +++ b/lunatrace/bsl/frontend/src/api/generated.ts @@ -781,7 +781,6 @@ export type Fix_State_Enum_Comparison_Exp = { export type Github_Repositories = { __typename?: 'github_repositories'; authenticated_clone_url?: Maybe; - default_branch?: Maybe; git_url: Scalars['String']; github_id?: Maybe; github_node_id?: Maybe; @@ -823,7 +822,6 @@ export type Github_Repositories_Bool_Exp = { _and?: InputMaybe>; _not?: InputMaybe; _or?: InputMaybe>; - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; @@ -835,7 +833,6 @@ export type Github_Repositories_Bool_Exp = { /** order by max() on columns of table "github_repositories" */ export type Github_Repositories_Max_Order_By = { - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; @@ -845,7 +842,6 @@ export type Github_Repositories_Max_Order_By = { /** order by min() on columns of table "github_repositories" */ export type Github_Repositories_Min_Order_By = { - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; @@ -855,7 +851,6 @@ export type Github_Repositories_Min_Order_By = { /** Ordering options when selecting data from "github_repositories". */ export type Github_Repositories_Order_By = { - default_branch?: InputMaybe; git_url?: InputMaybe; github_id?: InputMaybe; github_node_id?: InputMaybe; @@ -867,8 +862,6 @@ export type Github_Repositories_Order_By = { /** select columns of table "github_repositories" */ export enum Github_Repositories_Select_Column { - /** column name */ - DefaultBranch = 'default_branch', /** column name */ GitUrl = 'git_url', /** column name */ diff --git a/lunatrace/cli/Makefile b/lunatrace/cli/Makefile index f72337cc7..cb8938ee1 100644 --- a/lunatrace/cli/Makefile +++ b/lunatrace/cli/Makefile @@ -21,7 +21,7 @@ lunatrace: bindir CGO_ENABLED=0 GOOS=linux go build -o ./bin/${LUNATRACE_BINARY_NAME} ./cmd/lunatrace lunatrace-docker: - sudo docker build -f build/package/lunatrace.dockerfile . -t lunasec/lunatrace-cli:${version} + sudo docker build -f docker/lunatrace.dockerfile . -t lunasec/lunatrace-cli:${version} lunatrace-agent: bindir CGO_ENABLED=0 GOOS=linux go build -o bin/${LUNATRACE_AGENT_BINARY_NAME} ./cmd/lunatraceagent diff --git a/lunatrace/cli/build/package/log4shell-docker-compose.yml b/lunatrace/cli/docker/log4shell-docker-compose.yml similarity index 100% rename from lunatrace/cli/build/package/log4shell-docker-compose.yml rename to lunatrace/cli/docker/log4shell-docker-compose.yml diff --git a/lunatrace/cli/build/package/log4shell.dockerfile b/lunatrace/cli/docker/log4shell.dockerfile similarity index 100% rename from lunatrace/cli/build/package/log4shell.dockerfile rename to lunatrace/cli/docker/log4shell.dockerfile diff --git a/lunatrace/cli/build/package/lunatrace.dockerfile b/lunatrace/cli/docker/lunatrace.dockerfile similarity index 100% rename from lunatrace/cli/build/package/lunatrace.dockerfile rename to lunatrace/cli/docker/lunatrace.dockerfile diff --git a/lunatrace/schema.graphql b/lunatrace/schema.graphql index 15bd8df6e..93ffcacd0 100644 --- a/lunatrace/schema.graphql +++ b/lunatrace/schema.graphql @@ -2250,23 +2250,6 @@ input jsonb_comparison_exp { _nin: [jsonb!] } -scalar license_source - -""" -Boolean expression to compare columns of type "license_source". All fields are combined with logical 'AND'. -""" -input license_source_comparison_exp { - _eq: license_source - _gt: license_source - _gte: license_source - _in: [license_source!] - _is_null: Boolean - _lt: license_source - _lte: license_source - _neq: license_source - _nin: [license_source!] -} - """ columns and relationships of "manifests" """ @@ -2731,160 +2714,6 @@ type mutation_root { on_conflict: organizations_on_conflict ): organizations - """ - insert data into the table: "package.package" - """ - insert_package( - """the rows to be inserted""" - objects: [package_insert_input!]! - - """upsert condition""" - on_conflict: package_on_conflict - ): package_mutation_response - - """ - insert data into the table: "package.license" - """ - insert_package_license( - """the rows to be inserted""" - objects: [package_license_insert_input!]! - - """upsert condition""" - on_conflict: package_license_on_conflict - ): package_license_mutation_response - - """ - insert a single row into the table: "package.license" - """ - insert_package_license_one( - """the row to be inserted""" - object: package_license_insert_input! - - """upsert condition""" - on_conflict: package_license_on_conflict - ): package_license - - """ - insert data into the table: "package.maintainer" - """ - insert_package_maintainer( - """the rows to be inserted""" - objects: [package_maintainer_insert_input!]! - - """upsert condition""" - on_conflict: package_maintainer_on_conflict - ): package_maintainer_mutation_response - - """ - insert a single row into the table: "package.maintainer" - """ - insert_package_maintainer_one( - """the row to be inserted""" - object: package_maintainer_insert_input! - - """upsert condition""" - on_conflict: package_maintainer_on_conflict - ): package_maintainer - - """ - insert a single row into the table: "package.package" - """ - insert_package_one( - """the row to be inserted""" - object: package_insert_input! - - """upsert condition""" - on_conflict: package_on_conflict - ): package - - """ - insert data into the table: "package.package_maintainer" - """ - insert_package_package_maintainer( - """the rows to be inserted""" - objects: [package_package_maintainer_insert_input!]! - - """upsert condition""" - on_conflict: package_package_maintainer_on_conflict - ): package_package_maintainer_mutation_response - - """ - insert a single row into the table: "package.package_maintainer" - """ - insert_package_package_maintainer_one( - """the row to be inserted""" - object: package_package_maintainer_insert_input! - - """upsert condition""" - on_conflict: package_package_maintainer_on_conflict - ): package_package_maintainer - - """ - insert data into the table: "package.release" - """ - insert_package_release( - """the rows to be inserted""" - objects: [package_release_insert_input!]! - - """upsert condition""" - on_conflict: package_release_on_conflict - ): package_release_mutation_response - - """ - insert data into the table: "package.release_dependency" - """ - insert_package_release_dependency( - """the rows to be inserted""" - objects: [package_release_dependency_insert_input!]! - - """upsert condition""" - on_conflict: package_release_dependency_on_conflict - ): package_release_dependency_mutation_response - - """ - insert a single row into the table: "package.release_dependency" - """ - insert_package_release_dependency_one( - """the row to be inserted""" - object: package_release_dependency_insert_input! - - """upsert condition""" - on_conflict: package_release_dependency_on_conflict - ): package_release_dependency - - """ - insert data into the table: "package.release_license" - """ - insert_package_release_license( - """the rows to be inserted""" - objects: [package_release_license_insert_input!]! - - """upsert condition""" - on_conflict: package_release_license_on_conflict - ): package_release_license_mutation_response - - """ - insert a single row into the table: "package.release_license" - """ - insert_package_release_license_one( - """the row to be inserted""" - object: package_release_license_insert_input! - - """upsert condition""" - on_conflict: package_release_license_on_conflict - ): package_release_license - - """ - insert a single row into the table: "package.release" - """ - insert_package_release_one( - """the row to be inserted""" - object: package_release_insert_input! - - """upsert condition""" - on_conflict: package_release_on_conflict - ): package_release - """ insert data into the table: "package_versions" """ @@ -3264,221 +3093,6 @@ type mutation_root { pk_columns: organizations_pk_columns_input! ): organizations - """ - update data of the table: "package.package" - """ - update_package( - """sets the columns of the filtered rows to the given values""" - _set: package_set_input - - """filter the rows which have to be updated""" - where: package_bool_exp! - ): package_mutation_response - - """ - update single row of the table: "package.package" - """ - update_package_by_pk( - """sets the columns of the filtered rows to the given values""" - _set: package_set_input - pk_columns: package_pk_columns_input! - ): package - - """ - update data of the table: "package.license" - """ - update_package_license( - """sets the columns of the filtered rows to the given values""" - _set: package_license_set_input - - """filter the rows which have to be updated""" - where: package_license_bool_exp! - ): package_license_mutation_response - - """ - update single row of the table: "package.license" - """ - update_package_license_by_pk( - """sets the columns of the filtered rows to the given values""" - _set: package_license_set_input - pk_columns: package_license_pk_columns_input! - ): package_license - - """ - update data of the table: "package.maintainer" - """ - update_package_maintainer( - """sets the columns of the filtered rows to the given values""" - _set: package_maintainer_set_input - - """filter the rows which have to be updated""" - where: package_maintainer_bool_exp! - ): package_maintainer_mutation_response - - """ - update single row of the table: "package.maintainer" - """ - update_package_maintainer_by_pk( - """sets the columns of the filtered rows to the given values""" - _set: package_maintainer_set_input - pk_columns: package_maintainer_pk_columns_input! - ): package_maintainer - - """ - update data of the table: "package.package_maintainer" - """ - update_package_package_maintainer( - """sets the columns of the filtered rows to the given values""" - _set: package_package_maintainer_set_input - - """filter the rows which have to be updated""" - where: package_package_maintainer_bool_exp! - ): package_package_maintainer_mutation_response - - """ - update data of the table: "package.release" - """ - update_package_release( - """append existing jsonb value of filtered columns with new jsonb value""" - _append: package_release_append_input - - """ - delete the field or element with specified path (for JSON arrays, negative integers count from the end) - """ - _delete_at_path: package_release_delete_at_path_input - - """ - delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array - """ - _delete_elem: package_release_delete_elem_input - - """ - delete key/value pair or string element. key/value pairs are matched based on their key value - """ - _delete_key: package_release_delete_key_input - - """prepend existing jsonb value of filtered columns with new jsonb value""" - _prepend: package_release_prepend_input - - """sets the columns of the filtered rows to the given values""" - _set: package_release_set_input - - """filter the rows which have to be updated""" - where: package_release_bool_exp! - ): package_release_mutation_response - - """ - update single row of the table: "package.release" - """ - update_package_release_by_pk( - """append existing jsonb value of filtered columns with new jsonb value""" - _append: package_release_append_input - - """ - delete the field or element with specified path (for JSON arrays, negative integers count from the end) - """ - _delete_at_path: package_release_delete_at_path_input - - """ - delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array - """ - _delete_elem: package_release_delete_elem_input - - """ - delete key/value pair or string element. key/value pairs are matched based on their key value - """ - _delete_key: package_release_delete_key_input - - """prepend existing jsonb value of filtered columns with new jsonb value""" - _prepend: package_release_prepend_input - - """sets the columns of the filtered rows to the given values""" - _set: package_release_set_input - pk_columns: package_release_pk_columns_input! - ): package_release - - """ - update data of the table: "package.release_dependency" - """ - update_package_release_dependency( - """sets the columns of the filtered rows to the given values""" - _set: package_release_dependency_set_input - - """filter the rows which have to be updated""" - where: package_release_dependency_bool_exp! - ): package_release_dependency_mutation_response - - """ - update single row of the table: "package.release_dependency" - """ - update_package_release_dependency_by_pk( - """sets the columns of the filtered rows to the given values""" - _set: package_release_dependency_set_input - pk_columns: package_release_dependency_pk_columns_input! - ): package_release_dependency - - """ - update data of the table: "package.release_license" - """ - update_package_release_license( - """append existing jsonb value of filtered columns with new jsonb value""" - _append: package_release_license_append_input - - """ - delete the field or element with specified path (for JSON arrays, negative integers count from the end) - """ - _delete_at_path: package_release_license_delete_at_path_input - - """ - delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array - """ - _delete_elem: package_release_license_delete_elem_input - - """ - delete key/value pair or string element. key/value pairs are matched based on their key value - """ - _delete_key: package_release_license_delete_key_input - - """prepend existing jsonb value of filtered columns with new jsonb value""" - _prepend: package_release_license_prepend_input - - """sets the columns of the filtered rows to the given values""" - _set: package_release_license_set_input - - """filter the rows which have to be updated""" - where: package_release_license_bool_exp! - ): package_release_license_mutation_response - - """ - update single row of the table: "package.release_license" - """ - update_package_release_license_by_pk( - """append existing jsonb value of filtered columns with new jsonb value""" - _append: package_release_license_append_input - - """ - delete the field or element with specified path (for JSON arrays, negative integers count from the end) - """ - _delete_at_path: package_release_license_delete_at_path_input - - """ - delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array - """ - _delete_elem: package_release_license_delete_elem_input - - """ - delete key/value pair or string element. key/value pairs are matched based on their key value - """ - _delete_key: package_release_license_delete_key_input - - """prepend existing jsonb value of filtered columns with new jsonb value""" - _prepend: package_release_license_prepend_input - - """sets the columns of the filtered rows to the given values""" - _set: package_release_license_set_input - pk_columns: package_release_license_pk_columns_input! - ): package_release_license - """ update data of the table: "package_versions" """ @@ -4185,1475 +3799,53 @@ type organizations_sum_fields { } """ -update columns of table "organizations" -""" -enum organizations_update_column { - """column name""" - createdAt - - """column name""" - creator_id - - """column name""" - github_id - - """column name""" - github_node_id - - """column name""" - github_owner_type - - """column name""" - id - - """column name""" - installation_id - - """column name""" - name - - """column name""" - settings_id -} - -"""aggregate var_pop on columns""" -type organizations_var_pop_fields { - github_id: Float - installation_id: Float -} - -"""aggregate var_samp on columns""" -type organizations_var_samp_fields { - github_id: Float - installation_id: Float -} - -"""aggregate variance on columns""" -type organizations_variance_fields { - github_id: Float - installation_id: Float -} - -""" -columns and relationships of "package.package" -""" -type package { - custom_registry: String - description: String - id: uuid! - name: String! - - """An array relationship""" - package_maintainers( - """distinct select on columns""" - distinct_on: [package_package_maintainer_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_package_maintainer_order_by!] - - """filter the rows returned""" - where: package_package_maintainer_bool_exp - ): [package_package_maintainer!]! - package_manager: package_manager! - - """An array relationship""" - releases( - """distinct select on columns""" - distinct_on: [package_release_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_order_by!] - - """filter the rows returned""" - where: package_release_bool_exp - ): [package_release!]! -} - -""" -Boolean expression to filter rows from the table "package.package". All fields are combined with a logical 'AND'. -""" -input package_bool_exp { - _and: [package_bool_exp!] - _not: package_bool_exp - _or: [package_bool_exp!] - custom_registry: String_comparison_exp - description: String_comparison_exp - id: uuid_comparison_exp - name: String_comparison_exp - package_maintainers: package_package_maintainer_bool_exp - package_manager: package_manager_comparison_exp - releases: package_release_bool_exp -} - -""" -unique or primary key constraints on table "package.package" -""" -enum package_constraint { - """unique or primary key constraint""" - package_package_manager_custom_registry_name_idx - - """unique or primary key constraint""" - package_pkey -} - -""" -input type for inserting data into table "package.package" -""" -input package_insert_input { - custom_registry: String - description: String - id: uuid - name: String - package_maintainers: package_package_maintainer_arr_rel_insert_input - package_manager: package_manager - releases: package_release_arr_rel_insert_input -} - -""" -columns and relationships of "package.license" -""" -type package_license { - id: uuid! - name: String! - - """An array relationship""" - release_licenses( - """distinct select on columns""" - distinct_on: [package_release_license_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_license_order_by!] - - """filter the rows returned""" - where: package_release_license_bool_exp - ): [package_release_license!]! -} - -""" -Boolean expression to filter rows from the table "package.license". All fields are combined with a logical 'AND'. -""" -input package_license_bool_exp { - _and: [package_license_bool_exp!] - _not: package_license_bool_exp - _or: [package_license_bool_exp!] - id: uuid_comparison_exp - name: String_comparison_exp - release_licenses: package_release_license_bool_exp -} - -""" -unique or primary key constraints on table "package.license" -""" -enum package_license_constraint { - """unique or primary key constraint""" - license_name_idx - - """unique or primary key constraint""" - license_pkey -} - -""" -input type for inserting data into table "package.license" -""" -input package_license_insert_input { - id: uuid - name: String - release_licenses: package_release_license_arr_rel_insert_input -} - -""" -response of any mutation on the table "package.license" -""" -type package_license_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package_license!]! -} - -""" -input type for inserting object relation for remote table "package.license" -""" -input package_license_obj_rel_insert_input { - data: package_license_insert_input! - - """upsert condition""" - on_conflict: package_license_on_conflict -} - -""" -on_conflict condition type for table "package.license" -""" -input package_license_on_conflict { - constraint: package_license_constraint! - update_columns: [package_license_update_column!]! = [] - where: package_license_bool_exp -} - -"""Ordering options when selecting data from "package.license".""" -input package_license_order_by { - id: order_by - name: order_by - release_licenses_aggregate: package_release_license_aggregate_order_by -} - -"""primary key columns input for table: package_license""" -input package_license_pk_columns_input { - id: uuid! -} - -""" -select columns of table "package.license" -""" -enum package_license_select_column { - """column name""" - id - - """column name""" - name -} - -""" -input type for updating data in table "package.license" -""" -input package_license_set_input { - id: uuid - name: String -} - -""" -update columns of table "package.license" -""" -enum package_license_update_column { - """column name""" - id - - """column name""" - name -} - -""" -columns and relationships of "package.maintainer" -""" -type package_maintainer { - email: String! - id: uuid! - name: String - - """An array relationship""" - package_maintainers( - """distinct select on columns""" - distinct_on: [package_package_maintainer_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_package_maintainer_order_by!] - - """filter the rows returned""" - where: package_package_maintainer_bool_exp - ): [package_package_maintainer!]! - package_manager: package_manager - - """An array relationship""" - published_releases( - """distinct select on columns""" - distinct_on: [package_release_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_order_by!] - - """filter the rows returned""" - where: package_release_bool_exp - ): [package_release!]! -} - -""" -Boolean expression to filter rows from the table "package.maintainer". All fields are combined with a logical 'AND'. -""" -input package_maintainer_bool_exp { - _and: [package_maintainer_bool_exp!] - _not: package_maintainer_bool_exp - _or: [package_maintainer_bool_exp!] - email: String_comparison_exp - id: uuid_comparison_exp - name: String_comparison_exp - package_maintainers: package_package_maintainer_bool_exp - package_manager: package_manager_comparison_exp - published_releases: package_release_bool_exp -} - -""" -unique or primary key constraints on table "package.maintainer" -""" -enum package_maintainer_constraint { - """unique or primary key constraint""" - maintainer_package_manager_email_idx - - """unique or primary key constraint""" - maintainer_pkey -} - -""" -input type for inserting data into table "package.maintainer" -""" -input package_maintainer_insert_input { - email: String - id: uuid - name: String - package_maintainers: package_package_maintainer_arr_rel_insert_input - package_manager: package_manager - published_releases: package_release_arr_rel_insert_input -} - -""" -response of any mutation on the table "package.maintainer" -""" -type package_maintainer_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package_maintainer!]! -} - -""" -input type for inserting object relation for remote table "package.maintainer" -""" -input package_maintainer_obj_rel_insert_input { - data: package_maintainer_insert_input! - - """upsert condition""" - on_conflict: package_maintainer_on_conflict -} - -""" -on_conflict condition type for table "package.maintainer" -""" -input package_maintainer_on_conflict { - constraint: package_maintainer_constraint! - update_columns: [package_maintainer_update_column!]! = [] - where: package_maintainer_bool_exp -} - -"""Ordering options when selecting data from "package.maintainer".""" -input package_maintainer_order_by { - email: order_by - id: order_by - name: order_by - package_maintainers_aggregate: package_package_maintainer_aggregate_order_by - package_manager: order_by - published_releases_aggregate: package_release_aggregate_order_by -} - -"""primary key columns input for table: package_maintainer""" -input package_maintainer_pk_columns_input { - id: uuid! -} - -""" -select columns of table "package.maintainer" -""" -enum package_maintainer_select_column { - """column name""" - email - - """column name""" - id - - """column name""" - name - - """column name""" - package_manager -} - -""" -input type for updating data in table "package.maintainer" -""" -input package_maintainer_set_input { - email: String - id: uuid - name: String - package_manager: package_manager -} - -""" -update columns of table "package.maintainer" -""" -enum package_maintainer_update_column { - """column name""" - email - - """column name""" - id - - """column name""" - name - - """column name""" - package_manager -} - -scalar package_manager - -""" -Boolean expression to compare columns of type "package_manager". All fields are combined with logical 'AND'. -""" -input package_manager_comparison_exp { - _eq: package_manager - _gt: package_manager - _gte: package_manager - _in: [package_manager!] - _is_null: Boolean - _lt: package_manager - _lte: package_manager - _neq: package_manager - _nin: [package_manager!] -} - -""" -response of any mutation on the table "package.package" -""" -type package_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package!]! -} - -""" -input type for inserting object relation for remote table "package.package" -""" -input package_obj_rel_insert_input { - data: package_insert_input! - - """upsert condition""" - on_conflict: package_on_conflict -} - -""" -on_conflict condition type for table "package.package" -""" -input package_on_conflict { - constraint: package_constraint! - update_columns: [package_update_column!]! = [] - where: package_bool_exp -} - -"""Ordering options when selecting data from "package.package".""" -input package_order_by { - custom_registry: order_by - description: order_by - id: order_by - name: order_by - package_maintainers_aggregate: package_package_maintainer_aggregate_order_by - package_manager: order_by - releases_aggregate: package_release_aggregate_order_by -} - -""" -columns and relationships of "package.package_maintainer" -""" -type package_package_maintainer { - """An object relationship""" - maintainer: package_maintainer - maintainer_id: uuid - - """An object relationship""" - package: package - package_id: uuid -} - -""" -order by aggregate values of table "package.package_maintainer" -""" -input package_package_maintainer_aggregate_order_by { - count: order_by - max: package_package_maintainer_max_order_by - min: package_package_maintainer_min_order_by -} - -""" -input type for inserting array relation for remote table "package.package_maintainer" -""" -input package_package_maintainer_arr_rel_insert_input { - data: [package_package_maintainer_insert_input!]! - - """upsert condition""" - on_conflict: package_package_maintainer_on_conflict -} - -""" -Boolean expression to filter rows from the table "package.package_maintainer". All fields are combined with a logical 'AND'. -""" -input package_package_maintainer_bool_exp { - _and: [package_package_maintainer_bool_exp!] - _not: package_package_maintainer_bool_exp - _or: [package_package_maintainer_bool_exp!] - maintainer: package_maintainer_bool_exp - maintainer_id: uuid_comparison_exp - package: package_bool_exp - package_id: uuid_comparison_exp -} - -""" -unique or primary key constraints on table "package.package_maintainer" -""" -enum package_package_maintainer_constraint { - """unique or primary key constraint""" - package_maintainer_package_id_maintainer_id_idx -} - -""" -input type for inserting data into table "package.package_maintainer" -""" -input package_package_maintainer_insert_input { - maintainer: package_maintainer_obj_rel_insert_input - maintainer_id: uuid - package: package_obj_rel_insert_input - package_id: uuid -} - -""" -order by max() on columns of table "package.package_maintainer" -""" -input package_package_maintainer_max_order_by { - maintainer_id: order_by - package_id: order_by -} - -""" -order by min() on columns of table "package.package_maintainer" -""" -input package_package_maintainer_min_order_by { - maintainer_id: order_by - package_id: order_by -} - -""" -response of any mutation on the table "package.package_maintainer" -""" -type package_package_maintainer_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package_package_maintainer!]! -} - -""" -on_conflict condition type for table "package.package_maintainer" -""" -input package_package_maintainer_on_conflict { - constraint: package_package_maintainer_constraint! - update_columns: [package_package_maintainer_update_column!]! = [] - where: package_package_maintainer_bool_exp -} - -""" -Ordering options when selecting data from "package.package_maintainer". -""" -input package_package_maintainer_order_by { - maintainer: package_maintainer_order_by - maintainer_id: order_by - package: package_order_by - package_id: order_by -} - -""" -select columns of table "package.package_maintainer" -""" -enum package_package_maintainer_select_column { - """column name""" - maintainer_id - - """column name""" - package_id -} - -""" -input type for updating data in table "package.package_maintainer" -""" -input package_package_maintainer_set_input { - maintainer_id: uuid - package_id: uuid -} - -""" -update columns of table "package.package_maintainer" -""" -enum package_package_maintainer_update_column { - """column name""" - maintainer_id - - """column name""" - package_id -} - -"""primary key columns input for table: package""" -input package_pk_columns_input { - id: uuid! -} - -""" -columns and relationships of "package.release" -""" -type package_release { - blob_hash: String - id: uuid! - mirrored_blob_url: String - observed_time: timestamptz! - - """An object relationship""" - package: package - package_id: uuid - - """An object relationship""" - publishing_maintainer: package_maintainer - publishing_maintainer_id: uuid - - """An array relationship""" - release_dependencies( - """distinct select on columns""" - distinct_on: [package_release_dependency_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_dependency_order_by!] - - """filter the rows returned""" - where: package_release_dependency_bool_exp - ): [package_release_dependency!]! - - """An array relationship""" - release_dependents( - """distinct select on columns""" - distinct_on: [package_release_dependency_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_dependency_order_by!] - - """filter the rows returned""" - where: package_release_dependency_bool_exp - ): [package_release_dependency!]! - - """An array relationship""" - release_licenses( - """distinct select on columns""" - distinct_on: [package_release_license_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_license_order_by!] - - """filter the rows returned""" - where: package_release_license_bool_exp - ): [package_release_license!]! - release_time: timestamptz - upstream_blob_url: String - upstream_data( - """JSON select path""" - path: String - ): jsonb - version: String! -} - -""" -order by aggregate values of table "package.release" -""" -input package_release_aggregate_order_by { - count: order_by - max: package_release_max_order_by - min: package_release_min_order_by -} - -"""append existing jsonb value of filtered columns with new jsonb value""" -input package_release_append_input { - upstream_data: jsonb -} - -""" -input type for inserting array relation for remote table "package.release" -""" -input package_release_arr_rel_insert_input { - data: [package_release_insert_input!]! - - """upsert condition""" - on_conflict: package_release_on_conflict -} - -""" -Boolean expression to filter rows from the table "package.release". All fields are combined with a logical 'AND'. -""" -input package_release_bool_exp { - _and: [package_release_bool_exp!] - _not: package_release_bool_exp - _or: [package_release_bool_exp!] - blob_hash: String_comparison_exp - id: uuid_comparison_exp - mirrored_blob_url: String_comparison_exp - observed_time: timestamptz_comparison_exp - package: package_bool_exp - package_id: uuid_comparison_exp - publishing_maintainer: package_maintainer_bool_exp - publishing_maintainer_id: uuid_comparison_exp - release_dependencies: package_release_dependency_bool_exp - release_dependents: package_release_dependency_bool_exp - release_licenses: package_release_license_bool_exp - release_time: timestamptz_comparison_exp - upstream_blob_url: String_comparison_exp - upstream_data: jsonb_comparison_exp - version: String_comparison_exp -} - -""" -unique or primary key constraints on table "package.release" -""" -enum package_release_constraint { - """unique or primary key constraint""" - release_package_id_version_idx - - """unique or primary key constraint""" - release_pkey -} - -""" -delete the field or element with specified path (for JSON arrays, negative integers count from the end) -""" -input package_release_delete_at_path_input { - upstream_data: [String!] -} - -""" -delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array -""" -input package_release_delete_elem_input { - upstream_data: Int -} - -""" -delete key/value pair or string element. key/value pairs are matched based on their key value -""" -input package_release_delete_key_input { - upstream_data: String -} - -""" -columns and relationships of "package.release_dependency" -""" -type package_release_dependency { - """An object relationship""" - dependency_package: package - dependency_package_id: uuid - - """An object relationship""" - dependency_release: package_release - dependency_release_id: uuid - id: uuid! - package_name: String! - package_version_query: String! - - """An object relationship""" - release: package_release! - release_id: uuid! -} - -""" -order by aggregate values of table "package.release_dependency" -""" -input package_release_dependency_aggregate_order_by { - count: order_by - max: package_release_dependency_max_order_by - min: package_release_dependency_min_order_by -} - -""" -input type for inserting array relation for remote table "package.release_dependency" -""" -input package_release_dependency_arr_rel_insert_input { - data: [package_release_dependency_insert_input!]! - - """upsert condition""" - on_conflict: package_release_dependency_on_conflict -} - -""" -Boolean expression to filter rows from the table "package.release_dependency". All fields are combined with a logical 'AND'. -""" -input package_release_dependency_bool_exp { - _and: [package_release_dependency_bool_exp!] - _not: package_release_dependency_bool_exp - _or: [package_release_dependency_bool_exp!] - dependency_package: package_bool_exp - dependency_package_id: uuid_comparison_exp - dependency_release: package_release_bool_exp - dependency_release_id: uuid_comparison_exp - id: uuid_comparison_exp - package_name: String_comparison_exp - package_version_query: String_comparison_exp - release: package_release_bool_exp - release_id: uuid_comparison_exp -} - -""" -unique or primary key constraints on table "package.release_dependency" -""" -enum package_release_dependency_constraint { - """unique or primary key constraint""" - release_dependency_pkey - - """unique or primary key constraint""" - release_dependency_release_id_package_name_package_version__idx -} - -""" -input type for inserting data into table "package.release_dependency" -""" -input package_release_dependency_insert_input { - dependency_package: package_obj_rel_insert_input - dependency_package_id: uuid - dependency_release: package_release_obj_rel_insert_input - dependency_release_id: uuid - id: uuid - package_name: String - package_version_query: String - release: package_release_obj_rel_insert_input - release_id: uuid -} - -""" -order by max() on columns of table "package.release_dependency" -""" -input package_release_dependency_max_order_by { - dependency_package_id: order_by - dependency_release_id: order_by - id: order_by - package_name: order_by - package_version_query: order_by - release_id: order_by -} - -""" -order by min() on columns of table "package.release_dependency" -""" -input package_release_dependency_min_order_by { - dependency_package_id: order_by - dependency_release_id: order_by - id: order_by - package_name: order_by - package_version_query: order_by - release_id: order_by -} - -""" -response of any mutation on the table "package.release_dependency" -""" -type package_release_dependency_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package_release_dependency!]! -} - -""" -on_conflict condition type for table "package.release_dependency" -""" -input package_release_dependency_on_conflict { - constraint: package_release_dependency_constraint! - update_columns: [package_release_dependency_update_column!]! = [] - where: package_release_dependency_bool_exp -} - -""" -Ordering options when selecting data from "package.release_dependency". -""" -input package_release_dependency_order_by { - dependency_package: package_order_by - dependency_package_id: order_by - dependency_release: package_release_order_by - dependency_release_id: order_by - id: order_by - package_name: order_by - package_version_query: order_by - release: package_release_order_by - release_id: order_by -} - -"""primary key columns input for table: package_release_dependency""" -input package_release_dependency_pk_columns_input { - id: uuid! -} - -""" -select columns of table "package.release_dependency" -""" -enum package_release_dependency_select_column { - """column name""" - dependency_package_id - - """column name""" - dependency_release_id - - """column name""" - id - - """column name""" - package_name - - """column name""" - package_version_query - - """column name""" - release_id -} - -""" -input type for updating data in table "package.release_dependency" -""" -input package_release_dependency_set_input { - dependency_package_id: uuid - dependency_release_id: uuid - id: uuid - package_name: String - package_version_query: String - release_id: uuid -} - -""" -update columns of table "package.release_dependency" -""" -enum package_release_dependency_update_column { - """column name""" - dependency_package_id - - """column name""" - dependency_release_id - - """column name""" - id - - """column name""" - package_name - - """column name""" - package_version_query - - """column name""" - release_id -} - -""" -input type for inserting data into table "package.release" -""" -input package_release_insert_input { - blob_hash: String - id: uuid - mirrored_blob_url: String - observed_time: timestamptz - package: package_obj_rel_insert_input - package_id: uuid - publishing_maintainer: package_maintainer_obj_rel_insert_input - publishing_maintainer_id: uuid - release_dependencies: package_release_dependency_arr_rel_insert_input - release_dependents: package_release_dependency_arr_rel_insert_input - release_licenses: package_release_license_arr_rel_insert_input - release_time: timestamptz - upstream_blob_url: String - upstream_data: jsonb - version: String -} - -""" -columns and relationships of "package.release_license" -""" -type package_release_license { - id: uuid! - - """An object relationship""" - license: package_license! - license_id: uuid! - release_id: uuid! - scan_metadata( - """JSON select path""" - path: String - ): jsonb - scan_time: timestamptz! - source: license_source! -} - -""" -order by aggregate values of table "package.release_license" -""" -input package_release_license_aggregate_order_by { - count: order_by - max: package_release_license_max_order_by - min: package_release_license_min_order_by -} - -"""append existing jsonb value of filtered columns with new jsonb value""" -input package_release_license_append_input { - scan_metadata: jsonb -} - -""" -input type for inserting array relation for remote table "package.release_license" -""" -input package_release_license_arr_rel_insert_input { - data: [package_release_license_insert_input!]! - - """upsert condition""" - on_conflict: package_release_license_on_conflict -} - -""" -Boolean expression to filter rows from the table "package.release_license". All fields are combined with a logical 'AND'. -""" -input package_release_license_bool_exp { - _and: [package_release_license_bool_exp!] - _not: package_release_license_bool_exp - _or: [package_release_license_bool_exp!] - id: uuid_comparison_exp - license: package_license_bool_exp - license_id: uuid_comparison_exp - release_id: uuid_comparison_exp - scan_metadata: jsonb_comparison_exp - scan_time: timestamptz_comparison_exp - source: license_source_comparison_exp -} - -""" -unique or primary key constraints on table "package.release_license" -""" -enum package_release_license_constraint { - """unique or primary key constraint""" - release_license_pkey -} - -""" -delete the field or element with specified path (for JSON arrays, negative integers count from the end) -""" -input package_release_license_delete_at_path_input { - scan_metadata: [String!] -} - -""" -delete the array element with specified index (negative integers count from the end). throws an error if top level container is not an array -""" -input package_release_license_delete_elem_input { - scan_metadata: Int -} - -""" -delete key/value pair or string element. key/value pairs are matched based on their key value -""" -input package_release_license_delete_key_input { - scan_metadata: String -} - -""" -input type for inserting data into table "package.release_license" -""" -input package_release_license_insert_input { - id: uuid - license: package_license_obj_rel_insert_input - license_id: uuid - release_id: uuid - scan_metadata: jsonb - scan_time: timestamptz - source: license_source -} - -""" -order by max() on columns of table "package.release_license" -""" -input package_release_license_max_order_by { - id: order_by - license_id: order_by - release_id: order_by - scan_time: order_by -} - -""" -order by min() on columns of table "package.release_license" -""" -input package_release_license_min_order_by { - id: order_by - license_id: order_by - release_id: order_by - scan_time: order_by -} - -""" -response of any mutation on the table "package.release_license" -""" -type package_release_license_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package_release_license!]! -} - -""" -on_conflict condition type for table "package.release_license" -""" -input package_release_license_on_conflict { - constraint: package_release_license_constraint! - update_columns: [package_release_license_update_column!]! = [] - where: package_release_license_bool_exp -} - -"""Ordering options when selecting data from "package.release_license".""" -input package_release_license_order_by { - id: order_by - license: package_license_order_by - license_id: order_by - release_id: order_by - scan_metadata: order_by - scan_time: order_by - source: order_by -} - -"""primary key columns input for table: package_release_license""" -input package_release_license_pk_columns_input { - id: uuid! -} - -"""prepend existing jsonb value of filtered columns with new jsonb value""" -input package_release_license_prepend_input { - scan_metadata: jsonb -} - -""" -select columns of table "package.release_license" -""" -enum package_release_license_select_column { - """column name""" - id - - """column name""" - license_id - - """column name""" - release_id - - """column name""" - scan_metadata - - """column name""" - scan_time - - """column name""" - source -} - -""" -input type for updating data in table "package.release_license" -""" -input package_release_license_set_input { - id: uuid - license_id: uuid - release_id: uuid - scan_metadata: jsonb - scan_time: timestamptz - source: license_source -} - -""" -update columns of table "package.release_license" -""" -enum package_release_license_update_column { - """column name""" - id - - """column name""" - license_id - - """column name""" - release_id - - """column name""" - scan_metadata - - """column name""" - scan_time - - """column name""" - source -} - -""" -order by max() on columns of table "package.release" -""" -input package_release_max_order_by { - blob_hash: order_by - id: order_by - mirrored_blob_url: order_by - observed_time: order_by - package_id: order_by - publishing_maintainer_id: order_by - release_time: order_by - upstream_blob_url: order_by - version: order_by -} - -""" -order by min() on columns of table "package.release" -""" -input package_release_min_order_by { - blob_hash: order_by - id: order_by - mirrored_blob_url: order_by - observed_time: order_by - package_id: order_by - publishing_maintainer_id: order_by - release_time: order_by - upstream_blob_url: order_by - version: order_by -} - -""" -response of any mutation on the table "package.release" -""" -type package_release_mutation_response { - """number of rows affected by the mutation""" - affected_rows: Int! - - """data from the rows affected by the mutation""" - returning: [package_release!]! -} - -""" -input type for inserting object relation for remote table "package.release" -""" -input package_release_obj_rel_insert_input { - data: package_release_insert_input! - - """upsert condition""" - on_conflict: package_release_on_conflict -} - -""" -on_conflict condition type for table "package.release" -""" -input package_release_on_conflict { - constraint: package_release_constraint! - update_columns: [package_release_update_column!]! = [] - where: package_release_bool_exp -} - -"""Ordering options when selecting data from "package.release".""" -input package_release_order_by { - blob_hash: order_by - id: order_by - mirrored_blob_url: order_by - observed_time: order_by - package: package_order_by - package_id: order_by - publishing_maintainer: package_maintainer_order_by - publishing_maintainer_id: order_by - release_dependencies_aggregate: package_release_dependency_aggregate_order_by - release_dependents_aggregate: package_release_dependency_aggregate_order_by - release_licenses_aggregate: package_release_license_aggregate_order_by - release_time: order_by - upstream_blob_url: order_by - upstream_data: order_by - version: order_by -} - -"""primary key columns input for table: package_release""" -input package_release_pk_columns_input { - id: uuid! -} - -"""prepend existing jsonb value of filtered columns with new jsonb value""" -input package_release_prepend_input { - upstream_data: jsonb -} - -""" -select columns of table "package.release" -""" -enum package_release_select_column { - """column name""" - blob_hash - - """column name""" - id - - """column name""" - mirrored_blob_url - - """column name""" - observed_time - - """column name""" - package_id - - """column name""" - publishing_maintainer_id - - """column name""" - release_time - - """column name""" - upstream_blob_url - - """column name""" - upstream_data - - """column name""" - version -} - -""" -input type for updating data in table "package.release" -""" -input package_release_set_input { - blob_hash: String - id: uuid - mirrored_blob_url: String - observed_time: timestamptz - package_id: uuid - publishing_maintainer_id: uuid - release_time: timestamptz - upstream_blob_url: String - upstream_data: jsonb - version: String -} - -""" -update columns of table "package.release" -""" -enum package_release_update_column { - """column name""" - blob_hash - - """column name""" - id - - """column name""" - mirrored_blob_url - - """column name""" - observed_time - - """column name""" - package_id - - """column name""" - publishing_maintainer_id - - """column name""" - release_time - - """column name""" - upstream_blob_url - - """column name""" - upstream_data - - """column name""" - version -} - -""" -select columns of table "package.package" -""" -enum package_select_column { - """column name""" - custom_registry - - """column name""" - description - - """column name""" - id - - """column name""" - name - - """column name""" - package_manager -} - -""" -input type for updating data in table "package.package" -""" -input package_set_input { - custom_registry: String - description: String - id: uuid - name: String - package_manager: package_manager -} - -""" -update columns of table "package.package" +update columns of table "organizations" """ -enum package_update_column { +enum organizations_update_column { """column name""" - custom_registry + createdAt """column name""" - description + creator_id + + """column name""" + github_id + + """column name""" + github_node_id + + """column name""" + github_owner_type """column name""" id + """column name""" + installation_id + """column name""" name """column name""" - package_manager + settings_id +} + +"""aggregate var_pop on columns""" +type organizations_var_pop_fields { + github_id: Float + installation_id: Float +} + +"""aggregate var_samp on columns""" +type organizations_var_samp_fields { + github_id: Float + installation_id: Float +} + +"""aggregate variance on columns""" +type organizations_variance_fields { + github_id: Float + installation_id: Float } """ @@ -6623,170 +4815,6 @@ type query_root { """fetch data from the table: "organizations" using primary key columns""" organizations_by_pk(id: uuid!): organizations - """ - fetch data from the table: "package.package" - """ - package( - """distinct select on columns""" - distinct_on: [package_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_order_by!] - - """filter the rows returned""" - where: package_bool_exp - ): [package!]! - - """fetch data from the table: "package.package" using primary key columns""" - package_by_pk(id: uuid!): package - - """ - fetch data from the table: "package.license" - """ - package_license( - """distinct select on columns""" - distinct_on: [package_license_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_license_order_by!] - - """filter the rows returned""" - where: package_license_bool_exp - ): [package_license!]! - - """fetch data from the table: "package.license" using primary key columns""" - package_license_by_pk(id: uuid!): package_license - - """ - fetch data from the table: "package.maintainer" - """ - package_maintainer( - """distinct select on columns""" - distinct_on: [package_maintainer_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_maintainer_order_by!] - - """filter the rows returned""" - where: package_maintainer_bool_exp - ): [package_maintainer!]! - - """ - fetch data from the table: "package.maintainer" using primary key columns - """ - package_maintainer_by_pk(id: uuid!): package_maintainer - - """ - fetch data from the table: "package.package_maintainer" - """ - package_package_maintainer( - """distinct select on columns""" - distinct_on: [package_package_maintainer_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_package_maintainer_order_by!] - - """filter the rows returned""" - where: package_package_maintainer_bool_exp - ): [package_package_maintainer!]! - - """ - fetch data from the table: "package.release" - """ - package_release( - """distinct select on columns""" - distinct_on: [package_release_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_order_by!] - - """filter the rows returned""" - where: package_release_bool_exp - ): [package_release!]! - - """fetch data from the table: "package.release" using primary key columns""" - package_release_by_pk(id: uuid!): package_release - - """ - fetch data from the table: "package.release_dependency" - """ - package_release_dependency( - """distinct select on columns""" - distinct_on: [package_release_dependency_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_dependency_order_by!] - - """filter the rows returned""" - where: package_release_dependency_bool_exp - ): [package_release_dependency!]! - - """ - fetch data from the table: "package.release_dependency" using primary key columns - """ - package_release_dependency_by_pk(id: uuid!): package_release_dependency - - """ - fetch data from the table: "package.release_license" - """ - package_release_license( - """distinct select on columns""" - distinct_on: [package_release_license_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_license_order_by!] - - """filter the rows returned""" - where: package_release_license_bool_exp - ): [package_release_license!]! - - """ - fetch data from the table: "package.release_license" using primary key columns - """ - package_release_license_by_pk(id: uuid!): package_release_license - """An array relationship""" package_versions( """distinct select on columns""" @@ -7835,170 +5863,6 @@ type subscription_root { """fetch data from the table: "organizations" using primary key columns""" organizations_by_pk(id: uuid!): organizations - """ - fetch data from the table: "package.package" - """ - package( - """distinct select on columns""" - distinct_on: [package_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_order_by!] - - """filter the rows returned""" - where: package_bool_exp - ): [package!]! - - """fetch data from the table: "package.package" using primary key columns""" - package_by_pk(id: uuid!): package - - """ - fetch data from the table: "package.license" - """ - package_license( - """distinct select on columns""" - distinct_on: [package_license_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_license_order_by!] - - """filter the rows returned""" - where: package_license_bool_exp - ): [package_license!]! - - """fetch data from the table: "package.license" using primary key columns""" - package_license_by_pk(id: uuid!): package_license - - """ - fetch data from the table: "package.maintainer" - """ - package_maintainer( - """distinct select on columns""" - distinct_on: [package_maintainer_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_maintainer_order_by!] - - """filter the rows returned""" - where: package_maintainer_bool_exp - ): [package_maintainer!]! - - """ - fetch data from the table: "package.maintainer" using primary key columns - """ - package_maintainer_by_pk(id: uuid!): package_maintainer - - """ - fetch data from the table: "package.package_maintainer" - """ - package_package_maintainer( - """distinct select on columns""" - distinct_on: [package_package_maintainer_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_package_maintainer_order_by!] - - """filter the rows returned""" - where: package_package_maintainer_bool_exp - ): [package_package_maintainer!]! - - """ - fetch data from the table: "package.release" - """ - package_release( - """distinct select on columns""" - distinct_on: [package_release_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_order_by!] - - """filter the rows returned""" - where: package_release_bool_exp - ): [package_release!]! - - """fetch data from the table: "package.release" using primary key columns""" - package_release_by_pk(id: uuid!): package_release - - """ - fetch data from the table: "package.release_dependency" - """ - package_release_dependency( - """distinct select on columns""" - distinct_on: [package_release_dependency_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_dependency_order_by!] - - """filter the rows returned""" - where: package_release_dependency_bool_exp - ): [package_release_dependency!]! - - """ - fetch data from the table: "package.release_dependency" using primary key columns - """ - package_release_dependency_by_pk(id: uuid!): package_release_dependency - - """ - fetch data from the table: "package.release_license" - """ - package_release_license( - """distinct select on columns""" - distinct_on: [package_release_license_select_column!] - - """limit the number of rows returned""" - limit: Int - - """skip the first n rows. Use only with order_by""" - offset: Int - - """sort the rows by one or more columns""" - order_by: [package_release_license_order_by!] - - """filter the rows returned""" - where: package_release_license_bool_exp - ): [package_release_license!]! - - """ - fetch data from the table: "package.release_license" using primary key columns - """ - package_release_license_by_pk(id: uuid!): package_release_license - """An array relationship""" package_versions( """distinct select on columns"""