Copy
Copy
Copy
Copy
{
"url": "https://en.wikipedia.org/wiki/Special:Random",
"file_type": "jpg",
"window_width": 1440,
"window_height": 900,
"timeout": 10,
"css_media_type": "screen"
}
curl --request POST \
--url https://3.screeenly.com/api/v1/shots \
--header 'authorization: Bearer $token' \
--data 'url=https://en.wikipedia.org/wiki/Special:Random' \
--data 'file_type=jpg' \
--data 'window_width=1440' \
--data 'window_height=900' \
--data 'timeout=10' \
--data 'css_media_type=screen'
$response = Http::withToken($token)
->asForm()
->post('https://3.screeenly.com/api/v1/shots', [
'url' => 'https://en.wikipedia.org/wiki/Special:Random',
'file_type' => 'jpg',
'window_width' => 1440.0,
'window_height' => 900.0,
'timeout' => 10.0,
'css_media_type' => 'screen',
]);
Use screeenly to take a JPG screenshot of https://en.wikipedia.org/wiki/Special:Random at 1440×900 pixels.
Use these options: timeout: 10.0, css_media_type: 'screen'.