API Variables

Variables to be used in Push API

Request Variables

You need to use below variables to construct a PUSH API

Request URL

Method : POST

https://pickyassist.com/app/api/v2/push

Variable

Date Type

Description

Required

token

alphanumeric

Unique token for the project

Mandatory

application

numeric

Through which application the message need to sent.

1 = Whatsapp Personal (Phone Automation) 2 = Whatsapp Business (Phone Automation) 3 = SMS (Phone Automation) 4 = Call (Phone Automation)

5 = Facebook Messenger

Mandatory

voice

numeric

1 = Send the audio file as Voice Note in WhatsApp, supports only in WhatsApp Web Automation Channel

Optional

globalmessage

text

Global Message Text Message with emoji supported by whatsapp

If you are sending image and video you can pass caption text here

Mandatory only if message variable is empty

template_globalmessage

array

This is used for sending templated messages in WhatsApp Official account, need to pass the dynamic variable value in array

template_message

Optional

template_id

string

Template unique id used for sending WhatsApp Official Templated Message

Mandatory only if sending WhatsApp Official template messages

language

string

Language of the WhatsApp Official Template

Mandatory only if sending WhatsApp Official template messages

template_header

string

Header for sending WhatsApp Official Template , applicable only for sending documents (only pdf supports now)

Optional

globalmedia

URL

URL from we need to fetch the media , Maximum Size is 50 MB

Optional

globalmedia_code

string

Sending Global Media files as base64

Optional

media_code

string

Sending personalised media file as base64, works only with WhatsApp Official & Shared Number

Optional

sticker

numeric

1

Optional

priority

numeric

0 = Low 1 = High

Optional, default is 0

action

numeric

Optional

location

Array

Location values need to pass as array

name = name of the location address = Address of the Location

lat = Latitude long = Longitude

Not Supported in Phone Automation

Optional

contact

Array

Contact as Array, in case multiple contact shared then same will be passed as multiple array's

first_name = First Name

last_name = Last Name

phone = Phone Number

city = City

country = Country country_code = Country Short Code

state = State

street = Street address_type = Address Type

zip = Postal Code

email = Email Address

company = Company Name contact_image = Base 64 code of the contact image

Not Supported in Phone Automation

Optional

data

Array

Object through which you can pass multiple number and its personalised message

Mandatory

number

numeric

Mobile Number with full country code without 0 or +

+55 12345 6789 – Wrong Format

55123456789 – Correct Format

Mandatory, minimum 5 length

messenger_id

numeric

Unique User ID allocated by the Facebook.

Mandatory if application=5 i.e Facebook

message

string

Text Message with emoji supported by whatsapp If you are sending image and video you can pass caption text also here. Caption text is not supported for PDF, Audio, Document

Mandatory only if globalmessage variable is empty

reference_number

string

You can pass any value here like your internal message id etc and the same will be returned in the Event Webhook i.e Delivery Reports

Please note we don't check for duplicate or unique values here, we just return the value you passed

Optional

quoted

numeric

Optional

template_message

array

This field needs to be used for sending WhatsApp Official Template message, you need to pass the dynamic variable data as array

Mandatory only if sending WhatsApp Official template messages

payload

array

You can pass a custom payload like a reference number for each button in the quick replies, this is an array and optional

Optional

interactive_globalbuttons

array

This is applicable only for the Call to Action URL and used for sending dynamic variables that should be replaced in the dynamic URL button. Mandatory if button type is url and interactive_buttons is empty.

If the URL variable is dynamic in nature (personalise for each number) then you need to pass the dynamic value against each number through interactive_buttons

Optional

interactive_buttons

array

This is applicable only for the Call to Action URL and used for sending dynamic variables that should be replaced in the dynamic URL button.

This is used to pass personalised variable for each number dynamically and this is optional if interactive_globalbuttons is not empty

this is optional if interactive_globalbuttons is not empty

Response Variables

All API request will get the response

Please note “100 -> Sucess” response doesn’t mean the message has been successfully sent to the user, it means your message has been accepted by our servers and pushed to your phone for processing.

Variable

Description

status

100=>’Success’, 401=>’Authentication Failed’, 402=>’Empty Number List’, 403=>’Insufficient Balance’, 404=>’Unable to Communicate with Your Phone ! ‘, 405=>’API Is Not Active For This Plan’, 406=>’Invalid Mobile Number’, 407=>’Message cannot be empty’, 408=>’Project is not Active’, 409=>’Invalid User’

410=>'Invalid Request'

push_id

Push id generated by Picky Assist Server (for your reference)

message

Detailed Status Message (description of any error message)

data

Array which contacts below details

msg_id

Unique Message Id allocated to each number

number

Mobile Number in which the message is sent

credit

Credit / billing value used for sending the message out

Last updated