# Ur Next Door API Docs

> Create and schedule posts, questions, polls, MCQs, communities, services and jobs on Ur Next Door from scripts, automation tools and AI agents.

Source: https://docs.urnextdoor.com/

The Ur Next Door API lets you publish to [urnextdoor.com](https://urnextdoor.com) from code instead of the website or the app. You create a personal API key in **Settings > API keys**, give it to a script, an automation tool or an AI agent, and that tool can then create content for you: right now, or at a time you choose.

Every request acts as you. A key can never do more than you can do by hand on the website, and you can revoke it at any time.

## What you can do with the API

- **Create content:** [posts](https://docs.urnextdoor.com/guides/create-post.md), [questions](https://docs.urnextdoor.com/guides/create-question.md), [polls](https://docs.urnextdoor.com/guides/create-poll.md), [MCQs](https://docs.urnextdoor.com/guides/create-mcq.md), [communities](https://docs.urnextdoor.com/guides/create-community.md), [Marketplace services](https://docs.urnextdoor.com/guides/create-service.md) and [jobs](https://docs.urnextdoor.com/guides/create-job.md).
- **Schedule it:** add `scheduled_at` to any create and it goes live later, from 5 minutes to 180 days ahead. Then [list, reschedule, publish now or cancel](https://docs.urnextdoor.com/guides/manage-scheduled.md).
- **Upload images:** send an image, including one an AI tool generated, as [base64 JSON or a file upload](https://docs.urnextdoor.com/guides/upload-images.md), then use it as a featured image or in a gallery.
- **Look things up:** the [communities you can post in, service categories, job options and places](https://docs.urnextdoor.com/guides/lookups.md), so your tool never has to guess an id.
- **See what happened:** every key's activity shows up in [Settings > Analytics](https://docs.urnextdoor.com/analytics.md).

## Quickstart in three steps

1. **Create a key.** Sign in at urnextdoor.com, open **Settings > API keys**, create a key and copy it. It is shown only once. [Step by step](https://docs.urnextdoor.com/getting-started/create-api-key.md).
2. **Store it in an environment variable** named `UND_API_KEY`, so it never ends up in your code:

```bash
   # macOS or Linux: paste the key when asked. It is not shown or saved in your history.
   read -rs UND_API_KEY && export UND_API_KEY
   ```

3. **Make a request.** Check who the key belongs to:

**cURL**

```bash
curl "https://urnextdoor.com/api/v1/me" \
  -H "Authorization: Bearer $UND_API_KEY"
```

**JavaScript**

```js
const res = await fetch("https://urnextdoor.com/api/v1/me", {
  headers: {
    Authorization: `Bearer ${process.env.UND_API_KEY}`,
  },
});
console.log(res.status, await res.json());
```

**Python**

```python
import os

import requests

api_key = os.environ["UND_API_KEY"]

response = requests.get(
    "https://urnextdoor.com/api/v1/me",
    headers={
        "Authorization": f"Bearer {api_key}",
    },
    timeout=30,
)
print(response.status_code, response.json())
```

**PHP**

```php
<?php
$apiKey = getenv('UND_API_KEY');

$ch = curl_init('https://urnextdoor.com/api/v1/me');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . $apiKey,
    ],
]);
$body = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);

echo $status, PHP_EOL, $body, PHP_EOL;
```

Sample response: `200 OK`

```json
{
  "ok": true,
  "user": {
    "id": 7,
    "username": "aarav",
    "display_name": "Aarav",
    "plan": "free",
    "profile_url": "https://urnextdoor.com/users/aarav"
  },
  "key": {
    "id": 3,
    "name": "Claude Code",
    "prefix": "und_sk_7Hq2x",
    "scopes": [
      "content",
      "media",
      "schedule",
      "read"
    ],
    "created_at": "2026-10-15T09:00:00Z",
    "expires_at": "2027-01-13T09:00:00Z"
  },
  "request_id": "9f8e7d6c5b4a3921"
}
```

Then [create your first post](https://docs.urnextdoor.com/getting-started/first-request.md).

## Choose your path

- [Use it with an AI agent](https://docs.urnextdoor.com/ai.md): Claude Code, Codex CLI and ChatGPT custom GPTs, with a ready system prompt.
- [Automate it without code](https://docs.urnextdoor.com/integrations.md): Postman, n8n, Zapier, or plain cURL on the command line.
- [Follow a guide](https://docs.urnextdoor.com/guides.md): step by step pages for every content type, images and scheduling.
- [Browse the reference](https://docs.urnextdoor.com/reference.md): every endpoint, field, response and error, generated from the OpenAPI document.

## The essentials

| Item | Value |
| --- | --- |
| Base URL | `https://urnextdoor.com/api/v1` |
| Authentication | `Authorization: Bearer und_sk_...` or `X-API-Key: und_sk_...` |
| Request bodies | JSON. Content bodies are HTML. |
| Times | ISO 8601 with an offset or `Z`. Scheduling stores UTC. |
| Limits | A daily quota per action and plan, plus 60 requests a minute. See [limits](https://docs.urnextdoor.com/limits.md). |
| Machine readable contract | [OpenAPI 3.1](https://docs.urnextdoor.com/reference/openapi.md), also at `https://urnextdoor.com/api/v1/openapi.json` |
| Browsers | Not supported. The API sends no CORS headers, because a key in a web page leaks. |

## Frequently asked questions

### Who can use the API?

Any active Ur Next Door member can create API keys, on any plan, including Free. Your plan sets your [daily quotas](https://docs.urnextdoor.com/limits.md).

### Can I read, edit or delete my published posts with the API?

Not yet. Version 1 creates content, uploads images and manages scheduled items. Endpoints to read, update and delete published content are on the roadmap.

### Does it work with Claude Desktop or claude.ai?

Not directly. Those apps need an MCP server to call an API, and an official Ur Next Door MCP server is on the roadmap. Today, use Claude Code, Codex CLI or a ChatGPT custom GPT. See [Claude Desktop](https://docs.urnextdoor.com/ai/claude-desktop.md).

### Where can I see what my keys did?

Open Settings > Analytics on the website or in the app. It shows manual and API activity side by side, per key, with a full event log and a CSV export. See [API analytics](https://docs.urnextdoor.com/analytics.md).
