# LTI setup

Some settings need to be exchanged manually between Platform and Tool.

Settings provided from the tool:

* Tool URL: <https://www.example.com/launch/>
* Initiate login URL `Platform.LTI.toolLoginUrl`: <https://www.example.com/login/>
* Redirection URL(S) `Platform.LTI.toolRedirectionUrl`: <https://www.example.com/launch/>
* Public Keyset URL `Platform.LTI.toolKeysetUrl`: <https://www.example.com/jwks/>

Settings provided from the Platform:

* Platform ID/URL: <https://www.example.com/api/v3/lti/platform>
* Client ID `Platform.LTI.clientId`: xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx
* Deployment ID `Platform.LTI.deploymentId`: xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx
* Public keyset URL <https://www.example.com/api/v3/lti/platform/jwks>
* Access token URL <https://www.example.com/api/v3/lti/platform/token>
* Authentication request URL <https://www.example.com/api/v3/lti/platform/login>

In the Platform Config settings, we should store the config values, to be accessible via `Configure::read('Platform.LTI.<…>')`.

An RSA private key must be generated and stored in the .env `RSA_PRIVATE_KEY_BASE64`:

```
openssl genrsa -out private.key 2048
openssl rsa -in private.key -pubout -out public.pem
echo "RSA_PRIVATE_KEY_BASE64=" && base64 -w 9999 private.key
```


---

# 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://docs.eduplex.eu/lti-connector/lti-setup.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.
