Skip to content

Commit a9b476e

Browse files
committed
fix(confluence): stop documenting a cloudId users cannot supply
All 46 Confluence tools marked cloudId 'user-only', publishing it on 46 doc rows, but the block has no cloudId subBlock so no user could ever fill it. createConfluenceClient already resolves the cloud id from the domain through the shared Atlassian resolver, exactly as Jira does, and Jira marks the same param hidden. Marks cloudId hidden to match. domain stays user-only and settable — it is now the only user-provided param on every Confluence tool.
1 parent 77cece9 commit a9b476e

49 files changed

Lines changed: 68 additions & 93 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

apps/docs/content/docs/en/integrations/confluence.mdx

Lines changed: 0 additions & 46 deletions

apps/sim/tools/confluence/add_label.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ export const confluenceAddLabelTool: InternalToolConfig<
6868
cloudId: {
6969
type: 'string',
7070
required: false,
71-
visibility: 'user-only',
71+
visibility: 'hidden',
7272
description:
7373
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
7474
},
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/**
2+
* @vitest-environment node
3+
*/
4+
import { describe, expect, it } from 'vitest'
5+
import * as confluenceTools from '@/tools/confluence'
6+
7+
const toolEntries = Object.values(confluenceTools).map((tool) => [tool.id, tool] as const)
8+
9+
describe('Confluence cloudId', () => {
10+
it('covers every Confluence tool', () => {
11+
expect(toolEntries.length).toBeGreaterThanOrEqual(46)
12+
})
13+
14+
it.each(toolEntries)('%s resolves cloudId instead of asking the user for it', (_id, tool) => {
15+
expect(tool.params.cloudId?.visibility).toBe('hidden')
16+
})
17+
18+
it.each(toolEntries)('%s keeps domain user-settable', (_id, tool) => {
19+
expect(tool.params.domain?.visibility).toBe('user-only')
20+
})
21+
})

apps/sim/tools/confluence/create_blogpost.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ export const confluenceCreateBlogPostTool: InternalToolConfig<
8484
cloudId: {
8585
type: 'string',
8686
required: false,
87-
visibility: 'user-only',
87+
visibility: 'hidden',
8888
description:
8989
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
9090
},

apps/sim/tools/confluence/create_comment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ export const confluenceCreateCommentTool: InternalToolConfig<
5959
cloudId: {
6060
type: 'string',
6161
required: false,
62-
visibility: 'user-only',
62+
visibility: 'hidden',
6363
description:
6464
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
6565
},

apps/sim/tools/confluence/create_page.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ export const confluenceCreatePageTool: InternalToolConfig<
8080
cloudId: {
8181
type: 'string',
8282
required: false,
83-
visibility: 'user-only',
83+
visibility: 'hidden',
8484
description:
8585
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
8686
},

apps/sim/tools/confluence/create_page_property.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export const confluenceCreatePagePropertyTool: InternalToolConfig<
7272
cloudId: {
7373
type: 'string',
7474
required: false,
75-
visibility: 'user-only',
75+
visibility: 'hidden',
7676
description:
7777
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
7878
},

apps/sim/tools/confluence/create_space.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ export const confluenceCreateSpaceTool: InternalToolConfig<
7373
cloudId: {
7474
type: 'string',
7575
required: false,
76-
visibility: 'user-only',
76+
visibility: 'hidden',
7777
description:
7878
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
7979
},

apps/sim/tools/confluence/create_space_property.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ export const confluenceCreateSpacePropertyTool: InternalToolConfig<
6969
cloudId: {
7070
type: 'string',
7171
required: false,
72-
visibility: 'user-only',
72+
visibility: 'hidden',
7373
description:
7474
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
7575
},

apps/sim/tools/confluence/delete_attachment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export const confluenceDeleteAttachmentTool: InternalToolConfig<
5252
cloudId: {
5353
type: 'string',
5454
required: false,
55-
visibility: 'user-only',
55+
visibility: 'hidden',
5656
description:
5757
'Confluence Cloud ID for the instance. If not provided, it will be fetched using the domain.',
5858
},

0 commit comments

Comments
 (0)