Cloudflare Docs
Cloudflare for Platforms
Cloudflare for Platforms
Edit this page on GitHub
Set theme to dark (⇧+D)

Common API Calls

As a SaaS provider, you may want to configure and manage Cloudflare for SaaS via the API rather than the Cloudflare dashboard. Below are relevant API calls for creating, editing, and deleting custom hostnames, as well as monitoring, updating, and deleting fallback origins. Further details can be found in the Cloudflare API documentation.


​​ Custom hostnames

EndpointNotes
List custom hostnamesUse the page parameter to pull additional pages. Add a hostname parameter to search for specific hostnames.
Create custom hostnameIn the validation_records object of the response, use the txt_name and txt_record listed to validate the custom hostname.
Custom hostname details
Edit custom hostnameWhen sent with an ssl object that matches the existing value, indicates that hostname should restart domain control validation (DCV).
Delete custom hostnameAlso deletes any associated SSL/TLS certificates.

​​ Fallback origins

Our API includes the following endpoints related to the fallback origin of a custom hostname: