Generate image with QR code
QR Code generator (type text and press enter) https://browsercloud.io/doc-examples/qr-code.html
Get image with QR code only (using "selector" option)
curl -X POST \
https://chrome-v2.browsercloud.io/screenshot?token=API_TOKEN \
-H 'Cache-Control: no-cache' \
-H 'Content-Type: application/json' \
-d '
{
"url": "https://browsercloud.io/doc-examples/qr-code.html",
"addScriptTag" : [
{
"content" : "document.getElementById(\"text\").value = \"QR CODE CONTENT\"; makeCode();"
}
],
"options": {
"type": "png"
},
"selector" : ".output"
}'
Parameters | Available values | Description |
---|---|---|
url | string | URL for web scraping |
waitFor | string | Script waits certain DOM element to be rendered |
addScriptTag.content | string - js code | Adds custom <script> tag to the page |
selector | string - dom node selector | render certain DOM node by selector |
type | png,jpeg | image format |
quality | 1-100 | available for jpeg only |