Support PUTing typing status in clientapi#550
Conversation
|
|
||
| // InputTypingEventsRequest is a request to TypingServerInputAPI | ||
| type InputTypingEventsRequest struct { | ||
| InputTypingEvents []InputTypingEvent `json:"input_typing_events"` |
There was a problem hiding this comment.
Why do you want to input an array?
If one - but not all - requests are failing e.g. because of missing permissions for one request: How do you find out?
I think the easier way is to have one request per request. Where should the consolidating and separation happen?
There was a problem hiding this comment.
so, 1st thing is that these EDUs are already permitted (have gone through auth).
And from an perspective of drawing out an API, it seemed short-sighted to support single event per API call.
P.S. I remembered now that we'll need to put multiple events at a time for federation :P
There was a problem hiding this comment.
Given that we only currently send one typing event at a time I'd not use a slice for now. Its an internal API so we can change it down the road if we need it to handle multiple typing events :)
| @@ -59,6 +59,7 @@ listen: | |||
| federation_api: "localhost:7772" | |||
| sync_api: "localhost:7773" | |||
| media_api: "localhost:7774" | |||
There was a problem hiding this comment.
/me wonders why the other components haven't been added here.
Commits can be easily reviewed incrementally, :)
clientapi/producerstypingServerProducerSigned-off-by: Anant Prakash <anantprakashjsr@gmail.com>