Skip to main content
POST
/
{instance}
/
send-link-custom-preview
cURL
curl --request POST \
  --url https://app.hypersender.com/api/whatsapp/v1/{instance}/send-link-custom-preview \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "chatId": "[email protected]",
  "text": "<string>",
  "preview_title": "<string>",
  "preview_description": "<string>",
  "preview_url": "<string>",
  "preview_image_url": "<string>",
  "preview_image_file": "<string>",
  "reply_to": "<string>",
  "high_quality": true
}
'
{
  "key": {
    "remoteJid": "<string>",
    "fromMe": true,
    "id": "<string>"
  },
  "message": {
    "extendedTextMessage": {
      "text": "<string>",
      "matchedText": "<string>",
      "description": "<string>",
      "title": "<string>",
      "previewType": "<string>",
      "jpegThumbnail": "<string>",
      "thumbnailDirectPath": "<string>",
      "thumbnailSha256": "<string>",
      "thumbnailEncSha256": "<string>",
      "mediaKey": "<string>",
      "mediaKeyTimestamp": "<string>",
      "thumbnailHeight": 123,
      "thumbnailWidth": 123
    }
  },
  "messageTimestamp": "<string>",
  "status": "<string>"
}
This feature is only available for subscribed accounts.
Using send-text or send-text-safe you can send auto-generated link previews.

Provide a URL for the image.

send link custom preview url preview
WhatsApp requires the text to contain the preview URL anywhere in the text.Example: "text": "Check this out! https://hypersender.com/"
Please note that the URL must be publicly accessible and not require any authentication or special headers to access the file.

Send the image it self as a file upload.

send link custom preview file
By specifying the high_quality parameter as true, you can get a higher quality image.
send link custom preview preview

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Accept
string
Example:

"application/json"

Content-Type
string
Example:

"application/json"

Path Parameters

instance
string
required

Instance UUID copied from hypersender dashboard

Example:

"{{ instance_id }}"

Body

application/json
chatId
string
required

Contact number - learn what is chatId

text
string
required

text should contain the url to send

preview_title
string
required

title of the link preview

preview_description
string
required

description of the link preview

preview_url
string
required

must be a valid URL

preview_image_url
string
required

URL of the image to be used in the link preview - (only if preview_image_file is not provided)

preview_image_file
string
required

file of the image to be used in the link preview - (only if preview_image_url is not provided)

reply_to
string

reply to message id

high_quality
boolean

high quality for the image

Response

Successful response

key
object
message
object
messageTimestamp
string
status
string