POST https://zulip.cranfield.ac.uk/api/v1/messages/render
Render a message to HTML.
Usage examples
Python
JavaScript
curl
#!/usr/bin/env python3importzulip# Pass the path to your zuliprc file here.client=zulip.Client(config_file="~/zuliprc")# Render a message.request={"content":"**foo**",}result=client.render_message(request)print(result)
More examples and documentation can be found here.
constzulipInit=require("zulip-js");// Pass the path to your zuliprc file here.constconfig={zuliprc:"zuliprc"};(async()=>{constclient=awaitzulipInit(config);// Render a messageconstparams={content:"**foo**",};console.log(awaitclient.messages.render(params));})();
curl -sSX POST https://zulip.cranfield.ac.uk/api/v1/messages/render \
-u BOT_EMAIL_ADDRESS:BOT_API_KEY \
--data-urlencode content=Hello
Parameters
contentstringrequired
Example: "Hello"
The content of the message.
Clients should use the max_message_length returned by the
POST /register endpoint to determine
the maximum message size.
Response
Return values
rendered: string
The rendered HTML.
Example response(s)
Changes: As of Zulip 7.0 (feature level 167), if any
parameters sent in the request are not supported by this
endpoint, a successful JSON response will include an
ignored_parameters_unsupported array.