Compare AI model prices and generate media
The agent identifies the most cost-effective model for a specific media task and executes the generation, charging the user's API Stock balance for the result.
How it works
First, the agent uses list_models to retrieve available video, image, or music models and their starting prices. It then uses estimate_cost to calculate the exact price for the specific request parameters (e.g., duration, resolution). After confirming the cost with the user or based on predefined criteria, the agent calls create_generation to start the process. It then uses get_task to poll for the result until the generation is complete, finally providing the output URL.
Prompt
Paste this into an agent that has the servers below connected. Adjust the names and dates to your own.
Find the cheapest video model that supports 5-second clips. Estimate the cost for a 1080p clip. If under $0.10, generate a video of a cat playing piano using that model and return the final video URL.MCP servers it needs
Source
The vendor page this playbook is drawn from, and the passage that supports it.
create_generation Starts a generation and returns a taskId . Charges the balance.MCP server — API Stock