Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't get my number back into a signal group #515

Open
markmghali opened this issue Apr 11, 2024 · 11 comments
Open

Can't get my number back into a signal group #515

markmghali opened this issue Apr 11, 2024 · 11 comments

Comments

@markmghali
Copy link

I had to factory reset my phone. When I Setup signal on my phone again the my home group I use showed up right away. But none of the notifications from home assistant come through on my phone. My other member of the group gets there notifications from home assistant just fine. I looked at logs and tried resetting the group but couldn't figure it out.

Most likely my lack of knowledge.

Thank you

@bbernhard
Copy link
Owner

I guess it might be because your safety number changed (that happens when you factory reset your phone and install Signal again) and the Signal REST API doesn't trust the new safety number. You have to trust it manually with this endpoint: https://bbernhard.github.io/signal-cli-rest-api/#/Identities/put_v1_identities__number__trust__numberToTrust_

@markmghali
Copy link
Author

I guess it might be because your safety number changed (that happens when you factory reset your phone and install Signal again) and the Signal REST API doesn't trust the new safety number. You have to trust it manually with this endpoint: https://bbernhard.github.io/signal-cli-rest-api/#/Identities/put_v1_identities__number__trust__numberToTrust_

hmm okay I tried running it and got this output. My cli syntax is also pretty bad so lots of trial and error.

running the docker on unraid

root@UNRAID:~# curl -X PUT -H "Content-Type: application/json" 'http://ip:port of docker/v1/identities/+number/trust/+number to trust'

{"error":"Couldn't process request - invalid request"}

guessing this is my lack of understanding. any help would be appreciated.

@bbernhard
Copy link
Owner

I guess it might be because your safety number changed (that happens when you factory reset your phone and install Signal again) and the Signal REST API doesn't trust the new safety number. You have to trust it manually with this endpoint: https://bbernhard.github.io/signal-cli-rest-api/#/Identities/put_v1_identities__number__trust__numberToTrust_

hmm okay I tried running it and got this output. My cli syntax is also pretty bad so lots of trial and error.

running the docker on unraid

root@UNRAID:~# curl -X PUT -H "Content-Type: application/json" 'http://ip:port of docker/v1/identities/+number/trust/+number to trust'

{"error":"Couldn't process request - invalid request"}

guessing this is my lack of understanding. any help would be appreciated.

Looks like you are missing the payload, see https://bbernhard.github.io/signal-cli-rest-api/#/Identities/put_v1_identities__number__trust__numberToTrust_.

In the end, it should look something like this:

curl -X 'PUT' \
  'http://<ip>:<port>/v1/identities/<number>/trust/<numberToTrust>' \
  -H 'accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "trust_all_known_keys": false,
  "verified_safety_number": "<safety number>"
}'

The safety number can be obtained via the corresponding GET request:

https://bbernhard.github.io/signal-cli-rest-api/#/Identities/get_v1_identities__number_

@markmghali
Copy link
Author

markmghali commented Apr 17, 2024

Awesome Thank you! So Much!! I think I got it figured out now! Really appreciate the time

Getting the safety number and then adding it into your command worked! Thank you

@markmghali
Copy link
Author

@bbernhard

Now I got another new phone trying to get my safety number. Using the same process and getting an error. I am running the docker in json-rpc mode.

Here is the output of the command. I know it's not much info:

root@RAID:~# curl -X GET -H "Content-Type: application/json" 'http://192.168.1.4:8777/v1/identities/+15153716197' 

{"error":"unexpected end of JSON input"}

most likely it is something wrong in my syntax?
thank you again

@markmghali markmghali reopened this Oct 3, 2024
@bbernhard
Copy link
Owner

Which version are you using? Does it work if you temporarily switch to the normal mode?

@markmghali
Copy link
Author

markmghali commented Oct 3, 2024 via email

@markmghali
Copy link
Author

switched it to normal mode now and getting this error

# curl -X GET -H "Content-Type: application/json" 'http://192.168.1.4:8777/v1/identities/+15153716197' 
{"error":"User +15153716197 is not registered.\n"}#

running the docker on unraid

@bbernhard
Copy link
Owner

Which docker image version do you use?

@markmghali
Copy link
Author

bbernhard/signal-cli-rest-api:latest

The Latest version 0.88

@markmghali
Copy link
Author

markmghali commented Oct 7, 2024

Ok so I am in Native mode. on 0.89
I registered my number again
got the safety number and tried this command again and getting an error

curl -X 'PUT' \
  'http://192.168.1.4:8777/v1/identities/+number/trust/+number_to_trust' \
  -H 'accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "trust_all_known_keys": false,
  "verified_safety_number": "safety_number"
}'

Here is the error:
{"error":"Failed to set the trust for this number, make sure the number and the fingerprint/safety number are correct.\n"

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

No branches or pull requests

2 participants