I am using custom hostnames API but it keeps giving me 400 Bad Request error

What is the name of the domain?

I am adding this test.encurate.app as a custom domain on my SaaS domain through API.

What is the error number?

400

What is the error message?

Error adding custom hostname to Cloudflare: 400 Client Error: Bad Request for url: https://api.cloudflare.com/client/v4/zones//custom_hostnames

What is the issue you’re encountering

Error adding custom hostname to Cloudflare: 400 Client Error: Bad Request for url: https://api.cloudflare.com/client/v4/zones//custom_hostnames

What steps have you taken to resolve the issue?

The hostname is correctly set to the user’s domain (e.g., test.encurate.app).
The fallback origin is configured in Cloudflare.
The API credentials are correct:
I have verified the X-Auth-Email and X-Auth-Key.
The Zone ID is correct:

There are two slashes in your path.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.