# @playdrop/playdrop-cli

Official Playdrop CLI for the live [Playdrop](https://www.playdrop.ai/) platform.

Use it to browse live examples, create or remix projects, publish browser games and creator apps, and work with AI-generated game assets on Playdrop.

## Install

```bash
npm install -g @playdrop/playdrop-cli
```

## Quick Start

```bash
playdrop auth login
playdrop auth whoami
playdrop project init .
playdrop project create app my-first-game --template playdrop/template/typescript_template
playdrop project dev my-first-game
playdrop project publish .
```

## What You Can Do

- Browse the live Playdrop catalogue of apps, assets, and packs
- Inspect real references before building or remixing
- Create, remix, validate, and publish Playdrop projects
- Manage comments, versions, credits, notifications, and creations
- Read the public Playdrop docs directly from the CLI

## Links

- Website: [playdrop.ai](https://www.playdrop.ai/)
- Getting started: [playdrop.ai/getting-started](https://www.playdrop.ai/getting-started)
- CLI docs: [playdrop.ai/docs/cli](https://www.playdrop.ai/docs/cli)
- Runtime docs: [playdrop.ai/docs/runtime](https://www.playdrop.ai/docs/runtime)
- Templates and demos: [playdrop.ai/docs/examples#templates-and-demos](https://www.playdrop.ai/docs/examples#templates-and-demos)
- Public Playdrop skill: [skills.sh/playdrop-ai/playdrop-skills/playdrop](https://skills.sh/playdrop-ai/playdrop-skills/playdrop)

## Live Examples

- [Starter Kit Racing](https://www.playdrop.ai/creators/playdrop/apps/game/starter-kit-racing)
- [Hangingout](https://www.playdrop.ai/creators/playdrop/apps/game/hangingout)
- [Top Creators](https://www.playdrop.ai/top-creators)

## Main Commands

```bash
playdrop auth login
playdrop browse
playdrop search "city builder"
playdrop detail playdrop/app/hangingout
playdrop comments browse playdrop/app/hangingout
playdrop versions browse playdrop/app/hangingout
playdrop credits balance
playdrop notifications browse
playdrop creations browse
playdrop ai create image "Pixel art hero portrait"
playdrop project init .
playdrop project create app my-app --template playdrop/template/html_template
playdrop project dev my-app
playdrop project publish .
playdrop documentation browse
playdrop feedback send --title "Bug report" --comment "Details here."
playdrop getting-started
```

## Ref Format

Public content refs are always:

```text
<creator>/<kind>/<name>
```

Valid kinds:

- `app`
- `asset`
- `asset-pack`

Examples:

- `playdrop/app/hangingout`
- `playdrop/asset/astro`
- `playdrop/asset-pack/starter-kit`

## Local Project Flow

```bash
playdrop auth login
playdrop project init .
playdrop project create app my-app --template playdrop/template/html_template
playdrop project dev my-app
playdrop project publish .
```

## Documentation

```bash
playdrop documentation browse
playdrop documentation read runtime
```
