1. Install the Clay plugin
The Clay plugin gives agents both MCP capabilities and the Clay CLI.Clay plugin quickstart
Install the plugin and configure
CLAY_API_KEY.2. Choose a function
Use a Clay-managed function for common jobs like finding emails or enriching companies. Use a custom function when your team already has Clay logic it wants agents to call.Routines
Compare Clay-managed functions, custom functions, and Workflows.
3. Expose the function
For custom functions:- Open Functions.
- Select the function.
- Open Details.
- Enable MCP if the agent should call it through MCP.
- Enable API if you also want API or CLI execution.
4. Let the agent call it
After setup, the agent can discover and run the function from its available routines. Keep the input schema tight and the output predictable. Good functions for agents:- Find a person’s work email.
- Enrich a company by domain.
- Score an inbound lead.
- Summarize account research.
- Route a lead to the right owner or motion.

