Broadcasts

Preview an audience

Sizes a broadcast without sending it. The dashboard shows this before the confirm button, and an API caller needs the same safety rail.

curl "https://api.subscriby.net/v1/projects/$PROJECT_ID/broadcasts/preview?audience=customer&plan_id=$PLAN_ID" \
  -H "Authorization: Bearer $SUBSCRIBY_TOKEN"

The preview accepts the same audience, pass_window_id, plan_id and expiring_within_days as the send, and applies them identically, segments, plan narrowing and recipient rules alike, so a preview and the send it precedes can never describe different audiences. The fields answer the same as the send's, minus status.

get/v1/projects/{project}/broadcasts/preview

Request

  • Base URL: https://api.subscriby.net
  • URL: https://api.subscriby.net/v1/projects/{project}/broadcasts/preview
  • Auth: HTTP bearer

Path parameters

projectstring uuid required

The project, resolved by the route binder.

Query parameters

audiencestring

The segment to size: all (the default), customer, trialing, lead, churned, expiring_soon, cancelled_still_active, paused, trialing_cardless, all_pass_holders, all_pass_holders_not_in_queue, pass_holders or pass_holders_not_in_queue. An unknown value is 422 with reason: unknown_audience and the supported list.

pass_window_idstring uuid

The access window for pass_holders and pass_holders_not_in_queue; ignored by every other segment.

plan_idstring uuid

Narrow the segment to members whose subscription is on this plan. Refused for lead and the pass segments with reason: plan_filter_unsupported; a plan of another project is reason: unknown_plan.

expiring_within_daysinteger

The horizon expiring_soon counts within, 1 to 90; a value outside the range clamps. Defaults to 7. Read by no other segment.

Response

The recipient count and ETA for the segment as described.

Example response

{
  "data": {
    "project_id": "7f3d1c92-8b45-4e6a-9d21-5c8e0a4b6f13",
    "audience": "customer",
    "plan_id": "c4e82f16-93a7-4d5b-b81c-6e0f27a94d3b",
    "recipient_estimate": 41,
    "estimated_seconds": 2
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.