Skip to content

Add new RPC methods and notifications (mostly for scripting interaction) to server and client#3730

Open
dingodoppelt wants to merge 3 commits into
jamulussoftware:mainfrom
dingodoppelt:rpc_additions
Open

Add new RPC methods and notifications (mostly for scripting interaction) to server and client#3730
dingodoppelt wants to merge 3 commits into
jamulussoftware:mainfrom
dingodoppelt:rpc_additions

Conversation

@dingodoppelt

@dingodoppelt dingodoppelt commented Jun 8, 2026

Copy link
Copy Markdown
Member

Short description of changes

Add the following RPC methods and notifications to server and client. These are useful mostly for scripting interaction.

  • jamulus/getAvailableMethods
  • jamulusclient/setMuted
  • jamulusserver/broadcastChatMessage
  • jamulusserver/getClientDetails
  • jamulusserver/chatMessageReceived
  • jamulusserver/clientConnected
  • jamulusserver/clientDisconnected
  • jamulusserver/privateChatMessage

CHANGELOG: Add new RPC methods and notifications (mostly for scripting interaction) to server and client

Context: Fixes an issue?

Relates to #3029 #3447 #2828 #1057 #1371
This is needed for Jamban and others.

Does this change need documentation? What needs to be documented and how?

I guess the automated RPC documentation is sufficient?

Status of this Pull Request
up for discussion

What is missing until this pull request can be merged?
Approval

Checklist

  • I've verified that this Pull Request follows the general code principles
  • I tested my code and it does what I want
  • My code follows the style guide
  • I waited some time after this Pull Request was opened and all GitHub checks completed without errors.
  • I've filled all the content above

@dingodoppelt dingodoppelt force-pushed the rpc_additions branch 3 times, most recently from cdf20bb to 663a557 Compare June 8, 2026 19:10
@ann0see

ann0see commented Jun 8, 2026

Copy link
Copy Markdown
Member

@mcfnord you might be interested in this.

@ann0see ann0see added this to the Release 4.0.0 milestone Jun 8, 2026
@ann0see ann0see added this to Tracking Jun 8, 2026
@github-project-automation github-project-automation Bot moved this to Triage in Tracking Jun 8, 2026
@ann0see ann0see moved this from Triage to Waiting on Team in Tracking Jun 8, 2026
@ann0see ann0see requested review from ann0see and pljones June 8, 2026 19:23
Comment thread src/serverrpc.cpp Outdated
@dingodoppelt dingodoppelt force-pushed the rpc_additions branch 2 times, most recently from 8b270d7 to 6111ecb Compare June 9, 2026 13:35
Comment thread docs/JSON-RPC.md Outdated
Comment thread src/client.h
Comment thread docs/JSON-RPC.md

### jamulusserver/broadcastChatMessage

Sends a chat message to all connected clients.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Sends a chat message to all connected clients.
Sends a chat message from this client to the server. The server will send this to all connected clients.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What exactly is "this client" in this case? Should'nt it rather be "this RPC client" (like nc, curl or some script)? Since this is a server method I think my explanation is sufficient in making clear what this method does.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Client in Jamulus terms is the Client exchanging UDP messages with the Server. (I should have capitalised both for compliance with the style guide, my bad.)

Maybe

Suggested change
Sends a chat message to all connected clients.
Sends the chat message in the request from the Client to the Server. The Service will send the message to all connected Clients.

@dingodoppelt dingodoppelt Jun 9, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Client in Jamulus terms is the Client exchanging UDP messages with the Server.

But we are not a client in this case, we are the RPC server and we are processing a request from a client like curl or nc. I'm confused

Edit: To clarify: this is a server method, not client. This is not the client sending a normal chat message just triggered via RPC, it is actually the server itself broadcasting a message to all connected clients.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah right. I missed that, sorry. Still, make the doc clearer 😄 .

Comment thread docs/JSON-RPC.md Outdated

@pljones pljones left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs splitting. The private message feature should be separate.

@github-project-automation github-project-automation Bot moved this from Waiting on Team to Waiting externally in Tracking Jun 9, 2026
@dingodoppelt

Copy link
Copy Markdown
Member Author

Needs splitting. The private message feature should be separate.

In addition to jamulusserver/broadcastChatMessage and jamulusserver/chatMessageReceived I think this is the right place for it, tbh. It would make more sense to split the whole PR into three smaller ones

  1. Chat
  2. Client connection/disconnection
  3. set client muted status

but I don't see why only the private chat message should be handled independently.

@pljones

pljones commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

but I don't see why only the private chat message should be handled independently.

Because the feature is entirely new.

- jamulus/getAvailableMethods
- jamulusclient/setMuted
- jamulusserver/broadcastChatMessage
- jamulusserver/chatMessageReceived
- jamulusserver/clientConnected
- jamulusserver/clientDisconnected
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Waiting externally

Development

Successfully merging this pull request may close these issues.

3 participants