Software · Help
Connect your GitHub or Google Drive library
Files you upload to CAD Studio and Robot Studio are kept in our storage, which is 20 MB per organisation. A library in your own GitHub repository or Google Drive folder is stored in your account, so it does not count against those 20 MB.
What counts against the 20 MB
Uploads libraries, Robot Studio worlds and build results saved into an Uploads library. A GitHub or Google Drive library is not counted. The Libraries window shows how much you use (“x MB of 20 MB”) beside the organisation picker, and links here when you reach 90%. When the space is full, uploading stops with the message “20 MB used of 20 MB. Connect your GitHub or Google Drive to store more.”
GitHub: make a token for one repository
Use a fine-grained personal access token, limited to the one repository the library reads:
- On GitHub: Settings → Developer settings → Personal access tokens → Fine-grained tokens → Generate new token.
- Repository access: only the repository of this library.
- Permissions: Contents, read and write; Metadata, read. Nothing else. Write access is what lets CAD Studio save build results, renders and motion scripts back to the repository.
- Expiration: set one (we use 90 days for our own repositories). Coming soon: CAD Studio will read the expiry date from GitHub and warn the people who manage the token 14, 7 and 1 days before it runs out, and on the day. Until then, note the date yourself.
Give each repository its own token. The token does not need pull-request permission: when a build changes a file you keep in the repository, CAD Studio puts the change on a branch for review, and a person opens and merges the pull request.
GitHub: add the library in CAD Studio
- Open CAD Studio’s Libraries window and choose Add library, then GitHub.
- Give the library a name. Under Connection choose New connection…, name it, and paste the token into Personal access token.
- Enter the repository as owner/repo, the Branch, and optionally a Folder in the repo.
- Choose Add. The token is saved in your organisation’s credentials; later libraries can reuse the connection.
Build results are written to a branch of their own, cad-studio/outputs, one commit per job; your own branch is never written by a build.
Google Drive
A Drive library reads one folder through a Google service account:
- In a Google Cloud project, enable the Google Drive API.
- Under IAM & Admin → Service accounts, create a service account (it needs no roles), then Keys → Add key → JSON. Keep the downloaded file.
- Share the Drive folder with the service account’s email address (the
client_emailin the JSON file) as Editor. Builds, saves and uploads write into the folder; Viewer only allows reading. - In the Libraries window choose Add library, then Google Drive, and a New connection…: paste the whole JSON file as the Service account JSON key, and the Drive folder ID (the last part of the folder’s address in Drive). CAD Studio checks that it is a real service-account key before saving it.
A service account has no Drive storage of its own, so the safest place for the folder is a Shared Drive (Google Workspace). In a personal “My Drive” folder, files the account creates can fail on quota.
Build results are uploaded into the folder and replace the earlier ones. A service-account key has no expiry date, so there is no warning before it stops working.
When a token expires or is refused
The library stops syncing. In the launcher, open the Security folder, then Credentials; on the connection’s row open the menu (⋯) and choose Rotate to paste a new token or JSON key. Every library that uses the connection picks it up; the libraries need no change. Coming soon: the library will say why, for example “The GitHub token <name> expired on <date>” or “was refused by GitHub”, instead of a general error.