Reputation: 31
After integration of azure CDN in our site, we found that the cache is not purged while replacing the file. This is happening only for PDF file type. We want to purge the cache on replace of the file. Please help us if anyone has faced the similar issue and purged the CDN cache programmatically.
Thanks
Upvotes: 2
Views: 669
Reputation: 905
S.Ray ,
You can use the below Rest API doc to purge content from Azure CDN: https://learn.microsoft.com/en-us/rest/api/cdn/cdn/endpoints/purgecontent
In the request body, under contentPaths parameter, you can provide the path to the content to be purged. It can describe a file path or a wild card directory.
Thanks!
Upvotes: 3