GitHub
Connect your GitHub account to Memex for repository access and API operations.
What is GitHub?
GitHub is the world's largest code hosting platform, used for version control and collaboration. When you connect GitHub to Memex, you can access repositories, analyze code, and perform API operations through natural conversation.
What You'll Need
To connect GitHub to Memex, you'll need a Personal Access Token:
Personal Access Token
Authentication token for GitHub API
ghp_xxxxxxxxxxxxxxxxxxxx
Creating a Personal Access Token
Step 1: Open GitHub Settings
Sign in to github.com
Click your profile photo in the top-right corner
Select Settings
Step 2: Navigate to Developer Settings
Scroll down the left sidebar
Click Developer settings (near the bottom)
Click Personal access tokens
Click Fine-grained tokens
Step 3: Generate a New Token
Click Generate new token
Enter a Token name (e.g., "Memex Access")
Set an Expiration date
Under Resource owner, select your personal account or an organization you have access to
Under Repository access, select which repositories the token can access
Under Permissions, grant the permissions you need:
Contents: Read (to view repository files)
Metadata: Read (required for all tokens)
Add other permissions based on your needs
Click Generate token
Organization Considerations
Step 4: Copy Your Token
Copy your token immediately! GitHub only shows the token once. If you lose it, you'll need to generate a new one.

Connecting to Memex
Open the Memex Hub from the sidebar
Click on the Connectors tab
Click on the GitHub card
Enter a Connection Name (e.g., "My GitHub Account")
Paste your Personal Access Token
Click Add Connection
Your GitHub account is now connected! Memex can access it across all your conversations.
Using Your Connection
Once connected, you can ask Memex to work with your GitHub data:
Choosing Token Permissions
For reading repositories and code, these permissions are sufficient:
Contents: Read
Metadata: Read (required)
If you want Memex to create issues or pull requests, add these permissions:
Issues: Read and write
Pull requests: Read and write
For detailed permission information, see GitHub's token documentation.
Security Considerations
Token Security
Your token is stored securely in Memex's encrypted storage
Never share your token publicly or commit it to a repository
GitHub automatically scans for leaked tokens and can revoke them
Token Expiration
Set an expiration date for better security
GitHub recommends rotating tokens periodically
You'll need to update your Memex connection when tokens expire
Revoking Access
If you need to revoke Memex's access:
Delete the connection in Memex Hub
Go to GitHub Settings → Developer settings → Personal access tokens
Delete or revoke the token you created for Memex
If you suspect your token has been compromised, revoke it immediately in your GitHub settings and create a new one.
Troubleshooting
You can ask the Memex agent to help troubleshoot, but here are a few common problems:
"Bad credentials" Error
Verify you copied the entire token without extra spaces
Check that the token hasn't expired
Ensure the token hasn't been revoked in GitHub settings
"Not Found" Error for Repositories
Verify the token has access to the repository
Ensure the repository exists and you have access to it
Rate Limiting
GitHub limits API requests to 5,000 per hour for authenticated users
If you hit rate limits, wait for the limit to reset
Consider which operations you're performing frequently
Learn More
Last updated
Was this helpful?