> ## Documentation Index
> Fetch the complete documentation index at: https://collabase.ch/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Collabase documentation. Interface labels are quoted in English, as they appear in the product.
> Features marked Enterprise need the Collabase Enterprise Edition licence.

# Upload a plug

> Upload the package of your own plug, built with the plug command line tool; only system administrators may, and every upload is audited.

Uploads a plug package as the multipart part `file`. This is the call that `collabase-plug publish` makes. The instance checks the package in the sandbox and installs it as the active version of its name. See [Publish and versions](https://collabase.ch/docs/developer/plugs/publish.md).

> [!NOTE]
>
> Scope `automation:write`. The token owner must be a system administrator.

```bash theme={"dark"}
curl -X POST "https://your-instance/api/v1/automation/plugs" \
  -H "Authorization: Bearer cb_..." \
  -F "file=@dist/supplier-portal-0.2.0.tgz"
```

```json theme={"dark"}
{ "data": { "name": "supplier-portal", "version": "0.2.0", "sha256": "..." } }
```

The answer is `202`. A package over 20 MB answers `413`, a file that is not a package or whose licences are not allowed `422`, and a token of someone who is not a system administrator `403`.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.