Purge cache by Tags
Last updated
Last updated
POST
https://app.ismartframe.com/api/v1/cache/purge/tag
If you are using the 'Cache By Country' feature on your website, it will be necessary to include the country code as an extra parameter in the request body.
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Cache purge successful. This operation may take a few minutes to propagate across all data centers.
Our platform allows you to associate one or multiple tags with a cached resource on your website under two interoperable options.
It is possible to configure a designated response header (e.g., Tag-Header) to be sent by your website's backend whenever the platform initiates a request. The cache header must encompass one or more tags, separated by commas. Example value: tag1, tag2, tag3.
This option proves valuable especially when you need to execute a cache purge for all pages featuring a particular article (searches, listings, etc.) on your news website or a specific product price (listings, product pages, etc.) on your e-commerce site. It's essential to ensure that your backend supports this functionality by incorporating the appropriate tags in the custom header and implementing a correct logic; otherwise, this feature may not function as intended.
If you prefer not to implement a custom tag response header (or don't need to), you can alternatively assign one or more tags to a specific URL pattern (or a precise URL). This enables tagging all URLs that match the designated pattern, facilitating a cache purge by tag on the identified resources.
If you prefer not to implement a custom tag response header (or don't need to), you can alternatively assign one or more tags to a specific url based on url path structure. Example: /folderA/folderB/folderC/page.html will generate 3 tags as follow: - folder-folderA - folder-folderA-f-folderB - folder-folderA-f-folderB-f-folderC With this tags you are able to delete content inside each folder like a classic purge by folder.
In both cases, the response header "Isf-Tags" will be set by our systems in order to show the tags associated with the cached resource. This ensures that, upon retrieval, the header consistently presents itself, offering valuable insights about the tags that are intricately connected to the cached resource.
api_key*
String
Your API Key
tag*
Array of strings
List of Tags requiring a cache purge.
country
String
ISO 3166-1 alpha-2 Country Code or "ALL" if you want to clear the cache for all countries