For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
DiscordDashboard
DocumentationAPI ReferenceCookbook
DocumentationAPI ReferenceCookbook
  • API Reference
    • POSTStart instance
    • GETGet instance by ID
    • GETList all instances
    • GETList all browser authentication states
      • POSTTake screenshot
      • GETGet stream URL
      • POSTRun computer actions
      • POSTRun bash actions
      • POSTRun edit actions
      • POSTRun file actions
      • POSTUpload a file to the instance
      • POSTStop instance
      • POSTPause instance
      • POSTResume instance
  • SDK Reference
    • Python SDK
    • TypeScript SDK
Logo
DiscordDashboard
API ReferenceInstance

Upload a file to the instance

POST
https://api.scrapybara.com/v1/instance/:instance_id/upload
POST
/v1/instance/:instance_id/upload
1import requests
2
3url = "https://api.scrapybara.com/v1/instance/instance_id/upload"
4
5files = { "file": "open('<file1>', 'rb')" }
6payload = { "path": "path" }
7headers = {"x-api-key": "<apiKey>"}
8
9response = requests.post(url, data=payload, files=files, headers=headers)
10
11print(response.json())
1{
2 "filename": "filename",
3 "path": "path",
4 "media_type": "media_type"
5}
Upload a file to the instance.
Was this page helpful?
Previous

Stop instance

Next
Built with

Authentication

x-api-keystring
API Key authentication via header

Path parameters

instance_idstringRequired

Request

This endpoint expects a multipart form containing a file.
filefileRequired
pathstringRequired

Response

Successful Response
filenamestring
pathstring
media_typestring

Errors

422
Instance Upload Request Unprocessable Entity Error