> ## Documentation Index
> Fetch the complete documentation index at: https://docs.morrowly.app/llms.txt
> Use this file to discover all available pages before exploring further.

# API 개요

> 기본 주소, 인증, 응답 모양, 오류

<CardGroup cols={2}>
  <Card title="기본 주소" icon="globe">
    `https://api.morrowly.app/v1`
  </Card>

  <Card title="인증" icon="key" href="/authentication">
    `Authorization: Bearer` 헤더에 **API 토큰**
  </Card>
</CardGroup>

## 인증

모든 요청에 토큰이 필요합니다. 토큰이 없거나 틀리거나 만료되면 401, 권한이 모자라면 403 입니다.

```bash theme={null}
curl https://api.morrowly.app/v1/finances \
  -H "Authorization: Bearer $MORROWLY_TOKEN"
```

## 응답 모양

성공하면 `result` 가 `SUCCESS` 이고 값은 `data` 에 있습니다.

```json theme={null}
{ "result": "SUCCESS", "data": { "…": "…" }, "error": null }
```

실패하면 `result` 가 `ERROR` 이고 `error` 에 코드와 문구가 있습니다.

```json theme={null}
{ "result": "ERROR", "data": null, "error": { "code": "E404", "message": "Not found.", "data": null } }
```

## 오류

| 상태 | 코드 | 뜻 |
| - | - | - |
| 400 | `E400` | 요청이 잘못됨. `error.data` 에 이유 |
| 401 | | 토큰이 없거나 틀리거나 만료됨(본문 없음) |
| 402 | `E402` | 요금제가 필요한 기능 |
| 403 | | 권한이 모자라거나 토큰으로 쓸 수 없는 경로(본문 없음) |
| 404 | `E404` | 없거나 이 가구의 것이 아님 |
| 412 | `E412` | 읽은 뒤 다른 곳에서 바뀜. 다시 읽고 고칩니다 |
| 429 | `E429` | 모로의 이번 달 사용 한도를 다 씀 |
| 503 | `E503` | 실거래가 서버 등 바깥 서비스에 닿지 못함. `error.data` 에 이유 |
| 500 | `E500` | 서버 오류 |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.