Skip to content

fix: correct SlackListsItemFieldMessage type - #2722

Open
dajiaohuang wants to merge 1 commit into
slackapi:mainfrom
dajiaohuang:fix/2598-slacklists-message-type
Open

fix: correct SlackListsItemFieldMessage type#2722
dajiaohuang wants to merge 1 commit into
slackapi:mainfrom
dajiaohuang:fix/2598-slacklists-message-type

Conversation

@dajiaohuang

Copy link
Copy Markdown

Summary

The SlackListsItemFieldMessage interface incorrectly defined the message field as string[]. However, the Slack API can return the message field as either a single message object or an array of message objects.

Fix

This PR introduces a new SlackListsItemMessage interface and updates SlackListsItemFieldMessage to use a union type.

References

Fixes #2598

…ssage and array

The message field in Slack Lists API can return either:
- A single message object: "message": {"text":"hello", "ts": "123.456"}
- An array of message objects: "message":[{"text": "a"}, {"text":"b"}]

Previously the type was incorrectly defined as string[] which doesn't match
the API response shape.

Fixes slackapi#2598
@dajiaohuang
dajiaohuang requested a review from a team as a code owner September 2, 2026 09:48
@salesforce-cla

salesforce-cla Bot commented Sep 2, 2026

Copy link
Copy Markdown

Thanks for the contribution! Before we can merge this, we need @dajiaohuang to sign the Salesforce Inc. Contributor License Agreement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SlackListsItem FieldMessage.message type does not match API response shape

1 participant