Newline on NOTE in Engagement API


#1

I am trying to create NOTE engagement on a contact, my goal is to create something like this:
Topic:
line1
line2
line3

And I am passing a string like this:
“Topic:\nline1\nline2\nline3”

But when it shows on the Hubspot it becomes:
“Topic:line1lin2line3”

I am using this API: http://developers.hubspot.com/docs/methods/engagements/create_engagement


#2

@Eddie_Z

You can use </br> for line breaks.

Sebastian


#3

Thank you! it worked.


#4

Is this still working? It dos not worl for me


#5

Hi @Gaston_Krasny,

I did some testing and using </br> is still working for me. Can you share the body of the request you’re making?


#6

Any update on this? We have the same issue. Can the “body” field include HTML? This isn’t mentioned in the documentation. Incidentally I think you meant <br />, not </ br>.


#7

Hi @jtosey,

Either </br. or <br/> appear to function as a line break, based on my testing. Additionally, it appears that some light HTML markup is supported in NOTE engagements, but I’m not yet sure if that’s intentional or not. I wouldn’t recommend using HTML in NOTE engagements since it’s undocumented and may be subject to change. I’ll touch base with the product team on that.


#8

Hi @jtosey,

I was able to confirm with the product team; HTML elements like anchor tags, header tags, and line breaks are supported in the note body. Anything more sophisticated than that (even if it works) is unsupported, and is subject to change without notice. In general, if you need more complex formatting you would likely be better served using the Timeline API.