Resizely

Authentication

You'll need to authenticate your requests to access the endpoint in the Resize API. In this guide, we'll look at how authentication works.

Api key authentication

When you create an account, Resizely will generate a unique Api key for you. With this authentication, you use your Api key to authenticate your HTTP requests. You can retrieve your Api key from the Dashboard » Api key

Example request with Api key

curl https://api.resizely.net/[API_KEY]/w:960/https://url_of_theImage \

Since the API key is public, any user who knows how to analyze network requests on your site can obtain the API key you are using to contact Resizely. It is recommended to set up filters!

Filters

Resizely offers the ability to limit the use of your API key using from and to filters.

From filter

The From filter is applied on the Origin header of the request.

When a request from your website arrives to Resizely, we look at the Origin header present in the request. We than compare this value with the filter you setted up using a contain rule, so that your Origin header must be contained in the From filter.

For example if your website is example.com, or any subdomain, you must set example.com in the From filter to let Resizely handle the request.

To filter

The To filter is applied on the domain of the image resource you are requesting.

When a request from your website arrives to Resizely, we look at the domain of the image requested. We than compare this value with the filter you setted up using a contain rule, so that your image location domain must be contained in the To filter.

For example if you request an image on https://storage.googleapis.com/static.resizely.net/samples/sample_1.jpg, you must set https://storage.googleapis.com/static.resizely.net in the To filter to let Resizely handle the request.

Was this page helpful?