hosting

GET /v1/sites

List sites in scope.

จุดสิ้นสุด hosting ทั้งหมด

การยืนยันตัวตน

ส่ง API key เป็น bearer token เอนด์พอยต์นี้ไม่ได้ระบุสิทธิ์การใช้งานเฉพาะในข้อกำหนด ดังนั้นควรให้คีย์ของคุณมีสิทธิ์น้อยที่สุดเท่าที่จำเป็นและให้ตรวจสอบจากการตอบกลับแทนที่จะคาดเดา

ตำแหน่งสำหรับใส่รหัสองค์กรของคุณ

พอยต์ข้อมูลนี้รับ org_id เป็นพารามิเตอร์คิวรี หากเว้นว่างไว้ การเรียกใช้งานจะครอบคลุมย่อยของเทแนนท์ทั้งหมดของคุณ แต่หากระบุค่า จะช่วยจำกัดขอบเขตการเรียกให้เหลือเพียงองค์กรเดียว

รหัสองค์กรของคุณจะแสดงอยู่บนหน้าคีย์ API ในแดชบอร์ดของคุณ โดยอยู่ถัดจากคีย์นั้นๆ รหัสนี้จะเป็นรหัสเดิมในการเรียกใช้งานทุกครั้งของคุณ

ทดลองใช้เลย

แทนที่สิ่งใดๆ ที่อยู่ภายในวงเล็บแหลมด้วยค่าของคุณเอง และตัวยึดตำแหน่งคีย์ด้วยคีย์จากแดชบอร์ดของคุณ

curl -X GET https://api.zinndigital.com/v1/sites \
  -H "Authorization: Bearer zdk_live_…"

เข้าสู่ระบบแล้วใช่ไหม คอนโซล API ในแดชบอร์ดของคุณจะเติมรหัสองค์กรจริงและคีย์ของคุณเองโดยอัตโนมัติ และทำการส่งคำขอไปยัง API จริง เพื่อให้คุณเห็นผลลัพธ์ที่เป็นข้อมูลจริง เปิดจุดสิ้นสุดนี้ในคอนโซล API

รายละเอียด

Lists the sites the principal can view across its tenancy subtree. Cursor-paginated. RLS guarantees no site outside the principal's subtree is ever returned (CLAUDE.md §2.3). Sites with status `deleted` are **not** listed by default — they are a terminal state with their own endpoint, `GET /v1/sites/deleted`, which also reports how long each one stays recoverable. Pass `status=deleted` explicitly to list them here. Every other status, including `deleting`, is listed as normal.

พารามิเตอร์

ชื่อประเภทจำเป็นต้องมีลักษณะของสิ่งนี้
X-Zinn-Org (header)stringไม่ใช่**Which organisation this call acts for.** Send a client organisation's id and every org-scoped endpoint answers for that client alone; omit it and the answer covers everything…
cursor (query)stringไม่ใช่Opaque cursor from a previous page's `page.next_cursor`.
limit (query)integerไม่ใช่Maximum items to return (page size).
org_id (query)Uuidไม่ใช่Restrict to one organization in scope (default — the whole subtree).
status (query)SiteStatusไม่ใช่Filter by site lifecycle status. Omitted, every status except `deleted` is returned; pass `deleted` to list deleted sites here rather than at `GET /v1/sites/deleted`.
product_line (query)stringไม่ใช่Filter by product line code (e.g. `footprint_free`, `mainstream`).
group (query)stringไม่ใช่Restrict to the sites in one site group (#2729). A group id belonging to another tenant matches nothing and returns an empty page rather than a 404 — the queryset is already nar…
search (query)stringไม่ใช่Case-insensitive substring match on the site's primary domain or its name. Applied in the database across the whole collection in scope — not to the page already fetched — so a…
ordering (query)string<domain, -domain, name, -name, status, -status, line, -line, stack, -stack, region, -region, plan, -plan, created, -created, authority, -authority, indexed, -indexed>ไม่ใช่Sort key, optionally `-`-prefixed for descending. Defaults to `-created` (newest first). Sorting is applied across the whole collection and the cursor carries the sort position,…

การตอบกลับ

ชื่อประเภทจำเป็นต้องมีลักษณะของสิ่งนี้
dataSite[]ใช่
pagePageMetaใช่

ข้อผิดพลาดที่เอนด์พอยต์นี้สามารถส่งกลับได้

401 · 403 · 422 · 429