From f14101970625b6833124ba99ca095aa6727988cd Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Tue, 14 Apr 2026 20:07:45 -0700 Subject: [PATCH 1/3] fix(blocks): correct required field validation for Jira and Confluence blocks MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Jira: summary is only required for create (not update), projectId is not required for update (API uses issueKey). Confluence: title and content are required for page creation, title is required for blog post creation — all enforced by backend validation. Co-Authored-By: Claude Opus 4.6 --- apps/sim/blocks/blocks/confluence.ts | 4 ++++ apps/sim/blocks/blocks/jira.ts | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/apps/sim/blocks/blocks/confluence.ts b/apps/sim/blocks/blocks/confluence.ts index 8d90cfda4ca..e55a21a45c2 100644 --- a/apps/sim/blocks/blocks/confluence.ts +++ b/apps/sim/blocks/blocks/confluence.ts @@ -128,6 +128,7 @@ export const ConfluenceBlock: BlockConfig = { title: 'Title', type: 'short-input', placeholder: 'Enter title for the page', + required: { field: 'operation', value: 'create' }, condition: { field: 'operation', value: ['create', 'update'] }, }, { @@ -135,6 +136,7 @@ export const ConfluenceBlock: BlockConfig = { title: 'Content', type: 'long-input', placeholder: 'Enter content for the page', + required: { field: 'operation', value: 'create' }, condition: { field: 'operation', value: ['create', 'update'] }, }, { @@ -766,6 +768,7 @@ export const ConfluenceV2Block: BlockConfig = { title: 'Title', type: 'short-input', placeholder: 'Enter title', + required: { field: 'operation', value: ['create', 'create_blogpost'] }, condition: { field: 'operation', value: ['create', 'update', 'create_blogpost', 'update_blogpost', 'update_space'], @@ -776,6 +779,7 @@ export const ConfluenceV2Block: BlockConfig = { title: 'Content', type: 'long-input', placeholder: 'Enter content', + required: { field: 'operation', value: 'create' }, condition: { field: 'operation', value: ['create', 'update', 'create_blogpost', 'update_blogpost'], diff --git a/apps/sim/blocks/blocks/jira.ts b/apps/sim/blocks/blocks/jira.ts index c6c93e4b3d2..3864a236f5e 100644 --- a/apps/sim/blocks/blocks/jira.ts +++ b/apps/sim/blocks/blocks/jira.ts @@ -91,7 +91,7 @@ export const JiraBlock: BlockConfig = { placeholder: 'Select Jira project', dependsOn: ['credential', 'domain'], mode: 'basic', - required: { field: 'operation', value: ['write', 'update', 'read-bulk'] }, + required: { field: 'operation', value: ['write', 'read-bulk'] }, }, // Manual project ID input (advanced mode) { @@ -102,7 +102,7 @@ export const JiraBlock: BlockConfig = { placeholder: 'Enter Jira project ID', dependsOn: ['credential', 'domain'], mode: 'advanced', - required: { field: 'operation', value: ['write', 'update', 'read-bulk'] }, + required: { field: 'operation', value: ['write', 'read-bulk'] }, }, // Issue selector (basic mode) { @@ -218,7 +218,7 @@ export const JiraBlock: BlockConfig = { id: 'summary', title: 'New Summary', type: 'short-input', - required: true, + required: { field: 'operation', value: 'write' }, placeholder: 'Enter new summary for the issue', dependsOn: ['projectId'], condition: { field: 'operation', value: ['update', 'write'] }, From 9e59b606c27d53154dfcfff7b0e3d5d87202bc84 Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Tue, 14 Apr 2026 20:17:25 -0700 Subject: [PATCH 2/3] fix(blocks): remove projectId dependsOn gate for update fields, require content for blog post creation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Jira: Remove dependsOn projectId from shared write/update fields — projectId is not required for update so the gate would disable all update fields when no project is selected. Write-only fields (issueType, parentIssue, reporter) retain the gate since projectId is required for create. Confluence V2: Add create_blogpost to content required condition — backend Zod schema enforces content for blog post creation. Co-Authored-By: Claude Opus 4.6 --- apps/sim/blocks/blocks/confluence.ts | 2 +- apps/sim/blocks/blocks/jira.ts | 11 ----------- 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/apps/sim/blocks/blocks/confluence.ts b/apps/sim/blocks/blocks/confluence.ts index e55a21a45c2..e66efd70a08 100644 --- a/apps/sim/blocks/blocks/confluence.ts +++ b/apps/sim/blocks/blocks/confluence.ts @@ -779,7 +779,7 @@ export const ConfluenceV2Block: BlockConfig = { title: 'Content', type: 'long-input', placeholder: 'Enter content', - required: { field: 'operation', value: 'create' }, + required: { field: 'operation', value: ['create', 'create_blogpost'] }, condition: { field: 'operation', value: ['create', 'update', 'create_blogpost', 'update_blogpost'], diff --git a/apps/sim/blocks/blocks/jira.ts b/apps/sim/blocks/blocks/jira.ts index 3864a236f5e..b1eaf339d14 100644 --- a/apps/sim/blocks/blocks/jira.ts +++ b/apps/sim/blocks/blocks/jira.ts @@ -220,7 +220,6 @@ export const JiraBlock: BlockConfig = { type: 'short-input', required: { field: 'operation', value: 'write' }, placeholder: 'Enter new summary for the issue', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['update', 'write'] }, wandConfig: { enabled: true, @@ -240,7 +239,6 @@ Return ONLY the summary text - no explanations.`, title: 'New Description', type: 'long-input', placeholder: 'Enter new description for the issue', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['update', 'write'] }, wandConfig: { enabled: true, @@ -279,7 +277,6 @@ Return ONLY the description text - no explanations.`, title: 'Assignee Account ID', type: 'short-input', placeholder: 'Assignee account ID (e.g., 5b109f2e9729b51b54dc274d)', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -287,7 +284,6 @@ Return ONLY the description text - no explanations.`, title: 'Priority', type: 'short-input', placeholder: 'Priority ID or name (e.g., "10000" or "High")', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -295,7 +291,6 @@ Return ONLY the description text - no explanations.`, title: 'Labels', type: 'short-input', placeholder: 'Comma-separated labels (e.g., bug, urgent)', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -303,7 +298,6 @@ Return ONLY the description text - no explanations.`, title: 'Due Date', type: 'short-input', placeholder: 'YYYY-MM-DD (e.g., 2024-12-31)', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, wandConfig: { enabled: true, @@ -332,7 +326,6 @@ Return ONLY the date string in YYYY-MM-DD format - no explanations, no quotes, n title: 'Environment', type: 'long-input', placeholder: 'Environment information (e.g., Production, Staging)', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -340,7 +333,6 @@ Return ONLY the date string in YYYY-MM-DD format - no explanations, no quotes, n title: 'Custom Field ID', type: 'short-input', placeholder: 'e.g., customfield_10001 or 10001', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -348,7 +340,6 @@ Return ONLY the date string in YYYY-MM-DD format - no explanations, no quotes, n title: 'Custom Field Value', type: 'short-input', placeholder: 'Value for the custom field', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -356,7 +347,6 @@ Return ONLY the date string in YYYY-MM-DD format - no explanations, no quotes, n title: 'Components', type: 'short-input', placeholder: 'Comma-separated component names', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { @@ -364,7 +354,6 @@ Return ONLY the date string in YYYY-MM-DD format - no explanations, no quotes, n title: 'Fix Versions', type: 'short-input', placeholder: 'Comma-separated fix version names', - dependsOn: ['projectId'], condition: { field: 'operation', value: ['write', 'update'] }, }, { From 57e3449db4c7ce90767a3caa2b53dd350477727b Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Tue, 14 Apr 2026 20:19:51 -0700 Subject: [PATCH 3/3] lint --- apps/docs/content/docs/en/tools/jira.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/docs/content/docs/en/tools/jira.mdx b/apps/docs/content/docs/en/tools/jira.mdx index db433a3d4d9..17742deeda2 100644 --- a/apps/docs/content/docs/en/tools/jira.mdx +++ b/apps/docs/content/docs/en/tools/jira.mdx @@ -251,7 +251,7 @@ Update a Jira issue | `domain` | string | Yes | Your Jira domain \(e.g., yourcompany.atlassian.net\) | | `issueKey` | string | Yes | Jira issue key to update \(e.g., PROJ-123\) | | `summary` | string | No | New summary for the issue | -| `description` | string | No | New description for the issue | +| `description` | string | No | New description for the issue. Accepts plain text \(auto-wrapped in ADF\) or a raw ADF document object | | `priority` | string | No | New priority ID or name for the issue \(e.g., "High"\) | | `assignee` | string | No | New assignee account ID for the issue | | `labels` | json | No | Labels to set on the issue \(array of label name strings\) | @@ -284,7 +284,7 @@ Create a new Jira issue | `domain` | string | Yes | Your Jira domain \(e.g., yourcompany.atlassian.net\) | | `projectId` | string | Yes | Jira project key \(e.g., PROJ\) | | `summary` | string | Yes | Summary for the issue | -| `description` | string | No | Description for the issue | +| `description` | string | No | Description for the issue. Accepts plain text \(auto-wrapped in ADF\) or a raw ADF document object | | `priority` | string | No | Priority ID or name for the issue \(e.g., "10000" or "High"\) | | `assignee` | string | No | Assignee account ID for the issue | | `cloudId` | string | No | Jira Cloud ID for the instance. If not provided, it will be fetched using the domain. |