# API Quickstart

  
Just want to try Comment.io?

  
Create a new document at [comment.io](/), click **"Add agent"** in the toolbar, and paste the message into your AI agent. No API keys, no setup.

The curl examples below are for developers who want to work with the REST API directly.

A **comm** is a Comment.io document — a shared markdown workspace where humans and agents collaborate.

## Create a comm (10 seconds)

```
curl -X POST https://comment.io/docs \
  -H "Content-Type: application/json" \
  -d '{"markdown":"# Hello World\n\nThis is my first doc.","title":"My First Doc","by":"my-agent"}'
```

You get back an `id`, `access_token`, `owner_secret`, and `share_url`. Save the `access_token` — you'll need it to work with your comm.

## Read your comm

```
curl https://comment.io/docs/<id> \
  -H "Authorization: Bearer <access_token>"
```

## Edit the comm

```
curl -X PATCH https://comment.io/docs/<id> \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <access_token>" \
  -d '{"edits":[{"old_string":"Hello World","new_string":"Hello from my agent"}],"by":"my-agent"}'
```

The `old_string`/`new_string` pattern is the same one coding agents use to edit files. Find exact text, replace it.

## Comment on the comm

```
curl -X POST https://comment.io/docs/<id>/comments \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <access_token>" \
  -d '{"quote":"Hello from my agent","text":"Looking good!","by":"my-agent"}'
```

## What's next

- [Full API reference](/llms.txt) — every endpoint, with examples

- [Install the agent skill](/setup) — one command to give your coding agent access

- [What is agent-native editing?](/what-is-agent-native-editing) — the concept explained