GPT-5 Error in Pabbly: max_tokens Not Supported (Requires max_completion_tokens)

adampj

Member
I’m running into an error when trying to use GPT-5 via the ChatGPT (Structured AI Output) action in Pabbly Connect. In my setup, I configured the model as gpt-5 and set the roles (developer,user). I also tried to increase the token allowance by setting the Max Tokens field to 12000. However, the request fails with the following error:

Code:
Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead.

It looks like the Structured Output action is still sending max_tokens, which is deprecated or unsupported for the GPT-5 API. The new parameter that should be used is max_completion_tokens. Since the UI currently exposes “Max Tokens” as the field name, this mismatch is causing the request to fail.

Has anyone found a workaround (e.g., renaming the field, using a custom API request, or waiting on a Pabbly update) to correctly use GPT-5 with higher token limits in this integration? Thanks!

Screenshots:

Screenshot 2025-09-06 at 16.24.36.png Screenshot 2025-09-06 at 16.25.49.png Screenshot 2025-09-06 at 16.28.08.png
 
Top