Upload template media example

Uploads the sample media a template needs for approval and returns the handle to quote as exampleMedia when creating the template.

Request parameters

Path parameters

KeyDescriptionValuesData TypeRequired/Optional
appIdIdentifier of the WhatsApp app the call acts on.6f414190-d45c-4671-bca1-fb6c3018cb13StringRequired

Body

KeyDescriptionValuesData TypeRequired/Optional
fileThe media, as a binary part or as a public URLhttps://example.com/image.jpeg—Required
file_typeMIME type of the mediaimage/jpeg—Required

Sample cURL — Upload template media example.

curl --request POST \
  --url 'https://partner.gupshup.io/partner/bizgate/app/6f414190-d45c-4671-bca1-fb6c3018cb13/template/example' \
  --header 'Authorization: Bearer <UT>' \
  --header 'Accept: application/json' \
  --form 'file=@/path/to/file' \
  --form 'file_type=image/jpeg'

Sample success response (200)

{
  "status": "success",
  "data": {
    "h": "4::aW1hZ2UvanBlZw==:aW1hZ2UvanBlZw==:ARb4..."
  }
}
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required

Identifier of the WhatsApp app the call acts on.

Body Params

The example media, as a binary part or a public URL, plus its MIME type

Media upload (multipart/form-data): the file itself or a public URL to it

string
required

The media, as a binary part or as a public URL

string
required

MIME type of the media

Responses

Language
Credentials
Bearer
Universal Token (UT)
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json