I am using cursor cli on headless mode to implement an automation.
Ran into these things that make my life harder:
can’t disable tools calls
doesn’t support JSON schema structured responses
disable thinking - I’ve a custom logic to choose non-thinking models to solve that
any idea if some of these bullets going to be address by any chance? thanks!
What do you mean by disabling tools calls ? It seems to me that, using agent [prompt …] –print tool calls are disabled by default and you need to enable using --approve-mcps option / --yolo
There is a way for you to receive JSON structured responses using -–output format json or stream-json
@Matan_Lasry thank you for your post and the questions.
For disabling tools you may use --mode ask as that works read only and does not modify anything. It may still use some tools like for reading code, etc..
Cursor CLI supports JSON responses but not schema based with --output-format json as we do not pass schemas to the AI APIs.
For non-thinking models you can select a specific model that is not thinking e.g. --model sonnet-4.5 (without -thinking) though note that some models depending on provider may always have thinking enabled.
Yeah, I figured. By the way, non related, but it would be nice to export the cost field from the JSON response like Claude code does. It helps monitor automation costs more accurately