GitHub setup
Connecting SXL Studio to GitHub: which token to create and with which permissions, how to fill in the connection form, test it and run the first synchronization.
The plugin talks to GitHub through the REST API with a Personal Access Token: you do not need git on your computer. Setup takes five minutes: create a token, fill in the connection form, test it, press Pull.
Step 1. Create a Personal Access Token
Open GitHub → Settings → Developer settings → Personal access tokens. Either token type works.
Fine-grained token (recommended by GitHub)
- Press Generate new token.
- Give it a name, for example
SXL Studio, and an expiration. - In Resource owner choose yourself or the organization that owns the repository.
- In Repository access choose Only select repositories and tick the token repository.
- In Repository permissions set Contents: Read and write. GitHub adds Metadata: Read-only automatically.
- Press Generate token and copy it: it is shown only once.
If the organization requires token approval, wait until an administrator approves it. Until then the connection gets a 404 error.
Classic token
- Press Generate new token (classic).
- Give it a name and tick the repo scope.
- Press Generate token and copy it.
The plugin recognizes the github_pat_… (fine-grained) and ghp_… (classic) formats. If you paste another kind of token or a truncated one, the connection check warns you.
A token is needed even for a public repository: without it the plugin can only read, and Push is unavailable.
Step 2. Prepare the repository
The repository must have at least one commit: an empty GitHub repository returns error 409, so create a README in it.
The folder structure the plugin expects:
your-repo/
├── tokens/ ← Tokens Path: token JSON and config.json
└── data/ ← Data Path: Database files (optional)
If the token folder does not exist yet, the plugin creates it on the first Push.
Step 3. Create the connection in the plugin
- Press the Sync settings gear in the plugin footer, then New Sync.
- Fill in the form:
| Field | Value |
|---|---|
| Provider | GitHub |
| Name | Any name, for example Design tokens |
| Repository (owner/repo) | your-org/your-repo |
| Branch | The branch you work on, for example main |
| Access Token | The token from step 1 |
| Data Path | data, or empty if there is no such folder |
| Tokens Path | tokens |
- Press Test connection. The report should say Connection OK. If the plugin found that the branch or folders are named differently, press Fix to put the right values in.
- Press Save, then Use Git to make the connection active.
All form fields and checks are described on the Connecting a repository page.
Step 4. First synchronization
- Press Pull in the footer. The plugin loads tokens and data from the repository, and the folders appear in the file tree.
- Change any token and press Push: a window with the changed files and a commit message field opens. After Push the commit appears in the repository.
Next: Pull, Push and branches.
GitHub Enterprise Server
- Put the server address into Enterprise URL, for example
https://github.company.com. The plugin adds the API path itself. - Create the token on your server the same way as on github.com.
- If the organization uses SAML SSO, authorize the token for the organization: otherwise GitHub answers 403 and the plugin shows GitHub SSO authorization required.
If something does not work
| Message | What to do |
|---|---|
| GitHub returned 404 for branch … | Check the spelling of owner/repo and the branch. For a private repository the token must have access to that repository: a fine-grained token has it ticked in Repository access, a classic token has the repo scope. In an SSO organization authorize the token |
| GitHub repository … is empty (HTTP 409) | Make the first commit in the repository |
| GitHub authentication failed (401) | The token expired, was revoked or was not copied completely. Create a new one and paste it into the form |
| Token has read-only access to this repository: Push will fail | The token cannot write. It needs Contents: Read and write |
| GitHub rate limit exceeded | The API request limit. Wait a minute; the token does not need to change |
| Protected Branch on Push | The branch is protected by repository rules. Create another branch from the footer menu and work there |
The full list of checks and errors: Connecting a repository. If the cause is unclear, open the Diagnostics tab and run test.