Skip to content
CodeLifter
Search/ Browse prompts
CodeLifter Forum

Who is the author of a commit made through an MCP server?

Staff answerWritten by CodeLifter editors · AI code policies2 repliesupdated

Short answer

In Git terms, whoever the commit names: the account or identity the server used, which is usually yours. The GitHub REST API, for example, defaults both author and committer to the authenticated user. In project terms, the person who ran the agent is the accountable author, and the tool belongs in a trailer, never in Signed-off-by.

Written by CodeLifter editors · Staff, CodeLifter ·
CiteCodeLifter Forum, "Who is the author of a commit made through an MCP server?", https://codelifter.com/forum/posts/who-is-the-author-of-a-commit-made-through-an-mcp-server/, accessed 2026-11-12.
  1. Staff, CodeLifter ·

    Two meanings of "author"

    The question has a Git answer and a policy answer, and they are often confused.

    Git records two people on every commit. The Pro Git book puts it this way: "The author is the person who originally wrote the work, whereas the committer is the person who last applied the work." Both are just a name, an email address and a date stored in the commit. Git does not check that the named person typed anything.

    Projects, on the other hand, care about who is responsible. Fedora's approved policy says "The contributor is always the author and is fully accountable for their contributions." The Linux kernel says AI agents must not add Signed-off-by tags, because certifying the Developer Certificate of Origin is something only a person can do.

    What the commit will say, by setup

    MCP servers differ in how a change reaches the repository, so the name on the commit depends on which route the agent took.

    Route What creates the commit Name you will usually see What decides it
    A hosted Git service's API, through a server such as the GitHub MCP server The hosting service, acting on your token or OAuth login The account that owns the token API defaults, unless the call passes an explicit author
    The agent runs git commit in a terminal or shell tool on your machine Your local Git Whatever user.name and user.email that Git is set to Your Git config, unless the command the agent ran overrides it
    A file-only server such as the Filesystem MCP server Nobody yet: the server writes files, you commit later You, when you commit Your Git config

    Through the GitHub MCP server. The server's README says it authenticates with OAuth or a personal access token, and it lists write tools such as create_or_update_file and push_files. GitHub's REST endpoint for repository contents, which creates a commit for a file change, documents the defaults: the committer is "the authenticated user", and the author is "the committer or the authenticated user if you omit committer". The README does not say which REST endpoint each tool calls or whether it passes an author, so treat the table row as the likely result and check the commit itself.

    Through a local shell. If the agent commits with your local Git, the commit carries the identity your Git is configured with. An agent can override that identity in the command it runs, so read the command, not only the result.

    Through the Filesystem server. The Filesystem MCP server reads and writes files inside the directories you allow and has no Git tools of its own. Any commit is one you make afterwards.

    How to check a specific commit

    1. Fetch, then run git log -1 --format='author: %an <%ae> %ad%ncommitter: %cn <%ce> %cd' <commit>. The %an, %ae and %ad specifiers are the author's name, email and date; %cn, %ce and %cd are the committer's, as listed in the Pro Git table of format specifiers.
    2. Compare both to the account the agent used. If the author is you and you did not review the change, that is the problem to fix, not the name.
    3. On the hosting service, open the commit page and compare it with what your local Git printed.
    4. Read the end of the message for trailers such as Assisted-by: or Co-authored-by:.

    What to put in the commit

    Keep yourself as author when you directed the change and reviewed it, and record the tool separately:

    fix: escape user input in the search results list
    
    Replaces innerHTML with textContent in renderResults().
    
    Assisted-by: coding agent via GitHub MCP server (reviewed by hand)
    

    Do not use Co-authored-by: for the tool. GitHub reads that trailer to list co-authors on a commit, and Mesa says it is reserved for human co-authors. Do not let the agent add Signed-off-by: on your behalf on any project that uses the Developer Certificate of Origin.

    Because an API commit never runs your local hooks, the trailer has to come from the agent's instructions or from a CI check on the pull request. The thread on enforcing an Assisted-by trailer has a script for that check.

    Keep the agent from committing as you without review

    The MCP tools specification says there should always be a human in the loop with the ability to deny tool invocations. In practice:

    1. Give the token only the scopes the task needs, and use a separate token for agent work so its commits are easy to find. The GitHub MCP server's README recommends minimum scopes and separate tokens.
    2. Run the server read-only when the agent only needs to read. The server's configuration documentation describes a read-only mode that disables write tools even when they are requested.
    3. Have the agent work on a branch and open a pull request instead of pushing to the default branch, then review the diff yourself.
    4. Approve each write tool call in your client rather than allowing them all.

    The scopes question has its own thread: which token scopes the GitHub MCP server needs. For the details of each GitHub tool and its settings, see the CodeLifter page on the GitHub MCP server.

    Ownership is a separate question

    Who the commit names does not settle who owns the code. The US Copyright Office has said copyright does not extend to purely AI-generated material, and that the human contribution is analysed case by case. That question is covered on who owns AI-generated code.

    0
    ReplyLink

Plain text or simple Markdown. Links are nofollow. Your email is never shown.

  1. CodeLifter editorsStaffStaff, CodeLifter ·

    Does the Git MCP server set the author on commits? It has no author setting of its own. The reference Git server's README lists twelve tools, from git_status and git_diff to git_commit, git_log and git_checkout. The git_commit tool takes two inputs, the repository path and the message, and returns the new commit hash; it errors if nothing is staged. With no author or committer input, the commit takes whatever identity Git is configured with for that repository, which on your machine is usually you. There is no push, pull or fetch tool, so nothing leaves your machine until you push. That makes the server's commits the second row of the table in the opening post, with one difference: the agent cannot override the identity through this tool, though an agent with a separate shell tool still could. Two settings to check. --repository accepts any path inside a working tree, and the README says the server walks up to the repository root, so a path to a subfolder still allows tool calls anywhere in that repository. And because the message is free text, ask the agent to add the Assisted-by: line itself, then check it with git log -1 before you push.

  2. CodeLifter editorsStaffStaff, CodeLifter ·

    Will a commit made through the GitHub API show as Verified? It depends on who makes it, and the documentation is specific only for some cases. GitHub's signature verification page says GitHub automatically signs commits you make using the web interface, and that those show a verified status; the public key is at https://github.com/web-flow.gpg. For bots, it says verification works only if the request is authenticated as the GitHub App or bot and contains no custom author, committer or signature information. The page does not state the result for a commit created through the REST API with a personal access token, which is how a local GitHub MCP server often authenticates. So do not assume. Open the commit on GitHub and look at the badge, or read the commit's verification details through the REST API, which include a verified_at timestamp. Remember what the badge means even when it appears: a signature GitHub made says GitHub created the commit on an authenticated request. It says nothing about who wrote the change or whether anyone reviewed it, which is why the opening post puts the review step and the trailer ahead of the badge.

CodeLifter

Reviewed vibe coding prompts, the JavaScript each one should produce, and sourced answers on AI-generated code: who wrote it, who owns it, and whether you can ship it. Free since 1999.

Browse the Prompt Shelf

Popular topics

© 1999 to 2026 CodeLifter

Independent. No ties to any software vendor.
Code MIT Text CC-BY-4.0 Back to top