diff --git a/apps/sim/blocks/blocks/slack.ts b/apps/sim/blocks/blocks/slack.ts index 700d679f8ef..cc29e7109a4 100644 --- a/apps/sim/blocks/blocks/slack.ts +++ b/apps/sim/blocks/blocks/slack.ts @@ -2132,7 +2132,7 @@ Do not include any explanations, markdown formatting, or other text outside the user: { type: 'json', description: - 'Detailed user object with properties: id, name, real_name, display_name, first_name, last_name, title, is_bot, is_admin, deleted, timezone, avatars, status', + 'Detailed user object with properties: id, name, real_name, display_name, first_name, last_name, title, email, is_bot, is_admin, deleted, timezone, avatars, status, and a nested profile object mirroring the Slack users.info API shape', }, // slack_download outputs diff --git a/apps/sim/tools/slack/get_user.ts b/apps/sim/tools/slack/get_user.ts index 5c95b6ee349..a6bf7cc73d8 100644 --- a/apps/sim/tools/slack/get_user.ts +++ b/apps/sim/tools/slack/get_user.ts @@ -111,6 +111,27 @@ export const slackGetUserTool: ToolConfig /** @@ -1118,6 +1125,32 @@ export interface SlackListMembersResponse extends ToolResponse { } } +/** + * Nested profile object mirroring Slack's users.info response shape, + * so references written against the raw API (e.g. user.profile.email) resolve. + */ +interface SlackUserProfile { + real_name: string + real_name_normalized: string + display_name: string + display_name_normalized: string + first_name: string + last_name: string + title: string + phone: string + skype: string + email: string + status_text: string + status_emoji: string + status_expiration: number | null + image_24: string | null + image_32: string | null + image_48: string | null + image_72: string | null + image_192: string | null + image_512: string | null +} + interface SlackUser { id: string team_id?: string | null @@ -1153,6 +1186,7 @@ interface SlackUser { status_expiration?: number | null updated?: number | null has_2fa?: boolean + profile?: SlackUserProfile } export interface SlackListUsersResponse extends ToolResponse {