コンテンツブロック情報を参照
get
/content_blocks/info
このエンドポイントを使用して、既存のContent Blocks の情報を呼び出します。
前提条件
このエンドポイントを使用するには、content_blocks.info
権限を持つAPI キー が必要です。
レート制限
We apply the default Braze rate limit of 250,000 requests per hour to this endpoint, as documented in API rate limits.
要求パラメータ
パラメータ | 必須 | データ型 | 説明 |
---|---|---|---|
content_block_id |
Required | String | The Content Block identifier. これは、API コールでコンテンツブロック情報を一覧表示するか、API Keys ページに移動し、一番下までスクロールしてコンテンツブロックAPI 識別子を検索することで確認できます。 |
include_inclusion_data |
Optional | Boolean | true に設定すると、API は、このコンテンツブロックが含まれているキャンペーンおよびキャンバスのメッセージバリエーションAPI 識別子を返し、後続のコールで使用します。 アーカイブまたは削除されたキャンペーンまたはキャンバスは除外されます。 |
リクエスト例
1
2
curl --location -g --request GET 'https://rest.iad-01.braze.com/content_blocks/info?content_block_id={{content_block_id}}&include_inclusion_data=false' \
--header 'Authorization: Bearer YOUR-REST-API-KEY'
レスポンス
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Content-Type: application/json
Authorization: Bearer YOUR_REST_API_KEY
{
"content_block_id": (string) the Content Block identifier,
"name": (string) the name of the Content Block,
"content": (string) the content in the Content Block,
"description": (string) the Content Block description,
"content_type": (string) the content type, html or text,
"tags": (array) An array of tags formatted as strings,
"created_at": (string) The time the Content Block was created in ISO 8601,
"last_edited": (string) The time the Content Block was last edited in ISO 8601,
"inclusion_count" : (integer) the inclusion count,
"inclusion_data": (array) the inclusion data,
"message": "success",
}
トラブルシューティング
次の表に、返される可能性のあるエラーと関連するトラブルシューティング手順を示します。
エラー | トラブルシューティング |
---|---|
Content Block ID cannot be blank |
コンテンツブロックがリクエストにリストされ、引用符で囲まれていることを確認します("" )。 |
Content Block ID is invalid for this workspace |
このコンテンツブロックは存在しないか、別の会社アカウントまたはワークスペースにあります。 |
Content Block has been deleted—content not available |
このコンテンツブロックは以前に存在していたかもしれませんが、削除されました。 |
Include Inclusion Data—error |
このパラメータはブール値(true またはfalse) のみを受け入れます。include_inclusion_data の値が引用符で囲まれていないことを確認します("" )。この値は文字列として送信されます。詳細については、リクエストパラメータを参照してください。 |