Agent skill

Kotlin API Design

by chrisbanes in chrisbanes/skills

A skill your agent uses when designing or reviewing Kotlin function ownership, member or extension functions, factories, single-field domain types, value classes, data classes, Kotlin Multiplatform…

Apache-2.0Auto-check passedMobile

Install Kotlin API Design

skills CLI
$ npx skills add chrisbanes/skills --skill kotlin-api-design -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install chrisbanes/skills kotlin-api-design --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/chrisbanes/skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/kotlin-api-design .claude/skills/kotlin-api-design && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
kotlin-api-design
GitHub stars
1.1k
Token cost
~530 tokens
SKILL.md length
231 words
Files
4 (incl. references)
Skills in repo
19
Repo updated
First seen
Licence
Apache-2.0

At a glance

A skill your agent uses when designing or reviewing Kotlin function ownership, member or extension functions, factories, single-field domain types, value classes, data classes, Kotlin Multiplatform…

  • Works in 7 steps: Name the domain concept, its owning type… → Choose function ownership before adding… → When reviewing a public mapping over a… → …
  • Reviewing Kotlin function ownership
  • SKILL.md covers Core principle, Procedure and Topic router
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Kotlin API Design is an agent skill from chrisbanes/skills. Use when designing or reviewing Kotlin function ownership, member or extension functions, factories, single-field domain types, value classes, data classes, Kotlin Multiplatform expect/actual declarations, or platform service boundaries.

Its SKILL.md is about 530 tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including reference files (for example `references/functions.md`, `references/multiplatform-boundaries.md` and `references/value-classes.md`).

It sits in Mobile, covering Android development, API design and Cross-platform mobile apps. It works with Kotlin. The repository describes itself as: Skills for Kotlin, Jetpack Compose, and Android development. The licence is Apache-2.0.

When your agent uses it

  • Reviewing Kotlin function ownership
  • Extension functions
  • Single-field domain types
  • Kotlin Multiplatform expect/actual declarations

Example prompts

  • “/kotlin-api-design”

Workflow steps

7 steps, taken from the first numbered list in SKILL.md.

  1. Name the domain concept, its owning type or module, and the callers that
  2. Choose function ownership before adding an extension, factory, helper, or
  3. When reviewing a public mapping over a sealed result, name every
  4. Represent a single-field domain concept with the smallest type that preserves
  5. Keep shared code semantic; put native SDK and platform details behind an
  6. Read the focused reference for the selected decision below.
  7. Finish when the public surface states domain intent, platform details remain

What it can do on your machine

Read from SKILL.md and the folder at commit 00bda52. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Kotlin API Design loads about 530 tokens when it runs, and up to ~3.3k if it reads all its reference files. Until then it costs about 64 tokens; SKILL.md has 231 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~64
When it runs · the whole SKILL.md, loaded when a task matches
~530
With references · SKILL.md plus every file in references/, read only if the agent opens them
~3.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from chrisbanes/skills at commit 00bda52, republished under its Apache-2.0 licence (© chrisbanes). 231 words, ~530 tokens.

Download SKILL.mdSave it as .claude/skills/kotlin-api-design/SKILL.md (or your agent's skills folder). This skill also uses 3 other files; get the full folder from GitHub.
name
kotlin-api-design
description
Use when designing or reviewing Kotlin function ownership, member or extension functions, factories, single-field domain types, value classes, data classes, Kotlin Multiplatform expect/actual declarations, or platform service boundaries.

Kotlin API design

Core principle

Place behavior, types, and platform seams where their meaning is clearest to callers; use the smallest public abstraction that preserves domain language and platform independence.

Procedure

  1. Name the domain concept, its owning type or module, and the callers that need to depend on it.
  2. Choose function ownership before adding an extension, factory, helper, or service layer.
  3. When reviewing a public mapping over a sealed result, name every caller-visible outcome. Flag a catch-all else that hides a subtype and recommend explicit subtype branches so the contract stays exhaustive and preserves smart casts.
  4. Represent a single-field domain concept with the smallest type that preserves its semantic and interop contract.
  5. Keep shared code semantic; put native SDK and platform details behind an interface or a narrowly justified expect/actual boundary.
  6. Read the focused reference for the selected decision below.
  7. Finish when the public surface states domain intent, platform details remain at leaves, and callers do not depend on convenience abstractions with no clear owner.

Topic router

SignalRead
Member vs top-level, extension, factory, service, or receiver choiceFunction ownership
Primitive obsession, one-field domain type, @JvmInline value class, data class, interop, or Compose stabilityValue classes
Source sets, platform services, native SDKs, files, sensors, permissions, Compose Multiplatform interop, or expect/actualMultiplatform boundaries
Branching, guard-condition shape, sealed-result mapping, or a catch-all elseKotlin control flow

© chrisbanes, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 3 other files (references) in skills/kotlin-api-design of chrisbanes/skills.

  • SKILL.md
  • references/functions.md
  • references/multiplatform-boundaries.md
  • references/value-classes.md

Open the folder on GitHubat commit 00bda52

Compare with similar skills

Kotlin API Design next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Kotlin API Design compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Kotlin API Design this skillchrisbanes/skills1.1k—~530Automated safety check: PassApache-2.0
Build Nitro Modulesmargelo/react-native-skills175—~9.9kAutomated safety check: PassMIT
Compose Multiplatform Patternsmonta-app/ocpp-emulator1805 repos~2kAutomated safety check: PassApache-2.0
Summoncodeyousef/summon167—~1.1kAutomated safety check: PassApache-2.0
Jetpack Compose Expertaldefy/compose-skill596—~4.8kAutomated safety check: PassCustom licence
Claude Android NinjaDrjacky/claude-android-ninja124—~5.2kAutomated safety check: PassApache-2.0

Similar skills

  • Build Nitro Modules

    margelo/react-native-skills

    Builds and designs React Native Nitro Modules with Nitrogen, HybridObject TypeScript specs, Nitro View components, generated native implementations, zero-copy and native-state APIs, Swift/Kotlin/C++…

    175 GitHub stars~9.9k tokensUpdated 1 mo ago
    MobileAuto-check passed
  • Compose Multiplatform Patterns

    monta-app/ocpp-emulator

    Compose Multiplatform and Jetpack Compose patterns for KMP projects — state management, navigation, theming, performance, and platform-specific UI.

    180 GitHub starsUsed in 5 repos~2k tokens
    MobileAuto-check passed
  • Summon

    codeyousef/summon

    A skill your agent uses when developing applications with the Summon Kotlin Multiplatform UI framework.

    167 GitHub stars~1.1k tokensUpdated today
    MobileAuto-check passed
  • Jetpack Compose Expert

    aldefy/compose-skill

    Guides Jetpack Compose and Compose Multiplatform work across Android, Desktop, iOS and web, plus Android TV, Material 3 motion, paging, navigation and design-to-code.

    596 GitHub stars~4.8k tokensUpdated 2 mo ago
    MobileAuto-check passed
  • Claude Android Ninja

    Drjacky/claude-android-ninja

    Build and migrate Android apps with Kotlin, Jetpack Compose, MVVM, Hilt, Room 3 (KSP, SQLiteDriver, Flow/suspend DAOs), Navigation3, and multi-module Gradle.

    124 GitHub stars~5.2k tokensUpdated 10 days ago
    MobileAuto-check passed
  • Expo Brownfield Integration

    mweinbach/agent-coworker

    Helps add Expo and React Native to an existing native iOS or Android app, and choose between a prebuilt AAR or XCFramework and a fully integrated build.

    156 GitHub starsUsed in 2 repos~900 tokens
    MobileAuto-check: notes

More from chrisbanes/skills

All 19 skills in this repo
  • Gradle Run

    chrisbanes/skills

    A skill your agent uses when planning to execute Gradle through gradle, ./gradlew, or a custom gradlew wrapper script, or diagnosing a Gradle build, compact workflow ledger, repeated failure…

    1.1k GitHub stars~1.2k tokensUpdated yesterday
    Auto-check passed
  • Compose Animations

    chrisbanes/skills

    A skill your agent uses when writing or reviewing Jetpack Compose motion: visibility enter/exit, animating one property toward a target, color or size transitions, multiple properties from one…

    1.1k GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • A skill your agent uses when writing or reviewing Jetpack Compose UI tests, screenshot tests or baseline-recording evidence, previews, semantics assertions, fake image loading, keyboard input, focus…

    1.1k GitHub stars~1.8k tokensUpdated yesterday
    Auto-check passed
  • Release Kotlin Library

    chrisbanes/skills

    A skill your agent uses when preparing, publishing, or checking readiness for a Kotlin library release, including verifying its gradle-maven-publish-plugin prerequisite, reconciling changelogs and…

    1.1k GitHub stars~1.9k tokensUpdated yesterday
    Auto-check: notes
  • Run GitHub Project

    chrisbanes/skills

    A skill your agent uses when asked to set up, review, or operate a repository's GitHub Project workflow, including ready claims, role-labelled human work, unknown remote mutation outcomes, Todo…

    1.1k GitHub stars~1.5k tokensUpdated yesterday
    Auto-check passed
  • Compose Component Design

    chrisbanes/skills

    A skill your agent uses when designing or reviewing reusable Jetpack Compose component APIs with modifier parameters, root layout placement, caller-provided variable content, primitive content…

    1.1k GitHub starsUsed in 1 repo~718 tokens
    Auto-check passed

Works with

Categories

Questions about Kotlin API Design

What does Kotlin API Design do?

A skill your agent uses when designing or reviewing Kotlin function ownership, member or extension functions, factories, single-field domain types, value classes, data classes, Kotlin Multiplatform…. Kotlin API Design is an agent skill from chrisbanes/skills. Use when designing or reviewing Kotlin function ownership, member or extension functions, factories, single-field domain types, value classes, data classes, Kotlin Multiplatform expect/actual declarations, or platform service boundaries.

When should I use Kotlin API Design?

Kotlin API Design fits situations like: reviewing Kotlin function ownership; extension functions; single-field domain types; kotlin Multiplatform expect/actual declarations.

How do I install Kotlin API Design in Claude Code?

Run `npx skills add chrisbanes/skills --skill kotlin-api-design -a claude-code`. Or copy the skill folder (skills/kotlin-api-design in chrisbanes/skills) into .claude/skills/kotlin-api-design in your project. Claude Code loads it when a task matches its description.

How do I install Kotlin API Design in Codex?

Run `npx skills add chrisbanes/skills --skill kotlin-api-design -a codex`. Or copy the skill folder (skills/kotlin-api-design in chrisbanes/skills) into .agents/skills/kotlin-api-design in your project. Codex loads it when a task matches its description.

Can I use Kotlin API Design in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add chrisbanes/skills --skill kotlin-api-design -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/kotlin-api-design, .gemini/skills/kotlin-api-design, .github/skills/kotlin-api-design and .opencode/skills/kotlin-api-design in your project.

What does Kotlin API Design need to run?

SKILL.md names no scripts, command-line tools or credentials: Kotlin API Design is instructions for the agent only.

Does Kotlin API Design access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Kotlin API Design safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Kotlin API Design use?

Kotlin API Design is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Kotlin API Design use?

About 530 tokens (SKILL.md is roughly 2.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 2.8k tokens, read only when the agent opens those files.

What are the alternatives to Kotlin API Design?

Skills that share tags, products or a category with Kotlin API Design: Build Nitro Modules (margelo/react-native-skills, 175 stars), Compose Multiplatform Patterns (monta-app/ocpp-emulator, 180 stars), Summon (codeyousef/summon, 167 stars) and Jetpack Compose Expert (aldefy/compose-skill, 596 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Kotlin API Design?

chrisbanes (a GitHub user) maintains it in chrisbanes/skills, which has 1,093 GitHub stars. The repository holds 19 skills in this directory. The repository was last updated on October 8, 2026.

Source: chrisbanes/skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.