github. It was tested with @octokit/rest.
Connect
ancha connect github prints. acme/starter is the repository in the starter scene that ancha init writes. Worlds use acme/orders.
Endpoints
All 71 endpoints are partial: they implement the common request shapes, andancha twins coverage github lists what each one leaves out. Any other route returns HTTP 501 with GitHub’s error shape and x-ancha-gap: 1.
Account and repositories
Commits and Git data
Object SHAs are deterministic identities, not real Git content hashes. Commits are immutable, and new ones take their date from the simulated clock.
File contents
A file write creates a commit on an existing branch. Updates need the file’s current blob SHA, as on GitHub.
Pull requests and reviews
Pull requests are between branches of the same repository. A merge makes a two-parent merge commit when the base is an ancestor of the head. A diverged or stale head returns 409, and a closed or draft pull request returns 405. Squash, rebase and cross-repository pull requests are not modeled.
Issues and comments
Issues and pull requests share one numbering sequence. Labels apply on create and update, and the
labels filter matches issues that carry every listed label, ignoring case. Assignees and milestones are not modeled.
Labels
Repository labels have a name, color and description. Giving an issue a label the repository does not declare creates it, as GitHub does. Names match without regard to case. Label suggestions are a gap.
Check runs and Actions
Check runs are read-only starter data. Actions runs exist only for the simulated pipelines a living world defines; no workflow actually executes.
Deployments
A successful deployment status for the
production environment moves production to that deployment’s commit.
Events
Changes emit GitHub webhook events, signed withGITHUB_WEBHOOK_SECRET: pushes and branch updates emit push, pull request changes and merges emit pull_request, comments emit issue_comment, issues emit issues with the actions opened, edited, closed, reopened, labeled and unlabeled, and deployment statuses emit deployment_status. Agents receive them through the trial event feed or by HTTP. See ancha.yaml.
Starter data
Thegithub-starter dataset holds three private repositories of the organization acme.
acme/orders
acme/web and acme/warehouse-sync
The starter scene that
ancha init writes uses a different, smaller repository, acme/starter.
Checks
The second element of
github.file_at is a branch name, a commit ref, default or production. contains and equals compare exact bytes and are case-sensitive. To check that the agent opened an issue, use a github.issue state check, or a trace check such as { called: "POST /repos/acme/orders/issues" }. See Checks reference.
Limits
- No branch protection, permissions model, assignees, milestones or releases.
- No real Actions execution, jobs, artifacts or logs.
- Annotated tags, symlinks and submodules are not modeled.