Skip to content

Reduce leak between gql schema#17878

Merged
charlesBochet merged 13 commits intomainfrom
refactor-app-access-token
Feb 12, 2026
Merged

Reduce leak between gql schema#17878
charlesBochet merged 13 commits intomainfrom
refactor-app-access-token

Conversation

@charlesBochet
Copy link
Copy Markdown
Member

@charlesBochet charlesBochet commented Feb 11, 2026

Reduce type leakage between GraphQL schemas

Why

Twenty runs two separate GraphQL schemas: core and metadata. NestJS's @nestjs/graphql uses a global TypeMetadataStorage that accumulates all decorated types across all modules. When each schema is built, every registered type leaks into both schemas regardless of which module it belongs to.

This means the core schema's generated TypeScript (generated/graphql.ts) contained ~2,700 lines of types that only belong to the metadata schema (and vice versa). This creates confusion about type ownership, inflates generated code, and makes it harder to reason about which API surface each schema actually exposes.

How

1. Patch @nestjs/graphql to support schema-scoped type resolution

  • (Already done) Added a resolverSchemaScope option to GqlModuleOptions, allowing each schema to declare a scope (e.g. 'metadata')
  • ResolversExplorerService now filters resolvers by a RESOLVER_SCHEMA_SCOPE metadata key, so each schema only sees its own resolvers
  • GraphQLSchemaFactory now performs a reachability walk (computeReachableTypes) starting from scoped resolver return types and arguments, only including types that are transitively referenced — handling unions, interfaces, and prototype chains
  • Type definition storage and orphaned reference registry are cleared between schema builds to prevent cross-contamination

2. Register ClientConfig as orphaned type in metadata schema

Since ClientConfig is needed in the metadata schema but not directly returned by a resolver, it's explicitly declared via buildSchemaOptions.orphanedTypes.

3. Regenerate frontend types and fix imports

  • generated/graphql.ts shrank by ~2,700 lines (types moved to where they belong)
  • generated-metadata/graphql.ts gained types like ClientConfig that were previously missing
  • ~500 frontend files updated to import from the correct generated file

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Feb 11, 2026

Greptile Overview

Greptile Summary

This PR extends the existing NestJS GraphQL patch to significantly reduce schema type leakage between the 'core' and 'metadata' GraphQL schemas. The previous implementation only filtered resolvers by scope, but types could still leak across schemas. This update introduces a comprehensive type reachability analysis using breadth-first search (BFS) to compute which types are actually reachable from each schema's resolvers.

Key improvements:

  • Added computeReachableTypes() method that performs BFS traversal starting from resolver return types and arguments, following references through object properties, interfaces, unions, and input types
  • Enhanced storage clearing to include all type definition maps (interfaces, enums, unions, object types, input types) and orphaned reference registry
  • Modified type generation methods to filter metadata based on reachability before creating definitions
  • Properly handles edge cases like interface implementations and union members

Technical details:

  • The algorithm seeds with return types and arguments from scoped resolvers plus orphaned types
  • Traverses through object types, input types, interfaces, and argument metadata
  • Includes interface implementations and all union members when any member is reachable
  • Uses try-catch blocks to handle potentially failing typeFn() calls gracefully
  • Clears both TypeDefinitionsStorage and OrphanedReferenceRegistry to prevent cross-contamination

This ensures that when resolverSchemaScope is set to 'core' or 'metadata', only types actually reachable from that scope's resolvers are included in the generated schema.

Confidence Score: 4/5

  • This PR is safe to merge with moderate risk - the changes are well-structured but modify critical schema generation logic in a monkey-patched dependency.
  • The implementation is technically sound with proper BFS traversal, edge case handling, and comprehensive type filtering. However, the score is 4 rather than 5 because: (1) this patches a third-party library which carries inherent maintenance risks, (2) the schema generation logic is complex and central to GraphQL functionality, and (3) thorough integration testing is needed to verify no types are incorrectly excluded or included across both core and metadata schemas.
  • Check that the patch correctly identifies all reachable types in both core and metadata schemas through comprehensive integration testing, particularly for edge cases involving interfaces, unions, and nested type references.

Important Files Changed

Filename Overview
packages/twenty-server/patches/@nestjs+graphql+12.1.1.patch Significantly enhanced the NestJS GraphQL patch to prevent schema type leakage between core and metadata schemas by implementing a comprehensive type reachability analysis algorithm with proper storage clearing and filtering mechanisms.
yarn.lock Updated checksum hash for the patched @nestjs/graphql package to reflect the expanded patch file changes.

Sequence Diagram

sequenceDiagram
    participant Schema as GraphQLSchemaFactory
    participant Generator as TypeDefinitionsGenerator
    participant Storage as TypeDefinitionsStorage
    participant Registry as OrphanedReferenceRegistry
    participant TMS as TypeMetadataStorage

    Schema->>Generator: clearTypeDefinitionStorage()
    Generator->>Storage: clear()
    Storage->>Storage: Reset all Maps & Links
    
    Schema->>Registry: clear()
    Registry->>Registry: Clear registry
    
    Schema->>Schema: computeReachableTypes(resolvers, orphanedTypes)
    Schema->>TMS: getQueriesMetadata()
    Schema->>TMS: getMutationsMetadata()
    Schema->>TMS: getSubscriptionsMetadata()
    Schema->>Schema: Filter by resolvers scope
    Schema->>Schema: Seed queue with return types & args
    Schema->>Schema: BFS traversal
    loop Process Queue
        Schema->>TMS: Get metadata for type
        Schema->>Schema: Enqueue property types
        Schema->>Schema: Enqueue interfaces
    end
    Schema->>TMS: getObjectTypesMetadata()
    Schema->>Schema: Include interface implementations
    Schema->>TMS: getUnionsMetadata()
    Schema->>Schema: Include all union members
    
    Schema->>Generator: generate(options, reachableTypes)
    Generator->>TMS: Filter metadata by reachableTypes
    Generator->>Storage: Add filtered type definitions
Loading

Copy link
Copy Markdown
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 2 files

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them.


<file name="packages/twenty-server/patches/@nestjs+graphql+12.1.1.patch">

<violation number="1" location="packages/twenty-server/patches/@nestjs+graphql+12.1.1.patch:173">
P2: Enum types are not filtered by `reachableTypes`, unlike all other type kinds (objects, inputs, interfaces, unions). This means enum types will still leak across GraphQL schemas, undermining the goal of this patch. `generateEnumDefs` should accept `reachableTypes` and filter accordingly, and `computeReachableTypes` should track reachable enums (e.g., enums referenced by field types).</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

- this.generateUnionDefs();
+ generate(options, reachableTypes) {
+ this.generateUnionDefs(reachableTypes);
this.generateEnumDefs();
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: Enum types are not filtered by reachableTypes, unlike all other type kinds (objects, inputs, interfaces, unions). This means enum types will still leak across GraphQL schemas, undermining the goal of this patch. generateEnumDefs should accept reachableTypes and filter accordingly, and computeReachableTypes should track reachable enums (e.g., enums referenced by field types).

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/twenty-server/patches/@nestjs+graphql+12.1.1.patch, line 173:

<comment>Enum types are not filtered by `reachableTypes`, unlike all other type kinds (objects, inputs, interfaces, unions). This means enum types will still leak across GraphQL schemas, undermining the goal of this patch. `generateEnumDefs` should accept `reachableTypes` and filter accordingly, and `computeReachableTypes` should track reachable enums (e.g., enums referenced by field types).</comment>

<file context>
@@ -14,53 +14,230 @@ index 1234567..abcdefg 100644
+-        this.generateUnionDefs();
++    generate(options, reachableTypes) {
++        this.generateUnionDefs(reachableTypes);
+         this.generateEnumDefs();
+-        this.generateInterfaceDefs(options);
+-        this.generateObjectTypeDefs(options);
</file context>
Fix with Cubic

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 511 files

Note: This PR contains a large number of files. cubic only reviews up to 75 files per PR, so some files may not have been reviewed.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Feb 11, 2026

🚀 Preview Environment Ready!

Your preview environment is available at: http://bore.pub:21733

This environment will automatically shut down when the PR is closed or after 5 hours.

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 1 file (changes from recent commits).

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them.


<file name=".yarn/patches/@nestjs-graphql-npm-12.1.1-96ceb55a68.patch">

<violation number="1" location=".yarn/patches/@nestjs-graphql-npm-12.1.1-96ceb55a68.patch:200">
P2: Enum type definitions are not filtered by `reachableTypes`, unlike all other type generators (input, object, interface, union). This means enum types will leak across schemas. `generateEnumDefs` should accept `reachableTypes` and filter accordingly, and `computeReachableTypes` should track reachable enum references during the BFS traversal.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Feb 11, 2026

📊 API Changes Report

GraphQL Schema Changes

GraphQL Schema Changes

[log]
Detected the following changes (286) between schemas:

[log] ✖ Type AISystemPromptPreview was removed
[log] ✖ Type AISystemPromptSection was removed
[log] ✖ Type AdminPanelHealthServiceData was removed
[log] ✖ Type AdminPanelHealthServiceStatus was removed
[log] ✖ Type AdminPanelWorkerQueueHealth was removed
[log] ✖ Type Agent was removed
[log] ✖ Type AgentChatThread was removed
[log] ✖ Type AgentMessage was removed
[log] ✖ Type AgentMessagePart was removed
[log] ✖ Type AgentTurn was removed
[log] ✖ Type AgentTurnEvaluation was removed
[log] ✖ Type AggregateChartConfiguration was removed
[log] ✖ Type AggregateOperations was removed
[log] ✖ Type Analytics was removed
[log] ✖ Type ApiConfig was removed
[log] ✖ Type ApiKey was removed
[log] ✖ Type ApiKeyForRole was removed
[log] ✖ Type ApiKeyToken was removed
[log] ✖ Type AppToken was removed
[log] ✖ Type AppTokenEdge was removed
[log] ✖ Type Application was removed
[log] ✖ Type ApplicationVariable was removed
[log] ✖ Type ApprovedAccessDomain was removed
[log] ✖ Type AuthBypassProviders was removed
[log] ✖ Type AuthProviders was removed
[log] ✖ Type AuthToken was removed
[log] ✖ Type AuthTokenPair was removed
[log] ✖ Type AuthTokens was removed
[log] ✖ Type AuthorizeAppOutput was removed
[log] ✖ Type AutocompleteResult was removed
[log] ✖ Type AvailableWorkspace was removed
[log] ✖ Type AvailableWorkspaces was removed
[log] ✖ Type AvailableWorkspacesAndAccessTokensOutput was removed
[log] ✖ Type AxisNameDisplay was removed
[log] ✖ Type BarChartConfiguration was removed
[log] ✖ Type BarChartDataOutput was removed
[log] ✖ Type BarChartGroupMode was removed
[log] ✖ Type BarChartLayout was removed
[log] ✖ Type BarChartSeries was removed
[log] ✖ Type Billing was removed
[log] ✖ Type BillingEndTrialPeriodOutput was removed
[log] ✖ Type BillingEntitlement was removed
[log] ✖ Type BillingEntitlementKey was removed
[log] ✖ Type BillingLicensedProduct was removed
[log] ✖ Type BillingMeteredProduct was removed
[log] ✖ Type BillingMeteredProductUsageOutput was removed
[log] ✖ Type BillingPlanKey was removed
[log] ✖ Type BillingPlanOutput was removed
[log] ✖ Type BillingPriceLicensed was removed
[log] ✖ Type BillingPriceMetered was removed
[log] ✖ Type BillingPriceTier was removed
[log] ✖ Type BillingProduct was removed
[log] ✖ Type BillingProductDTO was removed
[log] ✖ Type BillingProductKey was removed
[log] ✖ Type BillingProductMetadata was removed
[log] ✖ Type BillingSessionOutput was removed
[log] ✖ Type BillingSubscription was removed
[log] ✖ Type BillingSubscriptionItemDTO was removed
[log] ✖ Type BillingSubscriptionSchedulePhase was removed
[log] ✖ Type BillingSubscriptionSchedulePhaseItem was removed
[log] ✖ Type BillingTrialPeriod was removed
[log] ✖ Type BillingUpdateOutput was removed
[log] ✖ Type BillingUsageType was removed
[log] ✖ Type BooleanFieldComparison was removed
[log] ✖ Type CalendarConfiguration was removed
[log] ✖ Type Captcha was removed
[log] ✖ Type CaptchaDriverType was removed
[log] ✖ Type ChannelSyncSuccess was removed
[log] ✖ Type CheckUserExistOutput was removed
[log] ✖ Type ClientAIModelConfig was removed
[log] ✖ Type CommandMenuItem was removed
[log] ✖ Type CommandMenuItemAvailabilityType was removed
[log] ✖ Type ConfigSource was removed
[log] ✖ Type ConfigVariable was removed
[log] ✖ Type ConfigVariableType was removed
[log] ✖ Type ConfigVariablesGroup was removed
[log] ✖ Type ConfigVariablesGroupData was removed
[log] ✖ Type ConfigVariablesOutput was removed
[log] ✖ Type ConnectedImapSmtpCaldavAccount was removed
[log] ✖ Type ConnectionParametersOutput was removed
[log] ✖ Type CoreView was removed
[log] ✖ Type CoreViewField was removed
[log] ✖ Type CoreViewFieldGroup was removed
[log] ✖ Type CoreViewFilter was removed
[log] ✖ Type CoreViewFilterGroup was removed
[log] ✖ Type CoreViewGroup was removed
[log] ✖ Type CoreViewSort was removed
[log] ✖ Type CursorPaging was removed
[log] ✖ Type DatabaseEventAction was removed
[log] ✖ Type DeleteJobsResponse was removed
[log] ✖ Type DeleteSsoOutput was removed
[log] ✖ Type DeleteTwoFactorAuthenticationMethodOutput was removed
[log] ✖ Type DeletedWorkspaceMember was removed
[log] ✖ Type DomainRecord was removed
[log] ✖ Type DomainValidRecords was removed
[log] ✖ Type DuplicatedDashboard was removed
[log] ✖ Type EditSsoOutput was removed
[log] ✖ Type EmailPasswordResetLinkOutput was removed
[log] ✖ Type EmailingDomain was removed
[log] ✖ Type EmailingDomainDriver was removed
[log] ✖ Type EmailingDomainStatus was removed
[log] ✖ Type EmailsConfiguration was removed
[log] ✖ Type EventLogPageInfo was removed
[log] ✖ Type EventLogQueryResult was removed
[log] ✖ Type EventLogRecord was removed
[log] ✖ Type EventSubscription was removed
[log] ✖ Type EventWithQueryIds was removed
[log] ✖ Type FeatureFlag was removed
[log] ✖ Type FeatureFlagDTO was removed
[log] ✖ Type FeatureFlagKey was removed
[log] ✖ Type Field was removed
[log] ✖ Type FieldConfiguration was removed
[log] ✖ Type FieldConnection was removed
[log] ✖ Type FieldEdge was removed
[log] ✖ Type FieldFilter was removed
[log] ✖ Type FieldMetadataType was removed
[log] ✖ Type FieldPermission was removed
[log] ✖ Type FieldRichTextConfiguration was removed
[log] ✖ Type FieldsConfiguration was removed
[log] ✖ Type File was removed
[log] ✖ Type FilesConfiguration was removed
[log] ✖ Type FindAvailableSSOIDPOutput was removed
[log] ✖ Type FrontComponent was removed
[log] ✖ Type FrontComponentConfiguration was removed
[log] ✖ Field FullName.firstName changed type from String! to String
[log] ✖ Field FullName.lastName changed type from String! to String
[log] ✖ Type GaugeChartConfiguration was removed
[log] ✖ Type GetAuthorizationUrlForSSOOutput was removed
[log] ✖ Type GraphOrderBy was removed
[log] ✖ Type GridPosition was removed
[log] ✖ Type HealthIndicatorId was removed
[log] ✖ Type IdentityProviderType was removed
[log] ✖ Type IframeConfiguration was removed
[log] ✖ Type ImapSmtpCaldavConnectionParameters was removed
[log] ✖ Type ImapSmtpCaldavConnectionSuccess was removed
[log] ✖ Type ImpersonateOutput was removed
[log] ✖ Type Index was removed
[log] ✖ Type IndexConnection was removed
[log] ✖ Type IndexEdge was removed
[log] ✖ Type IndexField was removed
[log] ✖ Type IndexFieldEdge was removed
[log] ✖ Type IndexFieldFilter was removed
[log] ✖ Type IndexFilter was removed
[log] ✖ Type IndexIndexFieldMetadatasConnection was removed
[log] ✖ Type IndexObjectMetadataConnection was removed
[log] ✖ Type IndexType was removed
[log] ✖ Type InitiateTwoFactorAuthenticationProvisioningOutput was removed
[log] ✖ Type InvalidatePasswordOutput was removed
[log] ✖ Type JSONObject was removed
[log] ✖ Type JobOperationResult was removed
[log] ✖ Type JobState was removed
[log] ✖ Type LineChartConfiguration was removed
[log] ✖ Type LineChartDataOutput was removed
[log] ✖ Type LineChartDataPoint was removed
[log] ✖ Type LineChartSeries was removed
[log] ✖ Type Location was removed
[log] ✖ Type LogicFunction was removed
[log] ✖ Type LogicFunctionExecutionResult was removed
[log] ✖ Type LogicFunctionExecutionStatus was removed
[log] ✖ Type LogicFunctionLogs was removed
[log] ✖ Type LoginTokenOutput was removed
[log] ✖ Type MarketplaceApp was removed
[log] ✖ Type ModelProvider was removed
[log] ✖ Type NativeModelCapabilities was removed
[log] ✖ Type NavigationMenuItem was removed
[log] ✖ Type NotesConfiguration was removed
[log] ✖ Type Object was removed
[log] ✖ Type ObjectConnection was removed
[log] ✖ Type ObjectEdge was removed
[log] ✖ Type ObjectFieldsConnection was removed
[log] ✖ Type ObjectFilter was removed
[log] ✖ Type ObjectIndexMetadatasConnection was removed
[log] ✖ Type ObjectPermission was removed
[log] ✖ Type ObjectRecordEvent was removed
[log] ✖ Type ObjectRecordEventProperties was removed
[log] ✖ Type ObjectRecordGroupByDateGranularity was removed
[log] ✖ Type ObjectStandardOverrides was removed
[log] ✖ Type OnDbEvent was removed
[log] ✖ Type OnboardingStatus was removed
[log] ✖ Type OnboardingStepSuccess was removed
[log] ✖ Type PageLayout was removed
[log] ✖ Type PageLayoutTab was removed
[log] ✖ Type PageLayoutTabLayoutMode was removed
[log] ✖ Type PageLayoutType was removed
[log] ✖ Type PageLayoutWidget was removed
[log] ✖ Type PageLayoutWidgetCanvasPosition was removed
[log] ✖ Type PageLayoutWidgetGridPosition was removed
[log] ✖ Type PageLayoutWidgetPosition was removed
[log] ✖ Type PageLayoutWidgetVerticalListPosition was removed
[log] ✖ Type PermissionFlag was removed
[log] ✖ Type PermissionFlagType was removed
[log] ✖ Type PieChartConfiguration was removed
[log] ✖ Type PieChartDataItem was removed
[log] ✖ Type PieChartDataOutput was removed
[log] ✖ Type PlaceDetailsResult was removed
[log] ✖ Type PostgresCredentials was removed
[log] ✖ Type PublicDomain was removed
[log] ✖ Type PublicFeatureFlag was removed
[log] ✖ Type PublicFeatureFlagMetadata was removed
[log] ✖ Type PublicWorkspaceDataOutput was removed
[log] ✖ Type QueueJob was removed
[log] ✖ Type QueueJobsResponse was removed
[log] ✖ Type QueueMetricsData was removed
[log] ✖ Type QueueMetricsDataPoint was removed
[log] ✖ Type QueueMetricsSeries was removed
[log] ✖ Type QueueMetricsTimeRange was removed
[log] ✖ Type QueueRetentionConfig was removed
[log] ✖ Type RatioAggregateConfig was removed
[log] ✖ Type RecordIdentifier was removed
[log] ✖ Type Relation was removed
[log] ✖ Type RelationType was removed
[log] ✖ Type ResendEmailVerificationTokenOutput was removed
[log] ✖ Type RetryJobsResponse was removed
[log] ✖ Type RichTextV2Body was removed
[log] ✖ Type Role was removed
[log] ✖ Type RowLevelPermissionPredicate was removed
[log] ✖ Type RowLevelPermissionPredicateGroup was removed
[log] ✖ Type RowLevelPermissionPredicateGroupLogicalOperator was removed
[log] ✖ Type RowLevelPermissionPredicateOperand was removed
[log] ✖ Type SSOConnection was removed
[log] ✖ Type SSOIdentityProvider was removed
[log] ✖ Type SSOIdentityProviderStatus was removed
[log] ✖ Type SendInvitationsOutput was removed
[log] ✖ Type Sentry was removed
[log] ✖ Type SetupSsoOutput was removed
[log] ✖ Type SignUpOutput was removed
[log] ✖ Type SignedFile was removed
[log] ✖ Type Skill was removed
[log] ✖ Type StandaloneRichTextConfiguration was removed
[log] ✖ Type StandardOverrides was removed
[log] ✖ Type SubscriptionInterval was removed
[log] ✖ Type SubscriptionStatus was removed
[log] ✖ Type Support was removed
[log] ✖ Type SupportDriver was removed
[log] ✖ Type SystemHealth was removed
[log] ✖ Type SystemHealthService was removed
[log] ✖ Type TasksConfiguration was removed
[log] ✖ Type TimelineConfiguration was removed
[log] ✖ Type ToolIndexEntry was removed
[log] ✖ Type TransientTokenOutput was removed
[log] ✖ Type TwoFactorAuthenticationMethodDTO was removed
[log] ✖ Type UUIDFilterComparison was removed
[log] ✖ Type UpsertRowLevelPermissionPredicatesResult was removed
[log] ✖ Type User was removed
[log] ✖ Type UserEdge was removed
[log] ✖ Type UserInfo was removed
[log] ✖ Type UserLookup was removed
[log] ✖ Type UserWorkspace was removed
[log] ✖ Type ValidatePasswordResetTokenOutput was removed
[log] ✖ Type VerificationRecord was removed
[log] ✖ Type VerifyEmailAndGetLoginTokenOutput was removed
[log] ✖ Type VerifyTwoFactorAuthenticationMethodOutput was removed
[log] ✖ Type VersionInfo was removed
[log] ✖ Type ViewCalendarLayout was removed
[log] ✖ Type ViewConfiguration was removed
[log] ✖ Type ViewFilterGroupLogicalOperator was removed
[log] ✖ Type ViewFilterOperand was removed
[log] ✖ Type ViewKey was removed
[log] ✖ Type ViewOpenRecordIn was removed
[log] ✖ Type ViewSortDirection was removed
[log] ✖ Type ViewType was removed
[log] ✖ Type ViewVisibility was removed
[log] ✖ Type Webhook was removed
[log] ✖ Type WidgetConfiguration was removed
[log] ✖ Type WidgetConfigurationType was removed
[log] ✖ Type WidgetType was removed
[log] ✖ Type WorkerQueueMetrics was removed
[log] ✖ Type WorkflowConfiguration was removed
[log] ✖ Type WorkflowRunConfiguration was removed
[log] ✖ Type WorkflowVersionConfiguration was removed
[log] ✖ Type Workspace was removed
[log] ✖ Type WorkspaceActivationStatus was removed
[log] ✖ Type WorkspaceEdge was removed
[log] ✖ Type WorkspaceInfo was removed
[log] ✖ Type WorkspaceInvitation was removed
[log] ✖ Type WorkspaceInviteHashValidOutput was removed
[log] ✖ Field roles was removed from object type WorkspaceMember
[log] ✖ Field WorkspaceMember.userEmail changed type from String! to String
[log] ✖ Field userWorkspaceId was removed from object type WorkspaceMember
[log] ✖ Type WorkspaceNameAndId was removed
[log] ✖ Type WorkspaceUrls was removed
[log] ✖ Type WorkspaceUrlsAndId was removed
[log] ✔ Description was removed from field PageInfo.endCursor
[log] ✔ Description was removed from field PageInfo.hasNextPage
[log] ✔ Description was removed from field PageInfo.hasPreviousPage
[log] ✔ Description was removed from field PageInfo.startCursor
[error] Detected 282 breaking changes
⚠️ Breaking changes or errors detected in GraphQL schema

[log] 
Detected the following changes (286) between schemas:

[log] ✖  Type AISystemPromptPreview was removed
[log] ✖  Type AISystemPromptSection was removed
[log] ✖  Type AdminPanelHealthServiceData was removed
[log] ✖  Type AdminPanelHealthServiceStatus was removed
[log] ✖  Type AdminPanelWorkerQueueHealth was removed
[log] ✖  Type Agent was removed
[log] ✖  Type AgentChatThread was removed
[log] ✖  Type AgentMessage was removed
[log] ✖  Type AgentMessagePart was removed
[log] ✖  Type AgentTurn was removed
[log] ✖  Type AgentTurnEvaluation was removed
[log] ✖  Type AggregateChartConfiguration was removed
[log] ✖  Type AggregateOperations was removed
[log] ✖  Type Analytics was removed
[log] ✖  Type ApiConfig was removed
[log] ✖  Type ApiKey was removed
[log] ✖  Type ApiKeyForRole was removed
[log] ✖  Type ApiKeyToken was removed
[log] ✖  Type AppToken was removed
[log] ✖  Type AppTokenEdge was removed
[log] ✖  Type Application was removed
[log] ✖  Type ApplicationVariable was removed
[log] ✖  Type ApprovedAccessDomain was removed
[log] ✖  Type AuthBypassProviders was removed
[log] ✖  Type AuthProviders was removed
[log] ✖  Type AuthToken was removed
[log] ✖  Type AuthTokenPair was removed
[log] ✖  Type AuthTokens was removed
[log] ✖  Type AuthorizeAppOutput was removed
[log] ✖  Type AutocompleteResult was removed
[log] ✖  Type AvailableWorkspace was removed
[log] ✖  Type AvailableWorkspaces was removed
[log] ✖  Type AvailableWorkspacesAndAccessTokensOutput was removed
[log] ✖  Type AxisNameDisplay was removed
[log] ✖  Type BarChartConfiguration was removed
[log] ✖  Type BarChartDataOutput was removed
[log] ✖  Type BarChartGroupMode was removed
[log] ✖  Type BarChartLayout was removed
[log] ✖  Type BarChartSeries was removed
[log] ✖  Type Billing was removed
[log] ✖  Type BillingEndTrialPeriodOutput was removed
[log] ✖  Type BillingEntitlement was removed
[log] ✖  Type BillingEntitlementKey was removed
[log] ✖  Type BillingLicensedProduct was removed
[log] ✖  Type BillingMeteredProduct was removed
[log] ✖  Type BillingMeteredProductUsageOutput was removed
[log] ✖  Type BillingPlanKey was removed
[log] ✖  Type BillingPlanOutput was removed
[log] ✖  Type BillingPriceLicensed was removed
[log] ✖  Type BillingPriceMetered was removed
[log] ✖  Type BillingPriceTier was removed
[log] ✖  Type BillingProduct was removed
[log] ✖  Type BillingProductDTO was removed
[log] ✖  Type BillingProductKey was removed
[log] ✖  Type BillingProductMetadata was removed
[log] ✖  Type BillingSessionOutput was removed
[log] ✖  Type BillingSubscription was removed
[log] ✖  Type BillingSubscriptionItemDTO was removed
[log] ✖  Type BillingSubscriptionSchedulePhase was removed
[log] ✖  Type BillingSubscriptionSchedulePhaseItem was removed
[log] ✖  Type BillingTrialPeriod was removed
[log] ✖  Type BillingUpdateOutput was removed
[log] ✖  Type BillingUsageType was removed
[log] ✖  Type BooleanFieldComparison was removed
[log] ✖  Type CalendarConfiguration was removed
[log] ✖  Type Captcha was removed
[log] ✖  Type CaptchaDriverType was removed
[log] ✖  Type ChannelSyncSuccess was removed
[log] ✖  Type CheckUserExistOutput was removed
[log] ✖  Type ClientAIModelConfig was removed
[log] ✖  Type CommandMenuItem was removed
[log] ✖  Type CommandMenuItemAvailabilityType was removed
[log] ✖  Type ConfigSource was removed
[log] ✖  Type ConfigVariable was removed
[log] ✖  Type ConfigVariableType was removed
[log] ✖  Type ConfigVariablesGroup was removed
[log] ✖  Type ConfigVariablesGroupData was removed
[log] ✖  Type ConfigVariablesOutput was removed
[log] ✖  Type ConnectedImapSmtpCaldavAccount was removed
[log] ✖  Type ConnectionParametersOutput was removed
[log] ✖  Type CoreView was removed
[log] ✖  Type CoreViewField was removed
[log] ✖  Type CoreViewFieldGroup was removed
[log] ✖  Type CoreViewFilter was removed
[log] ✖  Type CoreViewFilterGroup was removed
[log] ✖  Type CoreViewGroup was removed
[log] ✖  Type CoreViewSort was removed
[log] ✖  Type CursorPaging was removed
[log] ✖  Type DatabaseEventAction was removed
[log] ✖  Type DeleteJobsResponse was removed
[log] ✖  Type DeleteSsoOutput was removed
[log] ✖  Type DeleteTwoFactorAuthenticationMethodOutput was removed
[log] ✖  Type DeletedWorkspaceMember was removed
[log] ✖  Type DomainRecord was removed
[log] ✖  Type DomainValidRecords was removed
[log] ✖  Type DuplicatedDashboard was removed
[log] ✖  Type EditSsoOutput was removed
[log] ✖  Type EmailPasswordResetLinkOutput was removed
[log] ✖  Type EmailingDomain was removed
[log] ✖  Type EmailingDomainDriver was removed
[log] ✖  Type EmailingDomainStatus was removed
[log] ✖  Type EmailsConfiguration was removed
[log] ✖  Type EventLogPageInfo was removed
[log] ✖  Type EventLogQueryResult was removed
[log] ✖  Type EventLogRecord was removed
[log] ✖  Type EventSubscription was removed
[log] ✖  Type EventWithQueryIds was removed
[log] ✖  Type FeatureFlag was removed
[log] ✖  Type FeatureFlagDTO was removed
[log] ✖  Type FeatureFlagKey was removed
[log] ✖  Type Field was removed
[log] ✖  Type FieldConfiguration was removed
[log] ✖  Type FieldConnection was removed
[log] ✖  Type FieldEdge was removed
[log] ✖  Type FieldFilter was removed
[log] ✖  Type FieldMetadataType was removed
[log] ✖  Type FieldPermission was removed
[log] ✖  Type FieldRichTextConfiguration was removed
[log] ✖  Type FieldsConfiguration was removed
[log] ✖  Type File was removed
[log] ✖  Type FilesConfiguration was removed
[log] ✖  Type FindAvailableSSOIDPOutput was removed
[log] ✖  Type FrontComponent was removed
[log] ✖  Type FrontComponentConfiguration was removed
[log] ✖  Field FullName.firstName changed type from String! to String
[log] ✖  Field FullName.lastName changed type from String! to String
[log] ✖  Type GaugeChartConfiguration was removed
[log] ✖  Type GetAuthorizationUrlForSSOOutput was removed
[log] ✖  Type GraphOrderBy was removed
[log] ✖  Type GridPosition was removed
[log] ✖  Type HealthIndicatorId was removed
[log] ✖  Type IdentityProviderType was removed
[log] ✖  Type IframeConfiguration was removed
[log] ✖  Type ImapSmtpCaldavConnectionParameters was removed
[log] ✖  Type ImapSmtpCaldavConnectionSuccess was removed
[log] ✖  Type ImpersonateOutput was removed
[log] ✖  Type Index was removed
[log] ✖  Type IndexConnection was removed
[log] ✖  Type IndexEdge was removed
[log] ✖  Type IndexField was removed
[log] ✖  Type IndexFieldEdge was removed
[log] ✖  Type IndexFieldFilter was removed
[log] ✖  Type IndexFilter was removed
[log] ✖  Type IndexIndexFieldMetadatasConnection was removed
[log] ✖  Type IndexObjectMetadataConnection was removed
[log] ✖  Type IndexType was removed
[log] ✖  Type InitiateTwoFactorAuthenticationProvisioningOutput was removed
[log] ✖  Type InvalidatePasswordOutput was removed
[log] ✖  Type JSONObject was removed
[log] ✖  Type JobOperationResult was removed
[log] ✖  Type JobState was removed
[log] ✖  Type LineChartConfiguration was removed
[log] ✖  Type LineChartDataOutput was removed
[log] ✖  Type LineChartDataPoint was removed
[log] ✖  Type LineChartSeries was removed
[log] ✖  Type Location was removed
[log] ✖  Type LogicFunction was removed
[log] ✖  Type LogicFunctionExecutionResult was removed
[log] ✖  Type LogicFunctionExecutionStatus was removed
[log] ✖  Type LogicFunctionLogs was removed
[log] ✖  Type LoginTokenOutput was removed
[log] ✖  Type MarketplaceApp was removed
[log] ✖  Type ModelProvider was removed
[log] ✖  Type NativeModelCapabilities was removed
[log] ✖  Type NavigationMenuItem was removed
[log] ✖  Type NotesConfiguration was removed
[log] ✖  Type Object was removed
[log] ✖  Type ObjectConnection was removed
[log] ✖  Type ObjectEdge was removed
[log] ✖  Type ObjectFieldsConnection was removed
[log] ✖  Type ObjectFilter was removed
[log] ✖  Type ObjectIndexMetadatasConnection was removed
[log] ✖  Type ObjectPermission was removed
[log] ✖  Type ObjectRecordEvent was removed
[log] ✖  Type ObjectRecordEventProperties was removed
[log] ✖  Type ObjectRecordGroupByDateGranularity was removed
[log] ✖  Type ObjectStandardOverrides was removed
[log] ✖  Type OnDbEvent was removed
[log] ✖  Type OnboardingStatus was removed
[log] ✖  Type OnboardingStepSuccess was removed
[log] ✖  Type PageLayout was removed
[log] ✖  Type PageLayoutTab was removed
[log] ✖  Type PageLayoutTabLayoutMode was removed
[log] ✖  Type PageLayoutType was removed
[log] ✖  Type PageLayoutWidget was removed
[log] ✖  Type PageLayoutWidgetCanvasPosition was removed
[log] ✖  Type PageLayoutWidgetGridPosition was removed
[log] ✖  Type PageLayoutWidgetPosition was removed
[log] ✖  Type PageLayoutWidgetVerticalListPosition was removed
[log] ✖  Type PermissionFlag was removed
[log] ✖  Type PermissionFlagType was removed
[log] ✖  Type PieChartConfiguration was removed
[log] ✖  Type PieChartDataItem was removed
[log] ✖  Type PieChartDataOutput was removed
[log] ✖  Type PlaceDetailsResult was removed
[log] ✖  Type PostgresCredentials was removed
[log] ✖  Type PublicDomain was removed
[log] ✖  Type PublicFeatureFlag was removed
[log] ✖  Type PublicFeatureFlagMetadata was removed
[log] ✖  Type PublicWorkspaceDataOutput was removed
[log] ✖  Type QueueJob was removed
[log] ✖  Type QueueJobsResponse was removed
[log] ✖  Type QueueMetricsData was removed
[log] ✖  Type QueueMetricsDataPoint was removed
[log] ✖  Type QueueMetricsSeries was removed
[log] ✖  Type QueueMetricsTimeRange was removed
[log] ✖  Type QueueRetentionConfig was removed
[log] ✖  Type RatioAggregateConfig was removed
[log] ✖  Type RecordIdentifier was removed
[log] ✖  Type Relation was removed
[log] ✖  Type RelationType was removed
[log] ✖  Type ResendEmailVerificationTokenOutput was removed
[log] ✖  Type RetryJobsResponse was removed
[log] ✖  Type RichTextV2Body was removed
[log] ✖  Type Role was removed
[log] ✖  Type RowLevelPermissionPredicate was removed
[log] ✖  Type RowLevelPermissionPredicateGroup was removed
[log] ✖  Type RowLevelPermissionPredicateGroupLogicalOperator was removed
[log] ✖  Type RowLevelPermissionPredicateOperand was removed
[log] ✖  Type SSOConnection was removed
[log] ✖  Type SSOIdentityProvider was removed
[log] ✖  Type SSOIdentityProviderStatus was removed
[log] ✖  Type SendInvitationsOutput was removed
[log] ✖  Type Sentry was removed
[log] ✖  Type SetupSsoOutput was removed
[log] ✖  Type SignUpOutput was removed
[log] ✖  Type SignedFile was removed
[log] ✖  Type Skill was removed
[log] ✖  Type StandaloneRichTextConfiguration was removed
[log] ✖  Type StandardOverrides was removed
[log] ✖  Type SubscriptionInterval was removed
[log] ✖  Type SubscriptionStatus was removed
[log] ✖  Type Support was removed
[log] ✖  Type SupportDriver was removed
[log] ✖  Type SystemHealth was removed
[log] ✖  Type SystemHealthService was removed
[log] ✖  Type TasksConfiguration was removed
[log] ✖  Type TimelineConfiguration was removed
[log] ✖  Type ToolIndexEntry was removed
[log] ✖  Type TransientTokenOutput was removed
[log] ✖  Type TwoFactorAuthenticationMethodDTO was removed
[log] ✖  Type UUIDFilterComparison was removed
[log] ✖  Type UpsertRowLevelPermissionPredicatesResult was removed
[log] ✖  Type User was removed
[log] ✖  Type UserEdge was removed
[log] ✖  Type UserInfo was removed
[log] ✖  Type UserLookup was removed
[log] ✖  Type UserWorkspace was removed
[log] ✖  Type ValidatePasswordResetTokenOutput was removed
[log] ✖  Type VerificationRecord was removed
[log] ✖  Type VerifyEmailAndGetLoginTokenOutput was removed
[log] ✖  Type VerifyTwoFactorAuthenticationMethodOutput was removed
[log] ✖  Type VersionInfo was removed
[log] ✖  Type ViewCalendarLayout was removed
[log] ✖  Type ViewConfiguration was removed
[log] ✖  Type ViewFilterGroupLogicalOperator was removed
[log] ✖  Type ViewFilterOperand was removed
[log] ✖  Type ViewKey was removed
[log] ✖  Type ViewOpenRecordIn was removed
[log] ✖  Type ViewSortDirection was removed
[log] ✖  Type ViewType was removed
[log] ✖  Type ViewVisibility was removed
[log] ✖  Type Webhook was removed
[log] ✖  Type WidgetConfiguration was removed
[log] ✖  Type WidgetConfigurationType was removed
[log] ✖  Type WidgetType was removed
[log] ✖  Type WorkerQueueMetrics was removed
[log] ✖  Type WorkflowConfiguration was removed
[log] ✖  Type WorkflowRunConfiguration was removed
[log] ✖  Type WorkflowVersionConfiguration was removed
[log] ✖  Type Workspace was removed
[log] ✖  Type WorkspaceActivationStatus was removed
[log] ✖  Type WorkspaceEdge was removed
[log] ✖  Type WorkspaceInfo was removed
[log] ✖  Type WorkspaceInvitation was removed
[log] ✖  Type WorkspaceInviteHashValidOutput was removed
[log] ✖  Field roles was removed from object type WorkspaceMember
[log] ✖  Field WorkspaceMember.userEmail changed type from String! to String
[log] ✖  Field userWorkspaceId was removed from object type WorkspaceMember
[log] ✖  Type WorkspaceNameAndId was removed
[log] ✖  Type WorkspaceUrls was removed
[log] ✖  Type WorkspaceUrlsAndId was removed
[log] ✔  Description was removed from field PageInfo.endCursor
[log] ✔  Description was removed from field PageInfo.hasNextPage
[log] ✔  Description was removed from field PageInfo.hasPreviousPage
[log] ✔  Description was removed from field PageInfo.startCursor
[error] Detected 282 breaking changes
Error generating diff

GraphQL Metadata Schema Changes

GraphQL Metadata Schema Changes

[log]
Detected the following changes (16) between schemas:

[log] ✖ Type AppTokenEdge was removed
[log] ✖ Type CalendarChannelVisibility was removed
[log] ✖ Type LinkMetadata was removed
[log] ✖ Type LinksMetadata was removed
[log] ✖ Type MessageChannelVisibility was removed
[log] ✖ Type SearchRecord was removed
[log] ✖ Type SearchResultEdge was removed
[log] ✖ Type SearchResultPageInfo was removed
[log] ✖ Type TimelineCalendarEvent was removed
[log] ✖ Type TimelineCalendarEventParticipant was removed
[log] ✖ Type TimelineThread was removed
[log] ✖ Type TimelineThreadParticipant was removed
[log] ✖ Type UserEdge was removed
[log] ✖ Type WorkflowStepPosition was removed
[log] ✖ Type WorkspaceEdge was removed
[log] ✔ Type ClientConfig was added
[error] Detected 15 breaking changes
⚠️ Breaking changes or errors detected in GraphQL metadata schema

[log] 
Detected the following changes (16) between schemas:

[log] ✖  Type AppTokenEdge was removed
[log] ✖  Type CalendarChannelVisibility was removed
[log] ✖  Type LinkMetadata was removed
[log] ✖  Type LinksMetadata was removed
[log] ✖  Type MessageChannelVisibility was removed
[log] ✖  Type SearchRecord was removed
[log] ✖  Type SearchResultEdge was removed
[log] ✖  Type SearchResultPageInfo was removed
[log] ✖  Type TimelineCalendarEvent was removed
[log] ✖  Type TimelineCalendarEventParticipant was removed
[log] ✖  Type TimelineThread was removed
[log] ✖  Type TimelineThreadParticipant was removed
[log] ✖  Type UserEdge was removed
[log] ✖  Type WorkflowStepPosition was removed
[log] ✖  Type WorkspaceEdge was removed
[log] ✔  Type ClientConfig was added
[error] Detected 15 breaking changes
Error generating diff

⚠️ Please review these API changes carefully before merging.

⚠️ Breaking Change Protocol

Breaking changes detected but PR title does not contain "breaking" - CI will pass but action needed.

🔄 Options:

  1. If this IS a breaking change: Add "breaking" to your PR title and add BREAKING CHANGE: to your commit message
  2. If this is NOT a breaking change: The API diff tool may have false positives - please review carefully

For breaking changes, add to commit message:

feat: add new API endpoint

BREAKING CHANGE: removed deprecated field from User schema

Copy link
Copy Markdown
Member

@Weiko Weiko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@charlesBochet charlesBochet added this pull request to the merge queue Feb 12, 2026
@charlesBochet charlesBochet removed this pull request from the merge queue due to a manual request Feb 12, 2026
@charlesBochet charlesBochet merged commit b456f79 into main Feb 12, 2026
79 checks passed
@charlesBochet charlesBochet deleted the refactor-app-access-token branch February 12, 2026 09:58
@twenty-eng-sync
Copy link
Copy Markdown

Hey @charlesBochet! After you've done the QA of your Pull Request, you can mark it as done here. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants