JSON Web Token implementation
Minimum implementation used by Realtime auth, based on this spec: http://self-issued.info/docs/draft-jones-json-web-token-01.html.
author | Aleksey Korzun |
---|---|
package | Library |
subpackage | Twilio\Utility\Capability |
decode(string $jwt, string | null $key, bool $verify) : object
string
the JWT
string
null
the secret key
bool
don't skip verification process
\UnexpectedValueException |
|
---|---|
\DomainException |
object
JSON Web Token implementation as PHP objectencode(object | array $payload, string $key, string $algorithm) : string
object
array
PHP object or array
string
the secret key
string
the signing algorithm
string
JSON Web Token implementationjsonDecode(string $input) : object | string[]
string
JSON string
\DomainException |
---|
object
string[]
object representation of JSON stringjsonEncode(object | string[] $input) : string
object
string[]
a PHP object or array
\DomainException |
---|
string
JSON representation of the PHP object or arraysign(string $message, string $key, string $method) : string
string
the message to sign
string
the secret key
string
the signing algorithm
string
an encrypted messageurlsafeB64Decode(string $input) : string
string
a base64 encoded string
string
a decoded stringurlsafeB64Encode(string $input) : string
string
anything really
string
the base64 encode of what you passed inhandleJsonError(int $error)