Ellipse Gradient for Header

WhatsApp Business Platform Integration Guide

Connect enterprise applications with WhatsApp messaging through Meta’s Graph API, webhooks, media services, and business-account APIs.

WhatsApp Business Platform integration options at a glance

WhatsApp Business Platform is primarily an API-led, event-driven integration surface. The WhatsApp Cloud API and WhatsApp Business Management API use Meta’s REST-style Graph API for messaging, media, templates, phone numbers, and selected business-account operations. Webhooks deliver inbound messages and selected sent, delivered, read, and failed status notifications. Martini can consume these APIs, expose a webhook receiver, validate signatures, transform JSON payloads, and orchestrate downstream workflows. Access tokens, permissions, business asset identifiers, and webhook verification settings are stored securely. Scheduled workflows can reconcile selected management or reporting data, while controlled processing handles media and message responses without assuming a general-purpose bulk-messaging API.

Integration pointSupported by WhatsApp Business Platform?Common use casesHow Martini supports it
REST-style Graph APIYesThe WhatsApp Cloud API sends text, media, interactive, location, contact, reaction, and template messages. The WhatsApp Business Management API supports selected WABA, phone number, template, and business-configuration operations.Martini can consume the Meta Graph API through REST requests, parameterize phone number and WABA identifiers, map request payloads, and process response and error data.
Webhooks / outbound callbacksYesWebhooks deliver inbound text and media messages plus selected sent, delivered, read, failed, and error notifications. Coverage is not universal across administrative or business-account operations.Martini can expose a REST endpoint, handle Meta’s verification challenge, validate X-Hub-Signature-256 where applicable, parse JSON, and invoke asynchronous workflows.
File / attachment APIsYesThe Media API supports uploading, retrieving metadata or download URLs, and deleting images, audio, video, documents, and stickers associated with messages.Martini can retrieve media metadata or files, validate type and size, transform or route content, and store it in an approved downstream repository.
AuthenticationYesRequests use Meta access tokens, commonly system-user tokens for production, together with WhatsApp permissions and WABA, phone number, and app configuration.Martini stores tokens, app secrets, and webhook verification tokens in secure environment configuration and applies authenticated REST requests without embedding credentials in workflows.
Template management APIsYesBusiness applications can create, update, review, and use approved Message Templates through relevant WhatsApp Business Management API capabilities.Martini can retrieve or reference template configuration, validate names and parameters, apply business rules, and submit compliant template messages.
Batch / async / multi-request processingLimitedMeta Graph API supports some multi-request patterns, but WhatsApp does not provide a general unrestricted bulk-messaging API. Individual message submission remains subject to policies, throughput, and recipient controls.Martini can orchestrate controlled batches with bounded concurrency, rate limiting, correlation, retry handling, and failure reporting where the business process is permitted.
Database / analytics accessLimitedSelected business and messaging analytics may be available through Meta APIs, but WhatsApp Business Platform does not provide direct database access.Martini can consume confirmed reporting endpoints and persist selected results in a database or reporting system; it does not connect directly to WhatsApp databases.
Scheduled synchronizationLimitedReal-time webhooks are the primary synchronization pattern, while scheduled API reads can reconcile selected WABAs, phone numbers, templates, media references, or reporting data.Martini scheduler-triggered workflows can page through confirmed API results, compare checkpoints, and reconcile missing or delayed webhook state.

How WhatsApp Business Platform exposes data and business events

WhatsApp REST APIs

The WhatsApp Cloud API and WhatsApp Business Management API use Meta’s REST-style Graph API for messages, media, templates, phone numbers, WABAs, and selected business configuration operations.

Martini implementation pattern

Martini workflows consume the relevant Graph API endpoints with secure access tokens and business asset identifiers. They construct provider-specific JSON, map responses into canonical models, apply business rules, and classify authentication, validation, policy, rate-limit, and transient service errors.

Implementation sequence

Store the Graph API version and asset identifiers in environment configuration
Authenticate with a permitted Meta access token
Construct the provider-specific JSON request
Submit the request through the WhatsApp Cloud API or management API
Validate the response and persist message or asset identifiers
Route transient failures to bounded retry handling

WhatsApp Webhooks

WhatsApp webhooks provide inbound messages and selected message lifecycle notifications, including sent, delivered, read, failed, and error information. They are not a complete event stream for every account or administrative operation.

Martini implementation pattern

Martini exposes a REST API endpoint for Meta verification and event delivery. The workflow validates the verification challenge and signature, acknowledges promptly, parses the JSON payload, checks event idempotency, and routes the work to downstream applications or response workflows.

Implementation sequence

Expose a Martini REST endpoint for webhook verification and delivery
Validate Meta’s verification challenge during registration
Validate the X-Hub-Signature-256 header where applicable
Acknowledge valid notifications promptly
Parse the inbound message or status payload
Check the message or event identifier for duplicate delivery

WhatsApp Media API

The Media API supports uploading, retrieving, and deleting media associated with WhatsApp messages. Media identifiers and download URLs should be handled as time-sensitive integration data.

Martini implementation pattern

Martini receives a media reference from a webhook or outbound process, calls the relevant media endpoint, validates the returned content, and sends it to a document repository, case system, CRM, or ERP workflow. File controls and correlation identifiers are applied before persistence.

Implementation sequence

Receive or identify the WhatsApp media ID
Retrieve media metadata or the permitted download URL
Download the content through an authenticated request
Validate file type, size, ownership, and correlation data
Store or forward the content to the approved destination
Record the WhatsApp message and downstream document references

WhatsApp Management APIs

Management capabilities cover selected WABA, phone number, template, business configuration, and reporting operations. Availability and scope depend on the relevant account, permissions, endpoint, and API version.

Martini implementation pattern

Martini can run scheduled or API-triggered reconciliation workflows that retrieve paginated management data, compare it with a configuration or reporting store, and record changes. Webhooks should not be assumed for every management operation.

Implementation sequence

Authenticate with management permissions and the relevant business asset identifiers
Retrieve the selected management or reporting resource
Follow pagination cursors when present
Normalize the result into a canonical configuration model
Compare the result with the downstream configuration or reporting store
Persist the checkpoint and surface discrepancies for review

Common WhatsApp Business Platform integration patterns

Pattern 1: Send CRM notifications through WhatsApp

When to use this pattern

Use this pattern when Salesforce, ServiceNow, Dynamics 365, or another business application needs to send an approved transactional or service notification and capture the resulting WhatsApp message identifier.

Integration direction
Salesforce
Martini
WhatsApp Business Platform
Example Mapping
WhatsApp Business Platform FieldCanonical FieldTarget Field
recipient wa_idcustomer.messagingAddressto
template namenotification.templateCodetemplate.name
order or case numberbusinessReferencetemplate.components.parameters
source record IDcorrelationIdmetadata or integration store
Martini implementation pattern

Martini receives the source request, validates recipient and customer-service-window rules, selects an approved Message Template, maps parameters, and calls the phone-number-specific messages endpoint. The workflow persists the WhatsApp message ID and correlation ID, applies bounded retries for transient responses, and records permanent validation or policy failures for review.

Martini capabilities used
  • workflows
  • API consumption
  • data mapping
  • business rules
  • secure environment configuration
  • error handling

Pattern 2: Route inbound WhatsApp support messages

When to use this pattern

Use this pattern when customer messages should create or update a support case and optionally receive an acknowledgement or menu response.

Integration direction
WhatsApp Business Platform
Martini
ServiceNow
Example Mapping
WhatsApp Business Platform FieldCanonical FieldTarget Field
messages[0].fromcustomer.messagingAddressCaller or Contact
messages[0].text.bodyconversation.messageTextCase description
messages[0].idsourceMessageIdExternal message reference
metadata.phone_number_idbusinessPhoneNumberIdService channel
Martini implementation pattern

Martini validates the webhook, checks whether the message ID has already been processed, resolves the customer, and applies routing rules based on message type, account, language, or service context. It creates or updates the target case and can submit a permitted response through the Cloud API. Invalid payloads are rejected or quarantined without repeated side effects.

Martini capabilities used
  • API exposure
  • webhook consumption
  • JSON handling
  • data mapping
  • conditional routing
  • idempotency controls
  • error handling

Pattern 3: Send order and delivery notifications

When to use this pattern

Use this pattern when an order, shipment, fulfillment, or delivery event from a commerce or ERP application should trigger a WhatsApp notification and status feedback.

Integration direction
Shopify
Martini
WhatsApp Business Platform
Example Mapping
WhatsApp Business Platform FieldCanonical FieldTarget Field
order.idorderNumbertemplate parameter
fulfillment.statusshipmentStatustemplate parameter
customer.phonecustomer.messagingAddressto
WhatsApp status webhooknotificationDeliveryStatusorder notification status
Martini implementation pattern

A Martini workflow consumes the source event, chooses a template based on the business event, maps order and fulfillment values, and submits the message with correlation data. Delivery, read, and failure webhooks update the source process or initiate controlled retry and alternate-channel handling. Template, recipient, and policy errors are separated from retryable transport failures.

Martini capabilities used
  • event-driven workflows
  • API consumption
  • data transformation
  • business rules
  • correlation
  • retry handling
  • monitoring

Pattern 4: Process WhatsApp media into a case workflow

When to use this pattern

Use this pattern when customers or field personnel send documents, images, or proof-of-delivery files that must be attached to a case, order, or document-management process.

Integration direction
WhatsApp Business Platform
Martini
ServiceNow
Example Mapping
WhatsApp Business Platform FieldCanonical FieldTarget Field
messages[0].image.id or document.idsourceMediaIdattachment source reference
messages[0].typecontentTypeattachment type
messages[0].fromcustomer.messagingAddressCase contact
messages[0].context.idrelatedMessageIdCase correlation
Martini implementation pattern

Martini receives the media event, validates the sender and message context, retrieves the media metadata and content, applies file-type and size controls, and forwards the file to the target case or document process. The workflow records both source and destination references and avoids reprocessing a previously handled media ID.

Martini capabilities used
  • webhook consumption
  • API consumption
  • file handling
  • validation
  • data mapping
  • workflow orchestration
  • idempotency controls

Applications commonly integrated with WhatsApp Business Platform

WhatsApp Business Platform can be integrated with customer, service, commerce, and enterprise applications through their respective APIs. Martini can coordinate outbound notifications, inbound message routing, delivery status updates, and media processing without assuming a native WhatsApp connector.

Application Scenario Direction Martini Pattern
Salesforce Send customer notifications, sales follow-ups, and service updates while associating inbound conversations and delivery statuses with Leads, Contacts, Cases, or Opportunities. Salesforce → Martini → WhatsApp Business Platform Martini receives a Salesforce request, validates the approved Message Template and parameters, submits the message through the Cloud API, and stores the WhatsApp message ID for later webhook correlation. Inbound messages and statuses can be routed back to Salesforce.
ServiceNow Create or update customer service cases and tasks from WhatsApp messages and send case-status notifications to customers. WhatsApp Business Platform → Martini → ServiceNow A Martini API receives and verifies WhatsApp webhook events, identifies the customer, applies routing rules, and calls ServiceNow APIs to create or update Cases or tasks. Outbound case notifications follow the reverse path through an approved template.
Zendesk Convert inbound WhatsApp conversations into tickets and send ticket updates or acknowledgements to customers. WhatsApp Business Platform → Martini → Zendesk Martini parses inbound message JSON, resolves the requester and ticket correlation, maps the content to Zendesk fields, and sends permitted responses through the Cloud API. Duplicate event keys and message IDs are checked before side effects.
Shopify Send order confirmations, fulfillment updates, delivery notifications, and customer support messages associated with commerce activity. Shopify → Martini → WhatsApp Business Platform Martini consumes Shopify order or fulfillment events, selects the appropriate approved template, maps order values into template parameters, and submits the message. Delivery and failure webhooks can update the originating commerce process or route an exception.
NetSuite Deliver order, invoice, fulfillment, and payment-related notifications and return message delivery outcomes to the relevant business process. NetSuite → Martini → WhatsApp Business Platform A Martini workflow consumes NetSuite integration data, applies template and customer-service-window rules, calls the WhatsApp messages endpoint, and persists correlation data. Status webhooks are transformed into NetSuite updates or exception records.
SAP S/4HANA Deliver order, shipment, service, or account notifications and route selected customer replies into SAP business processes. SAP S/4HANA → Martini → WhatsApp Business Platform Martini maps SAP business events to WhatsApp template payloads, applies recipient and policy checks, and submits messages through the Cloud API. Verified inbound events can be mapped to selected SAP business objects using APIs exposed by the SAP landscape.
Microsoft Dynamics 365 Synchronize customer interactions with Accounts, Contacts, Leads, Cases, and customer-service processes. Microsoft Dynamics 365 → Martini → WhatsApp Business Platform Martini orchestrates outbound Dynamics notifications and inbound WhatsApp webhooks, maintaining customer and message identifiers across both systems. Business rules determine whether to update a Case, create an interaction, or send a response.
HubSpot Associate permitted transactional or customer-service messages and inbound responses with Contacts, Conversations, or Tickets. HubSpot → Martini → WhatsApp Business Platform Martini consumes HubSpot events or API data, applies WhatsApp template and eligibility rules, and submits messages. Inbound webhook payloads can be normalized and written to HubSpot through its APIs with duplicate protection.

How to build a WhatsApp Business Platform integration in Martini

Objective

Establish access to the WhatsApp Cloud API or Business Management API using the required Meta permissions, business asset identifiers, and environment-specific configuration.

Instructions in Martini

  • Store system-user or other approved access tokens as Martini secrets
  • Configure the Meta Graph API version, WABA ID, phone number ID, and app settings as environment values
  • Keep app secrets and webhook verification tokens outside workflow definitions
  • Confirm the permissions required for messaging or business management operations

Objective

Select a real-time webhook, source application event, API request, or scheduled reconciliation trigger according to the integration objective.

Instructions in Martini

  • Use a Martini API endpoint for WhatsApp webhook delivery
  • Use an application event or API request for outbound notifications
  • Use a scheduler for selected management or reconciliation reads
  • Do not assume webhooks cover every administrative or reporting change

Objective

Acquire the WhatsApp message, status, media, template, or management data required by the workflow while validating the provider response.

Instructions in Martini

  • Validate Meta webhook verification and signatures where applicable
  • Parse the JSON payload according to its event type
  • Retrieve media or paginated management data through authenticated API calls
  • Preserve source identifiers and correlation values for audit and replay

Objective

Coordinate routing, enrichment, lookups, API calls, and downstream writes as a maintainable Martini workflow rather than embedding logic in a point-to-point script.

Instructions in Martini

  • Resolve the customer, case, order, or business asset using downstream APIs or stored mappings
  • Route messages by type, source, template, account, and business context
  • Acknowledge webhooks promptly and process longer work asynchronously where appropriate
  • Use reusable workflow logic for common validation and correlation behavior

Objective

Translate WhatsApp message, template, media, and status structures into the canonical model used by downstream systems and construct compliant outbound payloads.

Instructions in Martini

  • Map sender, recipient, message ID, timestamp, status, and content fields
  • Map approved template names, languages, components, and parameters
  • Normalize media metadata and preserve the original source reference
  • Use tolerant JSON handling for event-specific payload differences

Objective

Enforce messaging, customer-service-window, recipient, template, media, privacy, and duplicate-processing rules before side effects occur.

Instructions in Martini

  • Require approved templates when the business process requires them
  • Check message or event identifiers before creating or updating downstream data
  • Reject malformed payloads and invalid asset, template, or media references
  • Separate permanent validation and permission failures from transient failures

Common WhatsApp Business Platform data objects used in integrations

ObjectTypical UseCommon target systemsMartini handling
WhatsApp Business Account (WABA)Groups phone numbers, templates, and WhatsApp business configuration.CRM, customer service platforms, administration systems, reporting storesMartini retrieves selected WABA information through management APIs, maps identifiers into canonical account configuration, and stores only required operational data.
Phone NumberRepresents a registered business number and is commonly referenced by phone number ID for messaging requests.CRM, customer service platforms, notification services, configuration storesMartini resolves the phone number ID from environment or account configuration and uses it to route outbound messages and associate inbound events.
MessageRepresents inbound or outbound text, media, template, interactive, location, contact, or reaction content.CRM, ticketing platforms, order systems, audit storesMartini maps message content and identifiers, preserves correlation data, applies routing rules, and prevents duplicate downstream processing.
Message TemplateApproved structure for business-initiated messages, particularly outside the customer service window.CRM, commerce, order management, campaign or notification processesMartini selects templates by business event, validates language and parameter counts, maps values into components, and handles template validation errors.
MediaImages, audio, video, documents, and stickers sent or received through WhatsApp.Document repositories, case systems, CRM, ERP processesMartini retrieves media metadata or content, validates ownership, type, and size, and forwards or stores the file with message correlation.
ConversationRepresents a billing and messaging interaction window, commonly reflected through message status and webhook metadata rather than a conventional CRUD resource.CRM, customer service, analytics, billing or reporting storesMartini derives and persists relevant conversation context from webhook and message data where required, while treating the platform as the system of record for conversation rules.

Authentication and security considerations

Meta access tokens and permissions

WhatsApp Business Platform requests use Meta access tokens, commonly system-user tokens for production server-to-server integrations. The required permissions depend on whether the workflow sends messages or manages WABAs, phone numbers, templates, and related business assets.

Webhook protection

Webhook registration uses a verification token, and incoming requests can be validated with the Meta app secret and X-Hub-Signature-256. Martini should reject malformed or unexpected payloads and keep verification values outside workflow definitions.

Secrets and personal data

  • Store access tokens, app secrets, and verification tokens in secure environment configuration.
  • Avoid logging credentials, unnecessary message content, and personal data.
  • Define retention, masking, access, encryption, and audit controls for messages and media.

Operational considerations for WhatsApp Business Platform integrations

Rate limits and throughput

Throughput depends on account status, phone-number quality, messaging limits, recipient quality, and Meta policies. Handle HTTP 429 and transient 5xx responses with bounded backoff and avoid uncontrolled parallel submission.

Templates and conversation rules

Business-initiated messages generally require approved templates with matching names, languages, components, and parameters. Workflows should distinguish active customer-service interactions from notifications that require templates.

Idempotency and pagination

Webhook deliveries may be repeated. Persist message IDs or equivalent event keys before creating downstream side effects. Management responses may be paginated, so reconciliation workflows should follow cursors.

Media and schema changes

Media references and download URLs should not be treated as permanent. Retrieve required content promptly, validate files, and use tolerant JSON parsing because webhook payloads vary by event type and API version.

Testing and monitoring

Test API-version changes, template variants, webhook verification, duplicate delivery, rate-limit behavior, media handling, and permanent versus transient failures before production deployment. Monitor workflow outcomes, message IDs, response errors, and account restrictions.

Why use Martini instead of scripts or point-to-point integrations?

Coordinate more than an API call

Direct scripts can submit messages, but enterprise integrations also need webhook verification, customer and order lookups, template rules, media processing, correlation, duplicate protection, and downstream updates. Martini keeps this behavior in explicit workflows and APIs.

Separate provider logic from business logic

Martini maps WhatsApp payloads into canonical models and applies reusable business rules before writing to CRM, service, commerce, ERP, or document systems. This reduces duplicated point-to-point transformations as applications change.

Operate and maintain integrations

  • Use secure environment configuration for tokens, app secrets, API versions, and business asset identifiers.
  • Apply bounded retries, validation, idempotency, pagination, and error routing consistently.
  • Expose controlled APIs for inbound events and reuse workflow assets for outbound messaging and reconciliation.
  • Monitor message correlations, webhook outcomes, media processing, and deployment behavior.

Frequently asked questions

How can WhatsApp Business Platform be integrated with enterprise systems?

It integrates primarily through Meta’s REST-style Graph API and webhooks. Enterprise applications can submit messages, media, and management requests through the Cloud API or Business Management API, while webhooks deliver selected inbound messages and message-status notifications. Files, message identifiers, templates, and business-account data can then be mapped into CRM, service, commerce, ERP, and reporting processes.

Can Martini integrate with WhatsApp Business Platform?

Yes. Martini can consume the WhatsApp Cloud API and WhatsApp Business Management API, expose an endpoint for WhatsApp webhook delivery, validate webhook requests, transform JSON payloads, process media, and orchestrate downstream applications. No native Martini WhatsApp connector is documented in the supplied sources, so the integration uses the vendor’s confirmed REST and webhook mechanisms.

Do I need a connector to integrate WhatsApp Business Platform with Martini?

No. A dedicated WhatsApp connector is not required. Martini can integrate using Meta’s Graph API, WhatsApp webhooks, Media API, management APIs, access tokens, permissions, business asset identifiers, and webhook verification and signature mechanisms confirmed for the platform.

Is there any extra Lonti cost to integrate WhatsApp Business Platform with Martini?

Lonti does not charge an additional per-connector or per-vendor fee to integrate WhatsApp Business Platform. Integration use is subject to the provisioned capacity of the Martini environment. Separate costs may apply from Meta, cloud infrastructure, storage, messaging usage, or other third-party systems depending on subscription, usage, and deployment model.

Which WhatsApp Business Platform APIs and methods should be used?

Use the WhatsApp Cloud API for messages and media, and the WhatsApp Business Management API for supported WABAs, phone numbers, templates, business configuration, and selected reporting operations. Use webhooks for real-time inbound messages and selected message statuses, with scheduled API reads for reconciliation where needed. No official WhatsApp Business Platform GraphQL or SOAP API was confirmed.

Are WhatsApp events and webhooks available?

Yes, but coverage is selective. WhatsApp webhooks support inbound messages and selected sent, delivered, read, failed, and error notifications. They should not be treated as a complete event stream for every template, billing, configuration, administrative, or business-account operation.

How does synchronization and data mapping work?

Real-time synchronization normally begins with a webhook or source-application event. Martini maps WhatsApp messages, statuses, templates, media references, and identifiers into a canonical model, enriches them with CRM or order data, and writes the result to downstream systems. Scheduled workflows can reconcile selected management or reporting data and follow pagination cursors.

How are errors, retries, and duplicate WhatsApp events handled?

Martini can classify authentication, permission, template, recipient, media, rate-limit, policy, and transient service errors. Bounded retries with backoff are appropriate for transient failures, while invalid payloads and permission failures require correction. Persisting message IDs or event identifiers allows workflows to ignore duplicate webhook deliveries and avoid repeated downstream side effects.