Use Github with AI Agents

A platform for version control and collaboration, allowing you to work together on projects from anywhere.
🔗 Connect and Use Github
1. 🔑 Connect your Github account
2. ✅ Select an action
3. 🚀 Go live with the agent
What do you want to do?
Actions
meta
security-advisories
apps
classroom
codes-of-conduct
emojis
dependabot
secret-scanning
activity
gists
gitignore
issues
licenses
markdown
orgs
actions
oidc
code-scanning
codespaces
copilot
packages
interactions
migrations
projects
repos
billing
teams
reactions
rate-limit
checks
dependency-graph
git
pulls
search
users
Main

API actions for Github for AI assitants/agents

Language
JS
PYTHON

Activity

Delete A Repository Subscription

This endpoint is for stopping repository watch. Use it to cease getting updates. For notification preferences, manually adjust the repository's subscription.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DELETE_A_REPOSITORY_SUBSCRIPTION])

Repos

List Repository Tags

This endpoint lists a GitHub repository's tags, requiring its owner and name. Offers optional pagination parameters `per_page` (max 100) and `page`. Detailed documentation is at GitHub's offic
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_REPOSITORY_TAGS])

List Tag Protection States For A Repository

This returns the tag protection states of a repository. This information is only available to repository administrators.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_TAG_PROTECTION_STATES_FOR_A_REPOSITORY])

Create A Tag Protection State For A Repository

This creates a tag protection state for a repository. This endpoint is only available to repository administrators.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CREATE_A_TAG_PROTECTION_STATE_FOR_A_REPOSITORY])

Delete A Tag Protection State For A Repository

This deletes a tag protection state for a repository. This endpoint is only available to repository administrators.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DELETE_A_TAG_PROTECTION_STATE_FOR_A_REPOSITORY])

Download A Repository Archive Tar

Generate a redirect URL to download a tar archive of a repository's default branch or a specified ref. Ensure HTTP framework follows redirects or use the `Location` header for a second request
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DOWNLOAD_A_REPOSITORY_ARCHIVE_TAR])

List Repository Teams

The text explains that listing of teams with repository access depends on the repository's visibility and the type of access token used, with specific scopes required for OAuth and personal to
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_REPOSITORY_TEAMS])

Get All Repository Topics

This endpoint fetches topics of a GitHub repository, using `owner` and `repo`. It supports pagination with `page` and `per_page`. API details at GitHub documentation.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_ALL_REPOSITORY_TOPICS])

Replace All Repository Topics

Replace or clear GitHub repo topics by passing an array of names or an empty array, respectively, including owner and repo name in the path. Full details: https://docs.github.com/rest/repos/re
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_REPLACE_ALL_REPOSITORY_TOPICS])

Get Repository Clones

Get the total number of clones and breakdown per day or week for the last 14 days. Timestamps are aligned to UTC midnight of the beginning of the day or week. Week begins on Monday.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_REPOSITORY_CLONES])

Get Top Referral Paths

Get the top 10 popular contents over the last 14 days.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_TOP_REFERRAL_PATHS])

Get Top Referral Sources

Get the top 10 referrers over the last 14 days.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_TOP_REFERRAL_SOURCES])

Get Page Views

Get the total number of views and breakdown per day or week for the last 14 days. Timestamps are aligned to UTC midnight of the beginning of the day or week. Week begins on Monday.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_PAGE_VIEWS])

Transfer A Repository

When transferring a personal repository to another user, the new owner must accept the request. The process is asynchronous, with details on the original owner included. For more on transferri
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_TRANSFER_A_REPOSITORY])

Check If Vulnerability Alerts Are Enabled For A Repository

This text explains that a user can check if dependency alerts are enabled or disabled for a repository, provided they have admin read access. It also links to a page for more information on se
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CHECK_IF_VULNERABILITY_ALERTS_ARE_ENABLED_FOR_A_REPOSITORY])

Enable Vulnerability Alerts

Enables dependency alerts/graph for a repository, requiring admin access. For details on security alerts for vulnerabilities, see the provided link.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_ENABLE_VULNERABILITY_ALERTS])

Disable Vulnerability Alerts

Disabling dependency alerts and the graph for a repository requires admin access. For details, see GitHub's guide on security alerts for vulnerable dependencies.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DISABLE_VULNERABILITY_ALERTS])

Download A Repository Archive Zip

Get a redirect URL for downloading a zip of a repo, defaulting to the main branch. Ensure redirects are followed. Link expires in 5 mins for private repos; empty ones give a 404 error.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DOWNLOAD_A_REPOSITORY_ARCHIVE_ZIP])

Create A Repository Using A Template

Create a repository from a template via `template_owner` and `template_repo`. Non-public templates need authentication. Verify with the `is_template` value. OAuth and personal tokens require s
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CREATE_A_REPOSITORY_USING_A_TEMPLATE])

List Public Repositories

This endpoint lists all public repositories by creation order. On GitHub Enterprise Server, it shows only universally accessible repositories. Pagination relies on the `since` parameter, with
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_PUBLIC_REPOSITORIES])

Search Code

This method supports searching content and paths, offering up to 100 results/page with text match data. Limited to default branch, files <384KB, and requires a search term. Authentication and
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_CODE])

Search Commits

Search commits on the default branch using criteria with up to 100 results per page. Include `text-match` media type for message metadata. Example search: `q=repo:octocat/Spoon-Knife+css`.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_COMMITS])

Search Issues And Pull Requests

This method finds issues by state and keyword, returning up to 100 results/page with titles and comments. It filters queries like 'open Python bugs on Windows'. GitHub Apps should avoid mixing
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_ISSUES_AND_PULL_REQUESTS])

Search Labels

Search repository labels by keywords in names or descriptions, with up to 100 results/page. Use `text-match` for highlights in names/descriptions. Example: `q=bug+defect+enhancement&repository
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_LABELS])

Search Repositories

Search for GitHub repositories by criteria, returning up to 100 results per page. Search includes text match metadata for names and descriptions. Example: find popular Tetris repositories in a
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_REPOSITORIES])

Search Repo S

Search for GitHub repositories by criteria, returning up to 100 results per page. Search includes text match metadata for names and descriptions. Example: find popular Tetris repositories in a
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_REPO_S])

Search Topics

Search for topics with criteria, getting up to 100 results per page, sorted by best match. Use `text-match` for metadata in search, e.g., `q=ruby+is:featured` for featured Ruby topics. See gui
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_TOPICS])

Search Users

This method searches for users by criteria, returning a max of 100 results/page with metadata for login, email, and name. It supports public user searches based on name, repo count, and follow
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_SEARCH_USERS])

Teams

Get A Team Legacy

**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the [Get a team by name](https://docs.github.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_A_TEAM_LEGACY])

Update A Team Legacy

The Teams API endpoint is deprecated; switch to the "Update a team" endpoint. Only organization owners or team maintainers can edit teams. Parent teams in nested setups can't be set to "secret
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_UPDATE_A_TEAM_LEGACY])

Delete A Team Legacy

The endpoint route is deprecated; use the [Delete a team](https://docs.github.com/rest/teams/teams#delete-a-team) endpoint instead. Organizational owners or team maintainers can delete teams,
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DELETE_A_TEAM_LEGACY])

List Discussions Legacy

This Teams API endpoint is being deprecated. Users should migrate to the `List discussions` endpoint for team page discussions. `read:discussion` scope is required for OAuth and classic tokens
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_DISCUSSIONS_LEGACY])

Create A Discussion Legacy

Deprecated Teams API endpoint for creating discussion posts will be removed. Use the new `Create a discussion` endpoint. Triggering notifications, subject to rate limits. Requires `write:discu
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CREATE_A_DISCUSSION_LEGACY])

Get A Discussion Legacy

The Teams API will remove the deprecated endpoint route. Users are advised to switch to the [Get a discussion](https://docs.github.com/rest/teams/discussions#get-a-discussion) endpoint. Access
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_A_DISCUSSION_LEGACY])

Update A Discussion Legacy

This Teams API endpoint is deprecated and will be removed. Users should switch to the new Update a discussion endpoint. It allows editing the title and body of a discussion, requiring `write:d
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_UPDATE_A_DISCUSSION_LEGACY])

Delete A Discussion Legacy

The Teams API's endpoint for deleting discussions is deprecated. It advises users to switch to the new "Delete a discussion" endpoint. Required OAuth or classic tokens need the `write:discussi
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DELETE_A_DISCUSSION_LEGACY])

List Discussion Comments Legacy

The Teams API's endpoint for listing team discussion comments is deprecated. Switch to the new endpoint for this purpose. OAuth and classic tokens require the `read:discussion` scope.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_DISCUSSION_COMMENTS_LEGACY])

Create A Discussion Comment Legacy

Deprecated Teams API endpoint for creating team discussion comments will be removed. Migrate to the new endpoint. Trigger notifications; avoid rapid content creation to prevent rate limiting.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CREATE_A_DISCUSSION_COMMENT_LEGACY])

Get A Discussion Comment Legacy

This Teams API endpoint for getting team discussion comments is deprecated and will be removed. Switch to the new endpoint. OAuth and personal tokens need `read:discussion` scope.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_A_DISCUSSION_COMMENT_LEGACY])

Update A Discussion Comment Legacy

Deprecated Teams API endpoint for editing discussion comments will be removed. Users should switch to the new "Update a discussion comment" endpoint. OAuth and classic tokens require `write:di
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_UPDATE_A_DISCUSSION_COMMENT_LEGACY])

Delete A Discussion Comment Legacy

The Teams API endpoint for deleting a team discussion comment is deprecated. Users are advised to switch to the new endpoint as outlined in the provided URL. OAuth and personal access tokens r
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_DELETE_A_DISCUSSION_COMMENT_LEGACY])

List Pending Team Invitations Legacy

Endpoint route in Teams API deprecated; advised to use new endpoint for pending team invitations. Includes `role` field with specific values; `login` field `null` if invitee not a GitHub membe
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_PENDING_TEAM_INVITATIONS_LEGACY])

List Team Members Legacy

The endpoint in the Teams API is deprecated and will be removed. Users should migrate to the new `List team members` endpoint, which now includes child team members.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_TEAM_MEMBERS_LEGACY])

Get Team Member Legacy

The "Get team member" endpoint is deprecated. Instead, use the "Get team membership for a user" endpoint for retrieving active and pending memberships, ensuring the team is visible to the auth
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_GET_TEAM_MEMBER_LEGACY])

Add Team Member Legacy

GitHub Enterprise Cloud's "Add team member" endpoint is deprecated, replaced by "Add or update team membership for a user". Org owners/maintainers can sync teams; API errors might occur. Use I
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_ADD_TEAM_MEMBER_LEGACY])

Remove Team Member Legacy

The "Remove team member" endpoint is deprecated; use "Remove team membership for a user" instead, requiring admin rights. It's available for GitHub Enterprise Cloud with some limits on IdP-syn
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_REMOVE_TEAM_MEMBER_LEGACY])

Reactions

List Reactions For A Team Discussion Comment Legacy

The Teams API endpoint for listing team discussion comment reactions is deprecated. Use the new endpoint instead. OAuth tokens require `read:discussion` scope.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_REACTIONS_FOR_A_TEAM_DISCUSSION_COMMENT_LEGACY])

Create Reaction For A Team Discussion Comment Legacy

The API endpoint to react to team discussion comments is outdated and recommends using a newer endpoint. Reactions that work will give an HTTP 200 response, needing `write:discussion` access.
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CREATE_REACTION_FOR_A_TEAM_DISCUSSION_COMMENT_LEGACY])

List Reactions For A Team Discussion Legacy

The Teams API endpoint for listing team discussion reactions is deprecated. Users are advised to migrate to the new "List reactions for a team discussion" endpoint. OAuth tokens require the `r
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_LIST_REACTIONS_FOR_A_TEAM_DISCUSSION_LEGACY])

Create Reaction For A Team Discussion Legacy

The Teams API endpoint for creating team discussion reactions is deprecated. Use the "Create reaction for a team discussion" endpoint instead. HTTP `200` means the reaction was added. Requires
from composio_langchain import ComposioToolSet, Action tool_set = ComposioToolSet() tools = tool_set.get_tools(actions=[Action.GITHUB_CREATE_REACTION_FOR_A_TEAM_DISCUSSION_LEGACY])

Frequently asked questions

What is Composio.dev?

Composio.dev is a platform for building AI applications, designed to make the process of developing AI solutions super easy and fun! It provides a comprehensive set of tools and libraries that simplify the process of developing AI solutions, allowing you to focus on the creative aspects of your project without getting bogged down by the technical details.

How does Composio.dev support Github?

Composio.dev seamlessly integrates with Github, allowing you to leverage its capabilities within the Composio.dev platform. You can utilize Github to call functions across various platforms, including Google, GitHub, and others, making it a breeze to incorporate different services into your AI applications. Additionally, it supports user authentication via OAuth2 and can work in conjunction with other popular frameworks like LangChain and CrewAI, giving you the flexibility to build truly innovative AI solutions.

What models can I use with Github?

With Github, you have access to a wide range of state-of-the-art language models, including GPT-4o (OpenAI), GPT-3.5 (OpenAI), GPT-4 (OpenAI), Claude (Anthropic), PaLM (Google), LLaMA and LLaMA 2 (Meta), Gemini, and many others. This flexibility allows you to choose the model that best suits your specific use case, whether you're building a chatbot, a content creation tool, or any other AI-powered application. You can experiment with different models and find the one that delivers the best performance for your project.

How can I integrate Github into my project?

Composio.dev provides a seamless integration for Github, making it super easy to incorporate this powerful framework into your projects. You can leverage the Composio.dev API to call functions from Github, allowing you to tap into its capabilities with just a few lines of code. The SDK is available in Python, JavaScript, and TypeScript, so you can work with your preferred programming language and integrate Github into your projects seamlessly.

What is the pricing for Github?

Github is completely free to use, with a generous free tier that allows up to 1000 requests per month. This makes it accessible for developers and organizations of all sizes to explore and experiment with this powerful tool without any upfront costs. Whether you're a student working on a personal project or a startup building the next big thing, you can get started with Github without worrying about breaking the bank.

What kind of authentication is supported for Github?

Github supports OAuth2 authentication, ensuring secure and authorized access to its functionalities. You can leverage the Composio.dev API to handle authentication and call functions from Github seamlessly. The SDK is available in Python, JavaScript, and TypeScript for your convenience, making it easy to integrate authentication into your projects and keep your users' data safe and secure.

Can I add Github to my project?

Absolutely! You can easily incorporate Github into your project by utilizing the Composio.dev API. This API allows you to call functions from Github, enabling you to leverage its capabilities within your application. The SDK is available in Python, JavaScript, and TypeScript to facilitate integration, so you can work with the language you're most comfortable with and add Github to your project with ease.

What is the accuracy of Github?

Github is designed to provide highly accurate and reliable results, ensuring that your AI applications perform at their best. The integration with Composio.dev ensures precise function calls, enabling you to build robust and powerful AI applications with confidence. Github's comprehensive framework and the ability to leverage state-of-the-art models ensure reliable and accurate outcomes for your AI development needs, whether you're working on a chatbot, a content creation tool, or any other AI-powered project.

What are some common use cases for Github?

Github can be used for a wide range of AI applications, making it a versatile tool for developers and creators alike. Some common use cases include natural language processing, text generation, question answering, sentiment analysis, and more. It's particularly useful for building chatbots, virtual assistants, content creation tools, and other AI-powered applications that can help you automate tasks, engage with users, and create compelling content. Whether you're working on a personal project or building a product for your startup, Github can help you bring your ideas to life.

How does Github handle data privacy and security?

Data privacy and security are crucial considerations when working with AI systems, and Github takes these issues seriously. It follows industry best practices and adheres to strict data protection regulations, ensuring that your data is kept safe and secure. Github provides robust security measures, such as encryption and access controls, to ensure the confidentiality and integrity of your data. You can rest assured that your sensitive information is protected when using Github for your AI development needs.
+ Integrate seamlessly with your agentic frameworks
Composio Works with All Shapes and SizesComposio Works with All Shapes and SizesComposio Works with All Shapes and SizesComposio Works with All Shapes and SizesComposio Works with All Shapes and Sizes
Building for AI across continents🧪