BasePath

BasePath is an option that defines the root directory path within a bucket from which resources are served. In other words, it specifies the top-level directory that the CDN will use as the base when fetching files.


Example

Assume the following files are stored in your bucket:

/dog.jpg
/assets/cat.png

In this case, BasePath can be configured in the following :

Setting
Description
Example (Weekerp)

/

Access all files from the root directory of the bucket.

https://cdn.weekerp.com/image/mysource/dog.jpg

/assets

Set the assets folder as the root directory.

https://cdn.weekerp.com/image/mysource/cat.jpg

/

When the assets folder is not defined as BasePath, the folder name remains part of the path.

https://cdn.weekerp.com/image/mysource/assets/cat.jpg


Notes

  • BasePath can be set individually for each Source (bucket).

  • The configured BasePath is automatically appended to the path during CDN requests.

    https://cdn.weekerp.com/image/{source}/{basePath}/cat.png
  • When set to the root (/), all paths are served as-is.

Last updated