Here we are looking into a simple standard way to do authentication for JSON-RPC calls.
# Basic auth This seems to be one way to go.
curl -X POST --data '{"username":"username1","password":"pegasys"}' <JSON-RPC-http-hostname:http-port>/login
Maybe something like this?
-i -X POST -d "{"jsonrpc": "2.0", "method": "Input.Up", "id": 1}" -H "content-type:application/json" http://username:password@ipaddress:portnumber/jsonrpc
- https://forum.kodi.tv/showthread.php?tid=327119
Looks like playing with Postman is the way to go: - https://deluge.readthedocs.io/en/latest/devguide/how-to/curl-jsonrpc.html
# JWT But a more general future proofed way to go looks like using JWT: