GET/api/v4/posts/{postId}

投稿を取得

単一のソーシャル投稿キャンペーンを、そのコンテンツ、サイトごとの公開ステータス、エンゲージメント分析とともに返します。

API キーが必要です。ヘッダーの形式とキーのローテーションについては認証を参照してください。

パラメーター

パス

名前型必須説明
postIdstring必須Base64-encoded social post ID (e.g. from the `id` field of a posts list, or the `socialPost.id` returned by POST /posts).

レスポンス

200The post's content, publish details, and analytics.
Response
{  "data": {    "socialPostView": {      "socialPostId": "U29jaWFsUG9zdDo0NDEyMg==",      "socialPostInfo": {        "id": "U29jaWFsUG9zdDo0NDEyMg==",        "name": "Summer Hours Update",        "status": "SUCCESS",        "type": "ANNOUNCEMENT",        "createdAt": "2026-06-28",        "scheduledStartDate": "2026-06-28",        "scheduledEndDate": "2026-07-28",        "views": 128,        "clicks": 14,        "shares": 0,        "reactions": 3,        "comments": 1,        "sites": ["GOOGLE"],        "message": [          { "site": "GOOGLE", "message": "We have extended our summer hours! Open until 9pm on weekdays." }        ],        "cta": [          { "type": { "value": "LEARN_MORE", "label": "Learn more" }, "url": "https://jennyhome.example/hours", "site": "GOOGLE", "tinyUrl": "https://tiny.cc/jh-hours" }        ],        "contextInfo": null,        "mediaUrl": [          { "url": "https://cdn.listingsapi.com/posts/44122/summer.jpg", "site": "GOOGLE", "type": "IMAGE" }        ],        "publishDetails": [          { "site": "GOOGLE", "status": "PUBLISHED", "createdDate": "2026-06-28", "publishedDate": "2026-06-28", "submissionError": null }        ],        "postLinks": [          { "site": "GOOGLE", "link": "https://www.google.com/maps/place/?post=44122" }        ],        "locationIds": [1800289]      },      "publishedLocationsCount": 1,      "socialPostAnalyticsBySite": [        { "site": "GOOGLE", "views": 128, "clicks": 14, "reactions": 3, "shares": 0, "comments": 1 }      ],      "socialPostAnalyticsByLocationId": [        {          "locationId": 1800289,          "siteStats": [            { "site": "GOOGLE", "status": "PUBLISHED", "views": 128, "clicks": 14, "reactions": 3, "shares": 0, "comments": 1 }          ]        }      ]    }  }}
401Unauthenticated, missing or invalid API key.

ID を指定して 1 件の投稿キャンペーンを取得します。サイトごとのメッセージと CTA、添付メディア、各サイトの現在の公開ステータス(publishDetails)、およびサイト別(socialPostAnalyticsBySite)と拠点別(socialPostAnalyticsByLocationId)の両方のエンゲージメント内訳が含まれます。

ユースケース:公開後の確認。 POST /posts でお知らせを作成した直後に、返された socialPost.id を使用して、socialPostInfo.status が INPROGRESS から SUCCESS に変わるまで GET /posts/{postId} をポーリングします。サイトへの公開に失敗した場合、publishDetails[].submissionError に理由が格納され、publishDetails[].status に ERROR が表示されます。

ユースケース:エンゲージメントダッシュボード。 単一拠点の投稿では、socialPostAnalyticsBySite を読み取ることで、拠点全体の投稿一覧を再取得せずに、Google と Facebook の閲覧数とクリック数の比較を表示できます。

注意事項。

  • postId は Base64 でエンコードされた ID であり、投稿一覧 では id として、作成時のレスポンスでは socialPost.id として示されます。エンコードされていない整数ではありません。
  • 複数拠点の一括キャンペーンを取得するには、GET /bulk-posts/{postId} を使用します。publishedLocationsCount > 1 を含む同じ構造のデータが返されます。

この例は API スキーマをもとに作成されています。実環境のシードアカウント(Jenny Home)には投稿がないため、取得に使用できる実際の投稿 ID はありませんでした。不明または無効な ID を指定すると、{"data":null,"errors":[{"message":"An error occurred processing your request."}]} が返されます。

Request
curl -X GET 'https://listingsapi.com/api/v4/posts/<postId>' \  -H "Authorization: API $LISTINGSAPI_KEY"