Skip to content

Quote marks in messages are not escaped, leading to malformed JSON #124

@TJC

Description

@TJC

To reproduce, attempt to send a message such as:

echo 'hello "world"...' | slack chat send --channel test --pretext "a test message"

You will receive an error:

{
  "ok": false,
  "error": "no_text"
}

I believe this is due to the way the JSON body is built in https://github.com/rockymadden/slack-cli/blob/master/src/slack#L224 where quote marks aren't escaped.

Update: Due to my frustration with this, I created a new tool which is just designed to do one thing - post text messages to Slack: https://github.com/TJC/simple-slack-message

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions