- Getting Started
- Code Review
- Platforms
- CI integrations
- Web Projects
- Developer Tools
- Get Notified
- API
Screenshotbot has a relatively simple REST API. In most cases, you shouldn’t need to use this API directly, and we suggest you instead use the command line interface instead
Uploading a test run to screenshotbot, is a two/three step process. First you find-or-create each image using the md5sum of the image. For each image, if its the first time screenshotbot is seeing the image, we might ask you to upload the actual png (If you’ve uploaded it previously, it will tell you not to do that). Once you have all your images uploaded, you create a run. Screenshotbot will process your run and decide if it needs to do anything with it such as sending out GitHub issues.
All our APIs are accessed from https://api.screenshotbot.io/api/. All requests will accept two arguments to indicate your API user: api-key, and api-secret-key. (You can get these values from you dashboard).
All resource objects will have "type" attribute that tells you what type it is. It will always be one of the documented types.
API responses will be returned in a JSON object that looks like this
{ "success": <true|false> "response": <actual-response> "error": <error message if success is false> }
Send a POST request to /api/image.
{ "id": <unique-id>, "uploadUrl": <a url to upload to> }
If the uploadUrl is present, it means you have to upload the image via a PUT request to the given URL. This will usually only be present the first time you upload this specific image (determined by the md5sum). However we might ask you to reupload images occasionally, so you should not rely on this assumption.
Send a POST request to /api/run.
Each screenshot object has the following structure:
{ "name": <name of the screenshot>, "imageId": <id of the image object associated with this screenshot> }
{ "id": <id of the run> }
Sign up or contact us.