Document Tools
Recupere un README GitHub et le convertit en PDF
Appelez cet outil depuis votre code en trois langages.
curl -X POST 'https://api.elysiatools.com/fr/api/tools/github-readme-to-pdf' \
-H 'Content-Type: application/json' \
-d '{"repository":"https://github.com/meilisearch/meilisearch","branch":"main","readmePath":"README.md","theme":"print","baseFontSize":13,"pageSize":"A4","landscape":false,"printBackground":true,"marginTop":18,"marginBottom":18,"marginLeft":16,"marginRight":16,"waitUntil":"networkidle0","waitTime":0}'Envoyez une requête POST avec vos entrées en JSON. Les paramètres de type fichier nécessitent un upload préalable.
POST https://api.elysiatools.com/fr/api/tools/github-readme-to-pdf| Nom | Type | Requis | Description |
|---|---|---|---|
| repository | text | Oui | — |
| branch | text | Non | — |
| readmePath | text | Non | — |
| theme | select | Non | — |
| baseFontSize | number | Non | — |
| pageSize |
Ajoutez cet outil à votre serveur Model Context Protocol pour que les agents IA puissent le lister et l'appeler.
Ajoutez ce bloc à la configuration de votre client MCP :
{
"mcpServers": {
"elysiatools-github-readme-to-pdf": {
"name": "github-readme-to-pdf",
"description": "Recupere un README GitHub et le convertit en PDF",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=github-readme-to-pdf",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}Après connexion au point d'accès SSE, listez les outils exposés :
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Appelez l'outil par son id ; les arguments sont construits à partir de ses paramètres :
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "github-readme-to-pdf",
"arguments": {
"repository": "https://github.com/meilisearch/meilisearch",
"branch": "main",
"readmePath": "README.md",
"theme": "print",
"baseFontSize": 13,
"pageSize": "A4",
"landscape": false,
"printBackground": true,
"marginTop": 18,
"marginBottom": 18,
"marginLeft": 16,
"marginRight": 16,
"waitUntil": "networkidle0",
"waitTime": 0
}
}
}| select |
| Non |
| — |
| landscape | checkbox | Non | — |
| printBackground | checkbox | Non | — |
| marginTop | number | Non | — |
| marginBottom | number | Non | — |
| marginLeft | number | Non | — |
| marginRight | number | Non | — |
| waitUntil | select | Non | — |
| waitTime | number | Non | — |
Résultat fichier
{
"filePath": "/public/processing/randomid.ext",
"fileName": "output.ext",
"contentType": "application/octet-stream",
"size": 1024,
"metadata": {
"key": "value"
},
"error": "Error message (optional)",
"message": "Notification message (optional)"
}Des questions ou un problème ? Contactez [email protected]