Tutorial: Create a REST API by importing an example. Keep your eyes open for even more input formats in the future. After youve deployed your WebSocket API, client applications can connect to it and send messages to. In fact, each argument may use a different input format. Postman supports various input formats like JSON, text, binary and more, which you can toggle as you wish. Also, you can attach additional logic to your event by clicking “+Arg”. You can write (or paste) your messages into the message editor to fire event, type an event name, and click Send. Like raw WebSockets, Socket.IO is bidirectional, which means you can send messages to the server whenever you want. Pro tip: Socket.IO events can have multiple arguments, so we’ve provided an argument selector to toggle between them (if there is more than one). The timeline shows a preview of each event, giving you an overview of the information, but you can dive into the full content of an event by simply clicking to expand it. When you send or receive an event, it will appear in the unified event timeline, showing you the entire history of the connection in one place. You can quickly disable and re-enable listeners with a single click, making it easy and flexible to listen to different combinations of events that interest you. Since this is Socket.IO, you will only receive events for which you have added listeners. To do this, type the name of an event in the Listener panel, and click the ”+” to add it. Now that you are connected to your server, you need to listen for specific events.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |