REST API - Create Integration "script"

Hello,

I’m currently trying to figure out how to create an Integration with the API method from https://rocket.chat/docs/developer-guides/rest-api/integration/create/

I dont have any problems setting the type, name, username, etc. attributes. But script wont work how i want it to.

Iam having a “normal” script with breaks, collums etc.

but the Problem is everytime i try to run it i get this error msg:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Bad Request</pre>
</body>
</html>

I already tried to make it a oneliner but it doesnt help either.

I am missing something or does it not Support this kind of Scripts?

I am running RC in a Docker environment.
Version: 1.0.3
Thanks!

Can I recommend switching to the Apps system? It has greater functionality and is supported a lot better. Internally we have been moving our integrations over to Apps from scripts.