We looked everywhere for this functionality and couldn't find anything so we've taken a crack at creating our own.
Small plugin that uses 3 system settings to connect to the CloudFlare API and purge your sites CloudFlare cache when clicking the "Clear Cache" button in the MODX manager (the OnBeforeCacheUpdate system event).
The project's on GitHub at
https://github.com/DashMedia/PurgeCloudFlare/ and we'd love any feedback or suggestions for improvements.
Hope this helps someone else out there.
Updateed with details about version 2.0:
The new version uses the CloudFlare API to purge the CloudFlare cache for your website, PurgeCloudFlare will purge single pages from CloudFlare when they are save within the MODX Manager, and purge the entire cache when the "Clear Cache" button is pressed.
We also now have support for multiple contexts with different domains. You can also use a context setting to skip over a specific context.
Another great new feature is that saving a resource will individually clear that page from CloudFlare along with the ancestors in the resource tree. For example: when I update a news item, the news item listing page also gets cleared.
Read the docs, take, browse the source, announce bugs, or submit pull requests at
https://github.com/DashMedia/PurgeCloudFlare/
We recommend installing via the MODX Extras directory at
http://modx.com/extras/package/purgecloudflare2 for easy upgrades.
[ed. note: dashmedia last edited this post 9 years, 1 month ago.]