Problem when using GLM-5 wih Cursor

I would test GLM-5 so I gave it my android app asking to make a flutter duplicate. I t analyze the code of the android app and make plan but upon execution it gives “Provider returned error: {“error”:{“code”:“1210”,“message”:“Invalid API parameter, please check the documentation.Request 143673 input tokens exceeds the model’s maximum context length 202752”}}”.
* I made subscriptopn to GLM coding Pro plan.
* Iam using https://api.z.ai/api/coding/paas/v4.

Is there a solution? How to do it?

Thanks.

Hey there!

Cursor’s BYOK (Bring Your Own Key) feature works with APIs that follow the standard OpenAI-compatible format. However, some providers have implemented custom extensions, response formats, or validations that deviate from this standard.

As a result, these providers may reject API calls from Cursor, making them incompatible with the BYOK feature.