KosmoKrator

productivity

GitHub CLI for AI Agents

Use the GitHub CLI from KosmoKrator to call GitHub tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

30 functions 16 read 14 write API key auth

GitHub CLI Setup

GitHub can be configured headlessly with `kosmokrator integrations:configure github`.

# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure github --set api_key="$GITHUB_API_KEY" --enable --read allow --write ask --json
kosmokrator integrations:doctor github --json
kosmokrator integrations:status --json

Credentials

Authentication type: API key api_key. Configure credentials once, then use the same stored profile from scripts, coding CLIs, Lua code mode, and the MCP gateway.

KeyEnv varTypeRequiredLabel
api_key GITHUB_API_KEY Secret secret yes Personal Access Token

Call GitHub Headlessly

Use the generic call form when another coding CLI or script needs a stable universal interface.

kosmo integrations:call github.github_list_repos '{
  "type": "example_type",
  "sort": "example_sort",
  "direction": "example_direction",
  "per_page": 1,
  "page": 1
}' --json

Use the provider shortcut form for shorter human-facing commands.

kosmo integrations:github github_list_repos '{
  "type": "example_type",
  "sort": "example_sort",
  "direction": "example_direction",
  "per_page": 1,
  "page": 1
}' --json

Agent Discovery Commands

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

kosmo integrations:docs github --json
kosmo integrations:docs github.github_list_repos --json
kosmo integrations:schema github.github_list_repos --json
kosmo integrations:search "GitHub" --json
kosmo integrations:list --json

All CLI Functions

Every function below can be called headlessly. The generic form is stable across all integrations; the provider shortcut is shorter but specific to GitHub.

github.github_list_repos

Read read

List repositories for the authenticated GitHub user. Supports filtering by type (all, owner, public, private, member), sorting (created, updated, pushed, full_name), and direction.

Parameters
type, sort, direction, per_page, page

Generic CLI call

kosmo integrations:call github.github_list_repos '{"type":"example_type","sort":"example_sort","direction":"example_direction","per_page":1,"page":1}' --json

Provider shortcut

kosmo integrations:github github_list_repos '{"type":"example_type","sort":"example_sort","direction":"example_direction","per_page":1,"page":1}' --json

github.github_get_repo

Read read

Get detailed information about a specific GitHub repository, including description, stats, default branch, and more.

Parameters
owner, repo

Generic CLI call

kosmo integrations:call github.github_get_repo '{"owner":"example_owner","repo":"example_repo"}' --json

Provider shortcut

kosmo integrations:github github_get_repo '{"owner":"example_owner","repo":"example_repo"}' --json

github.github_create_repo

Write write

Create a new repository for the authenticated GitHub user. Optionally set description, visibility, and auto-initialize with a README.

Parameters
name, description, private, auto_init

Generic CLI call

kosmo integrations:call github.github_create_repo '{"name":"example_name","description":"example_description","private":true,"auto_init":true}' --json

Provider shortcut

kosmo integrations:github github_create_repo '{"name":"example_name","description":"example_description","private":true,"auto_init":true}' --json

github.github_search_repos

Read read

Search for repositories on GitHub using keywords, language filters, stars, and more. Returns matching repositories with metadata.

Parameters
query, sort, order, per_page

Generic CLI call

kosmo integrations:call github.github_search_repos '{"query":"example_query","sort":"example_sort","order":"example_order","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_search_repos '{"query":"example_query","sort":"example_sort","order":"example_order","per_page":1}' --json

github.github_list_issues

Read read

List issues in a GitHub repository. Supports filtering by state (open, closed, all), labels, and sorting.

Parameters
owner, repo, state, labels, sort, direction, per_page

Generic CLI call

kosmo integrations:call github.github_list_issues '{"owner":"example_owner","repo":"example_repo","state":"example_state","labels":"example_labels","sort":"example_sort","direction":"example_direction","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_list_issues '{"owner":"example_owner","repo":"example_repo","state":"example_state","labels":"example_labels","sort":"example_sort","direction":"example_direction","per_page":1}' --json

github.github_get_issue

Read read

Get detailed information about a specific GitHub issue, including title, body, labels, assignees, milestone, and comments count.

Parameters
owner, repo, issue_number

Generic CLI call

kosmo integrations:call github.github_get_issue '{"owner":"example_owner","repo":"example_repo","issue_number":1}' --json

Provider shortcut

kosmo integrations:github github_get_issue '{"owner":"example_owner","repo":"example_repo","issue_number":1}' --json

github.github_create_issue

Write write

Create a new issue in a GitHub repository. Requires a title. Optionally set body, assignees, labels, and milestone.

Parameters
owner, repo, title, body, assignees, labels, milestone

Generic CLI call

kosmo integrations:call github.github_create_issue '{"owner":"example_owner","repo":"example_repo","title":"example_title","body":"example_body","assignees":"example_assignees","labels":"example_labels","milestone":1}' --json

Provider shortcut

kosmo integrations:github github_create_issue '{"owner":"example_owner","repo":"example_repo","title":"example_title","body":"example_body","assignees":"example_assignees","labels":"example_labels","milestone":1}' --json

github.github_update_issue

Write write

Update an existing issue in a GitHub repository. Can change title, body, state (open/closed), assignees, labels, and milestone.

Parameters
owner, repo, issue_number, title, body, state, assignees, labels, milestone

Generic CLI call

kosmo integrations:call github.github_update_issue '{"owner":"example_owner","repo":"example_repo","issue_number":1,"title":"example_title","body":"example_body","state":"example_state","assignees":"example_assignees","labels":"example_labels"}' --json

Provider shortcut

kosmo integrations:github github_update_issue '{"owner":"example_owner","repo":"example_repo","issue_number":1,"title":"example_title","body":"example_body","state":"example_state","assignees":"example_assignees","labels":"example_labels"}' --json

github.github_add_labels

Write write

Add one or more labels to a GitHub issue. Labels are specified by name. If a label does not exist in the repository, it will be created.

Parameters
owner, repo, issue_number, labels

Generic CLI call

kosmo integrations:call github.github_add_labels '{"owner":"example_owner","repo":"example_repo","issue_number":1,"labels":"example_labels"}' --json

Provider shortcut

kosmo integrations:github github_add_labels '{"owner":"example_owner","repo":"example_repo","issue_number":1,"labels":"example_labels"}' --json

github.github_create_issue_comment

Write write

Add a comment to a GitHub issue or pull request. The comment body supports GitHub Markdown.

Parameters
owner, repo, issue_number, body

Generic CLI call

kosmo integrations:call github.github_create_issue_comment '{"owner":"example_owner","repo":"example_repo","issue_number":1,"body":"example_body"}' --json

Provider shortcut

kosmo integrations:github github_create_issue_comment '{"owner":"example_owner","repo":"example_repo","issue_number":1,"body":"example_body"}' --json

github.github_list_pull_requests

Read read

List pull requests in a GitHub repository. Supports filtering by state (open, closed, all) and sorting.

Parameters
owner, repo, state, sort, direction, per_page

Generic CLI call

kosmo integrations:call github.github_list_pull_requests '{"owner":"example_owner","repo":"example_repo","state":"example_state","sort":"example_sort","direction":"example_direction","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_list_pull_requests '{"owner":"example_owner","repo":"example_repo","state":"example_state","sort":"example_sort","direction":"example_direction","per_page":1}' --json

github.github_get_pull_request

Read read

Get detailed information about a specific GitHub pull request, including title, body, branch info, merge status, and review status.

Parameters
owner, repo, pull_number

Generic CLI call

kosmo integrations:call github.github_get_pull_request '{"owner":"example_owner","repo":"example_repo","pull_number":1}' --json

Provider shortcut

kosmo integrations:github github_get_pull_request '{"owner":"example_owner","repo":"example_repo","pull_number":1}' --json

github.github_create_pull_request

Write write

Create a new pull request in a GitHub repository. Requires a title, head branch (source), and base branch (target).

Parameters
owner, repo, title, body, head, base, draft

Generic CLI call

kosmo integrations:call github.github_create_pull_request '{"owner":"example_owner","repo":"example_repo","title":"example_title","body":"example_body","head":"example_head","base":"example_base","draft":true}' --json

Provider shortcut

kosmo integrations:github github_create_pull_request '{"owner":"example_owner","repo":"example_repo","title":"example_title","body":"example_body","head":"example_head","base":"example_base","draft":true}' --json

github.github_update_pull_request

Write write

Update an existing pull request in a GitHub repository. Can change title, body, state (open/closed), and base branch.

Parameters
owner, repo, pull_number, title, body, state, base

Generic CLI call

kosmo integrations:call github.github_update_pull_request '{"owner":"example_owner","repo":"example_repo","pull_number":1,"title":"example_title","body":"example_body","state":"example_state","base":"example_base"}' --json

Provider shortcut

kosmo integrations:github github_update_pull_request '{"owner":"example_owner","repo":"example_repo","pull_number":1,"title":"example_title","body":"example_body","state":"example_state","base":"example_base"}' --json

github.github_merge_pull_request

Write write

Merge a GitHub pull request. Supports merge commit, squash, or rebase merge methods.

Parameters
owner, repo, pull_number, commit_title, commit_message, merge_method

Generic CLI call

kosmo integrations:call github.github_merge_pull_request '{"owner":"example_owner","repo":"example_repo","pull_number":1,"commit_title":"example_commit_title","commit_message":"example_commit_message","merge_method":"example_merge_method"}' --json

Provider shortcut

kosmo integrations:github github_merge_pull_request '{"owner":"example_owner","repo":"example_repo","pull_number":1,"commit_title":"example_commit_title","commit_message":"example_commit_message","merge_method":"example_merge_method"}' --json

github.github_list_pull_request_reviews

Read read

List all reviews on a GitHub pull request, including review state (approved, changes_requested, commented, dismissed).

Parameters
owner, repo, pull_number

Generic CLI call

kosmo integrations:call github.github_list_pull_request_reviews '{"owner":"example_owner","repo":"example_repo","pull_number":1}' --json

Provider shortcut

kosmo integrations:github github_list_pull_request_reviews '{"owner":"example_owner","repo":"example_repo","pull_number":1}' --json

github.github_create_review

Write write

Create a review on a GitHub pull request. Can approve, request changes, or comment. Optionally include inline review comments on specific lines.

Parameters
owner, repo, pull_number, body, event, comments

Generic CLI call

kosmo integrations:call github.github_create_review '{"owner":"example_owner","repo":"example_repo","pull_number":1,"body":"example_body","event":"example_event","comments":"example_comments"}' --json

Provider shortcut

kosmo integrations:github github_create_review '{"owner":"example_owner","repo":"example_repo","pull_number":1,"body":"example_body","event":"example_event","comments":"example_comments"}' --json

github.github_list_commits

Read read

List commits in a GitHub repository. Supports filtering by branch (SHA), file path, and author.

Parameters
owner, repo, sha, path, author, per_page

Generic CLI call

kosmo integrations:call github.github_list_commits '{"owner":"example_owner","repo":"example_repo","sha":"example_sha","path":"example_path","author":"example_author","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_list_commits '{"owner":"example_owner","repo":"example_repo","sha":"example_sha","path":"example_path","author":"example_author","per_page":1}' --json

github.github_get_commit

Read read

Get detailed information about a specific commit, including author, committer, message, and file changes.

Parameters
owner, repo, ref

Generic CLI call

kosmo integrations:call github.github_get_commit '{"owner":"example_owner","repo":"example_repo","ref":"example_ref"}' --json

Provider shortcut

kosmo integrations:github github_get_commit '{"owner":"example_owner","repo":"example_repo","ref":"example_ref"}' --json

github.github_get_file_content

Read read

Get the content of a file or directory from a GitHub repository. Returns base64-encoded content for files, or a listing for directories.

Parameters
owner, repo, path, ref

Generic CLI call

kosmo integrations:call github.github_get_file_content '{"owner":"example_owner","repo":"example_repo","path":"example_path","ref":"example_ref"}' --json

Provider shortcut

kosmo integrations:github github_get_file_content '{"owner":"example_owner","repo":"example_repo","path":"example_path","ref":"example_ref"}' --json

github.github_create_or_update_file

Write write

Create a new file or update an existing file in a GitHub repository. For updates, the SHA of the existing file is required. Content should be provided as plain text (it will be base64-encoded automatically).

Parameters
owner, repo, path, message, content, sha, branch

Generic CLI call

kosmo integrations:call github.github_create_or_update_file '{"owner":"example_owner","repo":"example_repo","path":"example_path","message":"example_message","content":"example_content","sha":"example_sha","branch":"example_branch"}' --json

Provider shortcut

kosmo integrations:github github_create_or_update_file '{"owner":"example_owner","repo":"example_repo","path":"example_path","message":"example_message","content":"example_content","sha":"example_sha","branch":"example_branch"}' --json

github.github_create_branch

Write write

Create a new branch in a GitHub repository. Requires a reference name (e.g. "refs/heads/my-feature") and the SHA of the commit to branch from.

Parameters
owner, repo, ref, sha

Generic CLI call

kosmo integrations:call github.github_create_branch '{"owner":"example_owner","repo":"example_repo","ref":"example_ref","sha":"example_sha"}' --json

Provider shortcut

kosmo integrations:github github_create_branch '{"owner":"example_owner","repo":"example_repo","ref":"example_ref","sha":"example_sha"}' --json

github.github_list_branches

Read read

List branches in a GitHub repository. Returns branch names and the SHA of each branch's latest commit.

Parameters
owner, repo, per_page

Generic CLI call

kosmo integrations:call github.github_list_branches '{"owner":"example_owner","repo":"example_repo","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_list_branches '{"owner":"example_owner","repo":"example_repo","per_page":1}' --json

github.github_list_releases

Read read

List releases in a GitHub repository. Returns release tag, title, body, draft/prerelease status, and assets.

Parameters
owner, repo

Generic CLI call

kosmo integrations:call github.github_list_releases '{"owner":"example_owner","repo":"example_repo"}' --json

Provider shortcut

kosmo integrations:github github_list_releases '{"owner":"example_owner","repo":"example_repo"}' --json

github.github_create_release

Write write

Create a new release in a GitHub repository. Requires a tag name. Optionally set target commit, release name, body, draft, and prerelease flags.

Parameters
owner, repo, tag_name, target_commitish, name, body, draft, prerelease

Generic CLI call

kosmo integrations:call github.github_create_release '{"owner":"example_owner","repo":"example_repo","tag_name":"example_tag_name","target_commitish":"example_target_commitish","name":"example_name","body":"example_body","draft":true,"prerelease":true}' --json

Provider shortcut

kosmo integrations:github github_create_release '{"owner":"example_owner","repo":"example_repo","tag_name":"example_tag_name","target_commitish":"example_target_commitish","name":"example_name","body":"example_body","draft":true,"prerelease":true}' --json

github.github_search_issues

Read read

Search for issues and pull requests across all of GitHub. Supports GitHub search syntax like "repo:owner/repo is:issue is:open label:bug".

Parameters
query, sort, order, per_page

Generic CLI call

kosmo integrations:call github.github_search_issues '{"query":"example_query","sort":"example_sort","order":"example_order","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_search_issues '{"query":"example_query","sort":"example_sort","order":"example_order","per_page":1}' --json

github.github_get_current_user

Read read

Get the authenticated GitHub user's profile information, including username, name, email, bio, public repos count, and more.

Parameters
none

Generic CLI call

kosmo integrations:call github.github_get_current_user '{}' --json

Provider shortcut

kosmo integrations:github github_get_current_user '{}' --json

github.github_create_gist

Write write

Create a new GitHub gist. Provide a description, a map of filenames to their content, and whether the gist should be public or secret.

Parameters
description, files, public

Generic CLI call

kosmo integrations:call github.github_create_gist '{"description":"example_description","files":"example_files","public":true}' --json

Provider shortcut

kosmo integrations:github github_create_gist '{"description":"example_description","files":"example_files","public":true}' --json

github.github_list_workflow_runs

Read read

List GitHub Actions workflow runs for a repository. Supports filtering by status (completed, in_progress, queued, etc.).

Parameters
owner, repo, status, per_page

Generic CLI call

kosmo integrations:call github.github_list_workflow_runs '{"owner":"example_owner","repo":"example_repo","status":"example_status","per_page":1}' --json

Provider shortcut

kosmo integrations:github github_list_workflow_runs '{"owner":"example_owner","repo":"example_repo","status":"example_status","per_page":1}' --json

github.github_dispatch_workflow

Write write

Trigger a GitHub Actions workflow dispatch event. The workflow must have a "workflow_dispatch" trigger in its YAML configuration. Requires the workflow ID or filename and a ref (branch or tag).

Parameters
owner, repo, workflow_id, ref, inputs

Generic CLI call

kosmo integrations:call github.github_dispatch_workflow '{"owner":"example_owner","repo":"example_repo","workflow_id":"example_workflow_id","ref":"example_ref","inputs":"example_inputs"}' --json

Provider shortcut

kosmo integrations:github github_dispatch_workflow '{"owner":"example_owner","repo":"example_repo","workflow_id":"example_workflow_id","ref":"example_ref","inputs":"example_inputs"}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

github.github_list_repos

List repositories for the authenticated GitHub user. Supports filtering by type (all, owner, public, private, member), sorting (created, updated, pushed, full_name), and direction.

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_repos --json
ParameterTypeRequiredDescription
type string no Repository type filter: all, owner, public, private, member. Default: all.
sort string no Sort field: created, updated, pushed, full_name. Default: full_name.
direction string no Sort direction: asc or desc. Default: asc when using full_name, desc otherwise.
per_page integer no Results per page (1-100). Default: 30.
page integer no Page number for pagination. Default: 1.

github.github_get_repo

Get detailed information about a specific GitHub repository, including description, stats, default branch, and more.

Operation
Read read
Schema command
kosmo integrations:schema github.github_get_repo --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.

github.github_create_repo

Create a new repository for the authenticated GitHub user. Optionally set description, visibility, and auto-initialize with a README.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_repo --json
ParameterTypeRequiredDescription
name string yes The name of the new repository.
description string no A short description of the repository.
private boolean no Whether the repository should be private. Default: false (public).
auto_init boolean no Initialize the repository with a README.md. Default: false.

github.github_search_repos

Search for repositories on GitHub using keywords, language filters, stars, and more. Returns matching repositories with metadata.

Operation
Read read
Schema command
kosmo integrations:schema github.github_search_repos --json
ParameterTypeRequiredDescription
query string yes Search query. Supports GitHub search syntax like "language:python stars:>100".
sort string no Sort field: stars, forks, help-wanted-issues, updated. Default: best match.
order string no Sort direction: asc or desc. Default: desc.
per_page integer no Results per page (1-100). Default: 30.

github.github_list_issues

List issues in a GitHub repository. Supports filtering by state (open, closed, all), labels, and sorting.

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_issues --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
state string no Issue state filter: open, closed, all. Default: open.
labels string no Comma-separated list of label names to filter by. Example: "bug,urgent".
sort string no Sort field: created, updated, comments. Default: created.
direction string no Sort direction: asc or desc. Default: desc.
per_page integer no Results per page (1-100). Default: 30.

github.github_get_issue

Get detailed information about a specific GitHub issue, including title, body, labels, assignees, milestone, and comments count.

Operation
Read read
Schema command
kosmo integrations:schema github.github_get_issue --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
issue_number integer yes The issue number.

github.github_create_issue

Create a new issue in a GitHub repository. Requires a title. Optionally set body, assignees, labels, and milestone.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_issue --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
title string yes The title of the issue.
body string no The body (description) of the issue. Supports GitHub Markdown.
assignees array no Array of GitHub usernames to assign to the issue. Example: ["octocat"].
labels array no Array of label names to apply. Example: ["bug", "help wanted"].
milestone integer no The milestone number to associate with the issue.

github.github_update_issue

Update an existing issue in a GitHub repository. Can change title, body, state (open/closed), assignees, labels, and milestone.

Operation
Write write
Schema command
kosmo integrations:schema github.github_update_issue --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
issue_number integer yes The issue number to update.
title string no New title for the issue.
body string no New body (description) for the issue. Supports GitHub Markdown.
state string no New state: open or closed.
assignees array no Array of GitHub usernames to assign. Replaces existing assignees.
labels array no Array of label names. Replaces existing labels.
milestone integer no Milestone number to associate. Use null to clear.

github.github_add_labels

Add one or more labels to a GitHub issue. Labels are specified by name. If a label does not exist in the repository, it will be created.

Operation
Write write
Schema command
kosmo integrations:schema github.github_add_labels --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
issue_number integer yes The issue number.
labels array yes Array of label names to add. Example: ["bug", "enhancement"].

github.github_create_issue_comment

Add a comment to a GitHub issue or pull request. The comment body supports GitHub Markdown.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_issue_comment --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
issue_number integer yes The issue or pull request number.
body string yes The comment body. Supports GitHub Markdown.

github.github_list_pull_requests

List pull requests in a GitHub repository. Supports filtering by state (open, closed, all) and sorting.

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_pull_requests --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
state string no Pull request state filter: open, closed, all. Default: open.
sort string no Sort field: created, updated, popularity, long-running. Default: created.
direction string no Sort direction: asc or desc. Default: desc.
per_page integer no Results per page (1-100). Default: 30.

github.github_get_pull_request

Get detailed information about a specific GitHub pull request, including title, body, branch info, merge status, and review status.

Operation
Read read
Schema command
kosmo integrations:schema github.github_get_pull_request --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
pull_number integer yes The pull request number.

github.github_create_pull_request

Create a new pull request in a GitHub repository. Requires a title, head branch (source), and base branch (target).

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_pull_request --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
title string yes The title of the pull request.
body string no The body (description) of the pull request. Supports GitHub Markdown.
head string yes The name of the branch where your changes are implemented (source branch).
base string yes The name of the branch you want the changes pulled into (target branch).
draft boolean no Whether to create the pull request as a draft. Default: false.

github.github_update_pull_request

Update an existing pull request in a GitHub repository. Can change title, body, state (open/closed), and base branch.

Operation
Write write
Schema command
kosmo integrations:schema github.github_update_pull_request --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
pull_number integer yes The pull request number to update.
title string no New title for the pull request.
body string no New body (description) for the pull request. Supports GitHub Markdown.
state string no New state: open or closed.
base string no New base branch name.

github.github_merge_pull_request

Merge a GitHub pull request. Supports merge commit, squash, or rebase merge methods.

Operation
Write write
Schema command
kosmo integrations:schema github.github_merge_pull_request --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
pull_number integer yes The pull request number to merge.
commit_title string no Title for the automatic commit message.
commit_message string no Extra detail for the automatic commit message.
merge_method string no Merge method: merge, squash, or rebase. Default: merge.

github.github_list_pull_request_reviews

List all reviews on a GitHub pull request, including review state (approved, changes_requested, commented, dismissed).

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_pull_request_reviews --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
pull_number integer yes The pull request number.

github.github_create_review

Create a review on a GitHub pull request. Can approve, request changes, or comment. Optionally include inline review comments on specific lines.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_review --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
pull_number integer yes The pull request number.
body string no The body text of the review. Required when using COMMENT or REQUEST_CHANGES event.
event string no The review action: APPROVE, REQUEST_CHANGES, or COMMENT. Default: COMMENT.
comments array no Array of inline review comments. Each comment needs "path" (file path), "position" (line index in diff), and "body" (comment text).

github.github_list_commits

List commits in a GitHub repository. Supports filtering by branch (SHA), file path, and author.

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_commits --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
sha string no Branch name or SHA to filter commits by.
path string no File path to filter commits by. Only commits containing this file path will be returned.
author string no GitHub username or email address to filter by author.
per_page integer no Results per page (1-100). Default: 30.

github.github_get_commit

Get detailed information about a specific commit, including author, committer, message, and file changes.

Operation
Read read
Schema command
kosmo integrations:schema github.github_get_commit --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
ref string yes The commit SHA or branch name.

github.github_get_file_content

Get the content of a file or directory from a GitHub repository. Returns base64-encoded content for files, or a listing for directories.

Operation
Read read
Schema command
kosmo integrations:schema github.github_get_file_content --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
path string yes The file or directory path. Use empty string for root.
ref string no The name of the commit/branch/tag. Default: the repository's default branch.

github.github_create_or_update_file

Create a new file or update an existing file in a GitHub repository. For updates, the SHA of the existing file is required. Content should be provided as plain text (it will be base64-encoded automatically).

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_or_update_file --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
path string yes The file path within the repository.
message string yes The commit message.
content string yes The file content as plain text. Will be base64-encoded automatically.
sha string no Required when updating an existing file. The blob SHA of the file being replaced.
branch string no The branch name. Default: the repository's default branch.

github.github_create_branch

Create a new branch in a GitHub repository. Requires a reference name (e.g. "refs/heads/my-feature") and the SHA of the commit to branch from.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_branch --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
ref string yes The name of the fully qualified reference (e.g. "refs/heads/new-branch-name").
sha string yes The SHA1 value of the commit to start the branch from.

github.github_list_branches

List branches in a GitHub repository. Returns branch names and the SHA of each branch's latest commit.

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_branches --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
per_page integer no Results per page (1-100). Default: 30.

github.github_list_releases

List releases in a GitHub repository. Returns release tag, title, body, draft/prerelease status, and assets.

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_releases --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.

github.github_create_release

Create a new release in a GitHub repository. Requires a tag name. Optionally set target commit, release name, body, draft, and prerelease flags.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_release --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
tag_name string yes The name of the tag for the release (e.g. "v1.0.0").
target_commitish string no The commitish value that determines where the Git tag is created from. Can be a branch or SHA. Default: default branch.
name string no The name of the release.
body string no The release body text describing the release. Supports GitHub Markdown.
draft boolean no Whether to create the release as a draft. Default: false.
prerelease boolean no Whether to identify the release as a prerelease. Default: false.

github.github_search_issues

Search for issues and pull requests across all of GitHub. Supports GitHub search syntax like "repo:owner/repo is:issue is:open label:bug".

Operation
Read read
Schema command
kosmo integrations:schema github.github_search_issues --json
ParameterTypeRequiredDescription
query string yes Search query using GitHub search syntax. Can filter by repo, type, state, labels, assignees, etc. Example: "repo:octocat/hello-world is:issue is:open".
sort string no Sort field: comments, reactions, reactions-+1, reactions--1, reactions-heart, interactions, created, updated. Default: best match.
order string no Sort direction: asc or desc. Default: desc.
per_page integer no Results per page (1-100). Default: 30.

github.github_get_current_user

Get the authenticated GitHub user's profile information, including username, name, email, bio, public repos count, and more.

Operation
Read read
Schema command
kosmo integrations:schema github.github_get_current_user --json
ParameterTypeRequiredDescription
No parameters.

github.github_create_gist

Create a new GitHub gist. Provide a description, a map of filenames to their content, and whether the gist should be public or secret.

Operation
Write write
Schema command
kosmo integrations:schema github.github_create_gist --json
ParameterTypeRequiredDescription
description string no A description of the gist.
files object yes A map of filenames to file content. Each entry should have a "content" key. Example: {"hello.py": {"content": "print('hello')"}}
public boolean no Whether the gist is public. Default: false (secret gist).

github.github_list_workflow_runs

List GitHub Actions workflow runs for a repository. Supports filtering by status (completed, in_progress, queued, etc.).

Operation
Read read
Schema command
kosmo integrations:schema github.github_list_workflow_runs --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
status string no Filter by status: completed, in_progress, queued, waiting, requested, pending.
per_page integer no Results per page (1-100). Default: 30.

github.github_dispatch_workflow

Trigger a GitHub Actions workflow dispatch event. The workflow must have a "workflow_dispatch" trigger in its YAML configuration. Requires the workflow ID or filename and a ref (branch or tag).

Operation
Write write
Schema command
kosmo integrations:schema github.github_dispatch_workflow --json
ParameterTypeRequiredDescription
owner string yes The repository owner (user or organization).
repo string yes The name of the repository.
workflow_id string yes The workflow ID or filename (e.g. "ci.yml" or "12345").
ref string yes The git reference (branch or tag) to run the workflow on.
inputs object no Input parameters for the workflow. Keys must match the workflow_dispatch inputs defined in the workflow YAML.

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.