This documentation and answers will help you get started and master the way you use PageCDN for better content delivery.

Lookup public files


This endpoint allows you to search files on Public CDN. With this endpoint, you can:

  • Search files by external URLs;
  • Search files by sha256 hash;
  • Search files in a repo or search the entire Public CDN;
  • Search minified files. For example, if your input matches library.js, you can request the API to find corresponding minified file library.min.js.

Note: PageCDN now supports on-the-fly CSS and JS minification. So, you can now use .min.css and .min.js with all CSS and JS files. If a minified file is not already available in the library, PageCDN will minify it for you. This feature is also available for your private content.

Query String Parameters

apikeystringrequiredThe api key to identify originator of the request.
matchstringrequiredSpecify the lookup method. This can either be hash or url.
hashstringoptionalsha256 hash of the file you want to lookup. Hash is required if you specified hash as lookup method.
urlstringoptionalURL to lookup a matching file on PageCDN. URL can be URL of a file on PageCDN, or an external URL. URL is required if you specified url as lookup method.
repostringoptionalIf you want to search files within a specific repo only, specify repo path as lib/jquery.
optimizedstringoptionalSpecify if you want the API to return corresponding minified files when available. Set true to enable this feature.

Successful Response

    "status": "200",
    "message": "Ok",
    "details": "Success",
    "response": {
        "count": 1,
        "files": [
                "repo": "lib/jquery",
                "repo_name": "jQuery",
                "version": "3.4.0",
                "file_hash": "0497a8d2a9bde7db8c0466fae73e347a3258192811ed1108e3e096d5f34ac0e8",
                "file_url": "",
                "file_size": "88151"

Sample Requests

Lookup a file by hash 

Lookup a file by external URL 

Lookup a minified file 

Lookup within a specific repo