BrandApp Playground

Tags

Brand 범위에서 사용된 태그와 사용 건수를 받는다. 태그 페이지(/blog/tag/[tag])나 태그 클라우드 빌드에 사용. tags.list는 SDK 1.8에서 추가됐다.

Loading...

data/tags.ts
import { createReoptSDK } from "@reopt-ai/brandapp-sdk";

const sdk = createReoptSDK({ /* ... */ });

// Brand 범위 내 사용된 태그 + 사용 건수
const tags = await sdk.cms.tags.list();
// → [{ id: "tag:launch", text: "launch", postCount: 12 }, ...]

// 특정 그룹으로 좁힘 — v2.1+ 신규 코드는 groupSlug 권장
const blogTags = await sdk.cms.tags.list({ groupId: blogId });
const blogTagsBySlug = await sdk.cms.tags.list({ groupSlug: "blog" });