Skip to Content

List Repositories

Retrieves a list of all accessible GitHub repositories for the authenticated user. This helps you discover which repositories you can use with background agents.

Overview

  • Purpose: Get a list of all GitHub repositories accessible through your Cursor integration.
  • Use Cases: Discovering available repositories, validating repository access, building repository selectors in UI, verifying permissions.
  • API Method: GET /v0/repositories

Input Fields

No Input Required: This action does not require any input parameters. It returns all repositories you have access to.

Output

Returns an array of repository objects, each containing:

  • Owner: The GitHub username or organization that owns the repository.
  • Name: The repository name (without the owner prefix).
  • Repository: The full repository URL that can be used in the ‘Launch Agent’ action.

Access Permissions

  • Personal Repositories: All repositories owned by your GitHub account.
  • Organization Repositories: Repositories from organizations where you have appropriate access.
  • Collaborator Access: Repositories where you’ve been added as a collaborator.
  • Permission Levels: The list reflects your current GitHub permissions through the Cursor integration.

Rate Limiting

[!WARNING] 429 Status: If you receive a rate limit error, wait before retrying.

  • Error Handling: The action includes graceful handling of rate limits with descriptive error messages.
  • Best Practice: Cache repository lists when possible to avoid hitting rate limits.

Tips

[!TIP] Use the full ‘repository’ URL value when launching agents, not just owner/name

[!TIP] Cache the repository list in your application to reduce API calls

[!TIP] Refresh the list periodically to capture newly added repositories or permission changes

[!TIP] Handle rate limit errors gracefully by implementing retry logic with exponential backoff

[!TIP] Filter repositories in your UI based on owner or name for better user experience

[!TIP] Verify repository access before attempting to launch agents on them

Need help? Have feedback?