Publish from GitHub

Import a game straight from a GitHub repository and publish it.

Publishing from GitHub, in a comic
  1. Asobi: “My game lives on GitHub.”
  2. Ai: “Just paste the URL to import it!” (github.com/you/my-game)
  3. Asobi: “And when I push…” Ai: “It updates automatically!”
  4. Asobi: “The changelog comes from my commits!”

Import from the site

  1. Open “Publish” and choose the “From GitHub” tab.
  2. Enter the repository URL (https://github.com/you/my-game).
  3. If the game is in a folder or you want a specific branch, set it under “Choose a branch or folder” (for example dist or gh-pages).
  4. Press “Next”: the files are imported and you continue to the details screen.
Publish from GitHub
  • index.html in the folder is the entry point. If the game needs a build step, point to the build output (such as dist) or a gh-pages branch.
  • The repository ZIP can be up to 50 MB, and the game up to 2000 files.
  • Import again later from “Settings → Versions” and the commit messages since the last import become the changelog.

Private repositories

Private repositories work after you install the Asobiai GitHub App. You choose which repositories it can read while installing (read-only; it never writes).

Install the GitHub App

Even from a private repository, the imported folder is served as game files. Make sure it contains nothing secret.

Update automatically on push

For games imported through the GitHub App, check “Update automatically on push” and every push is published as a new version, with the commit messages as the changelog.

  • Without a branch it follows the default branch; with a branch, pushes to that branch. Games pinned to a tag or commit are not updated automatically.
  • You can also update from GitHub Actions without the app (see “From AI or the API” below).

From AI or the API

These fields work with publish_game / update_game over MCP and with the REST API.

github_repoowner/repo or https://github.com/owner/repo (a /tree/<branch>/<folder> URL also works)
github_refBranch, tag or commit (default: the default branch)
github_pathFolder with index.html (default: the whole repository)
github_autoUpdate automatically on push (through the GitHub App only)
sync_githubupdate_game: import the latest commit from the same place again

REST API example:

sh
curl -X POST https://asobiai.games/api/v1/games \
  -H "Authorization: Bearer asb_xxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{ "title": "Neon Snake", "github_repo": "you/neon-snake", "github_path": "dist" }'

Updating from GitHub Actions (add ASOBIAI_TOKEN to the repository secrets and ASOBIAI_GAME_ID to its variables). With no new commits it succeeds as “no change”:

yaml
# .github/workflows/asobiai.yml
on:
  push:
    branches: [main]
jobs:
  publish:
    runs-on: ubuntu-latest
    steps:
      - run: |
          curl -fsS -X POST https://asobiai.games/api/v1/games/${{ vars.ASOBIAI_GAME_ID }} \
            -H "Authorization: Bearer ${{ secrets.ASOBIAI_TOKEN }}" \
            -H "Content-Type: application/json" \
            -d '{ "sync_github": true }'