dart-eventsource
dart-eventsource copied to clipboard
POST not working
Hello, I'm having problems using the post. I have tried on web
[...]
Map body = {
'text': message.text,
'apikey': APIKEY,
};
EventSource eventSource = await EventSource.connect(
"myserverurl.com", client: new BrowserClient(),
body: jsonEncode(body));
// listen for events
eventSource.listen((Event event) async {
[...]
My server is not receiving the post variables Hopefully it can be fixed Thanks :)
It might be that in the browser environment, HTTP GET requests cannot carry a body.