Codeberg icon

Codeberg

Interact with the Codeberg API

File → Create

AI-generated

Summary

Create a new file in a specified Codeberg repository by providing the file path, content, and commit message.

Inputs

  • Authentication — Choose the authentication method: Access Token or OAuth2.
  • Repository Owner (required) — Owner of the repository.
  • Repository Name (required) — Name of the repository.
  • File Path (required) — Path of the file to create in the repository.
  • Content (required) — The plain text content of the file, which will be base64-encoded automatically.
  • Commit Message (required) — The commit message for creating the file.
  • Additional Fields — Optional fields including Author Email, Author Name, Branch to commit to, or creating a new branch from a specified branch for the commit.

Output shape

a single record containing the API response JSON for the created file, including file metadata and commit information

The returned data includes details from the Codeberg API about the newly created file. Additional error information is provided on failure.

Links

Discussion