Skip to content

The open alternative to Salesforce, designed for AI.

22 branches 3 (#13181)

martmull47386e92a3f8
diff --git a/packages/twenty-front/src/modules/command-menu/hooks/useWorkflowCommandMenu.ts b/packages/twenty-front/src/modules/command-menu/hooks/useWorkflowCommandMenu.ts
index 4e0997ddf51..a77ba8200cf 100644
--- a/packages/twenty-front/src/modules/command-menu/hooks/useWorkflowCommandMenu.ts
+++ b/packages/twenty-front/src/modules/command-menu/hooks/useWorkflowCommandMenu.ts
@@ -4,7 +4,6 @@ import { commandMenuWorkflowRunIdComponentState } from '@/command-menu/pages/wor
import { commandMenuWorkflowVersionIdComponentState } from '@/command-menu/pages/workflow/states/commandMenuWorkflowVersionIdComponentState';
import { CommandMenuPages } from '@/command-menu/types/CommandMenuPages';
import { useSetInitialWorkflowRunRightDrawerTab } from '@/workflow/workflow-diagram/hooks/useSetInitialWorkflowRunRightDrawerTab';
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
import { t } from '@lingui/core/macro';
import { useRecoilCallback } from 'recoil';
import {
@@ -13,6 +12,7 @@ import {
IconSettingsAutomation,
} from 'twenty-ui/display';
import { v4 } from 'uuid';
+import { WorkflowRunStepStatus } from '@/workflow/types/Workflow';
export const useWorkflowCommandMenu = () => {
const { navigateCommandMenu } = useNavigateCommandMenu();
@@ -142,7 +142,7 @@ export const useWorkflowCommandMenu = () => {
title: string;
icon: IconComponent;
workflowSelectedNode: string;
- stepExecutionStatus: WorkflowDiagramRunStatus;
+ stepExecutionStatus: WorkflowRunStepStatus;
}) => {
const pageId = v4();
diff --git a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/components/CommandMenuWorkflowRunViewStepContent.tsx b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/components/CommandMenuWorkflowRunViewStepContent.tsx
index 2820a8f769f..cf4a93862cb 100644
--- a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/components/CommandMenuWorkflowRunViewStepContent.tsx
+++ b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/components/CommandMenuWorkflowRunViewStepContent.tsx
@@ -20,11 +20,11 @@ import {
WorkflowRunTabId,
WorkflowRunTabIdType,
} from '@/workflow/workflow-steps/types/WorkflowRunTabId';
-import { getWorkflowRunStepExecutionStatus } from '@/workflow/workflow-steps/utils/getWorkflowRunStepExecutionStatus';
import styled from '@emotion/styled';
import { isNull } from '@sniptt/guards';
import { isDefined } from 'twenty-shared/utils';
import { IconLogin2, IconLogout, IconStepInto } from 'twenty-ui/display';
+import { getWorkflowRunStepExecutionStatus } from '@/workflow/workflow-steps/utils/getWorkflowRunStepExecutionStatus';
const StyledContainer = styled.div`
display: flex;
@@ -65,9 +65,10 @@ export const CommandMenuWorkflowRunViewStepContent = () => {
}
const stepExecutionStatus = getWorkflowRunStepExecutionStatus({
- workflowRunOutput: workflowRun.output,
+ workflowRunState: workflowRun.state,
stepId: workflowSelectedNode,
});
+
const stepDefinition = getStepDefinitionOrThrow({
stepId: workflowSelectedNode,
trigger: flow.trigger,
diff --git a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsInputTabDisabled.ts b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsInputTabDisabled.ts
index dd3d28b64c5..84e026699e7 100644
--- a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsInputTabDisabled.ts
+++ b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsInputTabDisabled.ts
@@ -1,15 +1,15 @@
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
import { TRIGGER_STEP_ID } from '@/workflow/workflow-trigger/constants/TriggerStepId';
+import { WorkflowRunStepStatus } from '@/workflow/types/Workflow';
export const getIsInputTabDisabled = ({
stepExecutionStatus,
workflowSelectedNode,
}: {
workflowSelectedNode: string;
- stepExecutionStatus: WorkflowDiagramRunStatus;
+ stepExecutionStatus: WorkflowRunStepStatus;
}) => {
return (
workflowSelectedNode === TRIGGER_STEP_ID ||
- stepExecutionStatus === 'not-executed'
+ stepExecutionStatus === 'NOT_STARTED'
);
};
diff --git a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsOutputTabDisabled.ts b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsOutputTabDisabled.ts
index bb260bf04ba..94aee40a78f 100644
--- a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsOutputTabDisabled.ts
+++ b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getIsOutputTabDisabled.ts
@@ -1,11 +1,11 @@
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
+import { WorkflowRunStepStatus } from '@/workflow/types/Workflow';
export const getIsOutputTabDisabled = ({
stepExecutionStatus,
}: {
- stepExecutionStatus: WorkflowDiagramRunStatus;
+ stepExecutionStatus: WorkflowRunStepStatus;
}) => {
return (
- stepExecutionStatus === 'running' || stepExecutionStatus === 'not-executed'
+ stepExecutionStatus === 'RUNNING' || stepExecutionStatus === 'NOT_STARTED'
);
};
diff --git a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getShouldFocusNodeTab.ts b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getShouldFocusNodeTab.ts
index de70bcfd732..2c0aba8d857 100644
--- a/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getShouldFocusNodeTab.ts
+++ b/packages/twenty-front/src/modules/command-menu/pages/workflow/step/view-run/utils/getShouldFocusNodeTab.ts
@@ -1,12 +1,14 @@
-import { WorkflowActionType } from '@/workflow/types/Workflow';
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
+import {
+ WorkflowActionType,
+ WorkflowRunStepStatus,
+} from '@/workflow/types/Workflow';
export const getShouldFocusNodeTab = ({
stepExecutionStatus,
actionType,
}: {
- stepExecutionStatus: WorkflowDiagramRunStatus;
+ stepExecutionStatus: WorkflowRunStepStatus;
actionType: WorkflowActionType | undefined;
}) => {
- return actionType === 'FORM' && stepExecutionStatus === 'running';
+ return actionType === 'FORM' && stepExecutionStatus === 'PENDING';
};
diff --git a/packages/twenty-front/src/modules/object-record/record-show/components/CardComponents.tsx b/packages/twenty-front/src/modules/object-record/record-show/components/CardComponents.tsx
index 1e7a114d60f..a67da45d10c 100644
--- a/packages/twenty-front/src/modules/object-record/record-show/components/CardComponents.tsx
+++ b/packages/twenty-front/src/modules/object-record/record-show/components/CardComponents.tsx
@@ -8,7 +8,7 @@ import { TimelineActivities } from '@/activities/timeline-activities/components/
import { ActivityTargetableObject } from '@/activities/types/ActivityTargetableEntity';
import { FieldsCard } from '@/object-record/record-show/components/FieldsCard';
import { CardType } from '@/object-record/record-show/types/CardType';
-import { ListenRecordUpdatesEffect } from '@/subscription/components/ListenUpdatesEffect';
+import { ListenRecordUpdatesEffect } from '@/subscription/components/ListenRecordUpdatesEffect';
import { ShowPageActivityContainer } from '@/ui/layout/show-page/components/ShowPageActivityContainer';
import { getWorkflowVisualizerComponentInstanceId } from '@/workflow/utils/getWorkflowVisualizerComponentInstanceId';
import { WorkflowRunVisualizerEffect } from '@/workflow/workflow-diagram/components/WorkflowRunVisualizerEffect';
@@ -192,7 +192,7 @@ export const CardComponents: Record<CardType, CardComponentType> = {
<ListenRecordUpdatesEffect
objectNameSingular={targetableObject.targetObjectNameSingular}
recordId={targetableObject.id}
- listenedFields={['status', 'output']}
+ listenedFields={['status', 'state']}
/>
<Suspense fallback={<LoadingSkeleton />}>
<WorkflowRunVisualizer workflowRunId={targetableObject.id} />
diff --git a/packages/twenty-front/src/modules/object-record/record-table/record-table-row/components/RecordTableRow.tsx b/packages/twenty-front/src/modules/object-record/record-table/record-table-row/components/RecordTableRow.tsx
index 7f44840d773..5e61a54c312 100644
--- a/packages/twenty-front/src/modules/object-record/record-table/record-table-row/components/RecordTableRow.tsx
+++ b/packages/twenty-front/src/modules/object-record/record-table/record-table-row/components/RecordTableRow.tsx
@@ -8,7 +8,7 @@ import { RecordTableRowArrowKeysEffect } from '@/object-record/record-table/reco
import { RecordTableRowHotkeyEffect } from '@/object-record/record-table/record-table-row/components/RecordTableRowHotkeyEffect';
import { isRecordTableRowFocusActiveComponentState } from '@/object-record/record-table/states/isRecordTableRowFocusActiveComponentState';
import { isRecordTableRowFocusedComponentFamilyState } from '@/object-record/record-table/states/isRecordTableRowFocusedComponentFamilyState';
-import { ListenRecordUpdatesEffect } from '@/subscription/components/ListenUpdatesEffect';
+import { ListenRecordUpdatesEffect } from '@/subscription/components/ListenRecordUpdatesEffect';
import { getDefaultRecordFieldsToListen } from '@/subscription/utils/getDefaultRecordFieldsToListen.util';
import { useRecoilComponentFamilyValueV2 } from '@/ui/utilities/state/component-state/hooks/useRecoilComponentFamilyValueV2';
import { useRecoilComponentValueV2 } from '@/ui/utilities/state/component-state/hooks/useRecoilComponentValueV2';
diff --git a/packages/twenty-front/src/modules/subscription/components/ListenUpdatesEffect.tsx b/packages/twenty-front/src/modules/subscription/components/ListenRecordUpdatesEffect.tsx
similarity index 100%
rename from packages/twenty-front/src/modules/subscription/components/ListenUpdatesEffect.tsx
rename to packages/twenty-front/src/modules/subscription/components/ListenRecordUpdatesEffect.tsx
diff --git a/packages/twenty-front/src/modules/workflow/hooks/useRunWorkflowRunOpeningInCommandMenuSideEffects.ts b/packages/twenty-front/src/modules/workflow/hooks/useRunWorkflowRunOpeningInCommandMenuSideEffects.ts
index 4a263bb72df..4e33cc35c2b 100644
--- a/packages/twenty-front/src/modules/workflow/hooks/useRunWorkflowRunOpeningInCommandMenuSideEffects.ts
+++ b/packages/twenty-front/src/modules/workflow/hooks/useRunWorkflowRunOpeningInCommandMenuSideEffects.ts
@@ -47,15 +47,15 @@ export const useRunWorkflowRunOpeningInCommandMenuSideEffects = () => {
objectPermissionsByObjectMetadataId,
});
if (
- !(isDefined(workflowRunRecord) && isDefined(workflowRunRecord.output))
+ !(isDefined(workflowRunRecord) && isDefined(workflowRunRecord.state))
) {
return;
}
const { stepToOpenByDefault } = generateWorkflowRunDiagram({
- steps: workflowRunRecord.output.flow.steps,
- stepsOutput: workflowRunRecord.output.stepsOutput,
- trigger: workflowRunRecord.output.flow.trigger,
+ steps: workflowRunRecord.state.flow.steps,
+ stepInfos: workflowRunRecord.state.stepInfos,
+ trigger: workflowRunRecord.state.flow.trigger,
});
if (!isDefined(stepToOpenByDefault)) {
@@ -86,8 +86,8 @@ export const useRunWorkflowRunOpeningInCommandMenuSideEffects = () => {
}),
{
workflowVersionId: workflowRunRecord.workflowVersionId,
- trigger: workflowRunRecord.output.flow.trigger,
- steps: workflowRunRecord.output.flow.steps,
+ trigger: workflowRunRecord.state.flow.trigger,
+ steps: workflowRunRecord.state.flow.steps,
},
);
set(
diff --git a/packages/twenty-front/src/modules/workflow/types/Workflow.ts b/packages/twenty-front/src/modules/workflow/types/Workflow.ts
index 4d9e1d2873b..5b8caea2914 100644
--- a/packages/twenty-front/src/modules/workflow/types/Workflow.ts
+++ b/packages/twenty-front/src/modules/workflow/types/Workflow.ts
@@ -18,11 +18,12 @@ import {
workflowFormActionSettingsSchema,
workflowHttpRequestActionSchema,
workflowManualTriggerSchema,
- workflowRunContextSchema,
workflowRunOutputSchema,
workflowRunOutputStepsOutputSchema,
workflowRunSchema,
+ workflowRunStateSchema,
workflowRunStatusSchema,
+ workflowRunStepStatusSchema,
workflowSendEmailActionSchema,
workflowSendEmailActionSettingsSchema,
workflowTriggerSchema,
@@ -150,14 +151,16 @@ export type WorkflowRunOutputStepsOutput = z.infer<
typeof workflowRunOutputStepsOutputSchema
>;
-export type WorkflowRunContext = z.infer<typeof workflowRunContextSchema>;
-
-export type WorkflowRunFlow = WorkflowRunOutput['flow'];
-
export type WorkflowRunStatus = z.infer<typeof workflowRunStatusSchema>;
export type WorkflowRun = z.infer<typeof workflowRunSchema>;
+export type WorkflowRunState = z.infer<typeof workflowRunStateSchema>;
+
+export type WorkflowRunStepStatus = z.infer<typeof workflowRunStepStatusSchema>;
+
+export type WorkflowRunFlow = WorkflowRunState['flow'];
+
export type Workflow = {
__typename: 'Workflow';
id: string;
diff --git a/packages/twenty-front/src/modules/workflow/validation-schemas/workflowSchema.ts b/packages/twenty-front/src/modules/workflow/validation-schemas/workflowSchema.ts
index a7df039c5f0..8b68d442e45 100644
--- a/packages/twenty-front/src/modules/workflow/validation-schemas/workflowSchema.ts
+++ b/packages/twenty-front/src/modules/workflow/validation-schemas/workflowSchema.ts
@@ -1,5 +1,6 @@
import { FieldMetadataType } from 'twenty-shared/types';
import { z } from 'zod';
+import { StepStatus } from 'twenty-shared/workflow';
// Base schemas
export const objectRecordSchema = z.record(z.any());
@@ -317,6 +318,27 @@ export const workflowRunOutputSchema = z.object({
error: z.any().optional(),
});
+export const workflowRunStepStatusSchema = z.nativeEnum(StepStatus);
+
+export const workflowRunStateStepInfoSchema = z.object({
+ result: z.any().optional(),
+ error: z.any().optional(),
+ status: workflowRunStepStatusSchema,
+});
+
+export const workflowRunStateStepInfosSchema = z.record(
+ workflowRunStateStepInfoSchema,
+);
+
+export const workflowRunStateSchema = z.object({
+ flow: z.object({
+ trigger: workflowTriggerSchema,
+ steps: z.array(workflowActionSchema),
+ }),
+ stepInfos: workflowRunStateStepInfosSchema,
+ workflowRunError: z.any().optional(),
+});
+
export const workflowRunContextSchema = z.record(z.any());
export const workflowRunStatusSchema = z.enum([
@@ -335,6 +357,7 @@ export const workflowRunSchema = z
workflowId: z.string(),
output: workflowRunOutputSchema.nullable(),
context: workflowRunContextSchema.nullable(),
+ state: workflowRunStateSchema.nullable(),
status: workflowRunStatusSchema,
createdAt: z.string(),
deletedAt: z.string().nullable(),
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowDiagramStepNodeReadonly.tsx b/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowDiagramStepNodeReadonly.tsx
index 38a6d16ac6f..6d56234562c 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowDiagramStepNodeReadonly.tsx
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowDiagramStepNodeReadonly.tsx
@@ -1,27 +1,7 @@
import { WorkflowDiagramStepNodeBase } from '@/workflow/workflow-diagram/components/WorkflowDiagramStepNodeBase';
import { WorkflowDiagramStepNodeIcon } from '@/workflow/workflow-diagram/components/WorkflowDiagramStepNodeIcon';
-import {
- WorkflowDiagramRunStatus,
- WorkflowDiagramStepNodeData,
-} from '@/workflow/workflow-diagram/types/WorkflowDiagram';
-import { WorkflowDiagramNodeVariant } from '@/workflow/workflow-diagram/types/WorkflowDiagramNodeVariant';
-
-const getNodeVariantFromRunStatus = (
- runStatus: WorkflowDiagramRunStatus | undefined,
-): WorkflowDiagramNodeVariant => {
- switch (runStatus) {
- case 'success':
- return 'success';
- case 'failure':
- return 'failure';
- case 'running':
- return 'running';
- case 'not-executed':
- return 'not-executed';
- default:
- return 'default';
- }
-};
+import { WorkflowDiagramStepNodeData } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
+import { getNodeVariantFromStepRunStatus } from '@/workflow/workflow-diagram/utils/getNodeVariantFromStepRunStatus';
export const WorkflowDiagramStepNodeReadonly = ({
data,
@@ -31,7 +11,7 @@ export const WorkflowDiagramStepNodeReadonly = ({
return (
<WorkflowDiagramStepNodeBase
name={data.name}
- variant={getNodeVariantFromRunStatus(data.runStatus)}
+ variant={getNodeVariantFromStepRunStatus(data.runStatus)}
nodeType={data.nodeType}
Icon={<WorkflowDiagramStepNodeIcon data={data} />}
/>
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowRunVisualizerEffect.tsx b/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowRunVisualizerEffect.tsx
index a5de43a1fc3..5c2ff81f57f 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowRunVisualizerEffect.tsx
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/components/WorkflowRunVisualizerEffect.tsx
@@ -9,7 +9,7 @@ import { useWorkflowVersion } from '@/workflow/hooks/useWorkflowVersion';
import { flowComponentState } from '@/workflow/states/flowComponentState';
import { workflowVisualizerWorkflowIdComponentState } from '@/workflow/states/workflowVisualizerWorkflowIdComponentState';
import { workflowVisualizerWorkflowRunIdComponentState } from '@/workflow/states/workflowVisualizerWorkflowRunIdComponentState';
-import { WorkflowRunOutput } from '@/workflow/types/Workflow';
+import { WorkflowRunState } from '@/workflow/types/Workflow';
import { workflowDiagramComponentState } from '@/workflow/workflow-diagram/states/workflowDiagramComponentState';
import { workflowDiagramStatusComponentState } from '@/workflow/workflow-diagram/states/workflowDiagramStatusComponentState';
import { workflowRunDiagramAutomaticallyOpenedStepsComponentState } from '@/workflow/workflow-diagram/states/workflowRunDiagramAutomaticallyOpenedStepsComponentState';
@@ -82,15 +82,15 @@ export const WorkflowRunVisualizerEffect = ({
const handleWorkflowRunDiagramGeneration = useRecoilCallback(
({ snapshot, set }) =>
({
- workflowRunOutput,
+ workflowRunState,
workflowVersionId,
isInRightDrawer,
}: {
- workflowRunOutput: WorkflowRunOutput | undefined;
+ workflowRunState: WorkflowRunState | undefined;
workflowVersionId: string | undefined;
isInRightDrawer: boolean;
}) => {
- if (!(isDefined(workflowRunOutput) && isDefined(workflowVersionId))) {
+ if (!(isDefined(workflowRunState) && isDefined(workflowVersionId))) {
set(flowState, undefined);
set(workflowDiagramState, undefined);
@@ -108,15 +108,15 @@ export const WorkflowRunVisualizerEffect = ({
set(flowState, {
workflowVersionId,
- trigger: workflowRunOutput.flow.trigger,
- steps: workflowRunOutput.flow.steps,
+ trigger: workflowRunState.flow.trigger,
+ steps: workflowRunState.flow.steps,
});
const { diagram: baseWorkflowRunDiagram, stepToOpenByDefault } =
generateWorkflowRunDiagram({
- trigger: workflowRunOutput.flow.trigger,
- steps: workflowRunOutput.flow.steps,
- stepsOutput: workflowRunOutput.stepsOutput,
+ trigger: workflowRunState.flow.trigger,
+ steps: workflowRunState.flow.steps,
+ stepInfos: workflowRunState.stepInfos,
});
if (isDefined(stepToOpenByDefault)) {
@@ -197,14 +197,14 @@ export const WorkflowRunVisualizerEffect = ({
useEffect(() => {
handleWorkflowRunDiagramGeneration({
- workflowRunOutput: workflowRun?.output ?? undefined,
+ workflowRunState: workflowRun?.state ?? undefined,
workflowVersionId: workflowRun?.workflowVersionId,
isInRightDrawer,
});
}, [
handleWorkflowRunDiagramGeneration,
isInRightDrawer,
- workflowRun?.output,
+ workflowRun?.state,
workflowRun?.workflowVersionId,
]);
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/hooks/useSetInitialWorkflowRunRightDrawerTab.ts b/packages/twenty-front/src/modules/workflow/workflow-diagram/hooks/useSetInitialWorkflowRunRightDrawerTab.ts
index fd322c2422a..322064fb706 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-diagram/hooks/useSetInitialWorkflowRunRightDrawerTab.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/hooks/useSetInitialWorkflowRunRightDrawerTab.ts
@@ -3,10 +3,10 @@ import { getIsOutputTabDisabled } from '@/command-menu/pages/workflow/step/view-
import { commandMenuPageInfoState } from '@/command-menu/states/commandMenuPageInfoState';
import { activeTabIdComponentState } from '@/ui/layout/tab-list/states/activeTabIdComponentState';
import { getSnapshotValue } from '@/ui/utilities/state/utils/getSnapshotValue';
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
import { WorkflowRunTabId } from '@/workflow/workflow-steps/types/WorkflowRunTabId';
import { useRecoilCallback } from 'recoil';
import { isDefined } from 'twenty-shared/utils';
+import { WorkflowRunStepStatus } from '@/workflow/types/Workflow';
export const useSetInitialWorkflowRunRightDrawerTab = () => {
const setInitialWorkflowRunRightDrawerTab = useRecoilCallback(
@@ -16,7 +16,7 @@ export const useSetInitialWorkflowRunRightDrawerTab = () => {
stepExecutionStatus,
}: {
workflowSelectedNode: string;
- stepExecutionStatus: WorkflowDiagramRunStatus;
+ stepExecutionStatus: WorkflowRunStepStatus;
}) => {
const commandMenuPageInfo = getSnapshotValue(
snapshot,
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/types/WorkflowDiagram.ts b/packages/twenty-front/src/modules/workflow/workflow-diagram/types/WorkflowDiagram.ts
index 131a6414726..335a90f21aa 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-diagram/types/WorkflowDiagram.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/types/WorkflowDiagram.ts
@@ -1,5 +1,6 @@
import {
WorkflowActionType,
+ WorkflowRunStepStatus,
WorkflowTriggerType,
} from '@/workflow/types/Workflow';
import { Edge, Node } from '@xyflow/react';
@@ -21,32 +22,26 @@ export type WorkflowDiagram = {
edges: Array<WorkflowDiagramEdge>;
};
-export type WorkflowDiagramRunStatus =
- | 'running'
- | 'success'
- | 'failure'
- | 'not-executed';
-
export type WorkflowDiagramStepNodeData =
| {
nodeType: 'trigger';
triggerType: WorkflowTriggerType;
name: string;
icon?: string;
- runStatus?: WorkflowDiagramRunStatus;
+ runStatus?: WorkflowRunStepStatus;
}
| {
nodeType: 'action';
actionType: WorkflowActionType;
name: string;
- runStatus?: WorkflowDiagramRunStatus;
+ runStatus?: WorkflowRunStepStatus;
};
export type WorkflowRunDiagramStepNodeData = Exclude<
WorkflowDiagramStepNodeData,
'runStatus'
> & {
- runStatus: WorkflowDiagramRunStatus;
+ runStatus: WorkflowRunStepStatus;
};
export type WorkflowDiagramCreateStepNodeData = {
@@ -66,7 +61,7 @@ export type WorkflowDiagramNodeData =
export type WorkflowRunDiagramNodeData = Exclude<
WorkflowDiagramStepNodeData,
'runStatus'
-> & { runStatus: WorkflowDiagramRunStatus };
+> & { runStatus: WorkflowRunStepStatus };
export type EdgeData = {
stepId?: string;
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/__tests__/generateWorkflowRunDiagram.test.ts b/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/__tests__/generateWorkflowRunDiagram.test.ts
index 0f18ed3d60d..a73de557770 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/__tests__/generateWorkflowRunDiagram.test.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/__tests__/generateWorkflowRunDiagram.test.ts
@@ -1,11 +1,8 @@
-import {
- WorkflowRunOutputStepsOutput,
- WorkflowStep,
- WorkflowTrigger,
-} from '@/workflow/types/Workflow';
+import { WorkflowStep, WorkflowTrigger } from '@/workflow/types/Workflow';
import { FieldMetadataType } from 'twenty-shared/types';
import { getUuidV4Mock } from '~/testing/utils/getUuidV4Mock';
import { generateWorkflowRunDiagram } from '../generateWorkflowRunDiagram';
+import { StepStatus, WorkflowRunStepInfos } from 'twenty-shared/workflow';
jest.mock('uuid', () => ({
v4: getUuidV4Mock(),
@@ -82,14 +79,28 @@ describe('generateWorkflowRunDiagram', () => {
},
];
- const stepsOutput: WorkflowRunOutputStepsOutput = {
+ const stepInfos: WorkflowRunStepInfos = {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
step1: {
- result: undefined,
error: '',
+ status: StepStatus.FAILED,
+ },
+ step2: {
+ status: StepStatus.NOT_STARTED,
+ },
+ step3: {
+ status: StepStatus.NOT_STARTED,
},
};
- const result = generateWorkflowRunDiagram({ trigger, steps, stepsOutput });
+ const result = generateWorkflowRunDiagram({
+ trigger,
+ steps,
+ stepInfos,
+ });
expect(result).toMatchInlineSnapshot(`
{
@@ -130,7 +141,7 @@ describe('generateWorkflowRunDiagram', () => {
"icon": "IconPlaylistAdd",
"name": "Company created",
"nodeType": "trigger",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
"triggerType": "DATABASE_EVENT",
},
"id": "trigger",
@@ -144,7 +155,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 1",
"nodeType": "action",
- "runStatus": "failure",
+ "runStatus": "FAILED",
},
"id": "step1",
"position": {
@@ -157,7 +168,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 2",
"nodeType": "action",
- "runStatus": "not-executed",
+ "runStatus": "NOT_STARTED",
},
"id": "step2",
"position": {
@@ -170,7 +181,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 3",
"nodeType": "action",
- "runStatus": "not-executed",
+ "runStatus": "NOT_STARTED",
},
"id": "step3",
"position": {
@@ -255,22 +266,30 @@ describe('generateWorkflowRunDiagram', () => {
},
];
- const stepsOutput: WorkflowRunOutputStepsOutput = {
+ const stepInfos: WorkflowRunStepInfos = {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
step1: {
result: {},
- error: undefined,
+ status: StepStatus.SUCCESS,
},
step2: {
result: {},
- error: undefined,
+ status: StepStatus.SUCCESS,
},
step3: {
result: {},
- error: undefined,
+ status: StepStatus.SUCCESS,
},
};
- const result = generateWorkflowRunDiagram({ trigger, steps, stepsOutput });
+ const result = generateWorkflowRunDiagram({
+ trigger,
+ steps,
+ stepInfos,
+ });
expect(result).toMatchInlineSnapshot(`
{
@@ -313,7 +332,7 @@ describe('generateWorkflowRunDiagram', () => {
"icon": "IconPlaylistAdd",
"name": "Company created",
"nodeType": "trigger",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
"triggerType": "DATABASE_EVENT",
},
"id": "trigger",
@@ -327,7 +346,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 1",
"nodeType": "action",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
},
"id": "step1",
"position": {
@@ -340,7 +359,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 2",
"nodeType": "action",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
},
"id": "step2",
"position": {
@@ -353,7 +372,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 3",
"nodeType": "action",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
},
"id": "step3",
"position": {
@@ -438,9 +457,30 @@ describe('generateWorkflowRunDiagram', () => {
},
];
- const stepsOutput = undefined;
+ const stepInfos: WorkflowRunStepInfos = {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
+ step1: {
+ error: '',
+ status: StepStatus.RUNNING,
+ },
+ step2: {
+ error: '',
+ status: StepStatus.NOT_STARTED,
+ },
+ step3: {
+ error: '',
+ status: StepStatus.NOT_STARTED,
+ },
+ };
- const result = generateWorkflowRunDiagram({ trigger, steps, stepsOutput });
+ const result = generateWorkflowRunDiagram({
+ trigger,
+ steps,
+ stepInfos,
+ });
expect(result).toMatchInlineSnapshot(`
{
@@ -481,7 +521,7 @@ describe('generateWorkflowRunDiagram', () => {
"icon": "IconPlaylistAdd",
"name": "Company created",
"nodeType": "trigger",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
"triggerType": "DATABASE_EVENT",
},
"id": "trigger",
@@ -495,7 +535,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 1",
"nodeType": "action",
- "runStatus": "running",
+ "runStatus": "RUNNING",
},
"id": "step1",
"position": {
@@ -508,7 +548,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 2",
"nodeType": "action",
- "runStatus": "not-executed",
+ "runStatus": "NOT_STARTED",
},
"id": "step2",
"position": {
@@ -521,7 +561,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 3",
"nodeType": "action",
- "runStatus": "not-executed",
+ "runStatus": "NOT_STARTED",
},
"id": "step3",
"position": {
@@ -625,14 +665,30 @@ describe('generateWorkflowRunDiagram', () => {
},
];
- const stepsOutput: WorkflowRunOutputStepsOutput = {
+ const stepInfos: WorkflowRunStepInfos = {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
step1: {
result: {},
- error: undefined,
+ status: StepStatus.SUCCESS,
+ },
+ step2: {
+ result: {},
+ status: StepStatus.RUNNING,
+ },
+ step3: {
+ result: {},
+ status: StepStatus.NOT_STARTED,
},
};
- const result = generateWorkflowRunDiagram({ trigger, steps, stepsOutput });
+ const result = generateWorkflowRunDiagram({
+ trigger,
+ steps,
+ stepInfos,
+ });
expect(result).toMatchInlineSnapshot(`
{
@@ -683,7 +739,7 @@ describe('generateWorkflowRunDiagram', () => {
"icon": "IconPlaylistAdd",
"name": "Company created",
"nodeType": "trigger",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
"triggerType": "DATABASE_EVENT",
},
"id": "trigger",
@@ -697,7 +753,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 1",
"nodeType": "action",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
},
"id": "step1",
"position": {
@@ -710,7 +766,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 2",
"nodeType": "action",
- "runStatus": "running",
+ "runStatus": "RUNNING",
},
"id": "step2",
"position": {
@@ -723,7 +779,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 3",
"nodeType": "action",
- "runStatus": "not-executed",
+ "runStatus": "NOT_STARTED",
},
"id": "step3",
"position": {
@@ -736,7 +792,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "CODE",
"name": "Step 4",
"nodeType": "action",
- "runStatus": "not-executed",
+ "runStatus": "NOT_STARTED",
},
"id": "step4",
"position": {
@@ -786,15 +842,31 @@ describe('generateWorkflowRunDiagram', () => {
nextStepIds: undefined,
},
];
- const stepsOutput = {
+
+ const stepInfos: WorkflowRunStepInfos = {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
step1: {
- result: undefined,
- error: undefined,
- pendingEvent: true,
+ result: {},
+ status: StepStatus.PENDING,
+ },
+ step2: {
+ result: {},
+ status: StepStatus.NOT_STARTED,
+ },
+ step3: {
+ result: {},
+ status: StepStatus.NOT_STARTED,
},
};
- const result = generateWorkflowRunDiagram({ trigger, steps, stepsOutput });
+ const result = generateWorkflowRunDiagram({
+ trigger,
+ steps,
+ stepInfos,
+ });
expect(result).toMatchInlineSnapshot(`
{
@@ -817,7 +889,7 @@ describe('generateWorkflowRunDiagram', () => {
"icon": "IconPlaylistAdd",
"name": "Company created",
"nodeType": "trigger",
- "runStatus": "success",
+ "runStatus": "SUCCESS",
"triggerType": "DATABASE_EVENT",
},
"id": "trigger",
@@ -831,7 +903,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "FORM",
"name": "Step 1",
"nodeType": "action",
- "runStatus": "running",
+ "runStatus": "PENDING",
},
"id": "step1",
"position": {
@@ -846,7 +918,7 @@ describe('generateWorkflowRunDiagram', () => {
"actionType": "FORM",
"name": "Step 1",
"nodeType": "action",
- "runStatus": "running",
+ "runStatus": "PENDING",
},
"id": "step1",
},
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/generateWorkflowRunDiagram.ts b/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/generateWorkflowRunDiagram.ts
index b6b98b2a4c6..bcf58ecbcff 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/generateWorkflowRunDiagram.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/generateWorkflowRunDiagram.ts
@@ -1,11 +1,6 @@
-import {
- WorkflowRunOutputStepsOutput,
- WorkflowStep,
- WorkflowTrigger,
-} from '@/workflow/types/Workflow';
+import { WorkflowStep, WorkflowTrigger } from '@/workflow/types/Workflow';
import { WORKFLOW_VISUALIZER_EDGE_SUCCESS_CONFIGURATION } from '@/workflow/workflow-diagram/constants/WorkflowVisualizerEdgeSuccessConfiguration';
import {
- WorkflowDiagramRunStatus,
WorkflowRunDiagram,
WorkflowRunDiagramNode,
WorkflowRunDiagramStepNodeData,
@@ -14,15 +9,16 @@ import { generateWorkflowDiagram } from '@/workflow/workflow-diagram/utils/gener
import { isStepNode } from '@/workflow/workflow-diagram/utils/isStepNode';
import { transformFilterNodesAsEdges } from '@/workflow/workflow-diagram/utils/transformFilterNodesAsEdges';
import { isDefined } from 'twenty-shared/utils';
+import { WorkflowRunStepInfos, StepStatus } from 'twenty-shared/workflow';
export const generateWorkflowRunDiagram = ({
trigger,
steps,
- stepsOutput,
+ stepInfos,
}: {
trigger: WorkflowTrigger;
steps: Array<WorkflowStep>;
- stepsOutput: WorkflowRunOutputStepsOutput | undefined;
+ stepInfos: WorkflowRunStepInfos | undefined;
}): {
diagram: WorkflowRunDiagram;
stepToOpenByDefault:
@@ -43,50 +39,29 @@ export const generateWorkflowRunDiagram = ({
generateWorkflowDiagram({ trigger, steps }),
);
- let skippedExecution = false;
-
const workflowRunDiagramNodes: WorkflowRunDiagramNode[] =
workflowDiagram.nodes.filter(isStepNode).map((node) => {
- if (node.data.nodeType === 'trigger') {
+ const nodeId = node.id;
+
+ const stepInfo = stepInfos?.[nodeId];
+
+ if (!isDefined(stepInfo)) {
return {
...node,
data: {
...node.data,
- runStatus: 'success',
+ runStatus: StepStatus.NOT_STARTED,
},
};
}
- const nodeId = node.id;
-
- const runResult = stepsOutput?.[nodeId];
-
- const isPendingFormAction =
- node.data.nodeType === 'action' &&
- node.data.actionType === 'FORM' &&
- isDefined(runResult?.pendingEvent) &&
- runResult.pendingEvent;
-
- let runStatus: WorkflowDiagramRunStatus = 'success';
-
- if (skippedExecution) {
- runStatus = 'not-executed';
- } else if (!isDefined(runResult) || isPendingFormAction) {
- runStatus = 'running';
- } else if (isDefined(runResult.error)) {
- runStatus = 'failure';
- }
-
- skippedExecution =
- skippedExecution || runStatus === 'failure' || runStatus === 'running';
-
- const nodeData = { ...node.data, runStatus };
+ const nodeData = {
+ ...node.data,
+ runStatus: stepInfo.status,
+ };
- if (isPendingFormAction) {
- stepToOpenByDefault = {
- id: nodeId,
- data: nodeData,
- };
+ if (!isDefined(stepToOpenByDefault) && stepInfo.status === 'PENDING') {
+ stepToOpenByDefault = { id: nodeId, data: nodeData };
}
return {
@@ -100,7 +75,17 @@ export const generateWorkflowRunDiagram = ({
(node) => node.id === edge.source,
);
- if (isDefined(parentNode) && parentNode.data.runStatus === 'success') {
+ if (!isDefined(parentNode)) {
+ return edge;
+ }
+
+ const stepInfo = stepInfos?.[parentNode.id];
+
+ if (!isDefined(stepInfo)) {
+ return edge;
+ }
+
+ if (stepInfo.status === 'SUCCESS') {
return {
...edge,
...WORKFLOW_VISUALIZER_EDGE_SUCCESS_CONFIGURATION,
diff --git a/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/getNodeVariantFromStepRunStatus.ts b/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/getNodeVariantFromStepRunStatus.ts
new file mode 100644
index 00000000000..15e6dbf65af
--- /dev/null
+++ b/packages/twenty-front/src/modules/workflow/workflow-diagram/utils/getNodeVariantFromStepRunStatus.ts
@@ -0,0 +1,20 @@
+import { WorkflowRunStepStatus } from '@/workflow/types/Workflow';
+import { WorkflowDiagramNodeVariant } from '@/workflow/workflow-diagram/types/WorkflowDiagramNodeVariant';
+
+export const getNodeVariantFromStepRunStatus = (
+ runStatus: WorkflowRunStepStatus | undefined,
+): WorkflowDiagramNodeVariant => {
+ switch (runStatus) {
+ case 'SUCCESS':
+ return 'success';
+ case 'FAILED':
+ return 'failure';
+ case 'RUNNING':
+ case 'PENDING':
+ return 'running';
+ case 'NOT_STARTED':
+ return 'not-executed';
+ default:
+ return 'default';
+ }
+};
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepInputDetail.tsx b/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepInputDetail.tsx
index 3237b5f4455..bc9d694fd80 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepInputDetail.tsx
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepInputDetail.tsx
@@ -20,6 +20,7 @@ import {
ShouldExpandNodeInitiallyProps,
} from 'twenty-ui/json-visualizer';
import { useCopyToClipboard } from '~/hooks/useCopyToClipboard';
+import { JsonValue } from 'type-fest';
export const WorkflowRunStepInputDetail = ({ stepId }: { stepId: string }) => {
const { t, i18n } = useLingui();
@@ -29,15 +30,15 @@ export const WorkflowRunStepInputDetail = ({ stepId }: { stepId: string }) => {
const workflowRunId = useWorkflowRunIdOrThrow();
const workflowRun = useWorkflowRun({ workflowRunId });
- const step = workflowRun?.output?.flow.steps.find(
+ const step = workflowRun?.state?.flow.steps.find(
(step) => step.id === stepId,
);
if (
!(
isDefined(workflowRun) &&
- isDefined(workflowRun.context) &&
- isDefined(workflowRun.output?.flow) &&
+ isDefined(workflowRun.state?.stepInfos) &&
+ isDefined(workflowRun.state?.flow) &&
isDefined(step)
)
) {
@@ -46,7 +47,7 @@ export const WorkflowRunStepInputDetail = ({ stepId }: { stepId: string }) => {
const previousStepId = getWorkflowPreviousStepId({
stepId,
- steps: workflowRun.output.flow.steps,
+ steps: workflowRun.state.flow.steps,
});
if (previousStepId === undefined) {
@@ -55,8 +56,8 @@ export const WorkflowRunStepInputDetail = ({ stepId }: { stepId: string }) => {
const stepDefinition = getStepDefinitionOrThrow({
stepId,
- trigger: workflowRun.output.flow.trigger,
- steps: workflowRun.output.flow.steps,
+ trigger: workflowRun.state.flow.trigger,
+ steps: workflowRun.state.flow.steps,
});
if (stepDefinition?.type !== 'action') {
throw new Error('The input tab must be rendered with an action step.');
@@ -76,10 +77,11 @@ export const WorkflowRunStepInputDetail = ({ stepId }: { stepId: string }) => {
const allVariablesUsedInStep = Array.from(variablesUsedInStep);
const stepContext = getWorkflowRunStepContext({
- context: workflowRun.context,
- flow: workflowRun.output.flow,
+ stepInfos: workflowRun.state.stepInfos,
+ flow: workflowRun.state.flow,
stepId,
});
+
if (stepContext.length === 0) {
throw new Error('The input tab must be rendered with a non-empty context.');
}
@@ -132,7 +134,7 @@ export const WorkflowRunStepInputDetail = ({ stepId }: { stepId: string }) => {
elements={stepContext.map(({ id, name, context }) => ({
id,
label: name,
- value: context,
+ value: context as JsonValue,
}))}
Icon={IconBrackets}
depth={0}
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepNodeDetail.tsx b/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepNodeDetail.tsx
index 862423663e4..490acdc69f6 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepNodeDetail.tsx
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepNodeDetail.tsx
@@ -1,7 +1,10 @@
-import { WorkflowAction, WorkflowTrigger } from '@/workflow/types/Workflow';
+import {
+ WorkflowAction,
+ WorkflowRunStepStatus,
+ WorkflowTrigger,
+} from '@/workflow/types/Workflow';
import { assertUnreachable } from '@/workflow/utils/assertUnreachable';
import { getStepDefinitionOrThrow } from '@/workflow/utils/getStepDefinitionOrThrow';
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
import { WorkflowEditActionAiAgent } from '@/workflow/workflow-steps/workflow-actions/ai-agent-action/components/WorkflowEditActionAiAgent';
import { WorkflowActionServerlessFunction } from '@/workflow/workflow-steps/workflow-actions/code-action/components/WorkflowActionServerlessFunction';
import { WorkflowEditActionCreateRecord } from '@/workflow/workflow-steps/workflow-actions/components/WorkflowEditActionCreateRecord';
@@ -21,7 +24,7 @@ type WorkflowRunStepNodeDetailProps = {
stepId: string;
trigger: WorkflowTrigger | null;
steps: Array<WorkflowAction> | null;
- stepExecutionStatus?: WorkflowDiagramRunStatus;
+ stepExecutionStatus?: WorkflowRunStepStatus;
};
export const WorkflowRunStepNodeDetail = ({
@@ -172,7 +175,7 @@ export const WorkflowRunStepNodeDetail = ({
key={stepId}
action={stepDefinition.definition}
actionOptions={{
- readonly: stepExecutionStatus !== 'running',
+ readonly: stepExecutionStatus !== 'PENDING',
}}
/>
);
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepOutputDetail.tsx b/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepOutputDetail.tsx
index 5da5840d1b5..2ca3c74510d 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepOutputDetail.tsx
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/components/WorkflowRunStepOutputDetail.tsx
@@ -1,6 +1,5 @@
import { useWorkflowRun } from '@/workflow/hooks/useWorkflowRun';
import { useWorkflowRunIdOrThrow } from '@/workflow/hooks/useWorkflowRunIdOrThrow';
-import { WorkflowExecutorOutput } from '@/workflow/types/Workflow';
import { getStepDefinitionOrThrow } from '@/workflow/utils/getStepDefinitionOrThrow';
import { WorkflowRunStepJsonContainer } from '@/workflow/workflow-steps/components/WorkflowRunStepJsonContainer';
import { WorkflowStepHeader } from '@/workflow/workflow-steps/components/WorkflowStepHeader';
@@ -30,18 +29,16 @@ export const WorkflowRunStepOutputDetail = ({ stepId }: { stepId: string }) => {
const workflowRunId = useWorkflowRunIdOrThrow();
const workflowRun = useWorkflowRun({ workflowRunId });
- if (!isDefined(workflowRun?.output?.stepsOutput)) {
+ if (!isDefined(workflowRun?.state?.stepInfos)) {
return null;
}
- const stepOutput = workflowRun.output.stepsOutput[stepId] as
- | WorkflowExecutorOutput
- | undefined;
+ const stepInfo = workflowRun.state.stepInfos[stepId];
const stepDefinition = getStepDefinitionOrThrow({
stepId,
- trigger: workflowRun.output.flow.trigger,
- steps: workflowRun.output.flow.steps,
+ trigger: workflowRun.state.flow.trigger,
+ steps: workflowRun.state.flow.steps,
});
if (
!isDefined(stepDefinition?.definition) ||
@@ -87,7 +84,7 @@ export const WorkflowRunStepOutputDetail = ({ stepId }: { stepId: string }) => {
<WorkflowRunStepJsonContainer>
<JsonTree
- value={stepOutput ?? t`No output available`}
+ value={stepInfo ?? t`No output available`}
shouldExpandNodeInitially={isTwoFirstDepths}
emptyArrayLabel={t`Empty Array`}
emptyObjectLabel={t`Empty Object`}
@@ -95,7 +92,7 @@ export const WorkflowRunStepOutputDetail = ({ stepId }: { stepId: string }) => {
arrowButtonCollapsedLabel={t`Expand`}
arrowButtonExpandedLabel={t`Collapse`}
getNodeHighlighting={
- isDefined(stepOutput?.error)
+ isDefined(stepInfo?.error)
? setRedHighlightingForEveryNode
: undefined
}
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/hooks/useUpdateWorkflowRunStep.ts b/packages/twenty-front/src/modules/workflow/workflow-steps/hooks/useUpdateWorkflowRunStep.ts
index e06964766e2..ece69fdd78a 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/hooks/useUpdateWorkflowRunStep.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/hooks/useUpdateWorkflowRunStep.ts
@@ -49,18 +49,18 @@ export const useUpdateWorkflowRunStep = () => {
if (
!isDefined(cachedRecord) ||
- !isDefined(cachedRecord?.output?.flow?.steps)
+ !isDefined(cachedRecord?.state?.flow?.steps)
) {
return;
}
const newCachedRecord = {
...cachedRecord,
- output: {
- ...cachedRecord.output,
+ state: {
+ ...cachedRecord.state,
flow: {
- ...cachedRecord.output.flow,
- steps: cachedRecord.output.flow.steps.map((step: WorkflowAction) => {
+ ...cachedRecord.state.flow,
+ steps: cachedRecord.state.flow.steps.map((step: WorkflowAction) => {
if (step.id === updatedStep.id) {
return updatedStep;
}
@@ -71,7 +71,7 @@ export const useUpdateWorkflowRunStep = () => {
};
const recordGqlFields = {
- output: true,
+ state: true,
};
updateRecordFromCache({
objectMetadataItems,
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepContext.test.ts b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepContext.test.ts
index 148ab2fab55..1eda9ff0945 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepContext.test.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepContext.test.ts
@@ -1,6 +1,7 @@
import { WorkflowRunFlow } from '@/workflow/types/Workflow';
import { TRIGGER_STEP_ID } from '@/workflow/workflow-trigger/constants/TriggerStepId';
import { getWorkflowRunStepContext } from '../getWorkflowRunStepContext';
+import { StepStatus } from 'twenty-shared/workflow';
describe('getWorkflowRunStepContext', () => {
it('should return an empty array for trigger step', () => {
@@ -15,14 +16,17 @@ describe('getWorkflowRunStepContext', () => {
},
steps: [],
} satisfies WorkflowRunFlow;
- const context = {
- [TRIGGER_STEP_ID]: { company: { id: '123' } },
+ const stepInfos = {
+ [TRIGGER_STEP_ID]: {
+ result: { company: { id: '123' } },
+ status: StepStatus.SUCCESS,
+ },
};
const result = getWorkflowRunStepContext({
stepId: TRIGGER_STEP_ID,
flow,
- context,
+ stepInfos,
});
expect(result).toEqual([]);
@@ -77,15 +81,20 @@ describe('getWorkflowRunStepContext', () => {
},
],
} satisfies WorkflowRunFlow;
- const context = {
- [TRIGGER_STEP_ID]: { company: { id: '123' } },
- step1: { taskId: '456' },
+
+ const stepInfos = {
+ [TRIGGER_STEP_ID]: {
+ result: { company: { id: '123' } },
+ status: StepStatus.SUCCESS,
+ },
+ step1: { result: { taskId: '456' }, status: StepStatus.SUCCESS },
+ step2: { result: { taskId: '456' }, status: StepStatus.SUCCESS },
};
const result = getWorkflowRunStepContext({
stepId: 'step2',
flow,
- context,
+ stepInfos,
});
expect(result).toEqual([
@@ -149,16 +158,19 @@ describe('getWorkflowRunStepContext', () => {
},
],
} satisfies WorkflowRunFlow;
- const context = {
- [TRIGGER_STEP_ID]: { company: { id: '123' } },
- step1: { taskId: '456' },
- step2: { emailId: '789' },
+ const stepInfos = {
+ [TRIGGER_STEP_ID]: {
+ result: { company: { id: '123' } },
+ status: StepStatus.SUCCESS,
+ },
+ step1: { result: { taskId: '456' }, status: StepStatus.SUCCESS },
+ step2: { result: { emailId: '789' }, status: StepStatus.SUCCESS },
};
const result = getWorkflowRunStepContext({
stepId: 'step1',
flow,
- context,
+ stepInfos,
});
expect(result).toEqual([
@@ -237,17 +249,20 @@ describe('getWorkflowRunStepContext', () => {
},
],
} satisfies WorkflowRunFlow;
- const context = {
- [TRIGGER_STEP_ID]: { company: { id: '123' } },
- step1: { noteId: '456' },
- step2: { noteId: '789' },
- step3: { noteId: '101' },
+ const stepInfos = {
+ [TRIGGER_STEP_ID]: {
+ result: { company: { id: '123' } },
+ status: StepStatus.SUCCESS,
+ },
+ step1: { result: { noteId: '456' }, status: StepStatus.SUCCESS },
+ step2: { result: { noteId: '789' }, status: StepStatus.SUCCESS },
+ step3: { result: { noteId: '101' }, status: StepStatus.SUCCESS },
};
const result = getWorkflowRunStepContext({
stepId: 'step3',
flow,
- context,
+ stepInfos,
});
expect(result).toEqual([
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepExecutionStatus.test.ts b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepExecutionStatus.test.ts
index 37402bdcf16..f2a4f0823bf 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepExecutionStatus.test.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/__tests__/getWorkflowRunStepExecutionStatus.test.ts
@@ -1,4 +1,5 @@
import { getWorkflowRunStepExecutionStatus } from '../getWorkflowRunStepExecutionStatus';
+import { StepStatus } from 'twenty-shared/workflow';
describe('getWorkflowRunStepExecutionStatus', () => {
const stepId = '453e0084-aca2-45b9-8d1c-458a2b8ac70a';
@@ -6,16 +7,16 @@ describe('getWorkflowRunStepExecutionStatus', () => {
it('should return not-executed when the output is null', () => {
expect(
getWorkflowRunStepExecutionStatus({
- workflowRunOutput: null,
+ workflowRunState: null,
stepId,
}),
- ).toBe('not-executed');
+ ).toBe(StepStatus.NOT_STARTED);
});
it('should return success when step has result', () => {
expect(
getWorkflowRunStepExecutionStatus({
- workflowRunOutput: {
+ workflowRunState: {
flow: {
steps: [
{
@@ -60,15 +61,20 @@ describe('getWorkflowRunStepExecutionStatus', () => {
},
},
},
- stepsOutput: {
+ stepInfos: {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
[stepId]: {
result: {},
+ status: StepStatus.SUCCESS,
},
},
},
stepId,
}),
- ).toBe('success');
+ ).toBe(StepStatus.SUCCESS);
});
it('should return failure when workflow has error', () => {
@@ -76,7 +82,7 @@ describe('getWorkflowRunStepExecutionStatus', () => {
expect(
getWorkflowRunStepExecutionStatus({
- workflowRunOutput: {
+ workflowRunState: {
flow: {
steps: [
{
@@ -121,16 +127,21 @@ describe('getWorkflowRunStepExecutionStatus', () => {
},
},
},
- error,
- stepsOutput: {
+ workflowRunError: error,
+ stepInfos: {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
[stepId]: {
error,
+ status: StepStatus.FAILED,
},
},
},
stepId,
}),
- ).toBe('failure');
+ ).toBe(StepStatus.FAILED);
});
it('should return not-executed when step has no output', () => {
@@ -138,7 +149,7 @@ describe('getWorkflowRunStepExecutionStatus', () => {
expect(
getWorkflowRunStepExecutionStatus({
- workflowRunOutput: {
+ workflowRunState: {
flow: {
steps: [
{
@@ -217,14 +228,23 @@ describe('getWorkflowRunStepExecutionStatus', () => {
},
},
},
- stepsOutput: {
+ stepInfos: {
+ trigger: {
+ result: {},
+ status: StepStatus.SUCCESS,
+ },
[stepId]: {
result: {},
+ status: StepStatus.SUCCESS,
+ },
+ [secondStepId]: {
+ result: {},
+ status: StepStatus.NOT_STARTED,
},
},
},
stepId: secondStepId,
}),
- ).toBe('not-executed');
+ ).toBe(StepStatus.NOT_STARTED);
});
});
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepContext.ts b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepContext.ts
index 9b0fa3ed956..79766f9156a 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepContext.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepContext.ts
@@ -1,14 +1,18 @@
-import { WorkflowRunContext, WorkflowRunFlow } from '@/workflow/types/Workflow';
+import { WorkflowRunFlow } from '@/workflow/types/Workflow';
import { getPreviousSteps } from '@/workflow/workflow-steps/utils/getWorkflowPreviousSteps';
import { TRIGGER_STEP_ID } from '@/workflow/workflow-trigger/constants/TriggerStepId';
+import {
+ getWorkflowRunContext,
+ WorkflowRunStepInfos,
+} from 'twenty-shared/workflow';
export const getWorkflowRunStepContext = ({
stepId,
flow,
- context,
+ stepInfos,
}: {
stepId: string;
- context: WorkflowRunContext;
+ stepInfos: WorkflowRunStepInfos;
flow: WorkflowRunFlow;
}) => {
if (stepId === TRIGGER_STEP_ID) {
@@ -17,6 +21,8 @@ export const getWorkflowRunStepContext = ({
const previousSteps = getPreviousSteps(flow.steps, stepId);
+ const context = getWorkflowRunContext(stepInfos);
+
const previousStepsContext = previousSteps.map((step) => {
return {
id: step.id,
diff --git a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepExecutionStatus.ts b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepExecutionStatus.ts
index 9604436fb81..f241b8b1df0 100644
--- a/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepExecutionStatus.ts
+++ b/packages/twenty-front/src/modules/workflow/workflow-steps/utils/getWorkflowRunStepExecutionStatus.ts
@@ -1,37 +1,22 @@
-import { WorkflowRunOutput } from '@/workflow/types/Workflow';
-import { WorkflowDiagramRunStatus } from '@/workflow/workflow-diagram/types/WorkflowDiagram';
-import { TRIGGER_STEP_ID } from '@/workflow/workflow-trigger/constants/TriggerStepId';
-import { isNull } from '@sniptt/guards';
+import {
+ WorkflowRunState,
+ WorkflowRunStepStatus,
+} from '@/workflow/types/Workflow';
import { isDefined } from 'twenty-shared/utils';
+import { StepStatus } from 'twenty-shared/workflow';
export const getWorkflowRunStepExecutionStatus = ({
- workflowRunOutput,
+ workflowRunState,
stepId,
}: {
- workflowRunOutput: WorkflowRunOutput | null;
+ workflowRunState: WorkflowRunState | null;
stepId: string;
-}): WorkflowDiagramRunStatus => {
- if (isNull(workflowRunOutput)) {
- return 'not-executed';
- }
-
- if (stepId === TRIGGER_STEP_ID) {
- return 'success';
- }
-
- const stepOutput = workflowRunOutput.stepsOutput?.[stepId];
-
- if (isDefined(stepOutput?.error)) {
- return 'failure';
- }
-
- if (isDefined(stepOutput?.pendingEvent)) {
- return 'running';
- }
+}): WorkflowRunStepStatus => {
+ const stepOutput = workflowRunState?.stepInfos?.[stepId];
- if (isDefined(stepOutput?.result)) {
- return 'success';
+ if (isDefined(stepOutput)) {
+ return stepOutput.status;
}
- return 'not-executed';
+ return StepStatus.NOT_STARTED;
};
diff --git a/packages/twenty-front/src/testing/mock-data/workflow-run.ts b/packages/twenty-front/src/testing/mock-data/workflow-run.ts
index 9fae3eceb58..e86b47f83fe 100644
--- a/packages/twenty-front/src/testing/mock-data/workflow-run.ts
+++ b/packages/twenty-front/src/testing/mock-data/workflow-run.ts
@@ -1,24 +1,25 @@
+// eslint-disable-next-line @typescript-eslint/ban-ts-comment
+// @ts-ignore
import { WorkflowRun } from '@/workflow/types/Workflow';
+import { StepStatus } from 'twenty-shared/workflow';
-export const mockWorkflowRunFailedStepId =
- 'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30';
-
-export const oneFailedWorkflowRunQueryResult = {
+export const oneSucceededWorkflowRunQueryResult = {
workflowRun: {
__typename: 'WorkflowRun',
context: {
trigger: {
userId: '20202020-9e3b-46d4-a556-88b9ddc2b034',
- recordId: 'd7d081c7-6a04-4d62-abbb-86de750ce2ae',
+ recordId: '6bba55b1-6be2-49d3-adcd-470a56547c73',
properties: {
after: {
- id: 'd7d081c7-6a04-4d62-abbb-86de750ce2ae',
+ id: '6bba55b1-6be2-49d3-adcd-470a56547c73',
name: '',
xLink: {
primaryLinkUrl: '',
secondaryLinks: [],
primaryLinkLabel: '',
},
+ people: [],
address: {
addressLat: null,
addressLng: null,
@@ -30,8 +31,8 @@ export const oneFailedWorkflowRunQueryResult = {
addressPostcode: '',
},
tagline: '',
- position: -1,
- createdAt: '2025-03-06T11:52:42.765Z',
+ position: -3,
+ createdAt: '2025-03-06T12:15:43.288Z',
createdBy: {
name: 'Tim Apple',
source: 'MANUAL',
@@ -41,7 +42,7 @@ export const oneFailedWorkflowRunQueryResult = {
deletedAt: null,
employees: null,
favorites: [],
- updatedAt: '2025-03-06T11:52:42.765Z',
+ updatedAt: '2025-03-06T12:15:43.288Z',
domainName: {
primaryLinkUrl: '',
secondaryLinks: [],
@@ -2829,12 +2830,58 @@ export const oneFailedWorkflowRunQueryResult = {
'212a171a-f887-4213-8892-e39c2a3ecc30': {
userId: ['20202020', '9e3b', '46d4', 'a556', '88b9ddc2b034'],
},
+ '753b124e-f427-44a4-ab08-bacfe9c2f746': {
+ id: '0455ca41-bae1-4a3a-968c-b268a4e809bb',
+ body: null,
+ title: 'Proposal for ',
+ bodyV2: {
+ markdown: '',
+ blocknote: '',
+ },
+ position: 0,
+ createdAt: '2025-03-06T12:15:43.371Z',
+ createdBy: {
+ name: 'Workflow',
+ source: 'WORKFLOW',
+ context: {},
+ workspaceMemberId: null,
+ },
+ deletedAt: null,
+ updatedAt: '2025-03-06T12:15:43.371Z',
+ searchVector: "'for':2 'proposal':1",
+ },
+ 'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30': {
+ date: '2025-03-06T12:15:43.358Z',
+ },
+ 'd4a73172-3156-45bf-bc49-9358fbab2907': {
+ id: 'f76b6058-2c8b-4bfa-86c1-4a4d39de3ee9',
+ name: 'Opportunity with ',
+ stage: 'NEW',
+ amount: {
+ amountMicros: null,
+ currencyCode: '',
+ },
+ position: 0,
+ closeDate: null,
+ companyId: null,
+ createdAt: '2025-03-06T12:15:43.386Z',
+ createdBy: {
+ name: 'Workflow',
+ source: 'WORKFLOW',
+ context: {},
+ workspaceMemberId: null,
+ },
+ deletedAt: null,
+ updatedAt: '2025-03-06T12:15:43.386Z',
+ searchVector: "'opportunity':1 'with':2",
+ pointOfContactId: null,
+ },
},
- createdAt: '2025-03-06T11:52:42.801Z',
+ createdAt: '2025-03-06T12:15:43.316Z',
deletedAt: null,
- endedAt: '2025-03-06T11:52:42.910Z',
- id: '7473ccf8-303f-4588-8917-513b9b21c5c0',
- name: 'Execution of v2',
+ endedAt: '2025-03-06T12:15:43.404Z',
+ id: 'cb13fb82-82e5-46b6-8a80-0f8251ac98ff',
+ name: 'Execution of v5',
output: {
flow: {
steps: [
@@ -2879,7 +2926,7 @@ export const oneFailedWorkflowRunQueryResult = {
input: {
serverlessFunctionId: '605efcda-6689-43b3-b24c-2eb76948f523',
serverlessFunctionInput: {},
- serverlessFunctionVersion: '1',
+ serverlessFunctionVersion: '2',
},
outputSchema: {
link: {
@@ -4380,4807 +4427,410 @@ export const oneFailedWorkflowRunQueryResult = {
},
},
},
- error: 'fn(...).then is not a function',
stepsOutput: {
'212a171a-f887-4213-8892-e39c2a3ecc30': {
result: {
userId: ['20202020', '9e3b', '46d4', 'a556', '88b9ddc2b034'],
},
},
+ '753b124e-f427-44a4-ab08-bacfe9c2f746': {
+ result: {
+ id: '0455ca41-bae1-4a3a-968c-b268a4e809bb',
+ body: null,
+ title: 'Proposal for ',
+ bodyV2: {
+ markdown: '',
+ blocknote: '',
+ },
+ position: 0,
+ createdAt: '2025-03-06T12:15:43.371Z',
+ createdBy: {
+ name: 'Workflow',
+ source: 'WORKFLOW',
+ context: {},
+ workspaceMemberId: null,
+ },
+ deletedAt: null,
+ updatedAt: '2025-03-06T12:15:43.371Z',
+ searchVector: "'for':2 'proposal':1",
+ },
+ },
'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30': {
- error: 'fn(...).then is not a function',
+ result: {
+ date: '2025-03-06T12:15:43.358Z',
+ },
},
- },
- },
- position: 0,
- startedAt: '2025-03-06T11:52:42.818Z',
- status: 'FAILED',
- updatedAt: '2025-03-06T11:52:42.911Z',
- workflowId: 'f355201d-b1b5-4467-94b9-2a9da4202979',
- workflowVersionId: 'f3a93101-bc3a-4b5e-9e42-22d0ef5db23b',
- createdBy: {
- __typename: 'Actor',
- source: 'WORKFLOW',
- workspaceMemberId: null,
- name: 'Test Workflow',
- context: {},
- },
- favorites: {
- __typename: 'FavoriteConnection',
- edges: [],
- },
- timelineActivities: {
- __typename: 'TimelineActivityConnection',
- edges: [],
- },
- workflowVersion: {
- __typename: 'WorkflowVersion',
- createdAt: '2025-03-06T11:46:56.265Z',
- deletedAt: null,
- id: 'f3a93101-bc3a-4b5e-9e42-22d0ef5db23b',
- name: 'v2',
- position: 0,
- status: 'ACTIVE',
- steps: [
- {
- id: '212a171a-f887-4213-8892-e39c2a3ecc30',
- name: 'Code - Serverless Function',
- type: 'CODE',
- valid: false,
- settings: {
- input: {
- serverlessFunctionId: 'e031ae6a-5b9e-496b-9a98-ba015f7b5508',
- serverlessFunctionInput: {
- userId: '{{trigger.userId}}',
- },
- serverlessFunctionVersion: '1',
- },
- outputSchema: {
- link: {
- tab: 'test',
- icon: 'IconVariable',
- label: 'Generate Function Output',
- isLeaf: true,
- },
- _outputSchemaType: 'LINK',
+ 'd4a73172-3156-45bf-bc49-9358fbab2907': {
+ result: {
+ id: 'f76b6058-2c8b-4bfa-86c1-4a4d39de3ee9',
+ name: 'Opportunity with ',
+ stage: 'NEW',
+ amount: {
+ amountMicros: null,
+ currencyCode: '',
},
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
- },
- continueOnFailure: {
- value: false,
- },
+ position: 0,
+ closeDate: null,
+ companyId: null,
+ createdAt: '2025-03-06T12:15:43.386Z',
+ createdBy: {
+ name: 'Workflow',
+ source: 'WORKFLOW',
+ context: {},
+ workspaceMemberId: null,
},
+ deletedAt: null,
+ updatedAt: '2025-03-06T12:15:43.386Z',
+ searchVector: "'opportunity':1 'with':2",
+ pointOfContactId: null,
},
},
- {
- id: 'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30',
- name: 'Code - Serverless Function',
- type: 'CODE',
- valid: false,
- settings: {
- input: {
- serverlessFunctionId: '605efcda-6689-43b3-b24c-2eb76948f523',
- serverlessFunctionInput: {},
- serverlessFunctionVersion: '1',
- },
- outputSchema: {
- link: {
- tab: 'test',
- icon: 'IconVariable',
- label: 'Generate Function Output',
- isLeaf: true,
+ },
+ },
+ state: {
+ flow: {
+ steps: [
+ {
+ id: '212a171a-f887-4213-8892-e39c2a3ecc30',
+ name: 'Code - Serverless Function',
+ type: 'CODE',
+ valid: false,
+ settings: {
+ input: {
+ serverlessFunctionId: 'e031ae6a-5b9e-496b-9a98-ba015f7b5508',
+ serverlessFunctionInput: {
+ userId: '{{trigger.userId}}',
+ },
+ serverlessFunctionVersion: '1',
},
- _outputSchemaType: 'LINK',
- },
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
+ outputSchema: {
+ link: {
+ tab: 'test',
+ icon: 'IconVariable',
+ label: 'Generate Function Output',
+ isLeaf: true,
+ },
+ _outputSchemaType: 'LINK',
},
- continueOnFailure: {
- value: false,
+ errorHandlingOptions: {
+ retryOnFailure: {
+ value: false,
+ },
+ continueOnFailure: {
+ value: false,
+ },
},
},
},
- },
- {
- id: '753b124e-f427-44a4-ab08-bacfe9c2f746',
- name: 'Create Record',
- type: 'CREATE_RECORD',
- valid: false,
- settings: {
- input: {
- objectName: 'note',
- objectRecord: {
- title: 'Proposal for {{trigger.properties.after.name}}',
+ {
+ id: 'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30',
+ name: 'Code - Serverless Function',
+ type: 'CODE',
+ valid: false,
+ settings: {
+ input: {
+ serverlessFunctionId: '605efcda-6689-43b3-b24c-2eb76948f523',
+ serverlessFunctionInput: {},
+ serverlessFunctionVersion: '2',
},
- },
- outputSchema: {
- fields: {
- id: {
- icon: 'Icon123',
- type: 'UUID',
- label: 'Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- body: {
- icon: 'IconFilePencil',
- type: 'RICH_TEXT',
- label: 'Body (deprecated)',
- value: 'My rich text',
+ outputSchema: {
+ link: {
+ tab: 'test',
+ icon: 'IconVariable',
+ label: 'Generate Function Output',
isLeaf: true,
},
- title: {
- icon: 'IconNotes',
- type: 'TEXT',
- label: 'Title',
- value: 'My text',
- isLeaf: true,
+ _outputSchemaType: 'LINK',
+ },
+ errorHandlingOptions: {
+ retryOnFailure: {
+ value: false,
},
- bodyV2: {
- icon: 'IconFilePencil',
- label: 'Body',
- value: {
- markdown: {
- type: 'TEXT',
- label: ' Markdown',
- value: 'My text',
- isLeaf: true,
- },
- blocknote: {
- type: 'TEXT',
- label: ' Blocknote',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
+ continueOnFailure: {
+ value: false,
},
- createdAt: {
- icon: 'IconCalendar',
- type: 'DATE_TIME',
- label: 'Creation date',
- value: '01/23/2025 15:16',
- isLeaf: true,
+ },
+ },
+ },
+ {
+ id: '753b124e-f427-44a4-ab08-bacfe9c2f746',
+ name: 'Create Record',
+ type: 'CREATE_RECORD',
+ valid: false,
+ settings: {
+ input: {
+ objectName: 'note',
+ objectRecord: {
+ title: 'Proposal for {{trigger.properties.after.name}}',
},
- createdBy: {
- icon: 'IconCreativeCommonsSa',
- label: 'Created by',
- value: {
- name: {
- type: 'TEXT',
- label: ' Name',
- value: 'My text',
- isLeaf: true,
- },
- source: {
- type: 'SELECT',
- label: ' Source',
- value: null,
- isLeaf: true,
- },
- context: {
- type: 'RAW_JSON',
- label: ' Context',
- value: null,
- isLeaf: true,
+ },
+ outputSchema: {
+ fields: {
+ id: {
+ icon: 'Icon123',
+ type: 'UUID',
+ label: 'Id',
+ value: '123e4567-e89b-12d3-a456-426614174000',
+ isLeaf: true,
+ },
+ body: {
+ icon: 'IconFilePencil',
+ type: 'RICH_TEXT',
+ label: 'Body (deprecated)',
+ value: 'My rich text',
+ isLeaf: true,
+ },
+ title: {
+ icon: 'IconNotes',
+ type: 'TEXT',
+ label: 'Title',
+ value: 'My text',
+ isLeaf: true,
+ },
+ bodyV2: {
+ icon: 'IconFilePencil',
+ label: 'Body',
+ value: {
+ markdown: {
+ type: 'TEXT',
+ label: ' Markdown',
+ value: 'My text',
+ isLeaf: true,
+ },
+ blocknote: {
+ type: 'TEXT',
+ label: ' Blocknote',
+ value: 'My text',
+ isLeaf: true,
+ },
},
- workspaceMemberId: {
- type: 'UUID',
- label: ' Workspace Member Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
+ isLeaf: false,
+ },
+ createdAt: {
+ icon: 'IconCalendar',
+ type: 'DATE_TIME',
+ label: 'Creation date',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
+ },
+ createdBy: {
+ icon: 'IconCreativeCommonsSa',
+ label: 'Created by',
+ value: {
+ name: {
+ type: 'TEXT',
+ label: ' Name',
+ value: 'My text',
+ isLeaf: true,
+ },
+ source: {
+ type: 'SELECT',
+ label: ' Source',
+ value: null,
+ isLeaf: true,
+ },
+ context: {
+ type: 'RAW_JSON',
+ label: ' Context',
+ value: null,
+ isLeaf: true,
+ },
+ workspaceMemberId: {
+ type: 'UUID',
+ label: ' Workspace Member Id',
+ value: '123e4567-e89b-12d3-a456-426614174000',
+ isLeaf: true,
+ },
},
+ isLeaf: false,
+ },
+ deletedAt: {
+ icon: 'IconCalendarMinus',
+ type: 'DATE_TIME',
+ label: 'Deleted at',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
+ },
+ updatedAt: {
+ icon: 'IconCalendarClock',
+ type: 'DATE_TIME',
+ label: 'Last update',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
},
- isLeaf: false,
- },
- deletedAt: {
- icon: 'IconCalendarMinus',
- type: 'DATE_TIME',
- label: 'Deleted at',
- value: '01/23/2025 15:16',
- isLeaf: true,
},
- updatedAt: {
- icon: 'IconCalendarClock',
- type: 'DATE_TIME',
- label: 'Last update',
- value: '01/23/2025 15:16',
+ object: {
+ icon: 'IconNotes',
+ label: 'Note',
+ value: 'A note',
isLeaf: true,
+ fieldIdName: 'id',
+ nameSingular: 'note',
},
+ _outputSchemaType: 'RECORD',
},
- object: {
- icon: 'IconNotes',
- label: 'Note',
- value: 'A note',
- isLeaf: true,
- fieldIdName: 'id',
- nameSingular: 'note',
- },
- _outputSchemaType: 'RECORD',
- },
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
- },
- continueOnFailure: {
- value: false,
+ errorHandlingOptions: {
+ retryOnFailure: {
+ value: false,
+ },
+ continueOnFailure: {
+ value: false,
+ },
},
},
},
- },
- {
- id: 'd4a73172-3156-45bf-bc49-9358fbab2907',
- name: 'Create Record',
- type: 'CREATE_RECORD',
- valid: false,
- settings: {
- input: {
- objectName: 'opportunity',
- objectRecord: {
- name: 'Opportunity with {{trigger.properties.after.name}}',
- stage: 'NEW',
- },
- },
- outputSchema: {
- fields: {
- id: {
- icon: 'Icon123',
- type: 'UUID',
- label: 'Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- name: {
- icon: 'IconTargetArrow',
- type: 'TEXT',
- label: 'Name',
- value: 'My text',
- isLeaf: true,
+ {
+ id: 'd4a73172-3156-45bf-bc49-9358fbab2907',
+ name: 'Create Record',
+ type: 'CREATE_RECORD',
+ valid: false,
+ settings: {
+ input: {
+ objectName: 'opportunity',
+ objectRecord: {
+ name: 'Opportunity with {{trigger.properties.after.name}}',
+ stage: 'NEW',
},
- stage: {
- icon: 'IconProgressCheck',
- type: 'SELECT',
- label: 'Stage',
- value: null,
- isLeaf: true,
- },
- amount: {
- icon: 'IconCurrencyDollar',
- label: 'Amount',
- value: {
- amountMicros: {
- type: 'NUMERIC',
- label: ' Amount Micros',
- value: null,
- isLeaf: true,
- },
- currencyCode: {
- type: 'TEXT',
- label: ' Currency Code',
- value: 'My text',
- isLeaf: true,
- },
+ },
+ outputSchema: {
+ fields: {
+ id: {
+ icon: 'Icon123',
+ type: 'UUID',
+ label: 'Id',
+ value: '123e4567-e89b-12d3-a456-426614174000',
+ isLeaf: true,
},
- isLeaf: false,
- },
- closeDate: {
- icon: 'IconCalendarEvent',
- type: 'DATE_TIME',
- label: 'Close date',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- createdAt: {
- icon: 'IconCalendar',
- type: 'DATE_TIME',
- label: 'Creation date',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- createdBy: {
- icon: 'IconCreativeCommonsSa',
- label: 'Created by',
- value: {
- name: {
- type: 'TEXT',
- label: ' Name',
- value: 'My text',
- isLeaf: true,
- },
- source: {
- type: 'SELECT',
- label: ' Source',
- value: null,
- isLeaf: true,
- },
- context: {
- type: 'RAW_JSON',
- label: ' Context',
- value: null,
- isLeaf: true,
+ name: {
+ icon: 'IconTargetArrow',
+ type: 'TEXT',
+ label: 'Name',
+ value: 'My text',
+ isLeaf: true,
+ },
+ stage: {
+ icon: 'IconProgressCheck',
+ type: 'SELECT',
+ label: 'Stage',
+ value: null,
+ isLeaf: true,
+ },
+ amount: {
+ icon: 'IconCurrencyDollar',
+ label: 'Amount',
+ value: {
+ amountMicros: {
+ type: 'NUMERIC',
+ label: ' Amount Micros',
+ value: null,
+ isLeaf: true,
+ },
+ currencyCode: {
+ type: 'TEXT',
+ label: ' Currency Code',
+ value: 'My text',
+ isLeaf: true,
+ },
},
- workspaceMemberId: {
- type: 'UUID',
- label: ' Workspace Member Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
+ isLeaf: false,
+ },
+ closeDate: {
+ icon: 'IconCalendarEvent',
+ type: 'DATE_TIME',
+ label: 'Close date',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
+ },
+ createdAt: {
+ icon: 'IconCalendar',
+ type: 'DATE_TIME',
+ label: 'Creation date',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
+ },
+ createdBy: {
+ icon: 'IconCreativeCommonsSa',
+ label: 'Created by',
+ value: {
+ name: {
+ type: 'TEXT',
+ label: ' Name',
+ value: 'My text',
+ isLeaf: true,
+ },
+ source: {
+ type: 'SELECT',
+ label: ' Source',
+ value: null,
+ isLeaf: true,
+ },
+ context: {
+ type: 'RAW_JSON',
+ label: ' Context',
+ value: null,
+ isLeaf: true,
+ },
+ workspaceMemberId: {
+ type: 'UUID',
+ label: ' Workspace Member Id',
+ value: '123e4567-e89b-12d3-a456-426614174000',
+ isLeaf: true,
+ },
},
+ isLeaf: false,
+ },
+ deletedAt: {
+ icon: 'IconCalendarMinus',
+ type: 'DATE_TIME',
+ label: 'Deleted at',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
+ },
+ updatedAt: {
+ icon: 'IconCalendarClock',
+ type: 'DATE_TIME',
+ label: 'Last update',
+ value: '01/23/2025 15:16',
+ isLeaf: true,
},
- isLeaf: false,
- },
- deletedAt: {
- icon: 'IconCalendarMinus',
- type: 'DATE_TIME',
- label: 'Deleted at',
- value: '01/23/2025 15:16',
- isLeaf: true,
},
- updatedAt: {
- icon: 'IconCalendarClock',
- type: 'DATE_TIME',
- label: 'Last update',
- value: '01/23/2025 15:16',
+ object: {
+ icon: 'IconTargetArrow',
+ label: 'Opportunity',
+ value: 'An opportunity',
isLeaf: true,
+ fieldIdName: 'id',
+ nameSingular: 'opportunity',
},
+ _outputSchemaType: 'RECORD',
},
- object: {
- icon: 'IconTargetArrow',
- label: 'Opportunity',
- value: 'An opportunity',
- isLeaf: true,
- fieldIdName: 'id',
- nameSingular: 'opportunity',
+ errorHandlingOptions: {
+ retryOnFailure: {
+ value: false,
+ },
+ continueOnFailure: {
+ value: false,
+ },
},
- _outputSchemaType: 'RECORD',
},
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
+ },
+ ],
+ trigger: {
+ type: 'DATABASE_EVENT',
+ settings: {
+ eventName: 'company.created',
+ outputSchema: {
+ userId: {
+ type: 'string',
+ label: 'User ID',
+ value: '977a8fb6-1b97-4203-a64b-5d3e12f8587c',
+ isLeaf: true,
},
- continueOnFailure: {
- value: false,
- },
- },
- },
- },
- ],
- trigger: {
- type: 'DATABASE_EVENT',
- settings: {
- eventName: 'company.created',
- outputSchema: {
- userId: {
- type: 'string',
- label: 'User ID',
- value: '977a8fb6-1b97-4203-a64b-5d3e12f8587c',
- isLeaf: true,
- },
- recordId: {
- type: 'string',
- label: 'Record ID',
- value: '80d61929-1860-4f37-a639-b406a67f7800',
- isLeaf: true,
- },
- objectMetadata: {
- label: 'Object Metadata',
- value: {
- id: {
- label: ' Id',
- value: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLeaf: true,
- },
- icon: {
- label: ' Icon',
- value: 'IconBuildingSkyscraper',
- isLeaf: true,
- },
- fields: {
- label: ' Fields',
- value: [
- {
- id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
- icon: 'IconBuildingSkyscraper',
- name: 'name',
- type: 'TEXT',
- label: 'Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
- description: 'The company name',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
- icon: 'IconLink',
- name: 'domainName',
- type: 'LINKS',
- label: 'Domain Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: true,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
- description:
- 'The company website URL. We use this url to fetch the company icon',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
- icon: 'IconUsers',
- name: 'employees',
- type: 'NUMBER',
- label: 'Employees',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-8965-464a-8a75-74bafc152a0b',
- description: 'Number of employees in the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
- icon: 'IconBrandLinkedin',
- name: 'linkedinLink',
- type: 'LINKS',
- label: 'Linkedin',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
- description: 'The company Linkedin account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '5fc216dc-7af4-4927-a026-0e5144afa436',
- icon: 'IconBrandX',
- name: 'xLink',
- type: 'LINKS',
- label: 'X',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
- description: 'The company Twitter/X account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'fba56220-3f40-4569-a500-35a4a312e473',
- icon: 'IconMoneybag',
- name: 'annualRecurringRevenue',
- type: 'CURRENCY',
- label: 'ARR',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-602a-495c-9776-f5d5b11d227b',
- description:
- 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- amountMicros: null,
- currencyCode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
- icon: 'IconMap',
- name: 'address',
- type: 'ADDRESS',
- label: 'Address',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
- description: 'Address of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- addressLat: null,
- addressLng: null,
- addressCity: "''",
- addressState: "''",
- addressCountry: "''",
- addressStreet1: "''",
- addressStreet2: "''",
- addressPostcode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
- icon: 'IconTarget',
- name: 'idealCustomerProfile',
- type: 'BOOLEAN',
- label: 'ICP',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
- description:
- 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
- icon: 'IconHierarchy2',
- name: 'position',
- type: 'POSITION',
- label: 'Position',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-9b4e-462b-991d-a0ee33326454',
- description: 'Company record position',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 0,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '943f218e-6061-4f61-ac3a-298ac14cef41',
- icon: 'IconCreativeCommonsSa',
- name: 'createdBy',
- type: 'ACTOR',
- label: 'Created by',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-fabc-451d-ab7d-412170916baa',
- description: 'The creator of the record',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- name: "'System'",
- source: "'MANUAL'",
- context: {},
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
- icon: 'IconUser',
- name: 'searchVector',
- type: 'TS_VECTOR',
- label: 'Search vector',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
- description: 'Field used for full-text search',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
- icon: 'Icon123',
- name: 'id',
- type: 'UUID',
- label: 'Id',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
- description: 'Id',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'uuid',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
- icon: 'IconCalendar',
- name: 'createdAt',
- type: 'DATE_TIME',
- label: 'Creation date',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-66ac-4502-9975-e4d959c50311',
- description: 'Creation date',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '39526b16-7d21-4a91-a70c-bca108b27989',
- icon: 'IconCalendarClock',
- name: 'updatedAt',
- type: 'DATE_TIME',
- label: 'Last update',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-d767-4622-bdcf-d8a084834d86',
- description: 'Last time the record was changed',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
- icon: 'IconCalendarMinus',
- name: 'deletedAt',
- type: 'DATE_TIME',
- label: 'Deleted at',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
- description: 'Date when the record was deleted',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '11a04849-150b-4af0-9332-b4a9ba693b17',
- icon: 'IconUsers',
- name: 'people',
- type: 'RELATION',
- label: 'People',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
- description: 'People linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
- icon: 'IconUserCircle',
- name: 'accountOwnerId',
- type: 'UUID',
- label: 'Account Owner id (foreign key)',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cce0-424e-8028-91f50eb9c768',
- description:
- 'Your team member responsible for managing the company account id foreign key',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- icon: 'IconUserCircle',
- name: 'accountOwner',
- type: 'RELATION',
- label: 'Account Owner',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
- description:
- 'Your team member responsible for managing the company account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- icon: 'IconCheckbox',
- name: 'taskTargets',
- type: 'RELATION',
- label: 'Tasks',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
- description: 'Tasks tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- icon: 'IconNotes',
- name: 'noteTargets',
- type: 'RELATION',
- label: 'Notes',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
- description: 'Notes tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- icon: 'IconTargetArrow',
- name: 'opportunities',
- type: 'RELATION',
- label: 'Opportunities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
- description: 'Opportunities linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- icon: 'IconHeart',
- name: 'favorites',
- type: 'RELATION',
- label: 'Favorites',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-4d1d-41ac-b13b-621631298d55',
- description: 'Favorites linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- icon: 'IconFileImport',
- name: 'attachments',
- type: 'RELATION',
- label: 'Attachments',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
- description: 'Attachments linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '038ca1af-7f15-460d-b111-b71062a8a6be',
- icon: 'IconIconTimelineEvent',
- name: 'timelineActivities',
- type: 'RELATION',
- label: 'Timeline Activities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
- description: 'Timeline Activities linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
- icon: 'IconAdCircle',
- name: 'tagline',
- type: 'TEXT',
- label: 'Tagline',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.009Z',
- updatedAt: '2025-03-05T15:41:12.009Z',
- isNullable: false,
- standardId: null,
- description: "Company's Tagline",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
- icon: 'IconVideo',
- name: 'introVideo',
- type: 'LINKS',
- label: 'Intro Video',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.011Z',
- updatedAt: '2025-03-05T15:41:12.011Z',
- isNullable: true,
- standardId: null,
- description: "Company's Intro Video",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
- icon: 'IconHome',
- name: 'workPolicy',
- type: 'MULTI_SELECT',
- label: 'Work Policy',
- options: [
- {
- id: '4554330a-c3db-4042-b941-c2e299734d12',
- color: 'green',
- label: 'On-Site',
- value: 'ON_SITE',
- position: 0,
- },
- {
- id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
- color: 'turquoise',
- label: 'Hybrid',
- value: 'HYBRID',
- position: 1,
- },
- {
- id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
- color: 'sky',
- label: 'Remote Work',
- value: 'REMOTE_WORK',
- position: 2,
- },
- ],
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.013Z',
- updatedAt: '2025-03-05T15:41:12.013Z',
- isNullable: true,
- standardId: null,
- description: "Company's Work Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
- icon: 'IconBrandVisa',
- name: 'visaSponsorship',
- type: 'BOOLEAN',
- label: 'Visa Sponsorship',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.014Z',
- updatedAt: '2025-03-05T15:41:12.014Z',
- isNullable: true,
- standardId: null,
- description: "Company's Visa Sponsorship Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- ],
- isLeaf: true,
- },
- isActive: {
- label: ' Is Active',
- value: true,
- isLeaf: true,
- },
- isCustom: {
- label: ' Is Custom',
- value: false,
- isLeaf: true,
- },
- isRemote: {
- label: ' Is Remote',
- value: false,
- isLeaf: true,
- },
- isSystem: {
- label: ' Is System',
- value: false,
- isLeaf: true,
- },
- shortcut: {
- label: ' Shortcut',
- value: 'C',
- isLeaf: true,
- },
- createdAt: {
- label: ' Created At',
- value: '2025-03-05T15:41:09.390Z',
- isLeaf: true,
- },
- updatedAt: {
- label: ' Updated At',
- value: '2025-03-05T15:41:09.390Z',
- isLeaf: true,
- },
- namePlural: {
- label: ' Name Plural',
- value: 'companies',
- isLeaf: true,
- },
- standardId: {
- label: ' Standard Id',
- value: '20202020-b374-4779-a561-80086cb2e17f',
- isLeaf: true,
- },
- description: {
- label: ' Description',
- value: 'A company',
- isLeaf: true,
- },
- labelPlural: {
- label: ' Label Plural',
- value: 'Companies',
- isLeaf: true,
- },
- workspaceId: {
- label: ' Workspace Id',
- value: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- isLeaf: true,
- },
- dataSourceId: {
- label: ' Data Source Id',
- value: 'f20df2e6-420e-40e0-a4ca-68846bbe6c92',
- isLeaf: true,
- },
- isSearchable: {
- label: ' Is Searchable',
- value: true,
- isLeaf: true,
- },
- nameSingular: {
- label: ' Name Singular',
- value: 'company',
- isLeaf: true,
- },
- isAuditLogged: {
- label: ' Is Audit Logged',
- value: true,
- isLeaf: true,
- },
- labelSingular: {
- label: ' Label Singular',
- value: 'Company',
- isLeaf: true,
- },
- targetTableName: {
- label: ' Target Table Name',
- value: 'DEPRECATED',
- isLeaf: true,
- },
- duplicateCriteria: {
- label: ' Duplicate Criteria',
- value: [['name'], ['domainNamePrimaryLinkUrl']],
- isLeaf: true,
- },
- isLabelSyncedWithName: {
- label: ' Is Label Synced With Name',
- value: false,
- isLeaf: true,
- },
- imageIdentifierFieldMetadataId: {
- label: ' Image Identifier Field Metadata Id',
- value: null,
- isLeaf: true,
- },
- labelIdentifierFieldMetadataId: {
- label: ' Label Identifier Field Metadata Id',
- value: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- 'properties.after': {
- label: 'Record Fields',
- value: {
- fields: {
- id: {
- icon: 'Icon123',
- type: 'UUID',
- label: 'Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- name: {
- icon: 'IconBuildingSkyscraper',
- type: 'TEXT',
- label: 'Name',
- value: 'My text',
- isLeaf: true,
- },
- xLink: {
- icon: 'IconBrandX',
- label: 'X',
- value: {
- primaryLinkUrl: {
- type: 'TEXT',
- label: ' Primary Link Url',
- value: 'My text',
- isLeaf: true,
- },
- secondaryLinks: {
- type: 'RAW_JSON',
- label: ' Secondary Links',
- value: null,
- isLeaf: true,
- },
- primaryLinkLabel: {
- type: 'TEXT',
- label: ' Primary Link Label',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- address: {
- icon: 'IconMap',
- label: 'Address',
- value: {
- addressLat: {
- type: 'NUMERIC',
- label: ' Address Lat',
- value: null,
- isLeaf: true,
- },
- addressLng: {
- type: 'NUMERIC',
- label: ' Address Lng',
- value: null,
- isLeaf: true,
- },
- addressCity: {
- type: 'TEXT',
- label: ' Address City',
- value: 'My text',
- isLeaf: true,
- },
- addressState: {
- type: 'TEXT',
- label: ' Address State',
- value: 'My text',
- isLeaf: true,
- },
- addressCountry: {
- type: 'TEXT',
- label: ' Address Country',
- value: 'My text',
- isLeaf: true,
- },
- addressStreet1: {
- type: 'TEXT',
- label: ' Address Street1',
- value: 'My text',
- isLeaf: true,
- },
- addressStreet2: {
- type: 'TEXT',
- label: ' Address Street2',
- value: 'My text',
- isLeaf: true,
- },
- addressPostcode: {
- type: 'TEXT',
- label: ' Address Postcode',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- tagline: {
- icon: 'IconAdCircle',
- type: 'TEXT',
- label: 'Tagline',
- value: 'My text',
- isLeaf: true,
- },
- createdAt: {
- icon: 'IconCalendar',
- type: 'DATE_TIME',
- label: 'Creation date',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- createdBy: {
- icon: 'IconCreativeCommonsSa',
- label: 'Created by',
- value: {
- name: {
- type: 'TEXT',
- label: ' Name',
- value: 'My text',
- isLeaf: true,
- },
- source: {
- type: 'SELECT',
- label: ' Source',
- value: null,
- isLeaf: true,
- },
- context: {
- type: 'RAW_JSON',
- label: ' Context',
- value: null,
- isLeaf: true,
- },
- workspaceMemberId: {
- type: 'UUID',
- label: ' Workspace Member Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- deletedAt: {
- icon: 'IconCalendarMinus',
- type: 'DATE_TIME',
- label: 'Deleted at',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- employees: {
- icon: 'IconUsers',
- type: 'NUMBER',
- label: 'Employees',
- value: 20,
- isLeaf: true,
- },
- updatedAt: {
- icon: 'IconCalendarClock',
- type: 'DATE_TIME',
- label: 'Last update',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- domainName: {
- icon: 'IconLink',
- label: 'Domain Name',
- value: {
- primaryLinkUrl: {
- type: 'TEXT',
- label: ' Primary Link Url',
- value: 'My text',
- isLeaf: true,
- },
- secondaryLinks: {
- type: 'RAW_JSON',
- label: ' Secondary Links',
- value: null,
- isLeaf: true,
- },
- primaryLinkLabel: {
- type: 'TEXT',
- label: ' Primary Link Label',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- introVideo: {
- icon: 'IconVideo',
- label: 'Intro Video',
- value: {
- primaryLinkUrl: {
- type: 'TEXT',
- label: ' Primary Link Url',
- value: 'My text',
- isLeaf: true,
- },
- secondaryLinks: {
- type: 'RAW_JSON',
- label: ' Secondary Links',
- value: null,
- isLeaf: true,
- },
- primaryLinkLabel: {
- type: 'TEXT',
- label: ' Primary Link Label',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- workPolicy: {
- icon: 'IconHome',
- type: 'MULTI_SELECT',
- label: 'Work Policy',
- value: null,
- isLeaf: true,
- },
- linkedinLink: {
- icon: 'IconBrandLinkedin',
- label: 'Linkedin',
- value: {
- primaryLinkUrl: {
- type: 'TEXT',
- label: ' Primary Link Url',
- value: 'My text',
- isLeaf: true,
- },
- secondaryLinks: {
- type: 'RAW_JSON',
- label: ' Secondary Links',
- value: null,
- isLeaf: true,
- },
- primaryLinkLabel: {
- type: 'TEXT',
- label: ' Primary Link Label',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- visaSponsorship: {
- icon: 'IconBrandVisa',
- type: 'BOOLEAN',
- label: 'Visa Sponsorship',
- value: true,
- isLeaf: true,
- },
- idealCustomerProfile: {
- icon: 'IconTarget',
- type: 'BOOLEAN',
- label: 'ICP',
- value: true,
- isLeaf: true,
- },
- annualRecurringRevenue: {
- icon: 'IconMoneybag',
- label: 'ARR',
- value: {
- amountMicros: {
- type: 'NUMERIC',
- label: ' Amount Micros',
- value: null,
- isLeaf: true,
- },
- currencyCode: {
- type: 'TEXT',
- label: ' Currency Code',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- },
- object: {
- icon: 'IconBuildingSkyscraper',
- label: 'Company',
- value: 'A company',
- isLeaf: true,
- fieldIdName: 'id',
- nameSingular: 'company',
- },
- _outputSchemaType: 'RECORD',
- },
- isLeaf: false,
- },
- workspaceMemberId: {
- type: 'string',
- label: 'Workspace Member ID',
- value: '53562519-b9e8-44f1-8dd1-e247cc7ef584',
- isLeaf: true,
- },
- },
- },
- },
- updatedAt: '2025-03-06T11:52:37.081Z',
- workflowId: 'f355201d-b1b5-4467-94b9-2a9da4202979',
- },
- workflow: {
- __typename: 'Workflow',
- createdAt: '2025-03-05T15:43:13.971Z',
- deletedAt: null,
- id: 'f355201d-b1b5-4467-94b9-2a9da4202979',
- lastPublishedVersionId: 'f3a93101-bc3a-4b5e-9e42-22d0ef5db23b',
- name: 'Test Workflow',
- position: 1,
- statuses: ['ACTIVE'],
- updatedAt: '2025-03-06T11:52:37.083Z',
- createdBy: {
- __typename: 'Actor',
- source: 'MANUAL',
- workspaceMemberId: '20202020-0687-4c41-b707-ed1bfca972a7',
- name: 'Tim Apple',
- context: {},
- },
- },
- },
-} satisfies { workflowRun: WorkflowRun };
-
-export const oneSucceededWorkflowRunQueryResult = {
- workflowRun: {
- __typename: 'WorkflowRun',
- context: {
- trigger: {
- userId: '20202020-9e3b-46d4-a556-88b9ddc2b034',
- recordId: '6bba55b1-6be2-49d3-adcd-470a56547c73',
- properties: {
- after: {
- id: '6bba55b1-6be2-49d3-adcd-470a56547c73',
- name: '',
- xLink: {
- primaryLinkUrl: '',
- secondaryLinks: [],
- primaryLinkLabel: '',
- },
- people: [],
- address: {
- addressLat: null,
- addressLng: null,
- addressCity: '',
- addressState: '',
- addressCountry: '',
- addressStreet1: '',
- addressStreet2: '',
- addressPostcode: '',
- },
- tagline: '',
- position: -3,
- createdAt: '2025-03-06T12:15:43.288Z',
- createdBy: {
- name: 'Tim Apple',
- source: 'MANUAL',
- context: {},
- workspaceMemberId: '20202020-0687-4c41-b707-ed1bfca972a7',
- },
- deletedAt: null,
- employees: null,
- favorites: [],
- updatedAt: '2025-03-06T12:15:43.288Z',
- domainName: {
- primaryLinkUrl: '',
- secondaryLinks: [],
- primaryLinkLabel: '',
- },
- introVideo: {
- primaryLinkUrl: '',
- secondaryLinks: [],
- primaryLinkLabel: '',
- },
- workPolicy: null,
- attachments: [],
- noteTargets: [],
- accountOwner: null,
- linkedinLink: {
- primaryLinkUrl: '',
- secondaryLinks: [],
- primaryLinkLabel: '',
- },
- searchVector: '',
- opportunities: [],
- accountOwnerId: null,
- visaSponsorship: false,
- idealCustomerProfile: false,
- annualRecurringRevenue: {
- amountMicros: null,
- currencyCode: '',
- },
- },
- before: null,
- },
- objectMetadata: {
- id: '685ac06e-2351-421c-97ac-0bf4595819b8',
- icon: 'IconBuildingSkyscraper',
- fields: [
- {
- id: '5fc216dc-7af4-4927-a026-0e5144afa436',
- icon: 'IconBrandX',
- name: 'xLink',
- type: 'LINKS',
- label: 'X',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
- description: 'The company Twitter/X account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'fba56220-3f40-4569-a500-35a4a312e473',
- icon: 'IconMoneybag',
- name: 'annualRecurringRevenue',
- type: 'CURRENCY',
- label: 'ARR',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-602a-495c-9776-f5d5b11d227b',
- description:
- 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- amountMicros: null,
- currencyCode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
- icon: 'IconMap',
- name: 'address',
- type: 'ADDRESS',
- label: 'Address',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
- description: 'Address of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- addressLat: null,
- addressLng: null,
- addressCity: "''",
- addressState: "''",
- addressCountry: "''",
- addressStreet1: "''",
- addressStreet2: "''",
- addressPostcode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
- icon: 'IconTarget',
- name: 'idealCustomerProfile',
- type: 'BOOLEAN',
- label: 'ICP',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
- description:
- 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
- icon: 'IconHierarchy2',
- name: 'position',
- type: 'POSITION',
- label: 'Position',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-9b4e-462b-991d-a0ee33326454',
- description: 'Company record position',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 0,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '943f218e-6061-4f61-ac3a-298ac14cef41',
- icon: 'IconCreativeCommonsSa',
- name: 'createdBy',
- type: 'ACTOR',
- label: 'Created by',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-fabc-451d-ab7d-412170916baa',
- description: 'The creator of the record',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- name: "'System'",
- source: "'MANUAL'",
- context: {},
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
- icon: 'IconUser',
- name: 'searchVector',
- type: 'TS_VECTOR',
- label: 'Search vector',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
- description: 'Field used for full-text search',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
- icon: 'Icon123',
- name: 'id',
- type: 'UUID',
- label: 'Id',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
- description: 'Id',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'uuid',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
- icon: 'IconCalendar',
- name: 'createdAt',
- type: 'DATE_TIME',
- label: 'Creation date',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-66ac-4502-9975-e4d959c50311',
- description: 'Creation date',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '39526b16-7d21-4a91-a70c-bca108b27989',
- icon: 'IconCalendarClock',
- name: 'updatedAt',
- type: 'DATE_TIME',
- label: 'Last update',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-d767-4622-bdcf-d8a084834d86',
- description: 'Last time the record was changed',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
- icon: 'IconCalendarMinus',
- name: 'deletedAt',
- type: 'DATE_TIME',
- label: 'Deleted at',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
- description: 'Date when the record was deleted',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '11a04849-150b-4af0-9332-b4a9ba693b17',
- icon: 'IconUsers',
- name: 'people',
- type: 'RELATION',
- label: 'People',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
- description: 'People linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '427d1095-8ac0-4854-bf85-2adff18b653e',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: 'd25fcd48-4b3f-4d6a-b1c0-4241d64502ac',
- toObjectMetadataId: '462ac013-3ba0-4e87-b6a3-07069c308ca3',
- fromFieldMetadataId: '11a04849-150b-4af0-9332-b4a9ba693b17',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
- icon: 'IconUserCircle',
- name: 'accountOwnerId',
- type: 'UUID',
- label: 'Account Owner id (foreign key)',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cce0-424e-8028-91f50eb9c768',
- description:
- 'Your team member responsible for managing the company account id foreign key',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- icon: 'IconUserCircle',
- name: 'accountOwner',
- type: 'RELATION',
- label: 'Account Owner',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
- description:
- 'Your team member responsible for managing the company account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: {
- id: '9ca11143-4ae4-4ed4-b636-158bc14d9513',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- toObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- fromFieldMetadataId: '58a6c41e-9ff0-4607-be3a-4356175b75dc',
- fromObjectMetadataId: '82dd61be-d849-41c2-b7c2-6a8ddb796e3e',
- },
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- icon: 'IconCheckbox',
- name: 'taskTargets',
- type: 'RELATION',
- label: 'Tasks',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
- description: 'Tasks tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '40a2f0d1-f420-46a2-a010-2489e7f27a9d',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: 'e3ee1c65-5ec0-4d68-aac4-6c66720240f0',
- toObjectMetadataId: '3e31c837-b0f0-4e8e-a1e3-28d3b12950f4',
- fromFieldMetadataId: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- icon: 'IconNotes',
- name: 'noteTargets',
- type: 'RELATION',
- label: 'Notes',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
- description: 'Notes tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: 'b240e206-e8ba-496a-9671-063ad48a447d',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '5c582b90-c1d4-4ebe-bd66-3cc94e4abd35',
- toObjectMetadataId: 'b58841d9-7545-41b7-bb84-75e821285933',
- fromFieldMetadataId: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- icon: 'IconTargetArrow',
- name: 'opportunities',
- type: 'RELATION',
- label: 'Opportunities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
- description: 'Opportunities linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '889b83fc-9a5e-414c-acb6-48e5aa029394',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: '2a12de2d-3c43-4108-bd0a-f52b053e2449',
- toObjectMetadataId: 'da77d279-8984-4cb1-987a-14e2b0501288',
- fromFieldMetadataId: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- icon: 'IconHeart',
- name: 'favorites',
- type: 'RELATION',
- label: 'Favorites',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-4d1d-41ac-b13b-621631298d55',
- description: 'Favorites linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '2163bf40-3b55-4bf9-bb59-968b8eda9114',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '3f34086f-ad66-4e1d-9d4b-f42cdc0f2040',
- toObjectMetadataId: '323f077c-138b-4243-bbf2-59a77252f3c5',
- fromFieldMetadataId: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- icon: 'IconFileImport',
- name: 'attachments',
- type: 'RELATION',
- label: 'Attachments',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
- description: 'Attachments linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: 'a2c6a4d7-fbda-4075-9fec-0a96ee07953a',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: 'e907c0a6-3e66-45a4-9922-8bc4d5bf5208',
- toObjectMetadataId: 'f85c3930-9919-4887-b950-2e0496597c58',
- fromFieldMetadataId: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '038ca1af-7f15-460d-b111-b71062a8a6be',
- icon: 'IconIconTimelineEvent',
- name: 'timelineActivities',
- type: 'RELATION',
- label: 'Timeline Activities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
- description: 'Timeline Activities linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '29a10f41-0265-4775-923f-0bbf548dc2ec',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '96896f47-cb02-4164-b3f2-c24d12b30e74',
- toObjectMetadataId: '1a41f4ba-7aad-4111-8035-961962702ebb',
- fromFieldMetadataId: '038ca1af-7f15-460d-b111-b71062a8a6be',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
- icon: 'IconAdCircle',
- name: 'tagline',
- type: 'TEXT',
- label: 'Tagline',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.009Z',
- updatedAt: '2025-03-05T15:41:12.009Z',
- isNullable: false,
- standardId: null,
- description: "Company's Tagline",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
- icon: 'IconVideo',
- name: 'introVideo',
- type: 'LINKS',
- label: 'Intro Video',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.011Z',
- updatedAt: '2025-03-05T15:41:12.011Z',
- isNullable: true,
- standardId: null,
- description: "Company's Intro Video",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
- icon: 'IconHome',
- name: 'workPolicy',
- type: 'MULTI_SELECT',
- label: 'Work Policy',
- options: [
- {
- id: '4554330a-c3db-4042-b941-c2e299734d12',
- color: 'green',
- label: 'On-Site',
- value: 'ON_SITE',
- position: 0,
- },
- {
- id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
- color: 'turquoise',
- label: 'Hybrid',
- value: 'HYBRID',
- position: 1,
- },
- {
- id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
- color: 'sky',
- label: 'Remote Work',
- value: 'REMOTE_WORK',
- position: 2,
- },
- ],
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.013Z',
- updatedAt: '2025-03-05T15:41:12.013Z',
- isNullable: true,
- standardId: null,
- description: "Company's Work Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
- icon: 'IconBrandVisa',
- name: 'visaSponsorship',
- type: 'BOOLEAN',
- label: 'Visa Sponsorship',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.014Z',
- updatedAt: '2025-03-05T15:41:12.014Z',
- isNullable: true,
- standardId: null,
- description: "Company's Visa Sponsorship Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
- icon: 'IconBuildingSkyscraper',
- name: 'name',
- type: 'TEXT',
- label: 'Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
- description: 'The company name',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
- icon: 'IconLink',
- name: 'domainName',
- type: 'LINKS',
- label: 'Domain Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: true,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
- description:
- 'The company website URL. We use this url to fetch the company icon',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
- icon: 'IconUsers',
- name: 'employees',
- type: 'NUMBER',
- label: 'Employees',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-8965-464a-8a75-74bafc152a0b',
- description: 'Number of employees in the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- {
- id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
- icon: 'IconBrandLinkedin',
- name: 'linkedinLink',
- type: 'LINKS',
- label: 'Linkedin',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
- description: 'The company Linkedin account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- ],
- isActive: true,
- isCustom: false,
- isRemote: false,
- isSystem: false,
- shortcut: 'C',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- fieldsById: {
- '038ca1af-7f15-460d-b111-b71062a8a6be': {
- id: '038ca1af-7f15-460d-b111-b71062a8a6be',
- icon: 'IconIconTimelineEvent',
- name: 'timelineActivities',
- type: 'RELATION',
- label: 'Timeline Activities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
- description: 'Timeline Activities linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '29a10f41-0265-4775-923f-0bbf548dc2ec',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '96896f47-cb02-4164-b3f2-c24d12b30e74',
- toObjectMetadataId: '1a41f4ba-7aad-4111-8035-961962702ebb',
- fromFieldMetadataId: '038ca1af-7f15-460d-b111-b71062a8a6be',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '0ae7a621-f443-47f7-b255-82d2e589ca21': {
- id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- icon: 'IconFileImport',
- name: 'attachments',
- type: 'RELATION',
- label: 'Attachments',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
- description: 'Attachments linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: 'a2c6a4d7-fbda-4075-9fec-0a96ee07953a',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: 'e907c0a6-3e66-45a4-9922-8bc4d5bf5208',
- toObjectMetadataId: 'f85c3930-9919-4887-b950-2e0496597c58',
- fromFieldMetadataId: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '0b32256a-1bd2-40e1-98e0-74b400452aab': {
- id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
- icon: 'IconMap',
- name: 'address',
- type: 'ADDRESS',
- label: 'Address',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
- description: 'Address of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- addressLat: null,
- addressLng: null,
- addressCity: "''",
- addressState: "''",
- addressCountry: "''",
- addressStreet1: "''",
- addressStreet2: "''",
- addressPostcode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '11a04849-150b-4af0-9332-b4a9ba693b17': {
- id: '11a04849-150b-4af0-9332-b4a9ba693b17',
- icon: 'IconUsers',
- name: 'people',
- type: 'RELATION',
- label: 'People',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
- description: 'People linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '427d1095-8ac0-4854-bf85-2adff18b653e',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: 'd25fcd48-4b3f-4d6a-b1c0-4241d64502ac',
- toObjectMetadataId: '462ac013-3ba0-4e87-b6a3-07069c308ca3',
- fromFieldMetadataId: '11a04849-150b-4af0-9332-b4a9ba693b17',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a': {
- id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- icon: 'IconUserCircle',
- name: 'accountOwner',
- type: 'RELATION',
- label: 'Account Owner',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
- description:
- 'Your team member responsible for managing the company account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: {
- id: '9ca11143-4ae4-4ed4-b636-158bc14d9513',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- toObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- fromFieldMetadataId: '58a6c41e-9ff0-4607-be3a-4356175b75dc',
- fromObjectMetadataId: '82dd61be-d849-41c2-b7c2-6a8ddb796e3e',
- },
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '214a5118-3ab5-4d2a-ac89-020f776831b3': {
- id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
- icon: 'IconTarget',
- name: 'idealCustomerProfile',
- type: 'BOOLEAN',
- label: 'ICP',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
- description:
- 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '26a67635-7d43-47f0-b895-1c8194a7fa30': {
- id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
- icon: 'IconBrandVisa',
- name: 'visaSponsorship',
- type: 'BOOLEAN',
- label: 'Visa Sponsorship',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.014Z',
- updatedAt: '2025-03-05T15:41:12.014Z',
- isNullable: true,
- standardId: null,
- description: "Company's Visa Sponsorship Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '39526b16-7d21-4a91-a70c-bca108b27989': {
- id: '39526b16-7d21-4a91-a70c-bca108b27989',
- icon: 'IconCalendarClock',
- name: 'updatedAt',
- type: 'DATE_TIME',
- label: 'Last update',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-d767-4622-bdcf-d8a084834d86',
- description: 'Last time the record was changed',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '45b5decf-cd19-4a2e-a321-b0c7ad3c1407': {
- id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- icon: 'IconHeart',
- name: 'favorites',
- type: 'RELATION',
- label: 'Favorites',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-4d1d-41ac-b13b-621631298d55',
- description: 'Favorites linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '2163bf40-3b55-4bf9-bb59-968b8eda9114',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '3f34086f-ad66-4e1d-9d4b-f42cdc0f2040',
- toObjectMetadataId: '323f077c-138b-4243-bbf2-59a77252f3c5',
- fromFieldMetadataId: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '49e40a03-3f21-49d5-b03a-439bbc9ab73b': {
- id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
- icon: 'IconVideo',
- name: 'introVideo',
- type: 'LINKS',
- label: 'Intro Video',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.011Z',
- updatedAt: '2025-03-05T15:41:12.011Z',
- isNullable: true,
- standardId: null,
- description: "Company's Intro Video",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '4ebb7bb9-d451-4433-880d-32cd3f3744df': {
- id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
- icon: 'IconCalendar',
- name: 'createdAt',
- type: 'DATE_TIME',
- label: 'Creation date',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-66ac-4502-9975-e4d959c50311',
- description: 'Creation date',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '4f069436-1c42-4ec4-8dda-6b22011fc75a': {
- id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
- icon: 'IconAdCircle',
- name: 'tagline',
- type: 'TEXT',
- label: 'Tagline',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.009Z',
- updatedAt: '2025-03-05T15:41:12.009Z',
- isNullable: false,
- standardId: null,
- description: "Company's Tagline",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '55e17b77-84f7-4b8a-bef5-be65f783d9f8': {
- id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
- icon: 'IconCalendarMinus',
- name: 'deletedAt',
- type: 'DATE_TIME',
- label: 'Deleted at',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
- description: 'Date when the record was deleted',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '593dd556-69ab-4df7-aa2e-ab5e20eb7977': {
- id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
- icon: 'Icon123',
- name: 'id',
- type: 'UUID',
- label: 'Id',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
- description: 'Id',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'uuid',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '5fc216dc-7af4-4927-a026-0e5144afa436': {
- id: '5fc216dc-7af4-4927-a026-0e5144afa436',
- icon: 'IconBrandX',
- name: 'xLink',
- type: 'LINKS',
- label: 'X',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
- description: 'The company Twitter/X account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '7524cc63-2522-4c70-8b12-21fe2fe8de26': {
- id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- icon: 'IconTargetArrow',
- name: 'opportunities',
- type: 'RELATION',
- label: 'Opportunities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
- description: 'Opportunities linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '889b83fc-9a5e-414c-acb6-48e5aa029394',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: '2a12de2d-3c43-4108-bd0a-f52b053e2449',
- toObjectMetadataId: 'da77d279-8984-4cb1-987a-14e2b0501288',
- fromFieldMetadataId: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '7dd1b1ac-9765-423e-ac74-050b2b730885': {
- id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- icon: 'IconNotes',
- name: 'noteTargets',
- type: 'RELATION',
- label: 'Notes',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
- description: 'Notes tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: 'b240e206-e8ba-496a-9671-063ad48a447d',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '5c582b90-c1d4-4ebe-bd66-3cc94e4abd35',
- toObjectMetadataId: 'b58841d9-7545-41b7-bb84-75e821285933',
- fromFieldMetadataId: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '8a2883df-3e19-4d52-9309-d636767d1b6a': {
- id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
- icon: 'IconHome',
- name: 'workPolicy',
- type: 'MULTI_SELECT',
- label: 'Work Policy',
- options: [
- {
- id: '4554330a-c3db-4042-b941-c2e299734d12',
- color: 'green',
- label: 'On-Site',
- value: 'ON_SITE',
- position: 0,
- },
- {
- id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
- color: 'turquoise',
- label: 'Hybrid',
- value: 'HYBRID',
- position: 1,
- },
- {
- id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
- color: 'sky',
- label: 'Remote Work',
- value: 'REMOTE_WORK',
- position: 2,
- },
- ],
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.013Z',
- updatedAt: '2025-03-05T15:41:12.013Z',
- isNullable: true,
- standardId: null,
- description: "Company's Work Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03': {
- id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
- icon: 'IconUser',
- name: 'searchVector',
- type: 'TS_VECTOR',
- label: 'Search vector',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
- description: 'Field used for full-text search',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- '943f218e-6061-4f61-ac3a-298ac14cef41': {
- id: '943f218e-6061-4f61-ac3a-298ac14cef41',
- icon: 'IconCreativeCommonsSa',
- name: 'createdBy',
- type: 'ACTOR',
- label: 'Created by',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-fabc-451d-ab7d-412170916baa',
- description: 'The creator of the record',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- name: "'System'",
- source: "'MANUAL'",
- context: {},
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa': {
- id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
- icon: 'IconBrandLinkedin',
- name: 'linkedinLink',
- type: 'LINKS',
- label: 'Linkedin',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
- description: 'The company Linkedin account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2': {
- id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
- icon: 'IconUserCircle',
- name: 'accountOwnerId',
- type: 'UUID',
- label: 'Account Owner id (foreign key)',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cce0-424e-8028-91f50eb9c768',
- description:
- 'Your team member responsible for managing the company account id foreign key',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4': {
- id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
- icon: 'IconHierarchy2',
- name: 'position',
- type: 'POSITION',
- label: 'Position',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-9b4e-462b-991d-a0ee33326454',
- description: 'Company record position',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 0,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07': {
- id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- icon: 'IconCheckbox',
- name: 'taskTargets',
- type: 'RELATION',
- label: 'Tasks',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
- description: 'Tasks tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '40a2f0d1-f420-46a2-a010-2489e7f27a9d',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: 'e3ee1c65-5ec0-4d68-aac4-6c66720240f0',
- toObjectMetadataId: '3e31c837-b0f0-4e8e-a1e3-28d3b12950f4',
- fromFieldMetadataId: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10': {
- id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
- icon: 'IconBuildingSkyscraper',
- name: 'name',
- type: 'TEXT',
- label: 'Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
- description: 'The company name',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'c750e2c6-3de6-4c18-9876-6ba5ba970d42': {
- id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
- icon: 'IconUsers',
- name: 'employees',
- type: 'NUMBER',
- label: 'Employees',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-8965-464a-8a75-74bafc152a0b',
- description: 'Number of employees in the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'dbc86e47-d2cf-4094-9a57-90212efde6a0': {
- id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
- icon: 'IconLink',
- name: 'domainName',
- type: 'LINKS',
- label: 'Domain Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: true,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
- description:
- 'The company website URL. We use this url to fetch the company icon',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- 'fba56220-3f40-4569-a500-35a4a312e473': {
- id: 'fba56220-3f40-4569-a500-35a4a312e473',
- icon: 'IconMoneybag',
- name: 'annualRecurringRevenue',
- type: 'CURRENCY',
- label: 'ARR',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-602a-495c-9776-f5d5b11d227b',
- description:
- 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- amountMicros: null,
- currencyCode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- },
- namePlural: 'companies',
- standardId: '20202020-b374-4779-a561-80086cb2e17f',
- description: 'A company',
- labelPlural: 'Companies',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- dataSourceId: 'f20df2e6-420e-40e0-a4ca-68846bbe6c92',
- fieldsByName: {
- id: {
- id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
- icon: 'Icon123',
- name: 'id',
- type: 'UUID',
- label: 'Id',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
- description: 'Id',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'uuid',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- name: {
- id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
- icon: 'IconBuildingSkyscraper',
- name: 'name',
- type: 'TEXT',
- label: 'Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
- description: 'The company name',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- xLink: {
- id: '5fc216dc-7af4-4927-a026-0e5144afa436',
- icon: 'IconBrandX',
- name: 'xLink',
- type: 'LINKS',
- label: 'X',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
- description: 'The company Twitter/X account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- people: {
- id: '11a04849-150b-4af0-9332-b4a9ba693b17',
- icon: 'IconUsers',
- name: 'people',
- type: 'RELATION',
- label: 'People',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
- description: 'People linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '427d1095-8ac0-4854-bf85-2adff18b653e',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: 'd25fcd48-4b3f-4d6a-b1c0-4241d64502ac',
- toObjectMetadataId: '462ac013-3ba0-4e87-b6a3-07069c308ca3',
- fromFieldMetadataId: '11a04849-150b-4af0-9332-b4a9ba693b17',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- address: {
- id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
- icon: 'IconMap',
- name: 'address',
- type: 'ADDRESS',
- label: 'Address',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
- description: 'Address of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- addressLat: null,
- addressLng: null,
- addressCity: "''",
- addressState: "''",
- addressCountry: "''",
- addressStreet1: "''",
- addressStreet2: "''",
- addressPostcode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- tagline: {
- id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
- icon: 'IconAdCircle',
- name: 'tagline',
- type: 'TEXT',
- label: 'Tagline',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.009Z',
- updatedAt: '2025-03-05T15:41:12.009Z',
- isNullable: false,
- standardId: null,
- description: "Company's Tagline",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: "''",
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- position: {
- id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
- icon: 'IconHierarchy2',
- name: 'position',
- type: 'POSITION',
- label: 'Position',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-9b4e-462b-991d-a0ee33326454',
- description: 'Company record position',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 0,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- createdAt: {
- id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
- icon: 'IconCalendar',
- name: 'createdAt',
- type: 'DATE_TIME',
- label: 'Creation date',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-66ac-4502-9975-e4d959c50311',
- description: 'Creation date',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- createdBy: {
- id: '943f218e-6061-4f61-ac3a-298ac14cef41',
- icon: 'IconCreativeCommonsSa',
- name: 'createdBy',
- type: 'ACTOR',
- label: 'Created by',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-fabc-451d-ab7d-412170916baa',
- description: 'The creator of the record',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- name: "'System'",
- source: "'MANUAL'",
- context: {},
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- deletedAt: {
- id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
- icon: 'IconCalendarMinus',
- name: 'deletedAt',
- type: 'DATE_TIME',
- label: 'Deleted at',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
- description: 'Date when the record was deleted',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- employees: {
- id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
- icon: 'IconUsers',
- name: 'employees',
- type: 'NUMBER',
- label: 'Employees',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-8965-464a-8a75-74bafc152a0b',
- description: 'Number of employees in the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- favorites: {
- id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- icon: 'IconHeart',
- name: 'favorites',
- type: 'RELATION',
- label: 'Favorites',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-4d1d-41ac-b13b-621631298d55',
- description: 'Favorites linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '2163bf40-3b55-4bf9-bb59-968b8eda9114',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '3f34086f-ad66-4e1d-9d4b-f42cdc0f2040',
- toObjectMetadataId: '323f077c-138b-4243-bbf2-59a77252f3c5',
- fromFieldMetadataId: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- updatedAt: {
- id: '39526b16-7d21-4a91-a70c-bca108b27989',
- icon: 'IconCalendarClock',
- name: 'updatedAt',
- type: 'DATE_TIME',
- label: 'Last update',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: {
- displayFormat: 'RELATIVE',
- },
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-d767-4622-bdcf-d8a084834d86',
- description: 'Last time the record was changed',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: 'now',
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- domainName: {
- id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
- icon: 'IconLink',
- name: 'domainName',
- type: 'LINKS',
- label: 'Domain Name',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: true,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
- description:
- 'The company website URL. We use this url to fetch the company icon',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- introVideo: {
- id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
- icon: 'IconVideo',
- name: 'introVideo',
- type: 'LINKS',
- label: 'Intro Video',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.011Z',
- updatedAt: '2025-03-05T15:41:12.011Z',
- isNullable: true,
- standardId: null,
- description: "Company's Intro Video",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- workPolicy: {
- id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
- icon: 'IconHome',
- name: 'workPolicy',
- type: 'MULTI_SELECT',
- label: 'Work Policy',
- options: [
- {
- id: '4554330a-c3db-4042-b941-c2e299734d12',
- color: 'green',
- label: 'On-Site',
- value: 'ON_SITE',
- position: 0,
- },
- {
- id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
- color: 'turquoise',
- label: 'Hybrid',
- value: 'HYBRID',
- position: 1,
- },
- {
- id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
- color: 'sky',
- label: 'Remote Work',
- value: 'REMOTE_WORK',
- position: 2,
- },
- ],
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.013Z',
- updatedAt: '2025-03-05T15:41:12.013Z',
- isNullable: true,
- standardId: null,
- description: "Company's Work Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- attachments: {
- id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- icon: 'IconFileImport',
- name: 'attachments',
- type: 'RELATION',
- label: 'Attachments',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
- description: 'Attachments linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: 'a2c6a4d7-fbda-4075-9fec-0a96ee07953a',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: 'e907c0a6-3e66-45a4-9922-8bc4d5bf5208',
- toObjectMetadataId: 'f85c3930-9919-4887-b950-2e0496597c58',
- fromFieldMetadataId: '0ae7a621-f443-47f7-b255-82d2e589ca21',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- noteTargets: {
- id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- icon: 'IconNotes',
- name: 'noteTargets',
- type: 'RELATION',
- label: 'Notes',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
- description: 'Notes tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: 'b240e206-e8ba-496a-9671-063ad48a447d',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '5c582b90-c1d4-4ebe-bd66-3cc94e4abd35',
- toObjectMetadataId: 'b58841d9-7545-41b7-bb84-75e821285933',
- fromFieldMetadataId: '7dd1b1ac-9765-423e-ac74-050b2b730885',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- taskTargets: {
- id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- icon: 'IconCheckbox',
- name: 'taskTargets',
- type: 'RELATION',
- label: 'Tasks',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
- description: 'Tasks tied to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '40a2f0d1-f420-46a2-a010-2489e7f27a9d',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: 'e3ee1c65-5ec0-4d68-aac4-6c66720240f0',
- toObjectMetadataId: '3e31c837-b0f0-4e8e-a1e3-28d3b12950f4',
- fromFieldMetadataId: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- accountOwner: {
- id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- icon: 'IconUserCircle',
- name: 'accountOwner',
- type: 'RELATION',
- label: 'Account Owner',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
- description:
- 'Your team member responsible for managing the company account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: {
- id: '9ca11143-4ae4-4ed4-b636-158bc14d9513',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
- toObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- fromFieldMetadataId: '58a6c41e-9ff0-4607-be3a-4356175b75dc',
- fromObjectMetadataId: '82dd61be-d849-41c2-b7c2-6a8ddb796e3e',
- },
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- linkedinLink: {
- id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
- icon: 'IconBrandLinkedin',
- name: 'linkedinLink',
- type: 'LINKS',
- label: 'Linkedin',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
- description: 'The company Linkedin account',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- primaryLinkUrl: "''",
- secondaryLinks: "'[]'",
- primaryLinkLabel: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- searchVector: {
- id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
- icon: 'IconUser',
- name: 'searchVector',
- type: 'TS_VECTOR',
- label: 'Search vector',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
- description: 'Field used for full-text search',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- opportunities: {
- id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- icon: 'IconTargetArrow',
- name: 'opportunities',
- type: 'RELATION',
- label: 'Opportunities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
- description: 'Opportunities linked to the company.',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '889b83fc-9a5e-414c-acb6-48e5aa029394',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'SET_NULL',
- toFieldMetadataId: '2a12de2d-3c43-4108-bd0a-f52b053e2449',
- toObjectMetadataId: 'da77d279-8984-4cb1-987a-14e2b0501288',
- fromFieldMetadataId: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- accountOwnerId: {
- id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
- icon: 'IconUserCircle',
- name: 'accountOwnerId',
- type: 'UUID',
- label: 'Account Owner id (foreign key)',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-cce0-424e-8028-91f50eb9c768',
- description:
- 'Your team member responsible for managing the company account id foreign key',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- visaSponsorship: {
- id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
- icon: 'IconBrandVisa',
- name: 'visaSponsorship',
- type: 'BOOLEAN',
- label: 'Visa Sponsorship',
- options: null,
- isActive: true,
- isCustom: true,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:12.014Z',
- updatedAt: '2025-03-05T15:41:12.014Z',
- isNullable: true,
- standardId: null,
- description: "Company's Visa Sponsorship Policy",
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- timelineActivities: {
- id: '038ca1af-7f15-460d-b111-b71062a8a6be',
- icon: 'IconIconTimelineEvent',
- name: 'timelineActivities',
- type: 'RELATION',
- label: 'Timeline Activities',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: true,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
- description: 'Timeline Activities linked to the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: {
- id: '29a10f41-0265-4775-923f-0bbf548dc2ec',
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- relationType: 'ONE_TO_MANY',
- onDeleteAction: 'CASCADE',
- toFieldMetadataId: '96896f47-cb02-4164-b3f2-c24d12b30e74',
- toObjectMetadataId: '1a41f4ba-7aad-4111-8035-961962702ebb',
- fromFieldMetadataId: '038ca1af-7f15-460d-b111-b71062a8a6be',
- fromObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- },
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- idealCustomerProfile: {
- id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
- icon: 'IconTarget',
- name: 'idealCustomerProfile',
- type: 'BOOLEAN',
- label: 'ICP',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: false,
- standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
- description:
- 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: false,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- annualRecurringRevenue: {
- id: 'fba56220-3f40-4569-a500-35a4a312e473',
- icon: 'IconMoneybag',
- name: 'annualRecurringRevenue',
- type: 'CURRENCY',
- label: 'ARR',
- options: null,
- isActive: true,
- isCustom: false,
- isSystem: false,
- isUnique: false,
- settings: null,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- isNullable: true,
- standardId: '20202020-602a-495c-9776-f5d5b11d227b',
- description:
- 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- defaultValue: {
- amountMicros: null,
- currencyCode: "''",
- },
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- toRelationMetadata: null,
- fromRelationMetadata: null,
- isLabelSyncedWithName: false,
- relationTargetFieldMetadataId: null,
- relationTargetObjectMetadataId: null,
- },
- },
- isSearchable: true,
- nameSingular: 'company',
- isAuditLogged: true,
- labelSingular: 'Company',
- indexMetadatas: [
- {
- id: '9d5ef0cf-a301-44bf-98dd-c839d363f8f6',
- name: 'IDX_UNIQUE_2a32339058d0b6910b0834ddf81',
- isCustom: false,
- isUnique: true,
- createdAt: '2025-03-05T15:41:09.390Z',
- indexType: 'BTREE',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- indexWhereClause: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- indexFieldMetadatas: [
- {
- id: '12f75acc-33fc-49ee-af8f-39d9e8f17c3d',
- order: 0,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- fieldMetadataId: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
- indexMetadataId: '9d5ef0cf-a301-44bf-98dd-c839d363f8f6',
- },
- ],
- },
- {
- id: 'e554c7bb-c355-4594-a708-4ea4e7cbcbdc',
- name: 'IDX_123501237187c835ede626367b7',
- isCustom: false,
- isUnique: false,
- createdAt: '2025-03-05T15:41:09.390Z',
- indexType: 'BTREE',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- indexWhereClause: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- indexFieldMetadatas: [
- {
- id: 'cf3ebe8e-e213-4c4c-939f-d7fb36016823',
- order: 0,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- fieldMetadataId: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
- indexMetadataId: 'e554c7bb-c355-4594-a708-4ea4e7cbcbdc',
- },
- {
- id: 'd2663353-c4a2-4787-98d1-6ad448a66d86',
- order: 1,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- fieldMetadataId: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
- indexMetadataId: 'e554c7bb-c355-4594-a708-4ea4e7cbcbdc',
- },
- ],
- },
- {
- id: '48102f0b-0aef-4ae3-b3de-54e7c5bbdd1c',
- name: 'IDX_fb1f4905546cfc6d70a971c76f7',
- isCustom: false,
- isUnique: false,
- createdAt: '2025-03-05T15:41:09.390Z',
- indexType: 'GIN',
- updatedAt: '2025-03-05T15:41:09.390Z',
- workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
- indexWhereClause: null,
- objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
- indexFieldMetadatas: [
- {
- id: '5cd649b1-79b8-4b07-9c56-b70fe247954b',
- order: 0,
- createdAt: '2025-03-05T15:41:09.390Z',
- updatedAt: '2025-03-05T15:41:09.390Z',
- fieldMetadataId: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
- indexMetadataId: '48102f0b-0aef-4ae3-b3de-54e7c5bbdd1c',
- },
- ],
- },
- ],
- targetTableName: 'DEPRECATED',
- duplicateCriteria: [['name'], ['domainNamePrimaryLinkUrl']],
- isLabelSyncedWithName: false,
- imageIdentifierFieldMetadataId: null,
- labelIdentifierFieldMetadataId:
- 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
- },
- },
- '212a171a-f887-4213-8892-e39c2a3ecc30': {
- userId: ['20202020', '9e3b', '46d4', 'a556', '88b9ddc2b034'],
- },
- '753b124e-f427-44a4-ab08-bacfe9c2f746': {
- id: '0455ca41-bae1-4a3a-968c-b268a4e809bb',
- body: null,
- title: 'Proposal for ',
- bodyV2: {
- markdown: '',
- blocknote: '',
- },
- position: 0,
- createdAt: '2025-03-06T12:15:43.371Z',
- createdBy: {
- name: 'Workflow',
- source: 'WORKFLOW',
- context: {},
- workspaceMemberId: null,
- },
- deletedAt: null,
- updatedAt: '2025-03-06T12:15:43.371Z',
- searchVector: "'for':2 'proposal':1",
- },
- 'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30': {
- date: '2025-03-06T12:15:43.358Z',
- },
- 'd4a73172-3156-45bf-bc49-9358fbab2907': {
- id: 'f76b6058-2c8b-4bfa-86c1-4a4d39de3ee9',
- name: 'Opportunity with ',
- stage: 'NEW',
- amount: {
- amountMicros: null,
- currencyCode: '',
- },
- position: 0,
- closeDate: null,
- companyId: null,
- createdAt: '2025-03-06T12:15:43.386Z',
- createdBy: {
- name: 'Workflow',
- source: 'WORKFLOW',
- context: {},
- workspaceMemberId: null,
- },
- deletedAt: null,
- updatedAt: '2025-03-06T12:15:43.386Z',
- searchVector: "'opportunity':1 'with':2",
- pointOfContactId: null,
- },
- },
- createdAt: '2025-03-06T12:15:43.316Z',
- deletedAt: null,
- endedAt: '2025-03-06T12:15:43.404Z',
- id: 'cb13fb82-82e5-46b6-8a80-0f8251ac98ff',
- name: 'Execution of v5',
- output: {
- flow: {
- steps: [
- {
- id: '212a171a-f887-4213-8892-e39c2a3ecc30',
- name: 'Code - Serverless Function',
- type: 'CODE',
- valid: false,
- settings: {
- input: {
- serverlessFunctionId: 'e031ae6a-5b9e-496b-9a98-ba015f7b5508',
- serverlessFunctionInput: {
- userId: '{{trigger.userId}}',
- },
- serverlessFunctionVersion: '1',
- },
- outputSchema: {
- link: {
- tab: 'test',
- icon: 'IconVariable',
- label: 'Generate Function Output',
- isLeaf: true,
- },
- _outputSchemaType: 'LINK',
- },
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
- },
- continueOnFailure: {
- value: false,
- },
- },
- },
- },
- {
- id: 'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30',
- name: 'Code - Serverless Function',
- type: 'CODE',
- valid: false,
- settings: {
- input: {
- serverlessFunctionId: '605efcda-6689-43b3-b24c-2eb76948f523',
- serverlessFunctionInput: {},
- serverlessFunctionVersion: '2',
- },
- outputSchema: {
- link: {
- tab: 'test',
- icon: 'IconVariable',
- label: 'Generate Function Output',
- isLeaf: true,
- },
- _outputSchemaType: 'LINK',
- },
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
- },
- continueOnFailure: {
- value: false,
- },
- },
- },
- },
- {
- id: '753b124e-f427-44a4-ab08-bacfe9c2f746',
- name: 'Create Record',
- type: 'CREATE_RECORD',
- valid: false,
- settings: {
- input: {
- objectName: 'note',
- objectRecord: {
- title: 'Proposal for {{trigger.properties.after.name}}',
- },
- },
- outputSchema: {
- fields: {
- id: {
- icon: 'Icon123',
- type: 'UUID',
- label: 'Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- body: {
- icon: 'IconFilePencil',
- type: 'RICH_TEXT',
- label: 'Body (deprecated)',
- value: 'My rich text',
- isLeaf: true,
- },
- title: {
- icon: 'IconNotes',
- type: 'TEXT',
- label: 'Title',
- value: 'My text',
- isLeaf: true,
- },
- bodyV2: {
- icon: 'IconFilePencil',
- label: 'Body',
- value: {
- markdown: {
- type: 'TEXT',
- label: ' Markdown',
- value: 'My text',
- isLeaf: true,
- },
- blocknote: {
- type: 'TEXT',
- label: ' Blocknote',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- createdAt: {
- icon: 'IconCalendar',
- type: 'DATE_TIME',
- label: 'Creation date',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- createdBy: {
- icon: 'IconCreativeCommonsSa',
- label: 'Created by',
- value: {
- name: {
- type: 'TEXT',
- label: ' Name',
- value: 'My text',
- isLeaf: true,
- },
- source: {
- type: 'SELECT',
- label: ' Source',
- value: null,
- isLeaf: true,
- },
- context: {
- type: 'RAW_JSON',
- label: ' Context',
- value: null,
- isLeaf: true,
- },
- workspaceMemberId: {
- type: 'UUID',
- label: ' Workspace Member Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- deletedAt: {
- icon: 'IconCalendarMinus',
- type: 'DATE_TIME',
- label: 'Deleted at',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- updatedAt: {
- icon: 'IconCalendarClock',
- type: 'DATE_TIME',
- label: 'Last update',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- },
- object: {
- icon: 'IconNotes',
- label: 'Note',
- value: 'A note',
- isLeaf: true,
- fieldIdName: 'id',
- nameSingular: 'note',
- },
- _outputSchemaType: 'RECORD',
- },
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
- },
- continueOnFailure: {
- value: false,
- },
- },
- },
- },
- {
- id: 'd4a73172-3156-45bf-bc49-9358fbab2907',
- name: 'Create Record',
- type: 'CREATE_RECORD',
- valid: false,
- settings: {
- input: {
- objectName: 'opportunity',
- objectRecord: {
- name: 'Opportunity with {{trigger.properties.after.name}}',
- stage: 'NEW',
- },
- },
- outputSchema: {
- fields: {
- id: {
- icon: 'Icon123',
- type: 'UUID',
- label: 'Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- name: {
- icon: 'IconTargetArrow',
- type: 'TEXT',
- label: 'Name',
- value: 'My text',
- isLeaf: true,
- },
- stage: {
- icon: 'IconProgressCheck',
- type: 'SELECT',
- label: 'Stage',
- value: null,
- isLeaf: true,
- },
- amount: {
- icon: 'IconCurrencyDollar',
- label: 'Amount',
- value: {
- amountMicros: {
- type: 'NUMERIC',
- label: ' Amount Micros',
- value: null,
- isLeaf: true,
- },
- currencyCode: {
- type: 'TEXT',
- label: ' Currency Code',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- closeDate: {
- icon: 'IconCalendarEvent',
- type: 'DATE_TIME',
- label: 'Close date',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- createdAt: {
- icon: 'IconCalendar',
- type: 'DATE_TIME',
- label: 'Creation date',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- createdBy: {
- icon: 'IconCreativeCommonsSa',
- label: 'Created by',
- value: {
- name: {
- type: 'TEXT',
- label: ' Name',
- value: 'My text',
- isLeaf: true,
- },
- source: {
- type: 'SELECT',
- label: ' Source',
- value: null,
- isLeaf: true,
- },
- context: {
- type: 'RAW_JSON',
- label: ' Context',
- value: null,
- isLeaf: true,
- },
- workspaceMemberId: {
- type: 'UUID',
- label: ' Workspace Member Id',
- value: '123e4567-e89b-12d3-a456-426614174000',
- isLeaf: true,
- },
- },
- isLeaf: false,
- },
- deletedAt: {
- icon: 'IconCalendarMinus',
- type: 'DATE_TIME',
- label: 'Deleted at',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- updatedAt: {
- icon: 'IconCalendarClock',
- type: 'DATE_TIME',
- label: 'Last update',
- value: '01/23/2025 15:16',
- isLeaf: true,
- },
- },
- object: {
- icon: 'IconTargetArrow',
- label: 'Opportunity',
- value: 'An opportunity',
- isLeaf: true,
- fieldIdName: 'id',
- nameSingular: 'opportunity',
- },
- _outputSchemaType: 'RECORD',
- },
- errorHandlingOptions: {
- retryOnFailure: {
- value: false,
- },
- continueOnFailure: {
- value: false,
- },
- },
- },
- },
- ],
- trigger: {
- type: 'DATABASE_EVENT',
- settings: {
- eventName: 'company.created',
- outputSchema: {
- userId: {
- type: 'string',
- label: 'User ID',
- value: '977a8fb6-1b97-4203-a64b-5d3e12f8587c',
- isLeaf: true,
- },
- recordId: {
- type: 'string',
- label: 'Record ID',
- value: '80d61929-1860-4f37-a639-b406a67f7800',
- isLeaf: true,
+ recordId: {
+ type: 'string',
+ label: 'Record ID',
+ value: '80d61929-1860-4f37-a639-b406a67f7800',
+ isLeaf: true,
},
objectMetadata: {
label: 'Object Metadata',
@@ -10244,9 +5894,66 @@ export const oneSucceededWorkflowRunQueryResult = {
value: '01/23/2025 15:16',
isLeaf: true,
},
- domainName: {
- icon: 'IconLink',
- label: 'Domain Name',
+ domainName: {
+ icon: 'IconLink',
+ label: 'Domain Name',
+ value: {
+ primaryLinkUrl: {
+ type: 'TEXT',
+ label: ' Primary Link Url',
+ value: 'My text',
+ isLeaf: true,
+ },
+ secondaryLinks: {
+ type: 'RAW_JSON',
+ label: ' Secondary Links',
+ value: null,
+ isLeaf: true,
+ },
+ primaryLinkLabel: {
+ type: 'TEXT',
+ label: ' Primary Link Label',
+ value: 'My text',
+ isLeaf: true,
+ },
+ },
+ isLeaf: false,
+ },
+ introVideo: {
+ icon: 'IconVideo',
+ label: 'Intro Video',
+ value: {
+ primaryLinkUrl: {
+ type: 'TEXT',
+ label: ' Primary Link Url',
+ value: 'My text',
+ isLeaf: true,
+ },
+ secondaryLinks: {
+ type: 'RAW_JSON',
+ label: ' Secondary Links',
+ value: null,
+ isLeaf: true,
+ },
+ primaryLinkLabel: {
+ type: 'TEXT',
+ label: ' Primary Link Label',
+ value: 'My text',
+ isLeaf: true,
+ },
+ },
+ isLeaf: false,
+ },
+ workPolicy: {
+ icon: 'IconHome',
+ type: 'MULTI_SELECT',
+ label: 'Work Policy',
+ value: null,
+ isLeaf: true,
+ },
+ linkedinLink: {
+ icon: 'IconBrandLinkedin',
+ label: 'Linkedin',
value: {
primaryLinkUrl: {
type: 'TEXT',
@@ -10269,124 +5976,2915 @@ export const oneSucceededWorkflowRunQueryResult = {
},
isLeaf: false,
},
- introVideo: {
- icon: 'IconVideo',
- label: 'Intro Video',
- value: {
- primaryLinkUrl: {
- type: 'TEXT',
- label: ' Primary Link Url',
- value: 'My text',
- isLeaf: true,
- },
- secondaryLinks: {
- type: 'RAW_JSON',
- label: ' Secondary Links',
- value: null,
- isLeaf: true,
- },
- primaryLinkLabel: {
- type: 'TEXT',
- label: ' Primary Link Label',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
+ visaSponsorship: {
+ icon: 'IconBrandVisa',
+ type: 'BOOLEAN',
+ label: 'Visa Sponsorship',
+ value: true,
+ isLeaf: true,
+ },
+ idealCustomerProfile: {
+ icon: 'IconTarget',
+ type: 'BOOLEAN',
+ label: 'ICP',
+ value: true,
+ isLeaf: true,
+ },
+ annualRecurringRevenue: {
+ icon: 'IconMoneybag',
+ label: 'ARR',
+ value: {
+ amountMicros: {
+ type: 'NUMERIC',
+ label: ' Amount Micros',
+ value: null,
+ isLeaf: true,
+ },
+ currencyCode: {
+ type: 'TEXT',
+ label: ' Currency Code',
+ value: 'My text',
+ isLeaf: true,
+ },
+ },
+ isLeaf: false,
+ },
+ },
+ object: {
+ icon: 'IconBuildingSkyscraper',
+ label: 'Company',
+ value: 'A company',
+ isLeaf: true,
+ fieldIdName: 'id',
+ nameSingular: 'company',
+ },
+ _outputSchemaType: 'RECORD',
+ },
+ isLeaf: false,
+ },
+ workspaceMemberId: {
+ type: 'string',
+ label: 'Workspace Member ID',
+ value: '53562519-b9e8-44f1-8dd1-e247cc7ef584',
+ isLeaf: true,
+ },
+ },
+ },
+ },
+ },
+ stepInfos: {
+ trigger: {
+ result: {
+ userId: '20202020-9e3b-46d4-a556-88b9ddc2b034',
+ recordId: '6bba55b1-6be2-49d3-adcd-470a56547c73',
+ properties: {
+ after: {
+ id: '6bba55b1-6be2-49d3-adcd-470a56547c73',
+ name: '',
+ xLink: {
+ primaryLinkUrl: '',
+ secondaryLinks: [],
+ primaryLinkLabel: '',
+ },
+ people: [],
+ address: {
+ addressLat: null,
+ addressLng: null,
+ addressCity: '',
+ addressState: '',
+ addressCountry: '',
+ addressStreet1: '',
+ addressStreet2: '',
+ addressPostcode: '',
+ },
+ tagline: '',
+ position: -3,
+ createdAt: '2025-03-06T12:15:43.288Z',
+ createdBy: {
+ name: 'Tim Apple',
+ source: 'MANUAL',
+ context: {},
+ workspaceMemberId: '20202020-0687-4c41-b707-ed1bfca972a7',
+ },
+ deletedAt: null,
+ employees: null,
+ favorites: [],
+ updatedAt: '2025-03-06T12:15:43.288Z',
+ domainName: {
+ primaryLinkUrl: '',
+ secondaryLinks: [],
+ primaryLinkLabel: '',
+ },
+ introVideo: {
+ primaryLinkUrl: '',
+ secondaryLinks: [],
+ primaryLinkLabel: '',
+ },
+ workPolicy: null,
+ attachments: [],
+ noteTargets: [],
+ accountOwner: null,
+ linkedinLink: {
+ primaryLinkUrl: '',
+ secondaryLinks: [],
+ primaryLinkLabel: '',
+ },
+ searchVector: '',
+ opportunities: [],
+ accountOwnerId: null,
+ visaSponsorship: false,
+ idealCustomerProfile: false,
+ annualRecurringRevenue: {
+ amountMicros: null,
+ currencyCode: '',
+ },
+ },
+ before: null,
+ },
+ objectMetadata: {
+ id: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ icon: 'IconBuildingSkyscraper',
+ fields: [
+ {
+ id: '5fc216dc-7af4-4927-a026-0e5144afa436',
+ icon: 'IconBrandX',
+ name: 'xLink',
+ type: 'LINKS',
+ label: 'X',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
+ description: 'The company Twitter/X account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'fba56220-3f40-4569-a500-35a4a312e473',
+ icon: 'IconMoneybag',
+ name: 'annualRecurringRevenue',
+ type: 'CURRENCY',
+ label: 'ARR',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-602a-495c-9776-f5d5b11d227b',
+ description:
+ 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ amountMicros: null,
+ currencyCode: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
+ icon: 'IconMap',
+ name: 'address',
+ type: 'ADDRESS',
+ label: 'Address',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
+ description: 'Address of the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ addressLat: null,
+ addressLng: null,
+ addressCity: "''",
+ addressState: "''",
+ addressCountry: "''",
+ addressStreet1: "''",
+ addressStreet2: "''",
+ addressPostcode: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
+ icon: 'IconTarget',
+ name: 'idealCustomerProfile',
+ type: 'BOOLEAN',
+ label: 'ICP',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
+ description:
+ 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: false,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
+ icon: 'IconHierarchy2',
+ name: 'position',
+ type: 'POSITION',
+ label: 'Position',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-9b4e-462b-991d-a0ee33326454',
+ description: 'Company record position',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 0,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '943f218e-6061-4f61-ac3a-298ac14cef41',
+ icon: 'IconCreativeCommonsSa',
+ name: 'createdBy',
+ type: 'ACTOR',
+ label: 'Created by',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-fabc-451d-ab7d-412170916baa',
+ description: 'The creator of the record',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ name: "'System'",
+ source: "'MANUAL'",
+ context: {},
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
+ icon: 'IconUser',
+ name: 'searchVector',
+ type: 'TS_VECTOR',
+ label: 'Search vector',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
+ description: 'Field used for full-text search',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
+ icon: 'Icon123',
+ name: 'id',
+ type: 'UUID',
+ label: 'Id',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
+ description: 'Id',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'uuid',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
+ icon: 'IconCalendar',
+ name: 'createdAt',
+ type: 'DATE_TIME',
+ label: 'Creation date',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-66ac-4502-9975-e4d959c50311',
+ description: 'Creation date',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'now',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '39526b16-7d21-4a91-a70c-bca108b27989',
+ icon: 'IconCalendarClock',
+ name: 'updatedAt',
+ type: 'DATE_TIME',
+ label: 'Last update',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-d767-4622-bdcf-d8a084834d86',
+ description: 'Last time the record was changed',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'now',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
+ icon: 'IconCalendarMinus',
+ name: 'deletedAt',
+ type: 'DATE_TIME',
+ label: 'Deleted at',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
+ description: 'Date when the record was deleted',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '11a04849-150b-4af0-9332-b4a9ba693b17',
+ icon: 'IconUsers',
+ name: 'people',
+ type: 'RELATION',
+ label: 'People',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
+ description: 'People linked to the company.',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '427d1095-8ac0-4854-bf85-2adff18b653e',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: 'd25fcd48-4b3f-4d6a-b1c0-4241d64502ac',
+ toObjectMetadataId: '462ac013-3ba0-4e87-b6a3-07069c308ca3',
+ fromFieldMetadataId: '11a04849-150b-4af0-9332-b4a9ba693b17',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
+ icon: 'IconUserCircle',
+ name: 'accountOwnerId',
+ type: 'UUID',
+ label: 'Account Owner id (foreign key)',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-cce0-424e-8028-91f50eb9c768',
+ description:
+ 'Your team member responsible for managing the company account id foreign key',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
+ icon: 'IconUserCircle',
+ name: 'accountOwner',
+ type: 'RELATION',
+ label: 'Account Owner',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
+ description:
+ 'Your team member responsible for managing the company account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: {
+ id: '9ca11143-4ae4-4ed4-b636-158bc14d9513',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
+ toObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ fromFieldMetadataId: '58a6c41e-9ff0-4607-be3a-4356175b75dc',
+ fromObjectMetadataId:
+ '82dd61be-d849-41c2-b7c2-6a8ddb796e3e',
+ },
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
+ icon: 'IconCheckbox',
+ name: 'taskTargets',
+ type: 'RELATION',
+ label: 'Tasks',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
+ description: 'Tasks tied to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '40a2f0d1-f420-46a2-a010-2489e7f27a9d',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: 'e3ee1c65-5ec0-4d68-aac4-6c66720240f0',
+ toObjectMetadataId: '3e31c837-b0f0-4e8e-a1e3-28d3b12950f4',
+ fromFieldMetadataId: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
+ icon: 'IconNotes',
+ name: 'noteTargets',
+ type: 'RELATION',
+ label: 'Notes',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
+ description: 'Notes tied to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: 'b240e206-e8ba-496a-9671-063ad48a447d',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '5c582b90-c1d4-4ebe-bd66-3cc94e4abd35',
+ toObjectMetadataId: 'b58841d9-7545-41b7-bb84-75e821285933',
+ fromFieldMetadataId: '7dd1b1ac-9765-423e-ac74-050b2b730885',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
+ icon: 'IconTargetArrow',
+ name: 'opportunities',
+ type: 'RELATION',
+ label: 'Opportunities',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
+ description: 'Opportunities linked to the company.',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '889b83fc-9a5e-414c-acb6-48e5aa029394',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: '2a12de2d-3c43-4108-bd0a-f52b053e2449',
+ toObjectMetadataId: 'da77d279-8984-4cb1-987a-14e2b0501288',
+ fromFieldMetadataId: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
+ icon: 'IconHeart',
+ name: 'favorites',
+ type: 'RELATION',
+ label: 'Favorites',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-4d1d-41ac-b13b-621631298d55',
+ description: 'Favorites linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '2163bf40-3b55-4bf9-bb59-968b8eda9114',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '3f34086f-ad66-4e1d-9d4b-f42cdc0f2040',
+ toObjectMetadataId: '323f077c-138b-4243-bbf2-59a77252f3c5',
+ fromFieldMetadataId: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
+ icon: 'IconFileImport',
+ name: 'attachments',
+ type: 'RELATION',
+ label: 'Attachments',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
+ description: 'Attachments linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: 'a2c6a4d7-fbda-4075-9fec-0a96ee07953a',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: 'e907c0a6-3e66-45a4-9922-8bc4d5bf5208',
+ toObjectMetadataId: 'f85c3930-9919-4887-b950-2e0496597c58',
+ fromFieldMetadataId: '0ae7a621-f443-47f7-b255-82d2e589ca21',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '038ca1af-7f15-460d-b111-b71062a8a6be',
+ icon: 'IconIconTimelineEvent',
+ name: 'timelineActivities',
+ type: 'RELATION',
+ label: 'Timeline Activities',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
+ description: 'Timeline Activities linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '29a10f41-0265-4775-923f-0bbf548dc2ec',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '96896f47-cb02-4164-b3f2-c24d12b30e74',
+ toObjectMetadataId: '1a41f4ba-7aad-4111-8035-961962702ebb',
+ fromFieldMetadataId: '038ca1af-7f15-460d-b111-b71062a8a6be',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
+ icon: 'IconAdCircle',
+ name: 'tagline',
+ type: 'TEXT',
+ label: 'Tagline',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.009Z',
+ updatedAt: '2025-03-05T15:41:12.009Z',
+ isNullable: false,
+ standardId: null,
+ description: "Company's Tagline",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: "''",
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
+ icon: 'IconVideo',
+ name: 'introVideo',
+ type: 'LINKS',
+ label: 'Intro Video',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.011Z',
+ updatedAt: '2025-03-05T15:41:12.011Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Intro Video",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
+ icon: 'IconHome',
+ name: 'workPolicy',
+ type: 'MULTI_SELECT',
+ label: 'Work Policy',
+ options: [
+ {
+ id: '4554330a-c3db-4042-b941-c2e299734d12',
+ color: 'green',
+ label: 'On-Site',
+ value: 'ON_SITE',
+ position: 0,
+ },
+ {
+ id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
+ color: 'turquoise',
+ label: 'Hybrid',
+ value: 'HYBRID',
+ position: 1,
+ },
+ {
+ id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
+ color: 'sky',
+ label: 'Remote Work',
+ value: 'REMOTE_WORK',
+ position: 2,
+ },
+ ],
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.013Z',
+ updatedAt: '2025-03-05T15:41:12.013Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Work Policy",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
+ icon: 'IconBrandVisa',
+ name: 'visaSponsorship',
+ type: 'BOOLEAN',
+ label: 'Visa Sponsorship',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.014Z',
+ updatedAt: '2025-03-05T15:41:12.014Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Visa Sponsorship Policy",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: false,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
+ icon: 'IconBuildingSkyscraper',
+ name: 'name',
+ type: 'TEXT',
+ label: 'Name',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
+ description: 'The company name',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: "''",
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
+ icon: 'IconLink',
+ name: 'domainName',
+ type: 'LINKS',
+ label: 'Domain Name',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: true,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
+ description:
+ 'The company website URL. We use this url to fetch the company icon',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
+ icon: 'IconUsers',
+ name: 'employees',
+ type: 'NUMBER',
+ label: 'Employees',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-8965-464a-8a75-74bafc152a0b',
+ description: 'Number of employees in the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ {
+ id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
+ icon: 'IconBrandLinkedin',
+ name: 'linkedinLink',
+ type: 'LINKS',
+ label: 'Linkedin',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
+ description: 'The company Linkedin account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ ],
+ isActive: true,
+ isCustom: false,
+ isRemote: false,
+ isSystem: false,
+ shortcut: 'C',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ fieldsById: {
+ '038ca1af-7f15-460d-b111-b71062a8a6be': {
+ id: '038ca1af-7f15-460d-b111-b71062a8a6be',
+ icon: 'IconIconTimelineEvent',
+ name: 'timelineActivities',
+ type: 'RELATION',
+ label: 'Timeline Activities',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
+ description: 'Timeline Activities linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '29a10f41-0265-4775-923f-0bbf548dc2ec',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '96896f47-cb02-4164-b3f2-c24d12b30e74',
+ toObjectMetadataId: '1a41f4ba-7aad-4111-8035-961962702ebb',
+ fromFieldMetadataId: '038ca1af-7f15-460d-b111-b71062a8a6be',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '0ae7a621-f443-47f7-b255-82d2e589ca21': {
+ id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
+ icon: 'IconFileImport',
+ name: 'attachments',
+ type: 'RELATION',
+ label: 'Attachments',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
+ description: 'Attachments linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: 'a2c6a4d7-fbda-4075-9fec-0a96ee07953a',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: 'e907c0a6-3e66-45a4-9922-8bc4d5bf5208',
+ toObjectMetadataId: 'f85c3930-9919-4887-b950-2e0496597c58',
+ fromFieldMetadataId: '0ae7a621-f443-47f7-b255-82d2e589ca21',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '0b32256a-1bd2-40e1-98e0-74b400452aab': {
+ id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
+ icon: 'IconMap',
+ name: 'address',
+ type: 'ADDRESS',
+ label: 'Address',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
+ description: 'Address of the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ addressLat: null,
+ addressLng: null,
+ addressCity: "''",
+ addressState: "''",
+ addressCountry: "''",
+ addressStreet1: "''",
+ addressStreet2: "''",
+ addressPostcode: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '11a04849-150b-4af0-9332-b4a9ba693b17': {
+ id: '11a04849-150b-4af0-9332-b4a9ba693b17',
+ icon: 'IconUsers',
+ name: 'people',
+ type: 'RELATION',
+ label: 'People',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
+ description: 'People linked to the company.',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '427d1095-8ac0-4854-bf85-2adff18b653e',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: 'd25fcd48-4b3f-4d6a-b1c0-4241d64502ac',
+ toObjectMetadataId: '462ac013-3ba0-4e87-b6a3-07069c308ca3',
+ fromFieldMetadataId: '11a04849-150b-4af0-9332-b4a9ba693b17',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a': {
+ id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
+ icon: 'IconUserCircle',
+ name: 'accountOwner',
+ type: 'RELATION',
+ label: 'Account Owner',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
+ description:
+ 'Your team member responsible for managing the company account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: {
+ id: '9ca11143-4ae4-4ed4-b636-158bc14d9513',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
+ toObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ fromFieldMetadataId: '58a6c41e-9ff0-4607-be3a-4356175b75dc',
+ fromObjectMetadataId:
+ '82dd61be-d849-41c2-b7c2-6a8ddb796e3e',
+ },
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '214a5118-3ab5-4d2a-ac89-020f776831b3': {
+ id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
+ icon: 'IconTarget',
+ name: 'idealCustomerProfile',
+ type: 'BOOLEAN',
+ label: 'ICP',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
+ description:
+ 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: false,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '26a67635-7d43-47f0-b895-1c8194a7fa30': {
+ id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
+ icon: 'IconBrandVisa',
+ name: 'visaSponsorship',
+ type: 'BOOLEAN',
+ label: 'Visa Sponsorship',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.014Z',
+ updatedAt: '2025-03-05T15:41:12.014Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Visa Sponsorship Policy",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: false,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '39526b16-7d21-4a91-a70c-bca108b27989': {
+ id: '39526b16-7d21-4a91-a70c-bca108b27989',
+ icon: 'IconCalendarClock',
+ name: 'updatedAt',
+ type: 'DATE_TIME',
+ label: 'Last update',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-d767-4622-bdcf-d8a084834d86',
+ description: 'Last time the record was changed',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'now',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '45b5decf-cd19-4a2e-a321-b0c7ad3c1407': {
+ id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
+ icon: 'IconHeart',
+ name: 'favorites',
+ type: 'RELATION',
+ label: 'Favorites',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-4d1d-41ac-b13b-621631298d55',
+ description: 'Favorites linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '2163bf40-3b55-4bf9-bb59-968b8eda9114',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '3f34086f-ad66-4e1d-9d4b-f42cdc0f2040',
+ toObjectMetadataId: '323f077c-138b-4243-bbf2-59a77252f3c5',
+ fromFieldMetadataId: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '49e40a03-3f21-49d5-b03a-439bbc9ab73b': {
+ id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
+ icon: 'IconVideo',
+ name: 'introVideo',
+ type: 'LINKS',
+ label: 'Intro Video',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.011Z',
+ updatedAt: '2025-03-05T15:41:12.011Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Intro Video",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '4ebb7bb9-d451-4433-880d-32cd3f3744df': {
+ id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
+ icon: 'IconCalendar',
+ name: 'createdAt',
+ type: 'DATE_TIME',
+ label: 'Creation date',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-66ac-4502-9975-e4d959c50311',
+ description: 'Creation date',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'now',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '4f069436-1c42-4ec4-8dda-6b22011fc75a': {
+ id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
+ icon: 'IconAdCircle',
+ name: 'tagline',
+ type: 'TEXT',
+ label: 'Tagline',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.009Z',
+ updatedAt: '2025-03-05T15:41:12.009Z',
+ isNullable: false,
+ standardId: null,
+ description: "Company's Tagline",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: "''",
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '55e17b77-84f7-4b8a-bef5-be65f783d9f8': {
+ id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
+ icon: 'IconCalendarMinus',
+ name: 'deletedAt',
+ type: 'DATE_TIME',
+ label: 'Deleted at',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
+ description: 'Date when the record was deleted',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '593dd556-69ab-4df7-aa2e-ab5e20eb7977': {
+ id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
+ icon: 'Icon123',
+ name: 'id',
+ type: 'UUID',
+ label: 'Id',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
+ description: 'Id',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'uuid',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '5fc216dc-7af4-4927-a026-0e5144afa436': {
+ id: '5fc216dc-7af4-4927-a026-0e5144afa436',
+ icon: 'IconBrandX',
+ name: 'xLink',
+ type: 'LINKS',
+ label: 'X',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
+ description: 'The company Twitter/X account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '7524cc63-2522-4c70-8b12-21fe2fe8de26': {
+ id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
+ icon: 'IconTargetArrow',
+ name: 'opportunities',
+ type: 'RELATION',
+ label: 'Opportunities',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
+ description: 'Opportunities linked to the company.',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '889b83fc-9a5e-414c-acb6-48e5aa029394',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: '2a12de2d-3c43-4108-bd0a-f52b053e2449',
+ toObjectMetadataId: 'da77d279-8984-4cb1-987a-14e2b0501288',
+ fromFieldMetadataId: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '7dd1b1ac-9765-423e-ac74-050b2b730885': {
+ id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
+ icon: 'IconNotes',
+ name: 'noteTargets',
+ type: 'RELATION',
+ label: 'Notes',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
+ description: 'Notes tied to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: 'b240e206-e8ba-496a-9671-063ad48a447d',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '5c582b90-c1d4-4ebe-bd66-3cc94e4abd35',
+ toObjectMetadataId: 'b58841d9-7545-41b7-bb84-75e821285933',
+ fromFieldMetadataId: '7dd1b1ac-9765-423e-ac74-050b2b730885',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '8a2883df-3e19-4d52-9309-d636767d1b6a': {
+ id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
+ icon: 'IconHome',
+ name: 'workPolicy',
+ type: 'MULTI_SELECT',
+ label: 'Work Policy',
+ options: [
+ {
+ id: '4554330a-c3db-4042-b941-c2e299734d12',
+ color: 'green',
+ label: 'On-Site',
+ value: 'ON_SITE',
+ position: 0,
+ },
+ {
+ id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
+ color: 'turquoise',
+ label: 'Hybrid',
+ value: 'HYBRID',
+ position: 1,
},
- workPolicy: {
- icon: 'IconHome',
- type: 'MULTI_SELECT',
- label: 'Work Policy',
- value: null,
- isLeaf: true,
+ {
+ id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
+ color: 'sky',
+ label: 'Remote Work',
+ value: 'REMOTE_WORK',
+ position: 2,
},
- linkedinLink: {
- icon: 'IconBrandLinkedin',
- label: 'Linkedin',
- value: {
- primaryLinkUrl: {
- type: 'TEXT',
- label: ' Primary Link Url',
- value: 'My text',
- isLeaf: true,
- },
- secondaryLinks: {
- type: 'RAW_JSON',
- label: ' Secondary Links',
- value: null,
- isLeaf: true,
- },
- primaryLinkLabel: {
- type: 'TEXT',
- label: ' Primary Link Label',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
+ ],
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.013Z',
+ updatedAt: '2025-03-05T15:41:12.013Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Work Policy",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03': {
+ id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
+ icon: 'IconUser',
+ name: 'searchVector',
+ type: 'TS_VECTOR',
+ label: 'Search vector',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
+ description: 'Field used for full-text search',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ '943f218e-6061-4f61-ac3a-298ac14cef41': {
+ id: '943f218e-6061-4f61-ac3a-298ac14cef41',
+ icon: 'IconCreativeCommonsSa',
+ name: 'createdBy',
+ type: 'ACTOR',
+ label: 'Created by',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-fabc-451d-ab7d-412170916baa',
+ description: 'The creator of the record',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ name: "'System'",
+ source: "'MANUAL'",
+ context: {},
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa': {
+ id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
+ icon: 'IconBrandLinkedin',
+ name: 'linkedinLink',
+ type: 'LINKS',
+ label: 'Linkedin',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
+ description: 'The company Linkedin account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2': {
+ id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
+ icon: 'IconUserCircle',
+ name: 'accountOwnerId',
+ type: 'UUID',
+ label: 'Account Owner id (foreign key)',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-cce0-424e-8028-91f50eb9c768',
+ description:
+ 'Your team member responsible for managing the company account id foreign key',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4': {
+ id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
+ icon: 'IconHierarchy2',
+ name: 'position',
+ type: 'POSITION',
+ label: 'Position',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-9b4e-462b-991d-a0ee33326454',
+ description: 'Company record position',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 0,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07': {
+ id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
+ icon: 'IconCheckbox',
+ name: 'taskTargets',
+ type: 'RELATION',
+ label: 'Tasks',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
+ description: 'Tasks tied to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '40a2f0d1-f420-46a2-a010-2489e7f27a9d',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: 'e3ee1c65-5ec0-4d68-aac4-6c66720240f0',
+ toObjectMetadataId: '3e31c837-b0f0-4e8e-a1e3-28d3b12950f4',
+ fromFieldMetadataId: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10': {
+ id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
+ icon: 'IconBuildingSkyscraper',
+ name: 'name',
+ type: 'TEXT',
+ label: 'Name',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
+ description: 'The company name',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: "''",
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'c750e2c6-3de6-4c18-9876-6ba5ba970d42': {
+ id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
+ icon: 'IconUsers',
+ name: 'employees',
+ type: 'NUMBER',
+ label: 'Employees',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-8965-464a-8a75-74bafc152a0b',
+ description: 'Number of employees in the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'dbc86e47-d2cf-4094-9a57-90212efde6a0': {
+ id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
+ icon: 'IconLink',
+ name: 'domainName',
+ type: 'LINKS',
+ label: 'Domain Name',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: true,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
+ description:
+ 'The company website URL. We use this url to fetch the company icon',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ 'fba56220-3f40-4569-a500-35a4a312e473': {
+ id: 'fba56220-3f40-4569-a500-35a4a312e473',
+ icon: 'IconMoneybag',
+ name: 'annualRecurringRevenue',
+ type: 'CURRENCY',
+ label: 'ARR',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-602a-495c-9776-f5d5b11d227b',
+ description:
+ 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ amountMicros: null,
+ currencyCode: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ },
+ namePlural: 'companies',
+ standardId: '20202020-b374-4779-a561-80086cb2e17f',
+ description: 'A company',
+ labelPlural: 'Companies',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ dataSourceId: 'f20df2e6-420e-40e0-a4ca-68846bbe6c92',
+ fieldsByName: {
+ id: {
+ id: '593dd556-69ab-4df7-aa2e-ab5e20eb7977',
+ icon: 'Icon123',
+ name: 'id',
+ type: 'UUID',
+ label: 'Id',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
+ description: 'Id',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'uuid',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ name: {
+ id: 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
+ icon: 'IconBuildingSkyscraper',
+ name: 'name',
+ type: 'TEXT',
+ label: 'Name',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
+ description: 'The company name',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: "''",
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ xLink: {
+ id: '5fc216dc-7af4-4927-a026-0e5144afa436',
+ icon: 'IconBrandX',
+ name: 'xLink',
+ type: 'LINKS',
+ label: 'X',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
+ description: 'The company Twitter/X account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ people: {
+ id: '11a04849-150b-4af0-9332-b4a9ba693b17',
+ icon: 'IconUsers',
+ name: 'people',
+ type: 'RELATION',
+ label: 'People',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
+ description: 'People linked to the company.',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '427d1095-8ac0-4854-bf85-2adff18b653e',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: 'd25fcd48-4b3f-4d6a-b1c0-4241d64502ac',
+ toObjectMetadataId: '462ac013-3ba0-4e87-b6a3-07069c308ca3',
+ fromFieldMetadataId: '11a04849-150b-4af0-9332-b4a9ba693b17',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ address: {
+ id: '0b32256a-1bd2-40e1-98e0-74b400452aab',
+ icon: 'IconMap',
+ name: 'address',
+ type: 'ADDRESS',
+ label: 'Address',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
+ description: 'Address of the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ addressLat: null,
+ addressLng: null,
+ addressCity: "''",
+ addressState: "''",
+ addressCountry: "''",
+ addressStreet1: "''",
+ addressStreet2: "''",
+ addressPostcode: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ tagline: {
+ id: '4f069436-1c42-4ec4-8dda-6b22011fc75a',
+ icon: 'IconAdCircle',
+ name: 'tagline',
+ type: 'TEXT',
+ label: 'Tagline',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.009Z',
+ updatedAt: '2025-03-05T15:41:12.009Z',
+ isNullable: false,
+ standardId: null,
+ description: "Company's Tagline",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: "''",
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ position: {
+ id: 'b66efff8-c0ef-4cb6-a5f1-3ea7fd0bfbb4',
+ icon: 'IconHierarchy2',
+ name: 'position',
+ type: 'POSITION',
+ label: 'Position',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-9b4e-462b-991d-a0ee33326454',
+ description: 'Company record position',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 0,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ createdAt: {
+ id: '4ebb7bb9-d451-4433-880d-32cd3f3744df',
+ icon: 'IconCalendar',
+ name: 'createdAt',
+ type: 'DATE_TIME',
+ label: 'Creation date',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-66ac-4502-9975-e4d959c50311',
+ description: 'Creation date',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'now',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ createdBy: {
+ id: '943f218e-6061-4f61-ac3a-298ac14cef41',
+ icon: 'IconCreativeCommonsSa',
+ name: 'createdBy',
+ type: 'ACTOR',
+ label: 'Created by',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-fabc-451d-ab7d-412170916baa',
+ description: 'The creator of the record',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ name: "'System'",
+ source: "'MANUAL'",
+ context: {},
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ deletedAt: {
+ id: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
+ icon: 'IconCalendarMinus',
+ name: 'deletedAt',
+ type: 'DATE_TIME',
+ label: 'Deleted at',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
+ description: 'Date when the record was deleted',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ employees: {
+ id: 'c750e2c6-3de6-4c18-9876-6ba5ba970d42',
+ icon: 'IconUsers',
+ name: 'employees',
+ type: 'NUMBER',
+ label: 'Employees',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-8965-464a-8a75-74bafc152a0b',
+ description: 'Number of employees in the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ favorites: {
+ id: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
+ icon: 'IconHeart',
+ name: 'favorites',
+ type: 'RELATION',
+ label: 'Favorites',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-4d1d-41ac-b13b-621631298d55',
+ description: 'Favorites linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '2163bf40-3b55-4bf9-bb59-968b8eda9114',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '3f34086f-ad66-4e1d-9d4b-f42cdc0f2040',
+ toObjectMetadataId: '323f077c-138b-4243-bbf2-59a77252f3c5',
+ fromFieldMetadataId: '45b5decf-cd19-4a2e-a321-b0c7ad3c1407',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ updatedAt: {
+ id: '39526b16-7d21-4a91-a70c-bca108b27989',
+ icon: 'IconCalendarClock',
+ name: 'updatedAt',
+ type: 'DATE_TIME',
+ label: 'Last update',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: {
+ displayFormat: 'RELATIVE',
+ },
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-d767-4622-bdcf-d8a084834d86',
+ description: 'Last time the record was changed',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: 'now',
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ domainName: {
+ id: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
+ icon: 'IconLink',
+ name: 'domainName',
+ type: 'LINKS',
+ label: 'Domain Name',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: true,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
+ description:
+ 'The company website URL. We use this url to fetch the company icon',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ introVideo: {
+ id: '49e40a03-3f21-49d5-b03a-439bbc9ab73b',
+ icon: 'IconVideo',
+ name: 'introVideo',
+ type: 'LINKS',
+ label: 'Intro Video',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.011Z',
+ updatedAt: '2025-03-05T15:41:12.011Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Intro Video",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ workPolicy: {
+ id: '8a2883df-3e19-4d52-9309-d636767d1b6a',
+ icon: 'IconHome',
+ name: 'workPolicy',
+ type: 'MULTI_SELECT',
+ label: 'Work Policy',
+ options: [
+ {
+ id: '4554330a-c3db-4042-b941-c2e299734d12',
+ color: 'green',
+ label: 'On-Site',
+ value: 'ON_SITE',
+ position: 0,
},
- visaSponsorship: {
- icon: 'IconBrandVisa',
- type: 'BOOLEAN',
- label: 'Visa Sponsorship',
- value: true,
- isLeaf: true,
+ {
+ id: 'abfde6f9-64d5-430a-adb3-bea2f403d9a4',
+ color: 'turquoise',
+ label: 'Hybrid',
+ value: 'HYBRID',
+ position: 1,
},
- idealCustomerProfile: {
- icon: 'IconTarget',
- type: 'BOOLEAN',
- label: 'ICP',
- value: true,
- isLeaf: true,
+ {
+ id: '8eaca902-05c5-4087-86c0-30c664c2c4f5',
+ color: 'sky',
+ label: 'Remote Work',
+ value: 'REMOTE_WORK',
+ position: 2,
},
- annualRecurringRevenue: {
- icon: 'IconMoneybag',
- label: 'ARR',
- value: {
- amountMicros: {
- type: 'NUMERIC',
- label: ' Amount Micros',
- value: null,
- isLeaf: true,
- },
- currencyCode: {
- type: 'TEXT',
- label: ' Currency Code',
- value: 'My text',
- isLeaf: true,
- },
- },
- isLeaf: false,
+ ],
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.013Z',
+ updatedAt: '2025-03-05T15:41:12.013Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Work Policy",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ attachments: {
+ id: '0ae7a621-f443-47f7-b255-82d2e589ca21',
+ icon: 'IconFileImport',
+ name: 'attachments',
+ type: 'RELATION',
+ label: 'Attachments',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
+ description: 'Attachments linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: 'a2c6a4d7-fbda-4075-9fec-0a96ee07953a',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: 'e907c0a6-3e66-45a4-9922-8bc4d5bf5208',
+ toObjectMetadataId: 'f85c3930-9919-4887-b950-2e0496597c58',
+ fromFieldMetadataId: '0ae7a621-f443-47f7-b255-82d2e589ca21',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ noteTargets: {
+ id: '7dd1b1ac-9765-423e-ac74-050b2b730885',
+ icon: 'IconNotes',
+ name: 'noteTargets',
+ type: 'RELATION',
+ label: 'Notes',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
+ description: 'Notes tied to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: 'b240e206-e8ba-496a-9671-063ad48a447d',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '5c582b90-c1d4-4ebe-bd66-3cc94e4abd35',
+ toObjectMetadataId: 'b58841d9-7545-41b7-bb84-75e821285933',
+ fromFieldMetadataId: '7dd1b1ac-9765-423e-ac74-050b2b730885',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ taskTargets: {
+ id: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
+ icon: 'IconCheckbox',
+ name: 'taskTargets',
+ type: 'RELATION',
+ label: 'Tasks',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
+ description: 'Tasks tied to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '40a2f0d1-f420-46a2-a010-2489e7f27a9d',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: 'e3ee1c65-5ec0-4d68-aac4-6c66720240f0',
+ toObjectMetadataId: '3e31c837-b0f0-4e8e-a1e3-28d3b12950f4',
+ fromFieldMetadataId: 'c0d5849e-f4cd-4f40-81ff-5c8c82e49c07',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ accountOwner: {
+ id: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
+ icon: 'IconUserCircle',
+ name: 'accountOwner',
+ type: 'RELATION',
+ label: 'Account Owner',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
+ description:
+ 'Your team member responsible for managing the company account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: {
+ id: '9ca11143-4ae4-4ed4-b636-158bc14d9513',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: '20e60c1f-2dd8-4f1f-a1eb-b4c179cbcd4a',
+ toObjectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ fromFieldMetadataId: '58a6c41e-9ff0-4607-be3a-4356175b75dc',
+ fromObjectMetadataId:
+ '82dd61be-d849-41c2-b7c2-6a8ddb796e3e',
+ },
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ linkedinLink: {
+ id: 'a4230bd8-66ec-4f2f-810b-1d02f9709bfa',
+ icon: 'IconBrandLinkedin',
+ name: 'linkedinLink',
+ type: 'LINKS',
+ label: 'Linkedin',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
+ description: 'The company Linkedin account',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ primaryLinkUrl: "''",
+ secondaryLinks: "'[]'",
+ primaryLinkLabel: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ searchVector: {
+ id: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
+ icon: 'IconUser',
+ name: 'searchVector',
+ type: 'TS_VECTOR',
+ label: 'Search vector',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
+ description: 'Field used for full-text search',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ opportunities: {
+ id: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
+ icon: 'IconTargetArrow',
+ name: 'opportunities',
+ type: 'RELATION',
+ label: 'Opportunities',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
+ description: 'Opportunities linked to the company.',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '889b83fc-9a5e-414c-acb6-48e5aa029394',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'SET_NULL',
+ toFieldMetadataId: '2a12de2d-3c43-4108-bd0a-f52b053e2449',
+ toObjectMetadataId: 'da77d279-8984-4cb1-987a-14e2b0501288',
+ fromFieldMetadataId: '7524cc63-2522-4c70-8b12-21fe2fe8de26',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ accountOwnerId: {
+ id: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
+ icon: 'IconUserCircle',
+ name: 'accountOwnerId',
+ type: 'UUID',
+ label: 'Account Owner id (foreign key)',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-cce0-424e-8028-91f50eb9c768',
+ description:
+ 'Your team member responsible for managing the company account id foreign key',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ visaSponsorship: {
+ id: '26a67635-7d43-47f0-b895-1c8194a7fa30',
+ icon: 'IconBrandVisa',
+ name: 'visaSponsorship',
+ type: 'BOOLEAN',
+ label: 'Visa Sponsorship',
+ options: null,
+ isActive: true,
+ isCustom: true,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:12.014Z',
+ updatedAt: '2025-03-05T15:41:12.014Z',
+ isNullable: true,
+ standardId: null,
+ description: "Company's Visa Sponsorship Policy",
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: false,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ timelineActivities: {
+ id: '038ca1af-7f15-460d-b111-b71062a8a6be',
+ icon: 'IconIconTimelineEvent',
+ name: 'timelineActivities',
+ type: 'RELATION',
+ label: 'Timeline Activities',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: true,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
+ description: 'Timeline Activities linked to the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: {
+ id: '29a10f41-0265-4775-923f-0bbf548dc2ec',
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ relationType: 'ONE_TO_MANY',
+ onDeleteAction: 'CASCADE',
+ toFieldMetadataId: '96896f47-cb02-4164-b3f2-c24d12b30e74',
+ toObjectMetadataId: '1a41f4ba-7aad-4111-8035-961962702ebb',
+ fromFieldMetadataId: '038ca1af-7f15-460d-b111-b71062a8a6be',
+ fromObjectMetadataId:
+ '685ac06e-2351-421c-97ac-0bf4595819b8',
+ },
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ idealCustomerProfile: {
+ id: '214a5118-3ab5-4d2a-ac89-020f776831b3',
+ icon: 'IconTarget',
+ name: 'idealCustomerProfile',
+ type: 'BOOLEAN',
+ label: 'ICP',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: false,
+ standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
+ description:
+ 'Ideal Customer Profile: Indicates whether the company is the most suitable and valuable customer for you',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: false,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ annualRecurringRevenue: {
+ id: 'fba56220-3f40-4569-a500-35a4a312e473',
+ icon: 'IconMoneybag',
+ name: 'annualRecurringRevenue',
+ type: 'CURRENCY',
+ label: 'ARR',
+ options: null,
+ isActive: true,
+ isCustom: false,
+ isSystem: false,
+ isUnique: false,
+ settings: null,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ isNullable: true,
+ standardId: '20202020-602a-495c-9776-f5d5b11d227b',
+ description:
+ 'Annual Recurring Revenue: The actual or estimated annual revenue of the company',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ defaultValue: {
+ amountMicros: null,
+ currencyCode: "''",
+ },
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ toRelationMetadata: null,
+ fromRelationMetadata: null,
+ isLabelSyncedWithName: false,
+ relationTargetFieldMetadataId: null,
+ relationTargetObjectMetadataId: null,
+ },
+ },
+ isSearchable: true,
+ nameSingular: 'company',
+ isAuditLogged: true,
+ labelSingular: 'Company',
+ indexMetadatas: [
+ {
+ id: '9d5ef0cf-a301-44bf-98dd-c839d363f8f6',
+ name: 'IDX_UNIQUE_2a32339058d0b6910b0834ddf81',
+ isCustom: false,
+ isUnique: true,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ indexType: 'BTREE',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ indexWhereClause: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ indexFieldMetadatas: [
+ {
+ id: '12f75acc-33fc-49ee-af8f-39d9e8f17c3d',
+ order: 0,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ fieldMetadataId: 'dbc86e47-d2cf-4094-9a57-90212efde6a0',
+ indexMetadataId: '9d5ef0cf-a301-44bf-98dd-c839d363f8f6',
},
- },
- object: {
- icon: 'IconBuildingSkyscraper',
- label: 'Company',
- value: 'A company',
- isLeaf: true,
- fieldIdName: 'id',
- nameSingular: 'company',
- },
- _outputSchemaType: 'RECORD',
+ ],
},
- isLeaf: false,
- },
- workspaceMemberId: {
- type: 'string',
- label: 'Workspace Member ID',
- value: '53562519-b9e8-44f1-8dd1-e247cc7ef584',
- isLeaf: true,
- },
+ {
+ id: 'e554c7bb-c355-4594-a708-4ea4e7cbcbdc',
+ name: 'IDX_123501237187c835ede626367b7',
+ isCustom: false,
+ isUnique: false,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ indexType: 'BTREE',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ indexWhereClause: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ indexFieldMetadatas: [
+ {
+ id: 'cf3ebe8e-e213-4c4c-939f-d7fb36016823',
+ order: 0,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ fieldMetadataId: 'a6f9558c-76df-49d1-9011-16f2f3b8dbe2',
+ indexMetadataId: 'e554c7bb-c355-4594-a708-4ea4e7cbcbdc',
+ },
+ {
+ id: 'd2663353-c4a2-4787-98d1-6ad448a66d86',
+ order: 1,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ fieldMetadataId: '55e17b77-84f7-4b8a-bef5-be65f783d9f8',
+ indexMetadataId: 'e554c7bb-c355-4594-a708-4ea4e7cbcbdc',
+ },
+ ],
+ },
+ {
+ id: '48102f0b-0aef-4ae3-b3de-54e7c5bbdd1c',
+ name: 'IDX_fb1f4905546cfc6d70a971c76f7',
+ isCustom: false,
+ isUnique: false,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ indexType: 'GIN',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ workspaceId: '20202020-1c25-4d02-bf25-6aeccf7ea419',
+ indexWhereClause: null,
+ objectMetadataId: '685ac06e-2351-421c-97ac-0bf4595819b8',
+ indexFieldMetadatas: [
+ {
+ id: '5cd649b1-79b8-4b07-9c56-b70fe247954b',
+ order: 0,
+ createdAt: '2025-03-05T15:41:09.390Z',
+ updatedAt: '2025-03-05T15:41:09.390Z',
+ fieldMetadataId: '8b1e9e2c-684f-4e9e-9bdf-e1f705f8ca03',
+ indexMetadataId: '48102f0b-0aef-4ae3-b3de-54e7c5bbdd1c',
+ },
+ ],
+ },
+ ],
+ targetTableName: 'DEPRECATED',
+ duplicateCriteria: [['name'], ['domainNamePrimaryLinkUrl']],
+ isLabelSyncedWithName: false,
+ imageIdentifierFieldMetadataId: null,
+ labelIdentifierFieldMetadataId:
+ 'c6e6cf7d-63af-4131-9f99-ce0f74fd7d10',
},
},
+ status: StepStatus.SUCCESS,
},
- },
- stepsOutput: {
'212a171a-f887-4213-8892-e39c2a3ecc30': {
result: {
userId: ['20202020', '9e3b', '46d4', 'a556', '88b9ddc2b034'],
},
+ status: StepStatus.SUCCESS,
},
'753b124e-f427-44a4-ab08-bacfe9c2f746': {
result: {
@@ -10409,11 +8907,13 @@ export const oneSucceededWorkflowRunQueryResult = {
updatedAt: '2025-03-06T12:15:43.371Z',
searchVector: "'for':2 'proposal':1",
},
+ status: StepStatus.SUCCESS,
},
'a01b2953-9aa7-4d9a-aded-8e9bafbd6c30': {
result: {
date: '2025-03-06T12:15:43.358Z',
},
+ status: StepStatus.SUCCESS,
},
'd4a73172-3156-45bf-bc49-9358fbab2907': {
result: {
@@ -10439,6 +8939,7 @@ export const oneSucceededWorkflowRunQueryResult = {
searchVector: "'opportunity':1 'with':2",
pointOfContactId: null,
},
+ status: StepStatus.SUCCESS,
},
},
},
diff --git a/packages/twenty-server/src/database/commands/upgrade-version-command/1-1/1-1-migrate-workflow-run-state.command.ts b/packages/twenty-server/src/database/commands/upgrade-version-command/1-1/1-1-migrate-workflow-run-state.command.ts
index 76f1f9babb0..6daf6ed304f 100644
--- a/packages/twenty-server/src/database/commands/upgrade-version-command/1-1/1-1-migrate-workflow-run-state.command.ts
+++ b/packages/twenty-server/src/database/commands/upgrade-version-command/1-1/1-1-migrate-workflow-run-state.command.ts
@@ -3,6 +3,7 @@ import { InjectRepository } from '@nestjs/typeorm';
import { MoreThan, Repository } from 'typeorm';
import { Command, Option } from 'nest-commander';
import { isDefined } from 'twenty-shared/utils';
+import { StepStatus, WorkflowRunStepInfos } from 'twenty-shared/workflow';
import {
ActiveOrSuspendedWorkspacesMigrationCommandRunner,
@@ -15,10 +16,6 @@ import {
WorkflowRunOutput,
WorkflowRunWorkspaceEntity,
} from 'src/modules/workflow/common/standard-objects/workflow-run.workspace-entity';
-import {
- StepStatus,
- WorkflowRunStepInfo,
-} from 'src/modules/workflow/workflow-executor/types/workflow-run-step-info.type';
const DEFAULT_CHUNK_SIZE = 500;
@@ -121,7 +118,7 @@ export class MigrateWorkflowRunStatesCommand extends ActiveOrSuspendedWorkspaces
}
private buildRunStateFromOutput(output: WorkflowRunOutput): WorkflowRunState {
- const stepInfos: Record<string, WorkflowRunStepInfo> = Object.fromEntries(
+ const stepInfos: WorkflowRunStepInfos = Object.fromEntries(
output.flow.steps.map((step) => {
const stepOutput = output.stepsOutput?.[step.id];
const status = stepOutput?.pendingEvent
diff --git a/packages/twenty-server/src/engine/core-modules/cache-lock/with-lock.decorator.ts b/packages/twenty-server/src/engine/core-modules/cache-lock/with-lock.decorator.ts
new file mode 100644
index 00000000000..d5aea078ec2
--- /dev/null
+++ b/packages/twenty-server/src/engine/core-modules/cache-lock/with-lock.decorator.ts
@@ -0,0 +1,48 @@
+import { Inject } from '@nestjs/common';
+
+import {
+ CacheLockOptions,
+ CacheLockService,
+} from 'src/engine/core-modules/cache-lock/cache-lock.service';
+
+export const WithLock = (
+ lockKeyParamPath: string,
+ options?: CacheLockOptions,
+): MethodDecorator => {
+ const injectCacheLockService = Inject(CacheLockService);
+
+ return function (target, propertyKey, descriptor: PropertyDescriptor) {
+ injectCacheLockService(target, 'cacheLockService');
+
+ const originalMethod = descriptor.value;
+
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
+ descriptor.value = async function (...args: any[]) {
+ const self = this as { cacheLockService: CacheLockService };
+
+ if (!self.cacheLockService) {
+ throw new Error('cacheLockService not available on instance');
+ }
+
+ if (typeof args[0] !== 'object') {
+ throw new Error(
+ `You must use one object parameter to use @WithLock decorator. Received ${args}`,
+ );
+ }
+
+ const key = args[0][lockKeyParamPath];
+
+ if (typeof key !== 'string') {
+ throw new Error(
+ `Could not resolve lock key from path "${lockKeyParamPath}" on first argument`,
+ );
+ }
+
+ return await self.cacheLockService.withLock(
+ () => originalMethod.apply(self, args),
+ key,
+ options,
+ );
+ };
+ };
+};
diff --git a/packages/twenty-server/src/engine/core-modules/message-queue/decorators/process.decorator.ts b/packages/twenty-server/src/engine/core-modules/message-queue/decorators/process.decorator.ts
index 62ec636ade9..c739944a177 100644
--- a/packages/twenty-server/src/engine/core-modules/message-queue/decorators/process.decorator.ts
+++ b/packages/twenty-server/src/engine/core-modules/message-queue/decorators/process.decorator.ts
@@ -1,21 +1,11 @@
import { SetMetadata } from '@nestjs/common';
-import { isString } from '@nestjs/common/utils/shared.utils';
import { PROCESS_METADATA } from 'src/engine/core-modules/message-queue/message-queue.constants';
export interface MessageQueueProcessOptions {
jobName: string;
- concurrency?: number;
}
-export function Process(jobName: string): MethodDecorator;
-export function Process(options: MessageQueueProcessOptions): MethodDecorator;
-export function Process(
- nameOrOptions: string | MessageQueueProcessOptions,
-): MethodDecorator {
- const options = isString(nameOrOptions)
- ? { jobName: nameOrOptions }
- : nameOrOptions;
-
- return SetMetadata(PROCESS_METADATA, options || {});
+export function Process(jobName: string): MethodDecorator {
+ return SetMetadata(PROCESS_METADATA, { jobName });
}
diff --git a/packages/twenty-server/src/engine/core-modules/message-queue/decorators/processor.decorator.ts b/packages/twenty-server/src/engine/core-modules/message-queue/decorators/processor.decorator.ts
index 07979b452d3..e1301578c6e 100644
--- a/packages/twenty-server/src/engine/core-modules/message-queue/decorators/processor.decorator.ts
+++ b/packages/twenty-server/src/engine/core-modules/message-queue/decorators/processor.decorator.ts
@@ -1,12 +1,9 @@
import { Scope, SetMetadata } from '@nestjs/common';
import { SCOPE_OPTIONS_METADATA } from '@nestjs/common/constants';
-import { MessageQueueWorkerOptions } from 'src/engine/core-modules/message-queue/interfaces/message-queue-worker-options.interface';
-
import {
MessageQueue,
PROCESSOR_METADATA,
- WORKER_METADATA,
} from 'src/engine/core-modules/message-queue/message-queue.constants';
export interface MessageQueueProcessorOptions {
@@ -24,16 +21,7 @@ export interface MessageQueueProcessorOptions {
* Represents a worker that is able to process jobs from the queue.
* @param queueName name of the queue to process
*/
-export function Processor(queueName: string): ClassDecorator;
-/**
- * Represents a worker that is able to process jobs from the queue.
- * @param queueName name of the queue to process
- * @param workerOptions additional worker options
- */
-export function Processor(
- queueName: string,
- workerOptions: MessageQueueWorkerOptions,
-): ClassDecorator;
+export function Processor(queueName: MessageQueue): ClassDecorator;
/**
* Represents a worker that is able to process jobs from the queue.
* @param processorOptions processor options
@@ -41,21 +29,11 @@ export function Processor(
export function Processor(
processorOptions: MessageQueueProcessorOptions,
): ClassDecorator;
-/**
- * Represents a worker that is able to process jobs from the queue.
- * @param processorOptions processor options (Nest-specific)
- * @param workerOptions additional Bull worker options
- */
-export function Processor(
- processorOptions: MessageQueueProcessorOptions,
- workerOptions: MessageQueueWorkerOptions,
-): ClassDecorator;
export function Processor(
- queueNameOrOptions?: string | MessageQueueProcessorOptions,
- maybeWorkerOptions?: MessageQueueWorkerOptions,
+ queueNameOrOptions: string | MessageQueueProcessorOptions,
): ClassDecorator {
const options =
- queueNameOrOptions && typeof queueNameOrOptions === 'object'
+ typeof queueNameOrOptions === 'object'
? queueNameOrOptions
: { queueName: queueNameOrOptions };
@@ -63,7 +41,5 @@ export function Processor(
return (target: Function) => {
SetMetadata(SCOPE_OPTIONS_METADATA, options)(target);
SetMetadata(PROCESSOR_METADATA, options)(target);
- maybeWorkerOptions &&
- SetMetadata(WORKER_METADATA, maybeWorkerOptions)(target);
};
}
diff --git a/packages/twenty-server/src/engine/core-modules/message-queue/message-queue.constants.ts b/packages/twenty-server/src/engine/core-modules/message-queue/message-queue.constants.ts
index f5e2baa114f..a1277d8e74f 100644
--- a/packages/twenty-server/src/engine/core-modules/message-queue/message-queue.constants.ts
+++ b/packages/twenty-server/src/engine/core-modules/message-queue/message-queue.constants.ts
@@ -1,6 +1,5 @@
export const PROCESSOR_METADATA = Symbol('message-queue:processor_metadata');
export const PROCESS_METADATA = Symbol('message-queue:process_metadata');
-export const WORKER_METADATA = Symbol('bullmq:worker_metadata');
export const QUEUE_DRIVER = Symbol('message-queue:queue_driver');
export enum MessageQueue {
@@ -13,11 +12,8 @@ export enum MessageQueue {
contactCreationQueue = 'contact-creation-queue',
billingQueue = 'billing-queue',
workspaceQueue = 'workspace-queue',
- recordPositionBackfillQueue = 'record-position-backfill-queue',
entityEventsToDbQueue = 'entity-events-to-db-queue',
- testQueue = 'test-queue',
workflowQueue = 'workflow-queue',
- serverlessFunctionQueue = 'serverless-function-queue',
deleteCascadeQueue = 'delete-cascade-queue',
subscriptionsQueue = 'subscriptions-queue',
}
diff --git a/packages/twenty-server/src/modules/workflow/common/standard-objects/workflow-run.workspace-entity.ts b/packages/twenty-server/src/modules/workflow/common/standard-objects/workflow-run.workspace-entity.ts
index d0011e582e3..27089393e77 100644
--- a/packages/twenty-server/src/modules/workflow/common/standard-objects/workflow-run.workspace-entity.ts
+++ b/packages/twenty-server/src/modules/workflow/common/standard-objects/workflow-run.workspace-entity.ts
@@ -1,5 +1,6 @@
import { msg } from '@lingui/core/macro';
import { FieldMetadataType } from 'twenty-shared/types';
+import { WorkflowRunStepInfos } from 'twenty-shared/workflow';
import { RelationOnDeleteAction } from 'src/engine/metadata-modules/field-metadata/interfaces/relation-on-delete-action.interface';
import { RelationType } from 'src/engine/metadata-modules/field-metadata/interfaces/relation-type.interface';
@@ -29,7 +30,6 @@ import { TimelineActivityWorkspaceEntity } from 'src/modules/timeline/standard-o
import { WorkflowVersionWorkspaceEntity } from 'src/modules/workflow/common/standard-objects/workflow-version.workspace-entity';
import { WorkflowWorkspaceEntity } from 'src/modules/workflow/common/standard-objects/workflow.workspace-entity';
import { WorkflowActionOutput } from 'src/modules/workflow/workflow-executor/types/workflow-action-output.type';
-import { WorkflowRunStepInfo } from 'src/modules/workflow/workflow-executor/types/workflow-run-step-info.type';
import { WorkflowAction } from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action.type';
import { WorkflowTrigger } from 'src/modules/workflow/workflow-trigger/types/workflow-trigger.type';
@@ -60,7 +60,7 @@ export type WorkflowRunState = {
trigger: WorkflowTrigger;
steps: WorkflowAction[];
};
- stepInfos: Record<string, WorkflowRunStepInfo>;
+ stepInfos: WorkflowRunStepInfos;
workflowRunError?: string;
};
diff --git a/packages/twenty-server/src/modules/workflow/workflow-builder/workflow-step/workflow-version-step.workspace-service.ts b/packages/twenty-server/src/modules/workflow/workflow-builder/workflow-step/workflow-version-step.workspace-service.ts
index 0a5501a5e28..215d7511997 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-builder/workflow-step/workflow-version-step.workspace-service.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-builder/workflow-step/workflow-version-step.workspace-service.ts
@@ -6,6 +6,7 @@ import { FieldMetadataType } from 'twenty-shared/types';
import { isDefined, isValidUuid } from 'twenty-shared/utils';
import { Repository } from 'typeorm';
import { v4 } from 'uuid';
+import { StepStatus } from 'twenty-shared/workflow';
import { BASE_TYPESCRIPT_PROJECT_INPUT_SCHEMA } from 'src/engine/core-modules/serverless/drivers/constants/base-typescript-project-input-schema';
import { CreateWorkflowVersionStepInput } from 'src/engine/core-modules/workflow/dtos/create-workflow-version-step-input.dto';
@@ -27,7 +28,6 @@ import { WorkflowCommonWorkspaceService } from 'src/modules/workflow/common/work
import { WorkflowSchemaWorkspaceService } from 'src/modules/workflow/workflow-builder/workflow-schema/workflow-schema.workspace-service';
import { insertStep } from 'src/modules/workflow/workflow-builder/workflow-step/utils/insert-step';
import { removeStep } from 'src/modules/workflow/workflow-builder/workflow-step/utils/remove-step';
-import { StepStatus } from 'src/modules/workflow/workflow-executor/types/workflow-run-step-info.type';
import { BaseWorkflowActionSettings } from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action-settings.type';
import {
WorkflowAction,
@@ -302,7 +302,7 @@ export class WorkflowVersionStepWorkspaceService {
workspaceId,
});
- const step = workflowRun.output?.flow?.steps?.find(
+ const step = workflowRun.state?.flow?.steps?.find(
(step) => step.id === stepId,
);
diff --git a/packages/twenty-server/src/modules/workflow/workflow-executor/utils/__tests__/can-execute-step.util.spec.ts b/packages/twenty-server/src/modules/workflow/workflow-executor/utils/__tests__/can-execute-step.util.spec.ts
index 4a565771a65..b50dda8d1c5 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-executor/utils/__tests__/can-execute-step.util.spec.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-executor/utils/__tests__/can-execute-step.util.spec.ts
@@ -1,8 +1,10 @@
+import { StepStatus } from 'twenty-shared/workflow';
+
import {
WorkflowAction,
WorkflowActionType,
} from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action.type';
-import { canExecuteStep } from 'src/modules/workflow/workflow-executor/utils/can-execute-step.utils';
+import { canExecuteStep } from 'src/modules/workflow/workflow-executor/utils/can-execute-step.util';
describe('canExecuteStep', () => {
const steps = [
@@ -42,13 +44,19 @@ describe('canExecuteStep', () => {
] as WorkflowAction[];
it('should return true if all parents succeeded', () => {
- const context = {
- trigger: 'trigger result',
- 'step-1': 'step-1 result',
- 'step-2': 'step-2 result',
+ const stepInfos = {
+ 'step-1': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-2': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-3': {
+ status: StepStatus.NOT_STARTED,
+ },
};
- const result = canExecuteStep({ context, steps, stepId: 'step-3' });
+ const result = canExecuteStep({ stepInfos, steps, stepId: 'step-3' });
expect(result).toBe(true);
});
@@ -56,9 +64,90 @@ describe('canExecuteStep', () => {
it('should return false if one parent is not succeeded', () => {
expect(
canExecuteStep({
- context: {
- trigger: 'trigger result',
- 'step-2': 'step-2 result',
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.NOT_STARTED,
+ },
+ 'step-2': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-3': {
+ status: StepStatus.NOT_STARTED,
+ },
+ },
+ steps,
+ stepId: 'step-3',
+ }),
+ ).toBe(false);
+
+ expect(
+ canExecuteStep({
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-2': {
+ status: StepStatus.NOT_STARTED,
+ },
+ 'step-3': {
+ status: StepStatus.NOT_STARTED,
+ },
+ },
+ steps,
+ stepId: 'step-3',
+ }),
+ ).toBe(false);
+
+ expect(
+ canExecuteStep({
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.NOT_STARTED,
+ },
+ 'step-2': {
+ status: StepStatus.NOT_STARTED,
+ },
+ 'step-3': {
+ status: StepStatus.NOT_STARTED,
+ },
+ },
+ steps,
+ stepId: 'step-3',
+ }),
+ ).toBe(false);
+ });
+
+ it('should return false if step has already ran', () => {
+ expect(
+ canExecuteStep({
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-2': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-3': {
+ status: StepStatus.SUCCESS,
+ },
+ },
+ steps,
+ stepId: 'step-3',
+ }),
+ ).toBe(false);
+
+ expect(
+ canExecuteStep({
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-2': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-3': {
+ status: StepStatus.PENDING,
+ },
},
steps,
stepId: 'step-3',
@@ -67,9 +156,16 @@ describe('canExecuteStep', () => {
expect(
canExecuteStep({
- context: {
- trigger: 'trigger result',
- 'step-1': 'step-1 result',
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-2': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-3': {
+ status: StepStatus.FAILED,
+ },
},
steps,
stepId: 'step-3',
@@ -78,9 +174,16 @@ describe('canExecuteStep', () => {
expect(
canExecuteStep({
- context: {
- trigger: 'trigger result',
- 'step-1': {},
+ stepInfos: {
+ 'step-1': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-2': {
+ status: StepStatus.SUCCESS,
+ },
+ 'step-3': {
+ status: StepStatus.RUNNING,
+ },
},
steps,
stepId: 'step-3',
diff --git a/packages/twenty-server/src/modules/workflow/workflow-executor/utils/can-execute-step.utils.ts b/packages/twenty-server/src/modules/workflow/workflow-executor/utils/can-execute-step.util.ts
similarity index 53%
rename from packages/twenty-server/src/modules/workflow/workflow-executor/utils/can-execute-step.utils.ts
rename to packages/twenty-server/src/modules/workflow/workflow-executor/utils/can-execute-step.util.ts
index 81f31eb7f70..1f7a71e9b04 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-executor/utils/can-execute-step.utils.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-executor/utils/can-execute-step.util.ts
@@ -1,23 +1,30 @@
import { isDefined } from 'twenty-shared/utils';
+import { StepStatus, WorkflowRunStepInfos } from 'twenty-shared/workflow';
import { WorkflowAction } from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action.type';
export const canExecuteStep = ({
- context,
stepId,
steps,
+ stepInfos,
}: {
steps: WorkflowAction[];
- context: Record<string, unknown>;
+ stepInfos: WorkflowRunStepInfos;
stepId: string;
}) => {
+ if (
+ isDefined(stepInfos[stepId]?.status) &&
+ stepInfos[stepId].status !== StepStatus.NOT_STARTED
+ ) {
+ return false;
+ }
+
const parentSteps = steps.filter(
(parentStep) =>
isDefined(parentStep) && parentStep.nextStepIds?.includes(stepId),
);
- // TODO use workflowRun.state to check if step status is not COMPLETED. Return false in this case
- return parentSteps.every((parentStep) =>
- Object.keys(context).includes(parentStep.id),
+ return parentSteps.every(
+ (parentStep) => stepInfos[parentStep.id]?.status === StepStatus.SUCCESS,
);
};
diff --git a/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/__tests__/workflow-executor.workspace-service.spec.ts b/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/__tests__/workflow-executor.workspace-service.spec.ts
index ff1b75f3e1d..5ccb7daaa6c 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/__tests__/workflow-executor.workspace-service.spec.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/__tests__/workflow-executor.workspace-service.spec.ts
@@ -1,5 +1,7 @@
import { Test, TestingModule } from '@nestjs/testing';
+import { getWorkflowRunContext, StepStatus } from 'twenty-shared/workflow';
+
import { BILLING_FEATURE_USED } from 'src/engine/core-modules/billing/constants/billing-feature-used.constant';
import { BILLING_WORKFLOW_EXECUTION_ERROR_MESSAGE } from 'src/engine/core-modules/billing/constants/billing-workflow-execution-error-message.constant';
import { BillingMeterEventName } from 'src/engine/core-modules/billing/enums/billing-meter-event-names';
@@ -12,15 +14,14 @@ import {
} from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action.type';
import { WorkflowExecutorWorkspaceService } from 'src/modules/workflow/workflow-executor/workspace-services/workflow-executor.workspace-service';
import { WorkflowRunWorkspaceService } from 'src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service';
-import { StepStatus } from 'src/modules/workflow/workflow-executor/types/workflow-run-step-info.type';
import { WorkflowRunStatus } from 'src/modules/workflow/common/standard-objects/workflow-run.workspace-entity';
-import { canExecuteStep } from 'src/modules/workflow/workflow-executor/utils/can-execute-step.utils';
+import { canExecuteStep } from 'src/modules/workflow/workflow-executor/utils/can-execute-step.util';
jest.mock(
- 'src/modules/workflow/workflow-executor/utils/can-execute-step.utils',
+ 'src/modules/workflow/workflow-executor/utils/can-execute-step.util',
() => {
const actual = jest.requireActual(
- 'src/modules/workflow/workflow-executor/utils/can-execute-step.utils',
+ 'src/modules/workflow/workflow-executor/utils/can-execute-step.util',
);
return {
@@ -100,7 +101,6 @@ describe('WorkflowExecutorWorkspaceService', () => {
describe('execute', () => {
const mockWorkflowRunId = 'workflow-run-id';
const mockWorkspaceId = 'workspace-id';
- const mockContext = { trigger: 'trigger-result' };
const mockSteps = [
{
id: 'step-1',
@@ -125,10 +125,12 @@ describe('WorkflowExecutorWorkspaceService', () => {
nextStepIds: [],
},
] as WorkflowAction[];
+ const mockStepInfos = {
+ trigger: { result: {}, status: StepStatus.SUCCESS },
+ };
mockWorkflowRunWorkspaceService.getWorkflowRun.mockReturnValue({
- output: { flow: { steps: mockSteps } },
- context: mockContext,
+ state: { flow: { steps: mockSteps }, stepInfos: mockStepInfos },
});
it('should execute a step and continue to the next step on success', async () => {
@@ -151,7 +153,7 @@ describe('WorkflowExecutorWorkspaceService', () => {
expect(mockWorkflowExecutor.execute).toHaveBeenCalledWith({
currentStepId: 'step-1',
steps: mockSteps,
- context: mockContext,
+ context: getWorkflowRunContext(mockStepInfos),
});
expect(workspaceEventEmitter.emitCustomBatchEvent).toHaveBeenCalledWith(
@@ -319,8 +321,10 @@ describe('WorkflowExecutorWorkspaceService', () => {
] as WorkflowAction[];
mockWorkflowRunWorkspaceService.getWorkflowRun.mockReturnValueOnce({
- output: { flow: { steps: stepsWithContinueOnFailure } },
- context: mockContext,
+ state: {
+ flow: { steps: stepsWithContinueOnFailure },
+ stepInfos: mockStepInfos,
+ },
});
mockWorkflowExecutor.execute.mockResolvedValueOnce({
@@ -385,8 +389,10 @@ describe('WorkflowExecutorWorkspaceService', () => {
] as WorkflowAction[];
mockWorkflowRunWorkspaceService.getWorkflowRun.mockReturnValue({
- output: { flow: { steps: stepsWithRetryOnFailure } },
- context: mockContext,
+ state: {
+ flow: { steps: stepsWithRetryOnFailure },
+ stepInfos: mockStepInfos,
+ },
});
mockWorkflowExecutor.execute.mockResolvedValue({
diff --git a/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/workflow-executor.workspace-service.ts b/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/workflow-executor.workspace-service.ts
index b59fd5f9586..7ca405d7278 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/workflow-executor.workspace-service.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-executor/workspace-services/workflow-executor.workspace-service.ts
@@ -1,6 +1,7 @@
import { Injectable } from '@nestjs/common';
import { isDefined } from 'twenty-shared/utils';
+import { getWorkflowRunContext, StepStatus } from 'twenty-shared/workflow';
import { BILLING_FEATURE_USED } from 'src/engine/core-modules/billing/constants/billing-feature-used.constant';
import { BILLING_WORKFLOW_EXECUTION_ERROR_MESSAGE } from 'src/engine/core-modules/billing/constants/billing-workflow-execution-error-message.constant';
@@ -19,8 +20,7 @@ import {
WorkflowBranchExecutorInput,
WorkflowExecutorInput,
} from 'src/modules/workflow/workflow-executor/types/workflow-executor-input';
-import { StepStatus } from 'src/modules/workflow/workflow-executor/types/workflow-run-step-info.type';
-import { canExecuteStep } from 'src/modules/workflow/workflow-executor/utils/can-execute-step.utils';
+import { canExecuteStep } from 'src/modules/workflow/workflow-executor/utils/can-execute-step.util';
import { WorkflowRunWorkspaceService } from 'src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service';
const MAX_RETRIES_ON_FAILURE = 3;
@@ -57,7 +57,7 @@ export class WorkflowExecutorWorkspaceService {
workspaceId,
}: WorkflowBranchExecutorInput) {
const workflowRunInfo = await this.getWorkflowRunInfoOrEndWorkflowRun({
- stepId: stepId,
+ stepId,
workflowRunId,
workspaceId,
});
@@ -66,9 +66,9 @@ export class WorkflowExecutorWorkspaceService {
return;
}
- const { stepToExecute, steps, context } = workflowRunInfo;
+ const { stepToExecute, steps, stepInfos } = workflowRunInfo;
- if (!canExecuteStep({ stepId: stepToExecute.id, steps, context })) {
+ if (!canExecuteStep({ stepId, steps, stepInfos })) {
return;
}
@@ -98,7 +98,7 @@ export class WorkflowExecutorWorkspaceService {
actionOutput = await workflowAction.execute({
currentStepId: stepId,
steps,
- context,
+ context: getWorkflowRunContext(stepInfos),
});
} catch (error) {
actionOutput = {
@@ -219,31 +219,18 @@ export class WorkflowExecutorWorkspaceService {
return;
}
- const steps = workflowRun.output?.flow.steps;
-
- const context = workflowRun.context;
-
- if (!isDefined(steps)) {
+ if (!isDefined(workflowRun?.state)) {
await this.workflowRunWorkspaceService.endWorkflowRun({
workflowRunId,
workspaceId,
status: WorkflowRunStatus.FAILED,
- error: 'Steps undefined',
+ error: `WorkflowRun ${workflowRunId} doesn't have any state`,
});
return;
}
- if (!isDefined(context)) {
- await this.workflowRunWorkspaceService.endWorkflowRun({
- workflowRunId,
- workspaceId,
- status: WorkflowRunStatus.FAILED,
- error: 'Context not found',
- });
-
- return;
- }
+ const steps = workflowRun.state.flow.steps;
const stepToExecute = steps.find((step) => step.id === stepId);
@@ -258,7 +245,11 @@ export class WorkflowExecutorWorkspaceService {
return;
}
- return { stepToExecute, steps, context };
+ return {
+ stepToExecute,
+ steps,
+ stepInfos: workflowRun.state.stepInfos,
+ };
}
private sendWorkflowNodeRunEvent(workspaceId: string) {
diff --git a/packages/twenty-server/src/modules/workflow/workflow-runner/jobs/run-workflow.job.ts b/packages/twenty-server/src/modules/workflow/workflow-runner/jobs/run-workflow.job.ts
index c3cf95fe5ac..5af6eb2ae11 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-runner/jobs/run-workflow.job.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-runner/jobs/run-workflow.job.ts
@@ -144,7 +144,7 @@ export class RunWorkflowJob {
);
}
- const lastExecutedStep = workflowRun.output?.flow?.steps?.find(
+ const lastExecutedStep = workflowRun.state?.flow?.steps?.find(
(step) => step.id === lastExecutedStepId,
);
diff --git a/packages/twenty-server/src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service.ts b/packages/twenty-server/src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service.ts
index 1da904af46b..6460ad44666 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service.ts
+++ b/packages/twenty-server/src/modules/workflow/workflow-runner/workflow-run/workflow-run.workspace-service.ts
@@ -5,6 +5,7 @@ import { Repository } from 'typeorm';
import { v4 } from 'uuid';
import { isDefined } from 'twenty-shared/utils';
import { QueryDeepPartialEntity } from 'typeorm/query-builder/QueryPartialEntity';
+import { StepStatus } from 'twenty-shared/workflow';
import { DatabaseEventAction } from 'src/engine/api/graphql/graphql-query-runner/enums/database-event-action';
import { objectRecordChangedValues } from 'src/engine/core-modules/event-emitter/utils/object-record-changed-values';
@@ -28,9 +29,8 @@ import {
WorkflowRunException,
WorkflowRunExceptionCode,
} from 'src/modules/workflow/workflow-runner/exceptions/workflow-run.exception';
-import { StepStatus } from 'src/modules/workflow/workflow-executor/types/workflow-run-step-info.type';
import { WorkflowVersionWorkspaceEntity } from 'src/modules/workflow/common/standard-objects/workflow-version.workspace-entity';
-import { CacheLockService } from 'src/engine/core-modules/cache-lock/cache-lock.service';
+import { WithLock } from 'src/engine/core-modules/cache-lock/with-lock.decorator';
@Injectable()
export class WorkflowRunWorkspaceService {
@@ -43,7 +43,6 @@ export class WorkflowRunWorkspaceService {
private readonly objectMetadataRepository: Repository<ObjectMetadataEntity>,
private readonly recordPositionService: RecordPositionService,
private readonly metricsService: MetricsService,
- private readonly cacheLockService: CacheLockService,
) {}
async createWorkflowRun({
@@ -141,18 +140,8 @@ export class WorkflowRunWorkspaceService {
return workflowRun.id;
}
- async startWorkflowRun(params: {
- workflowRunId: string;
- workspaceId: string;
- payload: object;
- }) {
- await this.cacheLockService.withLock(
- async () => await this.startWorkflowRunWithoutLock(params),
- params.workflowRunId,
- );
- }
-
- private async startWorkflowRunWithoutLock({
+ @WithLock('workflowRunId')
+ async startWorkflowRun({
workflowRunId,
workspaceId,
payload,
@@ -207,19 +196,8 @@ export class WorkflowRunWorkspaceService {
await this.updateWorkflowRun({ workflowRunId, workspaceId, partialUpdate });
}
- async endWorkflowRun(params: {
- workflowRunId: string;
- workspaceId: string;
- status: WorkflowRunStatus;
- error?: string;
- }) {
- await this.cacheLockService.withLock(
- async () => await this.endWorkflowRunWithoutLock(params),
- params.workflowRunId,
- );
- }
-
- private async endWorkflowRunWithoutLock({
+ @WithLock('workflowRunId')
+ async endWorkflowRun({
workflowRunId,
workspaceId,
status,
@@ -259,19 +237,8 @@ export class WorkflowRunWorkspaceService {
});
}
- async updateWorkflowRunStepStatus(params: {
- workflowRunId: string;
- stepId: string;
- workspaceId: string;
- stepStatus: StepStatus;
- }) {
- await this.cacheLockService.withLock(
- async () => await this.updateWorkflowRunStepStatusWithoutLock(params),
- params.workflowRunId,
- );
- }
-
- private async updateWorkflowRunStepStatusWithoutLock({
+ @WithLock('workflowRunId')
+ async updateWorkflowRunStepStatus({
workflowRunId,
workspaceId,
stepId,
@@ -303,19 +270,8 @@ export class WorkflowRunWorkspaceService {
await this.updateWorkflowRun({ workflowRunId, workspaceId, partialUpdate });
}
- async saveWorkflowRunState(params: {
- workflowRunId: string;
- stepOutput: StepOutput;
- workspaceId: string;
- stepStatus: StepStatus;
- }) {
- await this.cacheLockService.withLock(
- async () => await this.saveWorkflowRunStateWithoutLock(params),
- params.workflowRunId,
- );
- }
-
- private async saveWorkflowRunStateWithoutLock({
+ @WithLock('workflowRunId')
+ async saveWorkflowRunState({
workflowRunId,
stepOutput,
workspaceId,
@@ -367,18 +323,8 @@ export class WorkflowRunWorkspaceService {
await this.updateWorkflowRun({ workflowRunId, workspaceId, partialUpdate });
}
- async updateWorkflowRunStep(params: {
- workflowRunId: string;
- step: WorkflowAction;
- workspaceId: string;
- }) {
- await this.cacheLockService.withLock(
- async () => await this.updateWorkflowRunStepWithoutLock(params),
- params.workflowRunId,
- );
- }
-
- private async updateWorkflowRunStepWithoutLock({
+ @WithLock('workflowRunId')
+ async updateWorkflowRunStep({
workflowRunId,
step,
workspaceId,
diff --git a/packages/twenty-shared/package.json b/packages/twenty-shared/package.json
index 9a244393969..2350472e470 100644
--- a/packages/twenty-shared/package.json
+++ b/packages/twenty-shared/package.json
@@ -34,6 +34,7 @@
"./translations/index.ts",
"./types/index.ts",
"./utils/index.ts",
+ "./workflow/index.ts",
"./workspace/index.ts"
]
},
@@ -44,6 +45,7 @@
"translations",
"types",
"utils",
+ "workflow",
"workspace"
]
}
diff --git a/packages/twenty-shared/project.json b/packages/twenty-shared/project.json
index 9d96d39732d..cb0e481317c 100644
--- a/packages/twenty-shared/project.json
+++ b/packages/twenty-shared/project.json
@@ -24,6 +24,8 @@
"{projectRoot}/types/dist",
"{projectRoot}/utils/package.json",
"{projectRoot}/utils/dist",
+ "{projectRoot}/workflow/package.json",
+ "{projectRoot}/workflow/dist",
"{projectRoot}/workspace/package.json",
"{projectRoot}/workspace/dist"
]
diff --git a/packages/twenty-shared/src/workflow/index.ts b/packages/twenty-shared/src/workflow/index.ts
new file mode 100644
index 00000000000..b6eab929393
--- /dev/null
+++ b/packages/twenty-shared/src/workflow/index.ts
@@ -0,0 +1,15 @@
+/*
+ * _____ _
+ *|_ _|_ _____ _ __ | |_ _ _
+ * | | \ \ /\ / / _ \ '_ \| __| | | | Auto-generated file
+ * | | \ V V / __/ | | | |_| |_| | Any edits to this will be overridden
+ * |_| \_/\_/ \___|_| |_|\__|\__, |
+ * |___/
+ */
+
+export type {
+ WorkflowRunStepInfo,
+ WorkflowRunStepInfos,
+} from './types/WorkflowRunStateStepInfos';
+export { StepStatus } from './types/WorkflowRunStateStepInfos';
+export { getWorkflowRunContext } from './utils/getWorkflowRunContext';
diff --git a/packages/twenty-server/src/modules/workflow/workflow-executor/types/workflow-run-step-info.type.ts b/packages/twenty-shared/src/workflow/types/WorkflowRunStateStepInfos.ts
similarity index 77%
rename from packages/twenty-server/src/modules/workflow/workflow-executor/types/workflow-run-step-info.type.ts
rename to packages/twenty-shared/src/workflow/types/WorkflowRunStateStepInfos.ts
index d4dbcfadeff..2719211bed8 100644
--- a/packages/twenty-server/src/modules/workflow/workflow-executor/types/workflow-run-step-info.type.ts
+++ b/packages/twenty-shared/src/workflow/types/WorkflowRunStateStepInfos.ts
@@ -11,3 +11,5 @@ export type WorkflowRunStepInfo = {
error?: string;
status: StepStatus;
};
+
+export type WorkflowRunStepInfos = Record<string, WorkflowRunStepInfo>;
diff --git a/packages/twenty-shared/src/workflow/utils/__tests__/getWorkflowRunContext.test.ts b/packages/twenty-shared/src/workflow/utils/__tests__/getWorkflowRunContext.test.ts
new file mode 100644
index 00000000000..b09e23ea9b6
--- /dev/null
+++ b/packages/twenty-shared/src/workflow/utils/__tests__/getWorkflowRunContext.test.ts
@@ -0,0 +1,37 @@
+import { getWorkflowRunContext } from '@/workflow/utils/getWorkflowRunContext';
+import {
+ StepStatus,
+ WorkflowRunStepInfos,
+} from '@/workflow/types/WorkflowRunStateStepInfos';
+
+describe('getWorkflowRunContext', () => {
+ it('returns a context with only steps that have a defined result', () => {
+ const stepInfos: WorkflowRunStepInfos = {
+ step1: { result: { res: 'value1' }, status: StepStatus.SUCCESS },
+ step2: { result: {}, status: StepStatus.SUCCESS },
+ step3: { status: StepStatus.NOT_STARTED },
+ step4: { result: { res: 0 }, status: StepStatus.SUCCESS },
+ step5: { result: { res: undefined }, status: StepStatus.SUCCESS },
+ };
+
+ const context = getWorkflowRunContext(stepInfos);
+
+ expect(context).toEqual({
+ step1: { res: 'value1' },
+ step2: {},
+ step4: { res: 0 },
+ step5: { res: undefined },
+ });
+ });
+
+ it('returns an empty object when no step has a defined result', () => {
+ const stepInfos: WorkflowRunStepInfos = {
+ step1: { status: StepStatus.NOT_STARTED },
+ step2: { status: StepStatus.NOT_STARTED },
+ };
+
+ const context = getWorkflowRunContext(stepInfos);
+
+ expect(context).toEqual({});
+ });
+});
diff --git a/packages/twenty-shared/src/workflow/utils/getWorkflowRunContext.ts b/packages/twenty-shared/src/workflow/utils/getWorkflowRunContext.ts
new file mode 100644
index 00000000000..248dca2c6f7
--- /dev/null
+++ b/packages/twenty-shared/src/workflow/utils/getWorkflowRunContext.ts
@@ -0,0 +1,12 @@
+import { isDefined } from '@/utils';
+import { WorkflowRunStepInfos } from '@/workflow/types/WorkflowRunStateStepInfos';
+
+export const getWorkflowRunContext = (
+ stepInfos: WorkflowRunStepInfos,
+): Record<string, unknown> => {
+ return Object.fromEntries(
+ Object.entries(stepInfos)
+ .filter(([, value]) => isDefined(value?.['result']))
+ .map(([key, value]) => [key, value?.['result']]),
+ );
+};
diff --git a/packages/twenty-shared/workflow/package.json b/packages/twenty-shared/workflow/package.json
new file mode 100644
index 00000000000..61e09225feb
--- /dev/null
+++ b/packages/twenty-shared/workflow/package.json
@@ -0,0 +1,4 @@
+{
+ "main": "dist/twenty-shared-workflow.cjs.js",
+ "module": "dist/twenty-shared-workflow.esm.js"
+}