X-Git-Url: https://git.nmode.ca/signal-cli/blobdiff_plain/fb99ff5284de467b42b80191c072b66c2221889a..dc787be17ba3ec2396c992b77fff3aa7d98d259c:/man/signal-cli.1.adoc

diff --git a/man/signal-cli.1.adoc b/man/signal-cli.1.adoc
index a626ab61..32321095 100644
--- a/man/signal-cli.1.adoc
+++ b/man/signal-cli.1.adoc
@@ -23,6 +23,17 @@ For registering you need a phone number where you can receive SMS or incoming ca
 signal-cli was primarily developed to be used on servers to notify admins of important events.
 For this use-case, it has a dbus and a JSON-RPC interface, that can be used to send messages from other programs.
 
+Originally the Signal protocol only allowed sending messages to other phone numbers.
+Now with the introduction of phone number privacy, the phone number of a recipient is not always known.
+Only the recipient's ServiceId, ACI/PNI (a special UUID) is known.
+
+In all places where a RECIPIENT argument is expected in signal-cli's interface, one of the following can be used:
+
+- The phone number
+- The ACI, just a UUID
+- The PNI, just a UUID, with "PNI:" prefix
+- The username, with "u:" prefix, e.g. "u:test.000"
+
 For some functionality the Signal protocol requires that all messages have been received from the server.
 The `receive` command should be regularly executed.
 In daemon mode messages are by default continuously received.
@@ -102,12 +113,15 @@ If the account was deleted (with --delete-account) it cannot be reactivated.
 The verification should be done over voice, not SMS.
 Voice verification only works if an SMS verification has been attempted before.
 
-*--captcha*::
+*--captcha* CAPTCHA::
 The captcha token, required if registration failed with a captcha required error.
 To get the token, go to https://signalcaptchas.org/registration/generate.html
 For the staging environment, use: https://signalcaptchas.org/staging/registration/generate.html
 After solving the captcha, right-click on the "Open Signal" link and copy the link.
 
+*--reregister*::
+Register even if account is already registered.
+
 === verify
 
 Verify the number using the code received via SMS or voice.
@@ -151,8 +165,9 @@ Can fix problems with receiving messages.
 *-n* NAME, *--device-name* NAME::
 Set a new device name for the primary or linked device
 
-*--username* NAME::
+*-u* NAME *--username* NAME::
 Specify a username that can then be used to contact this account.
+This can either be just the nickname (e.g. test) or the complete username with discriminator (e.g. test.000).
 Returns the new username with discriminator and the username link.
 
 *--delete-username*::
@@ -172,7 +187,7 @@ Indicates if Signal should share its phone number when sending a message.
 Change an account to a new phone number with SMS or voice verification.
 Use the finishChangeNumber command to complete the verification.
 
-NUMBER::
+RECIPIENT::
 The new phone number.
 
 *-v*, *--voice*::
@@ -189,7 +204,7 @@ After solving the captcha, right-click on the "Open Signal" link and copy the li
 
 Verify the number using the code received via SMS or voice.
 
-NUMBER::
+RECIPIENT::
 The new phone number.
 
 *-v*, *--verification-code*::
@@ -218,7 +233,7 @@ Indicates if Signal should generate link previews.
 
 === setPin
 
-Set a registration lock pin, to prevent others from registering this number.
+Set a registration lock pin, to prevent others from registering your account's phone number.
 
 REGISTRATION_LOCK_PIN::
 The registration lock PIN, that will be required for new registrations (resets after 7 days of inactivity)
@@ -245,7 +260,7 @@ Only works, if this is the primary device.
 
 *--uri* URI::
 Specify the uri contained in the QR code shown by the new device.
-You will need the full URI such as "sgnl://linkdevice?uuid=..." (formerly "tsdevice:/?uuid=...") Make sure to enclose it in quotation marks for shells.
+You will need the full URI such as "sgnl://linkdevice?uuid=...&pub_key=..." (formerly "tsdevice:/?uuid=...") Make sure to enclose it in quotation marks for shells.
 
 === listDevices
 
@@ -262,19 +277,22 @@ Use listDevices to see the deviceIds.
 
 === getUserStatus
 
-Uses a list of phone numbers to determine the statuses of those users.
+Uses a list of phone numbers or usernames to determine the statuses of those users.
 Shows if they are registered on the Signal Servers or not.
 In json mode this is outputted as a list of objects.
 
-[NUMBER [NUMBER ...]]::
+[RECIPIENT [RECIPIENT ...]]::
 One or more numbers to check.
 
+[--username [USERNAME ...]]::
+One or more usernames to check.
+
 === send
 
 Send a message to another user or group.
 
 RECIPIENT::
-Specify the recipientsâ phone number.
+Specify the recipients.
 
 *--note-to-self*::
 Send the message to self without notification.
@@ -305,10 +323,13 @@ e.g.: `--sticker 00abac3bc18d7f599bff2325dc306d43:2`
 
 *--mention*::
 Mention another group member (syntax: start:length:recipientNumber) In the apps the mention replaces part of the message text, which is specified by the start and length values.
+The units of start and length should be UTF-16 code units, NOT Unicode code points.
+For more information, see https://github.com/AsamK/signal-cli/wiki/FAQ#string-indexing-units
 e.g.: `-m "Hi X!" --mention "3:1:+123456789"`
 
 *--text-style*::
 Style parts of the message text (syntax: start:length:STYLE).
+Like `--mention`, the units are UTF-16 code units.
 Where STYLE is one of: BOLD, ITALIC, SPOILER, STRIKETHROUGH, MONOSPACE
 
 e.g.: `-m "Something BIG!" --text-style "10:3:BOLD"` or for a mixed text style `-m "Something BIG!" --text-style "0:9:ITALIC" "10:3:BOLD"`
@@ -317,7 +338,7 @@ e.g.: `-m "Something BIG!" --text-style "10:3:BOLD"` or for a mixed text style `
 Specify the timestamp of a previous message with the recipient or group to add a quote to the new message.
 
 *--quote-author*::
-Specify the number of the author of the original message.
+Specify the author of the original message.
 
 *--quote-message*::
 Specify the message of the original message.
@@ -348,7 +369,7 @@ Specify the image file for the link preview (optional).
 Specify the timestamp of a story to reply to.
 
 *--story-author*::
-Specify the number of the author of the story.
+Specify the author of the story.
 
 *-e*, *--end-session*::
 Clear session state and send end session message.
@@ -361,7 +382,7 @@ Specify the timestamp of a previous message with the recipient or group to send
 Send response to a message request to linked devices.
 
 RECIPIENT::
-Specify the recipientsâ phone number.
+Specify the recipients.
 
 *-g* GROUP, *--group-id* GROUP::
 Specify the recipient group ID in base64 encoding.
@@ -377,7 +398,7 @@ Type of message request response (accept, delete)
 Send a payment notification.
 
 RECIPIENT::
-Specify the recipientâs phone number.
+Specify the recipient.
 
 *--receipt* RECEIPT::
 The base64 encoded receipt blob.
@@ -390,7 +411,7 @@ Specify a note for the payment notification.
 Send reaction to a previously received or sent message.
 
 RECIPIENT::
-Specify the recipientsâ phone number.
+Specify the recipients.
 
 *-g* GROUP, *--group-id* GROUP::
 Specify the recipient group ID in base64 encoding.
@@ -401,8 +422,8 @@ Specify the recipient username or username link.
 *-e* EMOJI, *--emoji* EMOJI::
 Specify the emoji, should be a single unicode grapheme cluster.
 
-*-a* NUMBER, *--target-author* NUMBER::
-Specify the number of the author of the message to which to react.
+*-a* RECIPIENT, *--target-author* RECIPIENT::
+Specify the author of the message to which to react.
 
 *-t* TIMESTAMP, *--target-timestamp* TIMESTAMP::
 Specify the timestamp of the message to which to react.
@@ -418,7 +439,7 @@ React to a story instead of a normal message
 Send a read or viewed receipt to a previously received message.
 
 RECIPIENT::
-Specify the senderâs phone number.
+Specify the sender.
 
 *-t* TIMESTAMP, *--target-timestamp* TIMESTAMP::
 Specify the timestamp of the message to which to react.
@@ -432,7 +453,7 @@ Send typing message to trigger a typing indicator for the recipient.
 Indicator will be shown for 15seconds unless a typing STOP message is sent first.
 
 RECIPIENT::
-Specify the recipientsâ phone number.
+Specify the recipients.
 
 *-g* GROUP, *--group-id* GROUP::
 Specify the recipient group ID in base64 encoding.
@@ -445,7 +466,7 @@ Send a typing STOP message.
 Remotely delete a previously sent message.
 
 RECIPIENT::
-Specify the recipientsâ phone number.
+Specify the recipients.
 
 *-g* GROUP, *--group-id* GROUP::
 Specify the recipient group ID in base64 encoding.
@@ -571,7 +592,7 @@ Show a list of known contacts with names and profiles.
 When a specific recipient is given, its profile will be refreshed.
 
 RECIPIENT::
-Specify the recipientsâ phone number.
+Specify the recipients.
 
 *-a*, *--all-recipients*::
 Include all known recipients, not only contacts.
@@ -582,21 +603,28 @@ Specify if only blocked or unblocked contacts should be shown (default: all cont
 *--name*::
 Find contacts with the given contact or profile name.
 
+*--detailed*::
+List the contacts with more details.
+If output=json, then this is always set
+
+*--internal*::
+Include internal information that's normally not user visible
+
 === listIdentities
 
 List all known identity keys and their trust status, fingerprint and safety number.
 
-*-n* NUMBER, *--number* NUMBER::
-Only show identity keys for the given phone number.
+*-n* RECIPIENT, *--number* RECIPIENT::
+Only show identity keys for the given recipient.
 
 === trust
 
-Set the trust level of a given number.
-The first time a key for a number is seen, it is trusted by default (TOFU).
+Set the trust level of a given recipient.
+The first time a key for a recipient is seen, it is trusted by default (TOFU).
 If the key changes, the new key must be trusted manually.
 
-number::
-Specify the phone number, for which to set the trust.
+RECIPIENT::
+Specify the recipient, for which to set the trust.
 
 *-a*, *--trust-all-known-keys*::
 Trust all known keys of this user, only use this for testing.
@@ -629,23 +657,32 @@ Path to the new avatar image file.
 *--remove-avatar*::
 Remove the avatar
 
-*--mobile-coin-address*::
+*--mobile-coin-address*, **--mobilecoin-address**::
 New MobileCoin address (Base64 encoded public address)
 
 === updateContact
 
-Update the info associated to a number on our contact list.
+Update the info associated to a recipient on our contact list.
 This change is only local but can be synchronized to other devices by using `sendContacts` (see below).
 If the contact doesn't exist yet, it will be added.
 
-NUMBER::
-Specify the contact phone number.
+RECIPIENT::
+Specify the recipient.
 
-*--given-name* NAME, *--name* NAME::
-New (given) name.
+*--given-name* GIVEN_NAME, *--name* NAME::
+New system given name.
 
 *--family-name* FAMILY_NAME::
-New family name.
+New system family name.
+
+*--nick-given-name* NICK_GIVEN_NAME::
+New nick given name.
+
+*--nick-family-name* NICK_FAMILY_NAME::
+New nick family name.
+
+*--note* NOTE::
+New note.
 
 *-e*, *--expiration* EXPIRATION_SECONDS::
 Set expiration time of messages (seconds).
@@ -655,8 +692,8 @@ To disable expiration set expiration time to 0.
 
 Remove the info of a given contact
 
-NUMBER::
-Specify the contact phone number.
+RECIPIENT::
+Specify the recipient.
 
 *--hide*::
 Hide the contact in the contact list, but keep the data.
@@ -669,8 +706,8 @@ Delete all data associated with this contact, including identity keys and sessio
 Block the given contacts or groups (no messages will be received).
 This change is only local but can be synchronized to other devices by using `sendContacts` (see below).
 
-[CONTACT [CONTACT ...]]::
-Specify the phone numbers of contacts that should be blocked.
+[RECIPIENT [RECIPIENT ...]]::
+Specify the contacts that should be blocked.
 
 *-g* [GROUP [GROUP ...]], *--group-id* [GROUP [GROUP ...]]::
 Specify the group IDs that should be blocked in base64 encoding.
@@ -680,8 +717,8 @@ Specify the group IDs that should be blocked in base64 encoding.
 Unblock the given contacts or groups (messages will be received again).
 This change is only local but can be synchronized to other devices by using `sendContacts` (see below).
 
-[CONTACT [CONTACT ...]]::
-Specify the phone numbers of contacts that should be unblocked.
+[RECIPIENT [RECIPIENT ...]]::
+Specify the contacts that should be unblocked.
 
 *-g* [GROUP [GROUP ...]], *--group-id* [GROUP [GROUP ...]]::
 Specify the group IDs that should be unblocked in base64 encoding.
@@ -754,7 +791,7 @@ The attachment data is returned as a Base64 String.
 The ID of the attachment as given in the attachment list of the message.
 
 *--recipient* [RECIPIENT]::
-Specify the number which sent the attachment.
+Specify the recipient which sent the attachment.
 Referred to generally as recipient.
 
 *-g* [GROUP], *--group-id* [GROUP]::
@@ -766,10 +803,10 @@ Gets the raw data for a specified contact, contact's profile or group avatar.
 The attachment data is returned as a Base64 String.
 
 *--contact* [RECIPIENT]::
-Specify the number of a recipient.
+Specify the recipient.
 
 *--profile* [RECIPIENT]::
-Specify the number of a recipient.
+Specify the recipient.
 
 *-g* [GROUP], *--group-id* [GROUP]::
 Alternatively, specify the group ID for which to get the avatar.
@@ -890,10 +927,10 @@ Send a message to a group::
 signal-cli -a ACCOUNT send -m "This is a message" -g GROUP_ID
 
 Trust new key, after having verified it::
-signal-cli -a ACCOUNT trust -v SAFETY_NUMBER NUMBER
+signal-cli -a ACCOUNT trust -v SAFETY_NUMBER RECIPIENT
 
 Trust new key, without having verified it. Only use this if you don't care about security::
-signal-cli -a ACCOUNT trust -a NUMBER
+signal-cli -a ACCOUNT trust -a RECIPIENT
 
 == Exit codes
 
