Home / Servers / GitHub API / agent_tasks_create_task_in_repo

Start a task

An MCP tool from the GitHub API server, hosted on mcp.hjlabs.in.

Start a task > [!NOTE] > This endpoint is in public preview and is subject to change. Starts a new Copilot cloud agent task for a repository. This endpoint is only available to users with a Copilot Business or… [POST /agents/repos/{owner}/{repo}/tasks]

Name on the gateway: github_api__agent_tasks_create_task_in_repo · may change things.

Parameters

NameTypeDescription
owner requiredstringThe account owner of the repository. The name is not case…
repo requiredstringThe name of the repository. The name is not case sensitive.
prompt requiredstringThe user's prompt for the agent
modelstringThe model to use for this task. The allowed models may change over time and…
custom_agentstringOptional identifier for a custom agent to use for this task. Use the custom…
create_pull_requestbooleanWhether to create a PR.
base_refstringBase ref for new branch/PR
head_refstringHead ref for existing branch/PR. If provided with base_ref, the agent looks up…

How to call it

Through the Smart Gateway, any client can run it by name with call_tool, or let the gateway find it with search_tools:

call_tool arguments
{
  "name": "github_api__agent_tasks_create_task_in_repo",
  "arguments": {
    "owner": "…",
    "repo": "…",
    "prompt": "…"
  }
}

Or connect the GitHub API server directly, which lists 1,221 tools including this one:

Run in your terminal
claude mcp add --transport http hj-github-api https://mcp.hjlabs.in/mcp/github-api \
  --header "Authorization: Bearer YOUR_API_KEY"

Try asking

Use the start a task tool with owner set to ….

More from GitHub API