# Code Github API

> Work with GitHub APIs using documented endpoints, authentication boundaries, pagination, error handling, and least-privilege access.

- Skill: `samotech/code-github-api` (Agent Skill)
- Install (CLI): `npx get-skill add samotech/code-github-api`
- Raw SKILL.md: https://api.skillmd.com/api/skills/samotech/code-github-api/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: SamoTech (https://skillmd.com/u/samotech)
- Updated: 2026-11-21
- Page: https://skillmd.com/skills/samotech/code-github-api

---


## Description
Work with GitHub APIs using documented endpoints, authentication boundaries, pagination, error handling, and least-privilege access. Validate response semantics and avoid assuming that an API response proves a repository state change unless the resulting state is checked.

## When to Use
Use when an implementation or automation must interact with GitHub's API.

## Inputs / outputs / failure modes

| Area | Guidance |
|---|---|
| Inputs | API documentation, endpoint, authentication scope, request data, and expected response. |
| Outputs | Correct API interaction and independently verified resulting state. |
| Failure modes | Wrong endpoint, insufficient scope, pagination errors, rate limits, or false completion claims. |

## Runnable Example

```python
from urllib.parse import urlparse

url = 'https://api.github.com/repos/example/project'
parts = urlparse(url)
print(parts.netloc)
print(parts.path)
```

## Failure modes
- Using undocumented endpoint behavior.
- Exposing credentials in source or logs.
- Ignoring pagination or rate limits.
- Treating a request response as proof without verifying resulting state.

## Related
- 05-code
- AI_CONSTITUTION.md
- meta/AGENT_OPERATING_MODEL.md

## Evidence
Repository-backed implementation guidance grounded in repository governance and validation workflows; no external benchmark claim is made.

