SSH Key Invalid Token

Following the given instructions in my Pro account:

Users-iMac:ionic username$ ionic start --pro-id 45de0000

Ran into a 401 invalid token response, so configured my SSH key manually.

Users-iMac:ionic usersname$ ionic ssh setup
Looks like you haven't configured your SSH settings yet.

? How would you like to connect to Ionic Pro? 
Automatically setup new a SSH key pair for Ionic Pro
Using your previously generated key: ../../../.ssh/ionic/999999.
You can generate a new one by deleting it.

> ionic ssh add /Users/usersname/.ssh/ionic/999999.pub --use
Request: POST https://api.ionicjs.com/users/999999/sshkeys
Response: 401
Body: 
{ link: null, type: 'Unauthorized', message: 'Invalid Token' }

Would appreciate some assistance in resolving, I’m stumped.

1 Like

Ok - I don’t use Ionic much.

In Terminal, I was logged in under a different email about 5 months ago. This command fixed the problem:

ionic login
4 Likes

That fixed it thanks

that fix the problem!!! :slight_smile:

I had this…

ionic link --create

ionic ssh setup
Looks like you haven’t configured your SSH settings yet.

? How would you like to connect to Ionic Pro? Automatically setup new a SSH key pair for Ionic Pro
Using your previously generated key: …/…/…/…/.ssh/ionic/875.
You can generate a new one by deleting it.

ionic ssh add /Users/raulsagastume/.ssh/ionic/875.pub --use
Request: POST https://api.ionicjs.com/users/875/sshkeys
Response: 401
Body:

{ message: ‘Invalid Token’, link: null, type: ‘Unauthorized’ }

I executed the command “ionic login”

wrote my email again and everything works nice!!
Tnks!!