Skip to content

Add --no-urgent flag to send command#1933

Merged
AsamK merged 2 commits intoAsamK:masterfrom
kaikozlov:add-no-push-flag
Feb 25, 2026
Merged

Add --no-urgent flag to send command#1933
AsamK merged 2 commits intoAsamK:masterfrom
kaikozlov:add-no-push-flag

Conversation

@kaikozlov
Copy link
Contributor

@kaikozlov kaikozlov commented Feb 24, 2026

Summary

  • Adds a --no-push flag to the send command that sets urgent=false on the server request, skipping the FCM/APNs push notification to the recipient
  • The message is still delivered in real-time over WebSocket if the recipient's app is active
  • Follows the existing viewOnce pattern by adding noPush to the Message record, keeping the Manager interface unchanged

Test plan

  • ./gradlew build passes
  • ./gradlew test passes
  • Manual test: send with --no-push and verify recipient does not receive a push notification when app is backgrounded
  • Manual test: send without --no-push and verify normal push behavior

Expose the server's `urgent` parameter so callers can skip sending a
push notification (FCM/APNs) to the recipient. The message is still
delivered in real-time over WebSocket if the recipient's app is active.

The flag is added to the Message record (following the same pattern as
viewOnce) and threaded through ManagerImpl and SendHelper, keeping the
Manager interface unchanged.
@AsamK
Copy link
Owner

AsamK commented Feb 25, 2026

Thanks, the code looks good.
I'm not sure about the naming of the flag. The --no-push disables the push notification but the message is still pushed via websocket. What do you think about staying in line with the protocol naming and using something like --no-urgent?

Align with the protocol naming as suggested by the maintainer.
The flag controls the 'urgent' parameter on the server request.
@kaikozlov kaikozlov changed the title Add --no-push flag to send command Add --no-urgent flag to send command Feb 25, 2026
@kaikozlov
Copy link
Contributor Author

Yes, I agree that --no-urgent is the right call on the naming. Updated!

@AsamK AsamK merged commit d4b3816 into AsamK:master Feb 25, 2026
7 checks passed
@kaikozlov kaikozlov deleted the add-no-push-flag branch February 25, 2026 20:50
@AsamK AsamK added this to the next-version milestone Feb 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants