WhatsApp Phone Numbers

Get pricing analytics

Changed on

Message volume and approximate cost for one connected WhatsApp number, read live from Meta's pricing_analytics on the WhatsApp Business Account and scoped to that account's phone number. Meta's figures are approximate and can lag; Meta bills from its own invoice. Meta limits how far back and how fine the data goes (for example HALF_HOUR only over short ranges) and answers out-of-range requests with an error.

get/v1/whatsapp/pricing-analytics

Request

  • Base URL: https://zernio.com/api
  • URL: https://zernio.com/api/v1/whatsapp/pricing-analytics
  • Auth: HTTP bearer

Query parameters

accountIdstring required

WhatsApp account ID

startstring date-time required

Range start, ISO 8601 date or date-time.

endstring date-time required

Range end, ISO 8601 date or date-time. Must be after start.

granularity'HALF_HOUR' | 'DAILY' | 'MONTHLY' required

Size of each data point. Meta refuses MONTHLY when the range is too short for a monthly bucket (for example a range that starts at the beginning of the current month and ends today); that is a 400 with param: granularity and Meta's reason in error. Use DAILY for short or month-to-date ranges.

dimensionsstring
Example:PRICING_CATEGORY,COUNTRY

Comma-separated breakdowns: COUNTRY, PHONE, PRICING_CATEGORY, PRICING_TYPE, TIER. Without it each data point is a total for the interval.

metricTypesstring
Example:COST,VOLUME

Comma-separated: COST, VOLUME. Defaults to both.

pricingTypesstring
Example:REGULAR

Comma-separated filter: REGULAR, FREE_CUSTOMER_SERVICE, FREE_ENTRY_POINT.

pricingCategoriesstring
Example:MARKETING,UTILITY

Comma-separated filter of Meta pricing categories, for example MARKETING, MARKETING_LITE, UTILITY, AUTHENTICATION, AUTHENTICATION_INTERNATIONAL, SERVICE, REFERRAL_CONVERSION.

countryCodesstring
Example:ES,MX

Comma-separated ISO 3166-1 alpha-2 country codes to filter on.

Response

Pricing data points for the range

accountIdstring required
phoneNumberstring required

The number the data is scoped to, digits only.

granularity'HALF_HOUR' | 'DAILY' | 'MONTHLY' required
startstring date-time required
endstring date-time required

Changes

    • warning

      added the new account enum value to the / response property for the response status

    • warning

      added the new account enum value to the / response property for the response status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status