rafled Screenshot API allows you to get website screenshots. You may pass optional parameters such as screen width, height, and User Agent to get screenshots tailored to your needs.
Request URI
https://www.rafled.jp/api/website/screenshot
Rate Limiting
Duration | Requests |
---|---|
Monthly | Unlimited |
Per Minute | 60 Requests |
The following response headers detail your limits.
Headers | Remarks |
---|---|
X-RateLimit-Limit | # of requests you can make within a minute |
X-RateLimit-Remaining | Total number of remaining requests |
Caching
By default, we cache all the screenshots for up to 1 week. The following response headers will detail the cache information.
Header | Remarks |
---|---|
Expires | Cache Expiry Date |
URL Parameters
The URL Parameters which you can pass to the application to get an appropriate response.
Parameter | Type | Default Value |
---|---|---|
url | string | required | none |
width | integer | optional | 1920 |
height | integer | optional | 1080 |
userAgent | string | optional | Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.3.5029.61 Safari/537.36 |
Responses
Response | Response Type | Remarks |
---|---|---|
200 | application/json | Returns Screenshot URI and cache expiry (in GMT) |
400 | application/json | Bad Request. When requested parameters were not supplied. |
5xx | – | Internal Server Error |
Examples
To get started, you will have to sign up on our website here. Then, navigate to Dashboard > API Tokens to generate an API Token. Create a token and then replace {token} with your token.
cURL
curl "https://www.rafled.jp/api/website/screenshot?url=https://example.com&width=800&height=400&userAgent=foo" -H "Accept: application/json" -H "Authorization: Bearer {token}"