Send document message
Provide either id, for a media previously uploaded through POST /messages/upload-media, or link, a public URL WhatsApp can download from.
Requires an open service window: the recipient must have messaged the business in the last 24 hours. Use POST /messages/template to reach recipients outside that window.
Request body
Response
Message sent successfully
Changes
Changed in 2 of the 9 revisions of this API.49
- ○
added the media type
application/jsonfor the response with the status400response-media-type-added
- ○
added the media type
application/jsonfor the response with the status401response-media-type-added
- ○
added the media type
application/jsonfor the response with the status404response-media-type-added
- ○
- ▲
request body became required
request-body-became-required
- ▲
the
fromrequest property's minLength was increased from0to1request-property-min-length-increased
- ▲
the
torequest property's minLength was increased from0to1request-property-min-length-increased
- ▲
the
document/linkrequest property type/format changed fromstring/tostring/urirequest-property-type-changed
- ○
the request property
documentbecame optionalrequest-property-became-optional
- ○
added the non-success response with the status
400response-non-success-status-added
- ○
added the non-success response with the status
401response-non-success-status-added
- ○
added the non-success response with the status
404response-non-success-status-added
- ○
the response property
idbecame required for the status200response-property-became-required
- ○
the
idresponse's property pattern^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$was added for the status200response-property-pattern-added
- ▲