hint. They use the standard format, where the body is { tool, arguments, ... }. Replace the lookup with your own logic.
In the app: add the endpoint’s address in Sidebar → Agent Settings → APIs → Add API action with Format set to SmartAlex standard and Sent as set to Bearer token (
/home?settings=http_tools).How do I use these handlers?
Each sample needs theverifySignature function from Signature verification in the same file or module. Set two environment variables: SMARTALEX_SIGNING_SECRET (the shs_ secret) and SMARTALEX_TOOL_TOKEN (the key you saved under API key).
1
Copy your verify function
Take the one for your language from the signature page.
2
Add the handler below
It must read the raw body before any JSON parsing.
3
Expose it over HTTPS
Use a public address, then add it as the action’s URL.
- Node.js (Express)
- Python (Flask)
- Python (FastAPI)
- PHP
- Go
What does a stand-in lookup look like?
Related
Signature verification
The verify functions these handlers use.
Troubleshooting
When the handler is not reached or rejects a request.

