Notre avis
Ce skill permet d'appeler des API REST depuis Python, de parser les réponses JSON et de présenter les champs utiles à l'utilisateur.
Points forts
- Utilise directement le code Python via execute_code pour exécuter les requêtes.
- Se concentre sur l'extraction des champs pertinents plutôt que d'afficher tout le payload.
- Gère les authentifications par token ou clé API via les variables d'environnement.
- Signale clairement les erreurs HTTP et les informations manquantes.
Limites
- Nécessite que l'outil execute_code soit disponible.
- Dépend de la bibliothèque requests, qui peut ne pas être installée.
- Ne gère pas les API non-JSON ou les flux complexes.
Quand une donnée doit être récupérée depuis une API REST et présentée de manière synthétique.
Pour des appels API simples effectués avec un autre outil ou si l'environnement ne permet pas l'exécution de code Python.
Analyse de sécurité
PrudenceThe skill uses powerful execute_code and network access for legitimate API calling, but it does not include destructive or obfuscated instructions. The risk is similar to any code execution tool, so caution is warranted.
- •Uses execute_code to run arbitrary Python, which could perform unintended actions if the agent is compromised or the user request is malicious.
- •Makes network requests to user-specified endpoints, which could be used to exfiltrate data if combined with a malicious API or instruction.
- •Reads environment variables for tokens/API keys, which risks exposing secrets if the script prints them inadvertently.
Exemples
Use the REST API skill to get a random joke from https://official-joke-api.appspot.com/random_joke and show me the setup and punchline.Call the GitHub API to list my public repositories. Use the GITHUB_TOKEN environment variable for authentication and return only the repository names and URLs.Get the current weather for Paris from the Open-Meteo API at https://api.open-meteo.com/v1/forecast?latitude=48.85&longitude=2.35¤t_weather=true and tell me the temperature and wind speed.name: rest-api-caller description: Call REST APIs from Python, parse JSON responses, and report the useful fields back to the user. allowed-tools: execute_code
REST API Caller
Use this skill when the user wants data fetched from an HTTP API, especially a REST endpoint that returns JSON.
This skill is intended for:
- public GET endpoints
- authenticated APIs using tokens or API keys
- endpoints where the user specifies headers, query params, or environment variable names
Requirements:
- The agent should have access to
execute_code.
Workflow:
- Activate this skill when the task requires calling an API.
- If you need examples, call
read_skill_fileforreferences/examples.md. - Write a short Python script that performs the request.
- Prefer the
requestslibrary if available in the environment. - Prefer
execute_code. - Parse the response and print only the fields needed for the final answer.
- Summarize the API result clearly for the user.
Rules:
- Do not invent API responses. Run the request first.
- For JSON APIs, parse JSON and extract the relevant fields instead of dumping the whole payload unless the user asks for the raw body.
- If the user provides an environment variable name for a token or API key, read it from
os.environinside the script. - If the endpoint requires auth and no credential source is provided, say what is missing.
- If the request fails, report the HTTP status code or error message clearly.
- Do not claim there is a generic execution-environment issue unless the tool call actually returned one.
Demo endpoint:
GET https://official-joke-api.appspot.com/random_joke
Expected behavior for the demo endpoint:
- Fetch one random joke
- Return the setup and punchline in a readable format
Expert Next.js App Router
Developpement
Un skill qui transforme Claude en expert Next.js App Router.
Générateur de README
Developpement
Crée des README.md professionnels et complets pour vos projets.
Rédacteur de Documentation API
Developpement
Génère de la documentation API complète au format OpenAPI/Swagger.