掲示板の本文を取得する

目次

1件の掲示板の本文を取得する(2025年9月定期メンテナンス後より適用されます)

掲示板のIDを指定して、掲示板の本文を取得します。

URL

https://sample.cybozu.com/g/api/v1/bulletin/topics/TOPIC_ID

パスパラメーター
パラメーター名 説明
TOPIC_ID 取得する掲示板のID

HTTPメソッド

GET

利用できるバージョン

  • クラウド版Garoon

リクエスト

パラメーター

なし

リクエストの例
URL

https://sample.cybozu.com/g/api/v1/bulletin/topics/1

ヘッダー
1
2
3
{
  "X-Cybozu-Authorization": "QWRtaW5pc3RyYXRvcjpjeWJvenU="
}

リクエストヘッダーの詳細は Garoon REST APIの共通仕様 を参照してください。

レスポンス

プロパティ
プロパティ名 説明
id 文字列 掲示板のID
subject 文字列 掲示板のタイトル
creator オブジェクト 掲示板の作成者情報
creator.id 文字列 作成者のGaroonユーザーID
creator.name 文字列 作成者の表示名
creator.code 文字列 作成者のログイン名
updater オブジェクト 掲示板の更新者情報
updater.id 文字列 更新者のGaroonユーザーID
updater.name 文字列 更新者の表示名
updater.code 文字列 更新者のログイン名
manuallySender 文字列 直接入力された差出人名
createdAt 文字列 作成日時
updatedAt 文字列 更新日時
acknowledgement 真偽値 閲覧状況を確認するかどうか
  • true:閲覧状況を確認する
  • false:閲覧状況を確認しない
allowComments 真偽値 コメントの書き込みを許可するかどうか
  • true:コメントの書き込みを許可する
  • false:コメントの書き込みを許可しない
body 文字列 掲示板の本文
isHtmlBody 真偽値 掲示板の本文がHTML形式かどうか
  • true: HTML形式
  • false:プレーンテキスト
operatorType 文字列 掲示板の変更/削除の許可
  • ONLY_SENDER:差出人のみ
  • SELECT_USERS:許可したユーザー
operators 配列 掲示板の変更/削除が可能なユーザーの一覧
operators[].id 文字列 掲示板の変更/削除を許可されているGaroonユーザーID
operators[].name 文字列 掲示板の変更/削除を許可されているユーザーの表示名
operators[].code 文字列 掲示板の変更/削除を許可されているユーザーのログイン名
attachments 配列 添付ファイルの一覧
attachments[].id 文字列 添付ファイルのID
attachments[].name 文字列 添付ファイルの名前
attachments[].contentType 文字列 添付ファイルのコンテンツタイプ
attachments[].size 文字列 添付ファイルのサイズ
publicPeriod オブジェクト 掲示期間の情報
publicPeriod.isUnlimited 真偽値 掲示期間が指定されているかどうか
  • true:掲示期間が指定されていない
  • false:掲示期間が指定されている
publicPeriod.start 文字列 掲示開始日時
publicPeriod.end 文字列 掲示終了日時
isDraft 真偽値 下書きかどうか
  • true:下書き
  • false:下書きではない
isPublished 真偽値 掲示開始待ちかどうか
  • true:掲示開始済み
  • false:掲示開始済みではない
isExpired 真偽値 掲示期間切れかどうか
  • true:掲示期間切れ
  • false:掲示期間切れではない
category オブジェクト 掲示板が属するカテゴリー情報
category.id 文字列 カテゴリーID
category.name 文字列 カテゴリー名
レスポンスの例
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
{
    "id": "8",
    "subject": "subject of new topic",
    "category": {
        "id": "2",
        "name": "cat1"
    },
    "publicPeriod": {
        "isUnlimited": false,
        "start": "2025-06-05T08:30:00Z",
        "end": "2025-06-11T08:45:00Z"
    },
    "createdAt": "2025-06-05T08:24:39Z",
    "creator": {
        "id": "1",
        "code": "Administrator",
        "name": "Administrator"
    },
    "updatedAt": "2025-06-05T08:24:39Z",
    "updater": {
        "id": "1",
        "code": "Administrator",
        "name": "Administrator"
    },
    "body": "<div><strong>body is HTML</strong></div>",
    "isHtmlBody": true,
    "allowComments": true,
    "operatorType": "SELECT_USERS",
    "operators": [
        {
            "id": "2",
            "code": "user1",
            "name": "user1"
        },
        {
            "id": "3",
            "code": "vinh1",
            "name": "vinh1"
        }
    ],
    "acknowledgement": false,
    "attachments": [
        {
            "id": "1",
            "contentType": "text/plain",
            "name": "test1.txt",
            "size": "4089"
        },
        {
            "id": "2",
            "contentType": "text/plain",
            "name": "test2.txt",
            "size": "4089"
        }
    ],
  "isDraft":false,
  "isPublished": true,
  "isExpired":false
}

サンプルコード

curlを使ったリクエスト

ご利用の環境によって、curlのフォーマットは異なる場合があります。
詳細は、次のページを参照してください。
curlコマンドでkintone REST APIを実行してみよう/3.API実行

1
2
curl -X GET 'https://sample.cybozu.com/g/api/v1/bulletin/topics/1' \
  -H 'X-Cybozu-Authorization: QWRtaW5pc3RyYXRvcjpjeWJvenU='
Garoon REST APIリクエストを送信するAPI を使ったリクエスト
1
await garoon.api('/api/v1/bulletin/topics/1', 'GET', {});