Fastly is a CDN and caching service included with Magento Commerce (Cloud) plans and implementations. If you attempt to use a Fastly purge option, and it does not process, you may have incorrect Fastly credentials in your environment or may have encountered an issue. You may receive the error: “The purge request was not processed successfully.”
This information helps your verify and test Fastly headers for your live site and origin servers.
- Magento Commerce (Cloud) 2.0.X, 2.1.X, 2.2.X
- Fastly 1.2.27 and later
Caching is working, but when you try to purge, you receive an error or it doesn't work. The error includes: “The purge request was not processed successfully.”
You may have incorrect credentials set in your environment or need to upload VCL snippets.
Check Fastly credentials
Verify if you have the correct Fastly Service ID and API token in your environment. If you have Staging credentials in Production, the purges may not process or process incorrectly.
- Log in to your local Magento Admin as an administrator.
- Click Stores > Settings > Configuration > Advanced > System and expand Full Page Cache.
- Expand Fastly Configuration and verify the Fastly Service ID and API token for your environment.
- If you modify the values, click Test Credentials.
Check VCL snippets
If the credentials are correct, you may have issues with your VCLs. To list and review your VCLs per service, enter the following API call in a terminal:
curl -X GET -s https://api.fastly.com/service/<Service ID>/version/<Editable Version #>/snippet/ -H "Fastly-Key:FASTLY_API_TOKEN"
Review the list of VCLs. If you have issues with the default VCLs from Fastly, you can upload again or verify the content per the Fastly default VCLs. For editing your custom VCLs, see Custom Fastly VCL snippets.