Upload media
Upload an image or a document, then send it by its media_id on sendWhatsappMessage. Uploading costs nothing; only the send is charged. The media_id works for 24 hours and only for the number and type it was uploaded for.
Set up WhatsApp first. Connect a WhatsApp number in the dashboard or with Connect numbers. Included on every paid plan. See plans.
curl -X POST 'https://backend.omnidim.io/api/v1/whatsapp/media' \ -H 'Authorization: Bearer YOUR_API_KEY'
{ "media_id": "string", "type": "image", "mime": "string", "filename": "string", "size": 0, "expires_at": "string" }
BearerAuthAuthorizationBearer <token>Bearer token authentication. Obtain your API key from the OmniDimension dashboard.
multipart/form-dataphone_number_id*integerThe number that will send the file.
type*string"image""document"file*fileThe file to upload.
binaryResponse body
application/jsonThe uploaded file.
application/jsonAn uploaded file, ready to send by its media_id.
media_id?stringtype?string"image""document"mime?stringfilename?stringsize?integerexpires_at?stringWhen the media_id stops working. It lasts 24 hours.
Get a message
One message with its timeline: the delivery and read steps, oldest first. Poll it after a send to learn whether the message was delivered and read. Also shows what the send cost once it is charged.
List opt-outs
Who opted out of messages from this number, oldest first. By default it lists active opt-outs only.
