Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/AsyncFuncAI/deepwiki-open/llms.txt

Use this file to discover all available pages before exploring further.

DeepWiki can clone and index private repositories on GitHub, GitLab, and Bitbucket. Authentication is handled by providing a personal access token (or Bitbucket app password) through the UI before generating a wiki. The token is sent with the request and used only for that operation — it is not stored permanently on the server.
Never share your personal access token in a public environment or with untrusted DeepWiki deployments. Treat your token with the same care as a password. If you suspect a token has been exposed, revoke it immediately in your platform’s security settings and generate a new one.

How tokens work in DeepWiki

When you enter a token, the frontend passes it in the token field of the ChatCompletionRequest payload sent to the API. The backend uses this token to authenticate the git clone operation for that specific request. The TokenInput component notes explicitly: “Your token is stored locally and never sent to our servers” — it exists only in your browser session and travels to your own self-hosted DeepWiki instance via your own network. The ChatCompletionRequest model exposes the token as an optional field:
token: Optional[str] = Field(
    None,
    description="Personal access token for private repositories"
)

Adding a token in the UI

1

Open the token section

On the DeepWiki home page, click + Add Access Tokens for Private Repositories below the repository URL field. The token panel expands to show platform tabs and a token input field.
2

Select your platform

Click the GitHub, GitLab, or Bitbucket tab to select the platform that hosts your private repository.
3

Paste your token

Enter your personal access token (or Bitbucket app password) in the input field. The value is masked for security.
4

Generate the wiki

Click Generate Wiki as normal. DeepWiki will use your token to authenticate the clone operation.

Creating a token on each platform

GitHub offers two types of personal access tokens: classic and fine-grained.Classic token (simpler)
1

Open token settings

Go to GitHub → Settings → Developer settings → Personal access tokens → Tokens (classic).
2

Generate a new token

Click Generate new token (classic). Enter a note, choose an expiration, and select the repo scope to grant read access to private repositories.
3

Copy the token

Copy the token immediately — GitHub will not show it again.
Fine-grained token (recommended)
1

Open token settings

Go to GitHub → Settings → Developer settings → Personal access tokens → Fine-grained tokens.
2

Generate a new token

Click Generate new token. Set an expiration, select Only select repositories, choose the target repository, and grant Contents: Read-only under Repository permissions.
3

Copy the token

Copy the token immediately.

Minimum required permissions

PlatformToken typeRequired scope / permission
GitHubClassicrepo
GitHubFine-grainedContents: Read-only
GitLabPersonal access tokenread_repository
BitbucketApp passwordRepositories: Read
Broader scopes will also work, but granting the minimum required permissions limits risk if a token is ever accidentally exposed.

Build docs developers (and LLMs) love