insomania-plugin-signalr-client
v1.0.1
Published
Signal-R Client plugin For Insomnia
Downloads
3
Readme
Signal-R Client
How To Use
This plugin adds a SignalR-Client item to the request directory action menu. By clicking this, SignalR Client's window will pop, showing a list of available SignalR requests in the directory.
Clicking on any of these buttons, will provide you with the signal r client window for that request. Signal-R requests are describe later in this document.
The SignalR Client Window Provides a Start Listening button, a Stop button and a Clear Logs button. When listening to signal r channel has been started, the data would be logged underneath the buttons in json format.
Signal-R Requests And Panel Options
Each request can define configurations and options to run a client for a specific signal-r channel. Creating a signal-r request is no different than creating http requests. By selecting the New Request (Ctrl+N) item from the menu you can get to the new request window. By default it will suggest to create an Http-GET request with the name of your choice. You can change the request type with the drop-down right next to the name input box. There, you should click Custom Method options from the menu, then write "SIGNALR" in the input box as the name of the request type (Method). Then you need to choose the Json body type for your request so that you can write signal-r configurations as json in the request body:
| Property | Type | Description |
|:------------------:|:----------:|:-------------------|
| lastMessageOnly
| boolean | if true
, whenever a new message is received, the previously received messages will be deleted |
|url
| string | The server address and signal-r hub uri|
| method
| string | The signal-r hub's method which your client is supposed to listen to|
| authorizationToken
| string | If the signal-r server needs an authorization token for authorizing it's clients, you can add this property to provide that|
✅ You can use template tags in request body, for example you can create another request to do the authorization and then pick the authorization token from it and use in it in the request.
Example:
{
"lastMessageOnly":true,
"url":"http://localhost:8080/hub/v1/user-updates",
"method":"profile-updates",
"authorizationToken":"some-authorization-token"
}
How to install
Using Insomnia Hub: You can navigate to Insomnia Plugin Hub Page and search for Signal-R Client, Open the details page and click Install Plugin button. This throw an installation link which you can open with your insomnia on your desktop.
Directly installing the zip file:: You can download project zip file from github. Then extract the content into a directory at your insomnia's plugin's directory.
Using Insomnia Application: You can Open your insomnia application, go to Preferences menu, open the plugins tab and enter the name insomnia-plugin-signalr-plugin into text box, the click Install Plugin button.