Can I define tools in both prompt and API call?

Is it possible to define tools both in a Prompt and in the Responses API call?

I’m doing something like this:

...await openai.responses.create({
    ...
    tools: [...] 
    prompt: ...,
    ...
    });

But it seems that the tools in the API call replace the ones in the Prompt instead of combining.

1 Like

Thank you for performing the experimentation which essentially answers for others: the whole parameter is replaced.

Now try just “verbosity” in the "text" field with gpt-5 and see if your prompt’s text.format.json_schema is completely borked…for more fun.