CloudFront Cache Invalidation API
Use this API to tell Flightcontrol to clear the CloudFront cache for a path or set of paths for a particular service.
API Description
Method | Path |
---|---|
POST | /v1/services/{serviceId}/cloudfront/invalidation |
Headers | |
---|---|
Authorization | Bearer: [API key] |
Parameters | ||
---|---|---|
Parameter | Type | Description |
serviceId | string | The service unique CUID. |
Body | ||
---|---|---|
Parameter | Type | Description |
paths | string[] | This is an array of the paths you wish to invalidate. Note: The constraints here are consistent with the AWS path constraints. Particularly, a wildcard symbol * can only be passed at the end of the path. See AWS documentation for more details. |
Full Endpoint URL https://api.flightcontrol.dev/v1/services/{serviceId}/cloudfront/invalidation
Request Body Example
{
"paths": ["/*"]
}
Response Example
{
"message": "Invalidation Started. Be sure to save your invalidation ID if you would like to check on its status.",
"invalidationId": "cl2kx7acm00003f6gobvidq2i"
}
Response Conditions
Success
Errors