latchkey
npx skills add https://github.com/imbue-ai/latchkey --skill latchkey
Agent 安装分布
Skill 文档
Latchkey
Instructions
Latchkey is a CLI tool that automatically injects credentials into curl commands for supported public APIs. Instead of manually managing API tokens, latchkey opens a browser for login, extracts credentials from the session, and injects them into your curl requests.
Use this skill when the user asks you to work with third-party services like Slack, Discord, Dropbox, Github, Linear and others on their behalf.
Usage:
- Use
latchkey curlinstead of regularcurlfor supported services. - Use
latchkey info <service_name>to get developer notes about a specific service (API docs links, special requirements, etc.). - Look for the newest documentation of the desired public API online. Avoid bot-only endpoints if such a distinction exists.
- Pass through all regular curl arguments – latchkey is a transparent wrapper.
- Use
latchkey status <service_name>when you notice potentially expired credentials. - When the status is
invalid, force a new login by callinglatchkey clear <service_name>, then retry the curl command. - Do not force a new login if the status is
valid– the user might just not have the necessary permissions.
Examples
Make an authenticated curl request
latchkey curl [curl arguments]
Creating a Slack channel
latchkey curl -X POST 'https://slack.com/api/conversations.create' \
-H 'Content-Type: application/json' \
-d '{"name":"my-channel"}'
(Notice that -H 'Authorization: Bearer is not present in the invocation.)
Getting Discord user info
latchkey curl 'https://discord.com/api/v10/users/@me'
Clear expired credentials and force a new login to Discord
latchkey status discord # Returns "invalid"
latchkey clear discord
latchkey curl 'https://discord.com/api/v10/users/@me'
Only do this when you notice that your previous call ended up not being authenticated (HTTP 401 or 403). The next latchkey curl call will trigger a new login flow.
List supported services
latchkey services
Get service-specific info
latchkey info slack
Returns developer notes about the service, including API documentation links and any special requirements.
Notes
- All curl arguments are passed through unchanged
- Return codes, stdin, and stdout are passed back from curl