Purge Cache

Please refer to Purge Cache page to have a better understanding of cache purging.

Purges files from Global Caches & Internal Caches

POST https://api.imagemash.io/v1/storage/purgeCache

Headers

Name
Type
Description

apikey*

String

Your API Key

Request Body

Name
Type
Description

paths*

Array

Array of paths. Could be a complete path or a incomplete path. Consider as a search string. Please refer to

Purge Cache to understand requirements of paths.

domain

String

Domain name. Eg. john.imagemash.io

I26JPCNTSVM8DB

Example Codes

curl --location 'https://api.imagemash.io/v1/storage/purgeCache' \
--header 'apikey: your_api_key' \
--header 'Content-Type: application/json' \
--data '{
    "domain": "john.imagemash.io",
    "paths": [
        "/logo.png",
        "/img/big/my_"
    ]
}'

Get list of your Purge requests

POST https://api.imagemash.io/v1/storage/purgeCache

Headers

Name
Type
Description

apikey*

Your API Key

[
    {
        "createdAt": "2022-09-22T14:25:30.995Z",
        "requestId": "I26JPCNTSVM8DB",
        "status": "InProgress",
        "paths": [
            "/eg1.png",
            "/img/big/my_",
            "/my_image_repository/"
        ]
    },
    {
        "createdAt": "2022-08-22T14:22:05.877Z",
        "requestId": "IVSU919KZECQH",
        "status": "Completed",
        "paths": [
            "/companies/my_company"
        ]
    }
]

Example Codes

curl --location --request POST 'https://api.imagemash.io/v1/storage/getPurgeList' \
--header 'apikey: your_api_key'

Last updated