Skip to navigation

screenshot

Referenced In

Fields

FieldTypeDescriptionDefault
screenshotone of:
- string
- object(Capture screenshot (detailed))
- boolean
Required. Takes a screenshot in PNG format.—

Examples

{
"screenshot": true
}
{
"screenshot": "image.png"
}
{
"screenshot": "static/images/image.png"
}
{
"screenshot": "/User/manny/projects/doc-detective/static/images/image.png"
}
{
"screenshot": "/Users/jane doe/projects/my docs (v2)/static/images/image.png"
}
{
"screenshot": "https://example.com/static/images/image.png"
}
{
"screenshot": {
"path": "https://promptless-customer-doc-assets.s3.amazonaws.com/docs-images/request-changes-button-0c851bb3.png",
"maxVariation": 0.05,
"overwrite": "aboveVariation"
}
}
{
"screenshot": {
"path": "image.png",
"directory": "static/images",
"maxVariation": 0.1,
"overwrite": "aboveVariation",
"crop": "#elementToScreenshot"
}
}
{
"screenshot": {
"path": "image.png",
"directory": "static/images",
"maxVariation": 0.1,
"overwrite": "aboveVariation"
}
}
{
"screenshot": {
"path": "image.png",
"directory": "static/images",
"maxVariation": 0.1,
"overwrite": "aboveVariation",
"crop": {
"selector": "#elementToScreenshot",
"elementText": "Element text",
"padding": {
"top": 0,
"right": 0,
"bottom": 0,
"left": 0
}
}
}
}
{
"screenshot": {
"path": "login.png",
"directory": "static/images",
"annotations": [
{
"badge": "#username",
"label": "1"
},
{
"callout": {
"elementTestId": "submit"
},
"label": "Sends a one-time code",
"position": "right"
},
{
"blur": {
"selector": ".account-id"
},
"all": true
}
]
}
}