docs
  1. Authentication API
  2. Resources
  3. Single Sign-on (idp)
  4. Redirect User

Redirect User

JWT contains the callbackUrl, idpKey, clientId, iat, and exp. JWT needs to be signed with the shopSecret. All the following fields are required for the JWT:

  • callbackUrl
  • idpKey
  • clientId
  • iat
  • exp

Example JWT payload

$payload = [ 'callbackUrl' => $this->argument('callbackUrl'), 'idpKey' => $this->argument('idpKey'), 'clientId' => $this->argument('clientId'), 'iat' => time(), 'exp' => now()->modify('+15 minutes')->timestamp ];
  • iat - current timestamp
  • exp - expiration timestamp