1. Dispatch API
  2. Install Custom Chrome Extension

You can create a custom Chrome extension and install it on the virtual browser. Both zip and crx file formats are supported. A few gotchas:

  • The content-type is multipart/form-data rather than application/json
  • The body field must be set to the JSON request data
  • The field you passed into {“extension”: “foo”} must contain the path to the extension file and the file’s MIME type, separated by a semi-colon
    • For example, {“extension”: “a”} and —form ‘a=@/path/to/ext.crx;application/x-chrome-extension

Install custom Chrome extension

crx file


            
              
              
            
            
          curl -X POST \
  -H 'Authorization: Bearer <your-api-key>' \
  -H 'Content-Type: multipart/form-data' \
  https://engine.hyperbeam.com/v0/vm \
  --form 'body={"ublock":true,"extension":{"field":"ex"}}' \
  --form 'ex=@/tmp/ext.crx;type=application/x-chrome-extension'

zip file


            
              
              
            
            
          curl -X POST \
  -H 'Authorization: Bearer <your-api-key>' \
  -H 'Content-Type: multipart/form-data' \
  https://engine.hyperbeam.com/v0/vm \
  --form 'body={"ublock":true,"extension":{"field":"ex"}}' \
  --form 'ex=@/tmp/ext.zip;type=application/zip'