[BREAKING_CHANGE] Deprecate remaining entities standardId (#17639)

# Introduction
Following https://github.com/twentyhq/twenty/pull/17632 and
https://github.com/twentyhq/twenty/pull/17572
This PR deprecates the agent, skill, field metadata and role
`standardId` in favor of the `universalIdentifier` usage

## Note
- Removed previous standard ids declaration modules
- Twenty-sdk now re-exports the `STANDARD_OBJECTS` universalIdentifier
hashmap constant
- deleted some sync-metadata deadcode too ( mainly types )
This commit is contained in:
Paul Rastoin
2026-02-03 09:06:24 +01:00
committed by GitHub
parent cfdcc0065c
commit d35d5c0463
118 changed files with 534 additions and 2279 deletions
@@ -8,9 +8,9 @@ import { type WorkspaceAuthContext } from 'src/engine/core-modules/auth/types/wo
import { buildApplicationAuthContext } from 'src/engine/core-modules/auth/utils/build-application-auth-context.util';
import { buildUserAuthContext } from 'src/engine/core-modules/auth/utils/build-user-auth-context.util';
import { UserWorkspaceService } from 'src/engine/core-modules/user-workspace/user-workspace.service';
import { ADMIN_ROLE } from 'src/engine/metadata-modules/role/constants/admin-role';
import { RoleService } from 'src/engine/metadata-modules/role/role.service';
import { UserRoleService } from 'src/engine/metadata-modules/user-role/user-role.service';
import { STANDARD_ROLE } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-role.constant';
import { type WorkflowRunWorkspaceEntity } from 'src/modules/workflow/common/standard-objects/workflow-run.workspace-entity';
import { type WorkflowExecutionContext } from 'src/modules/workflow/workflow-executor/types/workflow-execution-context.type';
import { WorkflowRunWorkspaceService as WorkflowRunService } from 'src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service';
@@ -103,7 +103,7 @@ export class WorkflowExecutionContextService {
if (!isDefined(roleId)) {
// Fallback: Look up admin role for existing workspaces without defaultRoleId
const adminRole = await this.roleService.getRoleByUniversalIdentifier({
universalIdentifier: ADMIN_ROLE.standardId,
universalIdentifier: STANDARD_ROLE.admin.universalIdentifier,
workspaceId,
});