Graph API-Version

WhatsApp Business Account

Represents phone numbers that belong to a specific WhatsApp Business Account (WABA).

Die ID eines WhatsApp Business-Kontos findest du unter Business Manager > Unternehmenseinstellungen > Konten > WhatsApp Business-Konten. Suche dort nach dem Konto, das zu verwenden möchtest, und klicke darauf. Es wird eine Ansicht mit Informationen zum Konto angezeigt, einschließlich der ID.

For more information on how to use the API, see WhatsApp Business Management API.

The following API calls are subject to Business Use Case Rate Limits:

  • GET, POST, and DELETE calls to /{whats-app-business-account-id}/assigned_users
  • GET calls to /{whats-app-business-account-id}

Wird gelesen

Returns the account information of a WhatsApp Business Account

Example

Requirements

  • whatsapp_business_management permission

  • whatsapp_business_messaging permission

  • public_profile permission

  • WhatsApp Business Account (WABA) ID

  • USER ACCESS TOKEN

Request

curl -i -X GET \
 "https://graph.facebook.com/LATEST-VERSION/WHATSAPP-BUSINESS-ACCOUNT-ID?access_token=USER-ACCESS-TOKEN"
GraphRequest request = GraphRequest.newGraphPathRequest(
  accessToken,
  "/WHATSAPP-BUSINESS-ACCOUNT-ID",
  new GraphRequest.Callback() {
    @Override
    public void onCompleted(GraphResponse response) {
      // Insert your code here
    }
});

request.executeAsync();
FBSDKGraphRequest *request = [[FBSDKGraphRequest alloc]
    initWithGraphPath:@"/WHATSAPP-BUSINESS-ACCOUNT-ID"
           parameters:nil
           HTTPMethod:@"GET"];
[request startWithCompletionHandler:^(FBSDKGraphRequestConnection *connection, id result, NSError *error) {
    // Insert your code here
}];

Response

{
  "id": "WHATSAPP-BUSINESS-ACCOUNT-ID",
  "name": "Test WhatsApp Business Account",
  "timezone_id": "1",
  "message_template_namespace": "MESSAGE-TEMPLATE-NAMESPACE"
}

Parameter

Dieser Endpunkt hat keine Parameter.

Felder

FeldBeschreibung
analytics

Used to designate which analytics metrics you want returned. See Analytics.

business_verification_status
enum {expired, failed, ineligible, not_verified, pending, pending_need_more_info, pending_submission, rejected, revoked, verified}

Current status of business verification of Meta Business Account which owns this WhatsApp Business Account

country
string

country of the WhatsApp Business Account's owning Meta Business account

currency
string

The currency in which the payment transactions for the WhatsApp Business Account will be processed

health_status
WhatsAppBusinessHealthStatusForMessageSend

Health status of the WABA in regards to whether the WABA, Business, and App can send a message

is_enabled_for_insights
bool

If true, indicates the WhatsApp Business Account enabled template analytics. See Analytics.

is_shared_with_partners
bool

is_shared_with_partners

marketing_messages_lite_api_status
enum

WhatsApp Business Account's status for onboarding onto Marketing Messages Lite.

Values can be:

INELIGIBLE — Indicates the WABA has not met all eligibility requirements.

ELIGIBLE— Indicates WABA has met all eligibility requirements

ONBOARDED — Indicates the WABA is eligible to use MM Lite API and:

  • the owning business has signed MM Lite Terms of Service
  • the WABA has a valid payment method attached
  • the WABA is linked to an Ad account

UNKNOWN— Indicates an unknown status. Please contact support for assistance.

marketing_messages_onboarding_status
enum

Onboarding status of the WhatsApp Business account into Marketing Messages Lite API.

Values can be:

INELIGIBLE_ON_BEHALF_OF_WABA — The WhatsApp Business Account (“WABA”) uses the “OBO” model which is not supported. You must either first transfer ownership of the WABA to the customer or onboard using the Intent API.

INELIGIBLE_INACTIVE_OR_RESTRICTED — The WhatsApp Business Account is inactive or is restricted from messaging due to a policy enforcement issue.

INELIGIBLE_COUNTRY_NOT_SUPPORTED — The WhatsApp Business Account is in a region that does not support the MM Lite API.

INELIGIBLE_USING_WHATSAPP_BUSINESS_APP — The WhatsApp Business phone number is being used within the WhatsApp Business app.

ELIGIBLE — WhatsApp Business Account is eligible to onboard and use the MM Lite API.

PENDING_VALID_PAYMENT_METHOD — The WhatsApp Business Account requires setting up a valid payment method.

PENDING_INTERNAL_SETUP — WhatsApp Business Account is in the configuration process of using the MM Lite API and requires no further action from the business customer or partner.

The automated setup process is estimated to take less than ten minutes. Subscribe to the account_update webhook and listen for the AD_ACCOUNT_LINKED event.

Submit a support ticket if the setup process takes more than ten minutes and you have not received a webhook.

ONBOARDED — The WhatsApp Business Account has successfully onboarded and is ready to use the MM Lite API.

message_template_namespace
string

Namespace string for the message templates that belong to the WhatsApp Business Account

name
string

User-friendly name to differentiate WhatsApp Business Accounts

on_behalf_of_business_info
WABAOnBehalfOfComputedInfo

The "on behalf of" information for the WhatsApp Business Account

ownership_type
enum

Ownership type of the WhatsApp Business Account

primary_funding_id
numeric string

Primary funding ID for the WhatsApp Business Account paid service

purchase_order_number
string

The purchase order number supplied by the business for payment management purposes

status
string

WhatsApp Business Account status. Default: ACTIVE

timezone_id
string

The timezone of the WhatsApp Business Account

whatsapp_business_manager_messaging_limit
enum {TIER_100K, TIER_10K, TIER_250, TIER_2K, TIER_UNLIMITED, UNTIERED}

Maximum number of unique WhatsApp user phone numbers that your Business Manager account can message, outside of a customer service window, within a moving 24-hour period. This limit is shared across all WhatsApp phone numbers owned by your business.

Edges

EdgeBeschreibung
Edge<WhatsAppBusinessActivityHistory>

activities

Edge<WABACallAnalytics>

Analytics data of the WhatsApp Business Account for calling

Edge<WABAConversationAnalytics>

Analytics data of the WhatsApp Business Account with conversation based pricing

Edge<Dataset>

ID of the dataset

Edge<WhatsAppBusinessAccountMessageTemplatePreview>

Retrieves a preview of a message template based on the provided configuration

Edge<WhatsAppBusinessHSM>

Message templates that belong to the WhatsApp Business Account

Edge<WhatsAppBusinessAccountPaymentConfiguration>

Fetch payment configuration attached to the WhatsApp Business Account.

Edge<WhatsAppBusinessAccountPaymentConfigurations>

Fetch all payment configurations attached to the WhatsApp Business Account.

Edge<WhatsAppBusinessAccountToNumberCurrentStatus>

The phone numbers that belong to the WhatsApp Business Account

Edge<WABAPricingAnalytics>

Pricing analytics data of the WhatsApp Business Account with per message pricing

Edge<ProductCatalog>

product_catalogs

Edge<WhatsAppBusinessSolution>

Partner solutions that this WhatsApp Business Account is linked to

Edge<WhatsAppApplication>

List of apps that are subscribed to webhooks updates for this WABA

Edge<BusinessMessagingTemplateGroup>

Retrieve list of existing template groups associated with WhatsApp Business Account

Edge<WhatsAppBusinessHSMWhatsAppBusinessPerformanceMetrics>

template_performance_metrics

Error Codes

FehlerBeschreibung
80008There have been too many calls to this WhatsApp Business account. Wait a bit and try again. For more info, please refer to https://developers.facebook.com/docs/graph-api/overview/rate-limiting.
200008WhatsApp Business Account has no linked phone numbers.
100Invalid parameter
200Permissions error
2500Error parsing graph query
131031Business Account locked
190Invalid OAuth 2.0 Access Token
131000Something went wrong
200005Template Insights are not available yet for this WhatsApp Business account

Wird erstellt

Diese Handlung kann auf diesem Endpunkt nicht durchgeführt werden.

Wird aktualisiert

You can update a WhatsAppBusinessAccount by making a POST request to /{whats_app_business_account_id}/assigned_users.

Parameter

ParameterBeschreibung
tasks
array<enum {MANAGE, DEVELOP, MANAGE_TEMPLATES, MANAGE_PHONE, VIEW_COST, MANAGE_EXTENSIONS, VIEW_PHONE_ASSETS, MANAGE_PHONE_ASSETS, VIEW_TEMPLATES, MESSAGING}>

Permissions on WhatsApp Business Account

erforderlich
user
UID

Business user ID

erforderlich

Rückgabetyp

This endpoint supports read-after-write and will read the node to which you POSTed.
Struct {
success: bool,
}

Error Codes

FehlerBeschreibung
100Invalid parameter
200Permissions error
80008There have been too many calls to this WhatsApp Business account. Wait a bit and try again. For more info, please refer to https://developers.facebook.com/docs/graph-api/overview/rate-limiting.

Wird gelöscht

You can dissociate a WhatsAppBusinessAccount from a WhatsAppBusinessAccount by making a DELETE request to /{whats_app_business_account_id}/assigned_users.

Parameter

ParameterBeschreibung
user
UID

Business user ID

erforderlich

Rückgabetyp

Struct {
success: bool,
}

Error Codes

FehlerBeschreibung
100Invalid parameter

Supported values

Currencies

Supported values for currency codes can be found in currencies.

Time Zones

Supported values for time zones can be found in timezone ids.