App · Messaging · 24 actions
Send WhatsApp messages from your business number (text, templates, media, buttons and lists), manage message templates and your business profile. Someone who hasn't messaged you in the last 24 hours can only be sent a template message.
Actions
| Action | What it does |
|---|---|
| Block users | Block WhatsApp users from messaging your business number. |
| Create a message template | Submit a message template for WhatsApp's review. |
| Delete a message template | Delete a message template. |
| Delete media | Delete a file from WhatsApp's servers. |
| Download media | Download a photo, voice note, video or document someone sent your number (or one you uploaded) by its media ID, so a later step can save or attach it. |
| Get a message template | Read one message template, including whether it has been approved yet and, if not, why it was rejected. |
| Get a phone number | Get one business phone number's status, its quality rating, whether its display name is approved, and how many people it may message a day. |
| Get business profile | Read the public business profile customers see: about text, description, address, email, websites and industry. |
| List message templates | List the WhatsApp Business Account's message templates with each one's status, category, language and body text. |
| List phone numbers | List the business phone numbers on the WhatsApp Business Account, with each one's id, status and quality rating. |
| React to a message | React to a message in the chat with an emoji. |
| Send a contact card | Send someone a contact card with a name, phone number and email they can save to their phone. |
| Send a document | Send a document (PDF, Word, Excel, PowerPoint or text, up to 100 MB) by public URL. |
| Send a list message | Send a message with a button that opens a list of up to ten options to pick from. |
| Send a location | Send a map pin with an optional name and address. |
| Send a template message | Send a pre-approved message template. |
| Send a text message | Send a plain text WhatsApp message. |
| Send a video | Send an MP4 or 3GP video (H.264 and AAC, up to 16 MB) by public URL. |
| Send an audio message | Send an audio file or voice note, by public URL or media ID, to someone on WhatsApp. |
| Send an image | Send a JPEG or PNG image (up to 5 MB) by public URL, with an optional caption. |
| Send reply buttons | Send a message with up to three tap-to-reply buttons. |
| Unblock users | Unblock WhatsApp users so they can message your business number again. |
| Update business profile | Change fields of the public business profile. |
| Upload media | Store a file on WhatsApp for 30 days, so it can be sent by its media ID without a public link. |
Block users
Block WhatsApp users from messaging your business number. WhatsApp only lets you block someone who messaged you in the last 24 hours; any it refuses are listed with the reason.
Inputs
- Phone numbers
userslistRequired - The phone numbers to block, with country code, up to 1000.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
blocked_countnumberblocked_userslistfailed_countnumberfailed_userslistphone_number_idtext
Example output
{
"blocked_count": 1,
"blocked_users": [
{
"input": "+16505551234",
"wa_id": "16505551234"
}
],
"failed_count": 0,
"failed_users": [],
"phone_number_id": "106540352242922"
}Create a message template
Submit a message template for WhatsApp's review. Mark the parts that change in each message with {{1}}, {{2}} or {{first_name}}, and give an example of each. Review usually takes minutes, at most a day; the template can't be sent until it's approved.
Inputs
- Template name
nametextRequired - Lowercase letters, digits and underscores; spaces become underscores.
- Category
categorytextRequired - UTILITY for updates about something the customer did (orders, bookings); MARKETING for promotions.One of:
UTILITY,MARKETING. Default:UTILITY. - Body
body_texttextRequired - The message text, up to 1024 characters, such as 'Hi {{1}}, your order {{2}} has shipped.'
- Body example values
body_exampleslist - One example value per placeholder in the body, in the order they first appear. Meta's reviewers read these.
- Language code
language_codetext - Such as en_US, en or es. Defaults to en_US.Default:
en_US. - Header
header_texttext - Optional bold header line, up to 60 characters.
- Header example value
header_exampletext - An example value if the header has a placeholder.
- Footer
footer_texttext - Optional small gray footer, up to 60 characters.
- Quick reply buttons
quick_reply_buttonslist - Up to 10 button labels, each up to 25 characters.
Outputs
templateobject
Example output
{
"template": {
"category": "UTILITY",
"id": "1234567890123456",
"language": "en_US",
"name": "order_update",
"parameter_format": "POSITIONAL",
"status": "PENDING"
}
}Delete a message template
Delete a message template. Without a template ID every language of that name is deleted. The name of a deleted approved template cannot be reused for 30 days, and a disabled template cannot be deleted.
Inputs
- Template name
template_nametextRequired - The name of the template to delete.
- Template ID
template_idtext - Optionally, the id of one language version, to delete only that one.
Outputs
all_languagestrue/falsedeletedtrue/falsetemplate_idtexttemplate_nametext
Example output
{
"all_languages": false,
"deleted": true,
"template_id": "1234567890123456",
"template_name": "order_update"
}Delete media
Delete a file from WhatsApp's servers. Messages already sent with it keep their copy.
Inputs
- Media ID
media_idtextRequired - The media file's id: one 'Upload media' gave, or one from a message someone sent your number.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
deletedtrue/false- True once WhatsApp has deleted it
media_idtext- The deleted media file's ID
Example output
{
"deleted": true,
"media_id": "1037543291543636"
}Download media
Download a photo, voice note, video or document someone sent your number (or one you uploaded) by its media ID, so a later step can save or attach it.
Inputs
- Media ID
media_idtextRequired - The media file's id: one 'Upload media' gave, or one from a message someone sent your number.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
document_reftext- The downloaded file, for a later step to attach or upload
file_nametext- A name for the file, from its ID and type
media_idtext- The media file's ID
mime_typetext- The file's type, such as image/jpeg
sha256text- The file's SHA-256 checksum, as WhatsApp gave it
sizenumber- The file's size in bytes
Example output
{
"document_ref": "doc_3f2a9c1b7e5d4a60",
"file_name": "whatsapp-1037543291543636.jpg",
"media_id": "1037543291543636",
"mime_type": "image/jpeg",
"sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"size": 48213
}Get a message template
Read one message template, including whether it has been approved yet and, if not, why it was rejected.
Inputs
- Template ID
template_idtextRequired - The template's numeric id, as List message templates or Create a message template returns it.
Outputs
templateobject
Example output
{
"template": {
"body_text": "Hi {{1}}, your order {{2}} has shipped.",
"category": "UTILITY",
"components": [
{
"text": "Hi {{1}}, your order {{2}} has shipped.",
"type": "BODY"
}
],
"id": "1234567890123456",
"language": "en_US",
"name": "order_update",
"parameter_format": "POSITIONAL",
"quality_score": "GREEN",
"rejected_reason": "NONE",
"status": "APPROVED"
}
}Get a phone number
Get one business phone number's status, its quality rating, whether its display name is approved, and how many people it may message a day.
Inputs
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
phone_numberobject
Example output
{
"phone_number": {
"account_mode": "LIVE",
"code_verification_status": "VERIFIED",
"display_phone_number": "+1 555-005-1310",
"id": "106540352242922",
"messaging_limit_tier": "TIER_1K",
"name_status": "APPROVED",
"quality_rating": "GREEN",
"status": "CONNECTED",
"verified_name": "Lodol Demo"
}
}Get business profile
Read the public business profile customers see: about text, description, address, email, websites and industry.
Inputs
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
business_profileobjectphone_number_idtext
Example output
{
"business_profile": {
"about": "Workflows that run themselves.",
"address": "1 Market St, San Francisco, CA 94105",
"description": "Lodol automates the busywork between your tools.",
"email": "hello@example.com",
"profile_picture_url": "https://pps.whatsapp.net/v/t61.24694-24/example.jpg",
"vertical": "PROF_SERVICES",
"websites": [
"https://www.example.com/"
]
},
"phone_number_id": "106540352242922"
}List message templates
List the WhatsApp Business Account's message templates with each one's status, category, language and body text.
Inputs
- Name
nametext - Only return templates with this name.
- Status
statustext - Only return templates in this status.One of:
APPROVED,PENDING,REJECTED,PAUSED,DISABLED,IN_APPEAL,LIMIT_EXCEEDED,ARCHIVED,PENDING_DELETION,DELETED. - Maximum results
max_resultsnumber - How many rows to return (1-500). Defaults to 25.From 1 to 500. Default:
25.
Outputs
countnumber- How many were returned.
templateslist
Example output
{
"count": 1,
"templates": [
{
"body_text": "Hi {{1}}, your order {{2}} has shipped.",
"category": "UTILITY",
"components": [
{
"text": "Hi {{1}}, your order {{2}} has shipped.",
"type": "BODY"
}
],
"id": "1234567890123456",
"language": "en_US",
"name": "order_update",
"parameter_format": "POSITIONAL",
"quality_score": "GREEN",
"rejected_reason": "NONE",
"status": "APPROVED"
}
]
}List phone numbers
List the business phone numbers on the WhatsApp Business Account, with each one's id, status and quality rating.
Inputs
- Maximum results
max_resultsnumber - How many rows to return (1-500). Defaults to 25.From 1 to 500. Default:
25.
Outputs
countnumber- How many were returned.
phone_numberslist
Example output
{
"count": 1,
"phone_numbers": [
{
"account_mode": "LIVE",
"code_verification_status": "VERIFIED",
"display_phone_number": "+1 555-005-1310",
"id": "106540352242922",
"messaging_limit_tier": "TIER_1K",
"name_status": "APPROVED",
"quality_rating": "GREEN",
"status": "CONNECTED",
"verified_name": "Lodol Demo"
}
]
}React to a message
React to a message in the chat with an emoji. A message over 30 days old, or one that was deleted, can't show it.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Message ID
message_idtextRequired - The wamid.… id of the message to react to.
- Emoji
emojitextRequired - The emoji to react with, such as 👍.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a contact card
Send someone a contact card with a name, phone number and email they can save to their phone. WhatsApp only delivers it to someone who messaged your number in the last 24 hours; to start a conversation, send a template message instead.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Contact's name
contact_nametextRequired - The name shown on the card, such as Ana Ruiz.
- Contact's phone
contact_phonetext - Their phone number with its country code, such as +16505551234. Give this, an email, or both.
- Contact's email
contact_emailtext - Their email address.
- Company
companytext - Where they work, such as Ruiz Bakery.
- Website
websitetext - A website for them, starting with https://.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a document
Send a document (PDF, Word, Excel, PowerPoint or text, up to 100 MB) by public URL.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Media URL
media_urltext - A public http(s) link to the file for WhatsApp to download. Give this or a media ID.
- Media ID
media_idtext - The id of media already uploaded to WhatsApp, instead of a URL. Uploaded media ids expire after 30 days.
- Caption
captiontext - Optional caption, up to 1024 characters.
- File name
filenametext - The name shown to the recipient, with its extension, such as invoice.pdf.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a list message
Send a message with a button that opens a list of up to ten options to pick from.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Message
bodytextRequired - The message text, up to 4096 characters.
- Button label
button_labeltextRequired - The label of the button that opens the list, up to 20 characters.
- Options
rowslistRequired - Up to 10 options. Each is a title (up to 24 characters), optionally followed by ' | ' and a description (up to 72).
- List heading
section_titletext - Heading above the options, up to 24 characters. Defaults to the button label.
- Header
header_texttext - Optional bold header line, up to 60 characters.
- Footer
footer_texttext - Optional small gray footer, up to 60 characters.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a location
Send a map pin with an optional name and address.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Latitude
latitudenumberRequired - Latitude in decimal degrees, -90 to 90.From -90 to 90.
- Longitude
longitudenumberRequired - Longitude in decimal degrees, -180 to 180.From -180 to 180.
- Place name
nametext - Optional name shown above the pin.
- Address
addresstext - Optional street address shown under the name.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a template message
Send a pre-approved message template. This is the only kind of message you can send to someone who has not messaged you in the last 24 hours.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Template name
template_nametextRequired - The template's name, as List message templates shows it.
- Language code
language_codetext - The template's language code, such as en_US, en or es. Defaults to en_US.Default:
en_US. - Header value
header_parametertext - The value for the placeholder in the template's text header, if it has one.
- Body values
body_parameterslist - One value per {{1}}, {{2}}, ... placeholder in the template body, in order.
- Named body values
named_body_parametersobject - For a template with named placeholders such as {{first_name}}: each placeholder name and its value.
- Components (advanced)
componentslist - The raw template components JSON, for button or media-header parameters. Use instead of the value fields above.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a text message
Send a plain text WhatsApp message. WhatsApp only delivers it to someone who messaged your number in the last 24 hours; to start a conversation, send a template message instead.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Message
bodytextRequired - The text to send, up to 4096 characters.
- Show link preview
preview_urltrue/false - Show a preview of the first link in the message.Default:
false. - Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send a video
Send an MP4 or 3GP video (H.264 and AAC, up to 16 MB) by public URL.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Media URL
media_urltext - A public http(s) link to the file for WhatsApp to download. Give this or a media ID.
- Media ID
media_idtext - The id of media already uploaded to WhatsApp, instead of a URL. Uploaded media ids expire after 30 days.
- Caption
captiontext - Optional caption, up to 1024 characters.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send an audio message
Send an audio file or voice note, by public URL or media ID, to someone on WhatsApp. WhatsApp only delivers it to someone who messaged your number in the last 24 hours; to start a conversation, send a template message instead.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Audio URL
media_urltext - A public http(s) link to the audio file (AAC, AMR, MP3, M4A or OGG Opus, up to 16 MB). Give this or a media ID.
- Media ID
media_idtext - The id of media already uploaded to WhatsApp, instead of a URL. Uploaded media ids expire after 30 days.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send an image
Send a JPEG or PNG image (up to 5 MB) by public URL, with an optional caption.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Media URL
media_urltext - A public http(s) link to the file for WhatsApp to download. Give this or a media ID.
- Media ID
media_idtext - The id of media already uploaded to WhatsApp, instead of a URL. Uploaded media ids expire after 30 days.
- Caption
captiontext - Optional caption, up to 1024 characters.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Send reply buttons
Send a message with up to three tap-to-reply buttons. The customer's choice comes back as a reply carrying the button title.
Inputs
- To
totextRequired - The recipient's WhatsApp number with its country code, such as +16505551234. Spaces, dashes and brackets are fine, and so is a number an earlier step got from WhatsApp.
- Message
bodytextRequired - The message text, up to 1024 characters.
- Button titles
buttonslistRequired - One to three button titles, each up to 20 characters and unique.
- Header
header_texttext - Optional bold header line, up to 60 characters.
- Footer
footer_texttext - Optional small gray footer, up to 60 characters.
- Reply to message ID
reply_to_message_idtext - Optionally quote an earlier message (its wamid.… id) so this one shows as a reply to it.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
message_idtextmessage_statustextrecipient_wa_idtexttotext
Example output
{
"message_id": "wamid.HBgLMTY1MDU1NTEyMzQVAgARGBI4QzY3RjQ0RUQ3QjA1NEM2OQA=",
"message_status": "accepted",
"recipient_wa_id": "16505551234",
"to": "+16505551234"
}Unblock users
Unblock WhatsApp users so they can message your business number again. Any WhatsApp refuses are listed with the reason.
Inputs
- Phone numbers
userslistRequired - The phone numbers to unblock, with country code, up to 1000.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
failed_countnumberfailed_userslistphone_number_idtextunblocked_countnumberunblocked_userslist
Example output
{
"failed_count": 0,
"failed_users": [],
"phone_number_id": "106540352242922",
"unblocked_count": 1,
"unblocked_users": [
{
"input": "+16505551234",
"wa_id": "16505551234"
}
]
}Update business profile
Change fields of the public business profile. Only the fields you fill in are changed.
Inputs
- About
abouttext - Short status text, up to 139 characters.
- Description
descriptiontext - Business description, up to 256 characters.
- Address
addresstext - Up to 256 characters.
- Email
emailtext - Contact email address.
- Websites
websiteslist - Up to 2 http(s) URLs. Replaces the current list.
- Industry
verticaltext - The business's industry.One of:
OTHER,AUTO,BEAUTY,APPAREL,EDU,ENTERTAIN,EVENT_PLAN,FINANCE,GROCERY,GOVT, and 11 more. - Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
phone_number_idtextupdatedtrue/falseupdated_fieldslist
Example output
{
"phone_number_id": "106540352242922",
"updated": true,
"updated_fields": [
"about"
]
}Upload media
Store a file on WhatsApp for 30 days, so it can be sent by its media ID without a public link. Nothing is sent to anyone.
Inputs
- File
filetextRequired - The file: upload one, pick a file from an earlier step, or paste a link to one.
- File name
file_nametext - The file's name, such as menu.pdf; its ending tells WhatsApp the type. Defaults to the file's own name.
- Business phone number
phone_number_idtext - Which of your business numbers to use. Leave empty to use the one saved when WhatsApp was connected.
Outputs
file_nametext- The file's name
media_idtext- The file's media ID, for the send steps' Media ID field
mime_typetext- The file's type, such as image/jpeg
phone_number_idtext- The business number it was uploaded for
sizenumber- The file's size in bytes
Example output
{
"file_name": "menu.pdf",
"media_id": "1037543291543636",
"mime_type": "application/pdf",
"phone_number_id": "106540352242922",
"size": 48213
}