# Prerequisites

This framework needs at least:

* PHP 8.2+
* Extensions (required):
  * openssl
* Extensions (recommended):
  * gmp or bcmath (for better performance with RSA/PSS algorithms)
  * sodium (for EdDSA with Ed25519, ECDH-ES with X25519, and faster Base64URL encoding)
  * curl (for loading keys from remote URLs)

{% hint style="info" %}
The `json` extension is built-in with PHP 8.2+ and no longer needs to be installed separately.
{% endhint %}

{% hint style="info" %}
When the `ext-sodium` extension is available, the framework automatically uses it for Base64URL encoding/decoding operations, providing significant performance improvements.
{% endhint %}

<mark style="color:orange;">Please note that cryptographic operations may be really slow, especially RSA functions. It is highly recommended to enable GMP or BCMath.</mark>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://web-token.spomky-labs.com/introduction/pre-requisite.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
