diff --git a/apps/web/app/(app)/environments/[environmentId]/integrations/notion/constants.ts b/apps/web/app/(app)/environments/[environmentId]/integrations/notion/constants.ts index 5f24b5fd24..a2ef63ba6a 100644 --- a/apps/web/app/(app)/environments/[environmentId]/integrations/notion/constants.ts +++ b/apps/web/app/(app)/environments/[environmentId]/integrations/notion/constants.ts @@ -25,6 +25,8 @@ export const TYPE_MAPPING = { [TSurveyQuestionTypeEnum.Address]: ["rich_text"], [TSurveyQuestionTypeEnum.Matrix]: ["rich_text"], [TSurveyQuestionTypeEnum.Cal]: ["checkbox"], + [TSurveyQuestionTypeEnum.ContactInfo]: ["rich_text"], + [TSurveyQuestionTypeEnum.Ranking]: ["rich_text"], }; export const UNSUPPORTED_TYPES_BY_NOTION = [ diff --git a/apps/web/app/api/(internal)/pipeline/lib/handleIntegrations.ts b/apps/web/app/api/(internal)/pipeline/lib/handleIntegrations.ts index 5eea313aaa..d3e45df96c 100644 --- a/apps/web/app/api/(internal)/pipeline/lib/handleIntegrations.ts +++ b/apps/web/app/api/(internal)/pipeline/lib/handleIntegrations.ts @@ -392,6 +392,19 @@ const getValue = (colType: string, value: string | string[] | Date | number | Re }, ]; } + if (Array.isArray(value)) { + const content = value.join("\n"); + return [ + { + text: { + content: + content.length > NOTION_RICH_TEXT_LIMIT + ? truncateText(content, NOTION_RICH_TEXT_LIMIT) + : content, + }, + }, + ]; + } return [ { text: {