---
title: "12 Palaces"
method: POST
path: "/ziwei/twelve-palaces"
tags: ["Zi Wei Dou Shu (Purple Star): MVP"]
---

# 12 Palaces

`POST /ziwei/twelve-palaces`

All 12 palaces with English/pinyin/Chinese names + theme + rules.

## Request body

- ZiweiDateInput
  - `date` string, required
  - `time` string
  - `timezoneOffset` number

## Response `200`

Successful calculation

- object
  - `ok` boolean
  - `data` object
    - `solarYear` number, nullable
    - `animal` string, nullable
    - `palaces` object[], nullable
      - `key` string, nullable
      - `english` string, nullable
      - `pinyin` string, nullable
      - `chinese` string, nullable
      - `theme` string, nullable
      - `rules` string[], nullable
      - `governingAnimal` string, nullable
    - `disclaimer` string, nullable

## Other responses

- `400` — Validation error
- `401` — Missing or invalid API key

## Changes

- **2026-08-24** `8ab5a768b521` — 2 breaking, 4 info
  - the response property `data/palaces/items/rules/items/` became nullable for the status `200`
  - the `data/palaces/items/rules/items/` response's property type/format changed from ``/`` to `string`/`` for status `200`
  - added the optional property `data/animal` to the response with the `200` status
  - added the optional property `data/disclaimer` to the response with the `200` status
  - …2 more
- **2026-08-22** `5a17388652f3` — 1 breaking, 2 info
  - added the new required request property `date`
  - added the new optional request property `time`
  - added the new optional request property `timezoneOffset`
- **2026-08-14** `994755209cea` — 2 info
  - api tag `Zi Wei Dou Shu (Purple Star): MVP` added
  - api tag `Zi Wei Dou Shu (Purple Star) — MVP` removed

[Change history](https://skmtc.dev/astroway/apis/astroway-calculation-api/changes/ziwei/twelve-palaces/post.md)

---

[API](https://skmtc.dev/astroway/apis/astroway-calculation-api.md) · [All operations](https://skmtc.dev/astroway/apis/astroway-calculation-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/astroway/astroway-calculation-api/revisions/8ab5a768b521/schema)
