Search code examples
jira-rest-apiclubhouse

How do I include a newline in a Shortcut (JIRA-like FKA clubhouse.io ) REST API Comment message


I'm using this Shortcut REST API resource: https://developer.shortcut.com/api/rest/v3#Create-Story-Comment

I'm trying to send a multi-line comment

I tried include an \\n in the JSON value, but it just got rendered as \n instead of inserting a newline.


Solution

  • It turned out to be a double-encoding issue, it is \\n in the JSON, but the function I was using turned that into \\\\n :facepalm