Evolutionv2 API parameters to track 6.5?

Daniel Wendell2 months ago

What parameters to pass in the traccar.xml file to install evolutionv2, nothing comes of it, can anyone help?

Anton Tananaev2 months ago

I have no idea what Evolutionv2 is. Do you want to provide some context?

Daniel Wendell2 months ago

Hello Anton.

Whatsapp API that I want to put in the traccar, but the parameters here are for SMS, and I can't send it, there is an error that appears in the sent message.
Traccar.xml é

  <entry key='sms.http.url'>http://192.168.254.203:8080/message/sendText/TraccarXXX</entry>
    <entry key='sms.http.authorization'>apikey=xxxxxxxxxx</entry>
    <entry key='sms.http.authorizationHeader'>Content-Type=application/json</entry>
    <entry key='sms.http.template'>
        {"number":"{phone}","text":"{message}"}
    </entry>

In the logs it generates this error:

WARN: Notification failed -  - MessageException (HttpSmsClient:99 < NotificatorSms:48 < Notificator:39 < NotificationManager:139 < ...)
Anton Tananaev2 months ago

Where's the API documentation for it?

Daniel Wendell2 months ago

There is an evolution 2 api to be able to integrate with traccar, here is the link

https://doc.evolution-api.com/v2/api-reference/message-controller/send-text

Anton Tananaev2 months ago

Your authorization setup definitely makes no sense. It should be something like this:

<entry key='sms.http.authorizationHeader'>apikey</entry>
<entry key='sms.http.authorization'>xxxxxxxxxx</entry>
Daniel Wendell2 months ago

Now it brought me this error below:

WARN: Notification failed - {"status":400,"error":"Internal Server Error","response":{"message":"Bad control character in string literal in JSON at position 50"}}
Daniel Wendell2 months ago

Anton I did a test by passing a text and it worked, the error is in the message field, in the template below:

<entry key='sms.http.template'>
    {
        "number": "{phone}",
        "text": "{message}"
    }
</entry>

What would be the field to be able to get traccar message templates?

Anton Tananaev2 months ago
Daniel Wendell2 months ago

Anton wouldn't be because I've already updated the templates before. To make the call, would the string really be message?

Daniel Wendell2 months ago

Does Anton really have something to do with the line break in the message file, in which case it is not possible to send a message with a line break?

Anton Tananaev2 months ago

It's not possible in the current version. It will be possible in the next:

https://github.com/traccar/traccar/commit/66b538f03690c34eae6c74086207b472e8f5c55c

Daniel Wendell2 months ago

Do you intend to have this version ready?

Anton Tananaev2 months ago

Yes, at some point.

Daniel Wendell2 months ago

When you do, let me know so I can update anything I need to? But if I get these flagged changes, will it work?