GET/api/v4/locations/{locationId}/bulk-posts

获取某个地点的批量帖子

返回一页包含指定地点的批量(多地点)帖子营销活动。

需要 API 密钥。请求头格式和密钥轮换请参阅身份验证。

参数

路径

名称类型必填描述
locationIdstring必填Base64-encoded location cursor / global ID (e.g. `TG9jYXRpb246MTgwMDI4OQ==`). Pass it unchanged, do not URL-encode it. The base64 cursor always resolves; the raw numeric database ID also works on this endpoint, but the base64 form is the portable choice across the API.

查询

名称类型必填描述默认值
pageinteger可选1-based page number for offset pagination.1
perPageinteger可选Number of records per page.—
filtersstring可选JSON-encoded SocialPostFiltersInput (e.g. by `type`, `status`, `creationDateRange`, `siteUrls`).—
sortFieldsstring可选JSON-encoded sort object `{ "field": "created_at", "order": "Descending" }`. `field` is one of name, type, status, created_at, schedule_start_date, schedule_end_date, client_name, clicks, views, shares.—
locationIdsstring可选JSON-encoded array of location IDs to include alongside the path location.—
componentIdentifierstring可选Filter to campaigns created by a specific component/integration.—

响应

200A page of bulk campaigns that include the location. `records` is empty when no bulk campaign has targeted it.
Response
{  "data": {    "rollupSocialPosts": {      "records": [        {          "id": "U29jaWFsUG9zdDo1MTA4OA==",          "name": "Diwali Offer - All Stores",          "status": "SUCCESS",          "type": "OFFER",          "createdAt": "2026-06-20",          "scheduledStartDate": "2026-06-22",          "scheduledEndDate": "2026-07-06",          "views": 4210,          "clicks": 318,          "shares": 12,          "reactions": 87,          "comments": 4,          "sites": ["GOOGLE", "FACEBOOK"],          "message": [            { "site": "GOOGLE", "message": "Festive savings across all our stores this week." },            { "site": "FACEBOOK", "message": "Festive savings across all our stores this week!" }          ],          "cta": [            { "type": { "value": "GET_OFFER", "label": "Get offer" }, "url": "https://jennyhome.example/diwali", "site": "GOOGLE", "tinyUrl": "https://tiny.cc/jh-diwali" }          ],          "contextInfo": {            "couponCode": "DIWALI25",            "redeemUrl": "https://jennyhome.example/diwali",            "termsConditions": "Valid in-store only. Cannot be combined with other offers.",            "title": "25% off storewide",            "discount": "25%",            "startDay": "2026-06-22",            "endDay": "2026-07-06"          },          "mediaUrl": [            { "url": "https://cdn.listingsapi.com/posts/51088/diwali.jpg", "site": "GOOGLE", "type": "IMAGE" }          ],          "publishDetails": [            { "site": "GOOGLE", "status": "PUBLISHED", "createdDate": "2026-06-20", "publishedDate": "2026-06-22", "submissionError": null },            { "site": "FACEBOOK", "status": "PUBLISHED", "createdDate": "2026-06-20", "publishedDate": "2026-06-22", "submissionError": null }          ],          "postLinks": [            { "site": "GOOGLE", "link": "https://www.google.com/maps/place/?post=51088" }          ],          "locationIds": [1800289, 1800290, 1800291],          "clientName": "Jenny Home"        }      ],      "locationDetails": [        {          "id": "TG9jYXRpb246MTgwMDI4OQ==",          "name": "Jenny Home",          "street": "600 Congress Ave, Suite 200",          "city": "Austin",          "postalCode": "78701",          "countryIso": "US",          "stateIso": "TX",          "stateName": "Texas",          "storeId": null        }      ],      "pageInfo": {        "totalPages": 1,        "hasNextPage": false,        "hasPreviousPage": false,        "totalRecords": 1      }    }  }}
401Unauthenticated, missing or invalid API key.
429Rate limit exceeded. Retry after the `Retry-After` header value.

批量帖子是同时发布到多个地点的单个营销活动(通过 POST /bulk-posts 创建)。此端点列出包含指定地点的批量营销活动,方便您从单个门店的角度查看多门店汇总。响应结构与 GET /locations/{locationId}/posts 完全相同;此处的记录只是涵盖了多个 locationIds。

使用场景:核对整个连锁门店的发布情况。 在所有门店推出“排灯节优惠”活动后,从任意一家门店调用 GET /locations/1800289/bulk-posts,确认该营销活动已发布到该门店,检查共享的 contextInfo(优惠码、折扣、条款),并读取各站点的 publishDetails,以发现该地点上的 FACEBOOK submissionError。

注意事项。

  • 与单地点列表相同:通过 page/perPage 按偏移量分页,sortFields 是单个对象(不是数组),频繁轮询可能会返回 HTTP 429。
  • 每条记录中的 locationIds 是该营销活动目标地点的完整集合,其中会包含路径中指定的 ID 以外的其他 ID。

上面的 records 数组仅作示例。线上的示例地点(Jenny Home)没有批量营销活动,因此实际调用会返回 records: [] 和 pageInfo.totalRecords: 0。

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