here you can create a template for a particular app.
you will need below details to start using this api.
1. app Id
2. app token
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
elementName | ticket_check_url_334 | The name of a template. Element name is unique for a WABAs namespace. |
languageCode | en_US | Language code for the template. Refer to all the language codes here. |
category | TRANSACTIONAL | The category of your template. Possible Values: TRANSACTIONAL , MARKETING , and OTP . |
templateType | TEXT | The type of template |
vertical | BUTTON_CHECK | |
content | your ticket has been confirmed for {{1}} persons on date {{2}}. | The body of the template. Character limit: 1028 |
header | This is the header | Header of the template. Applicable for templateType = Text Character limit: 60 |
footer | This is the footer | Footer of the template. Character limit: 60 |
buttons | [{"type":"PHONE_NUMBER","text":"Call Us","phone_number":"+919872329959"},{"type":"URL","text":"Book A Demo","url":"https://bookins.gupshup.io/{{1}}","example":["https://bookins.gupshup.io/abc"]}] | Used only if your template has a CTA. An example is also submitted if a URL button has variable parameter. |
example | your ticket has been confirmed for 4 persons on date 2020-05-04. | An example of the template. |
|
Using this API, you can create and submit a template along with a Sample Media. You will need below details to start using this API.
Key | Value | Description |
---|---|---|
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
elementName | ticket_check_url_334 | |
languageCode | en_US | |
content | Your verification code is {{1}}. | |
footer | This is the footer | Footer of the template. Character limit: 60 |
category | TRANSACTIONAL | The category of your template. Possible Values: TRANSACTIONAL , MARKETING , and OTP . |
templateType | IMAGE | |
vertical | Ticket update | |
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 | |
example | Your verification code is 213. | |
exampleMedia | 4::aW1hZ2UvcadG5n:ARYaMMMA2QvIXuQZdPjWVXTOqfoBU3n0L1Ftyg4w57yxi9nD105yQDvW2nu3-HNo9HGefxZ-Ig-HAi3YSsckwIsOEUwxSPatsxT0Niob30E63A:e:1634884682:2281283925530161:100033655335566:ARaBAxW-1L-ZRu6SMSg |
This is the handleId. |
enableSample | true |
|
Using this API, you can upload your sample media and generate a handleId
for it. Using the handleId
, you can create and submit a template along with a sample media. The handleId is passed in the exampleMedia
parameter of the Apply for templates with sample media API. You will need below details to start using this API.
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
file | @"/C:/Users/Pictures/sample.png" | Upload a file from your local machine. |
file_type | image/png |
|
This will provide you the list of templates for a particular app. You will also get the rejection reason for templates.
The following details are required to start using this API.
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
{
"status": "success",
"templates": [
{
"category": "ISSUE_RESOLUTION",
"createdOn": 1635439783282,
"data": "Here is a sample video for your help.",
"elementName": "media_video_template2",
"id": "11ce423b-4d77-4a97-a5a0-aa91bdbde1f4",
"languageCode": "en",
"languagePolicy": "deterministic",
"master": true,
"meta": "{\"example\":\"Here is a sample video for your help.\"}",
"modifiedOn": 1638721806995,
"reason": "Template not submitted due to internal error. Try again",
"status": "REJECTED",
"templateType": "VIDEO",
"vertical": "ISSUE_RESOLUTION"
},
{
"category": "ACCOUNT_UPDATE",
"createdOn": 1630544236074,
"data": "Buen día, {{1}}. ✨En redes sociales es fundamental saber cómo transmitir mensajes a tus clientes. 🔊 👀\\\\nHoy aprenderás a mejorar la comunicación con tus clientes 💬 y conocerás una herramienta muy útil para este proceso: *WhatsApp Business*.\\\\n💡 Revisa la infografía que te compartimos en este mensaje para enterarte de más.",
"elementName": "digital_basico_m01_comunicacion_con_clientes_v1_doc",
"id": "1a6b3d02-948d-4040-b7d2-8a6092ae8d81",
"languageCode": "es",
"languagePolicy": "deterministic",
"master": true,
"meta": "{\"example\":\"Buen día, [Leo Q]. ✨En redes sociales es fundamental saber cómo transmitir mensajes a tus clientes. 🔊 👀\\\\\\\\nHoy aprenderás a mejorar la comunicación con tus clientes 💬 y conocerás una herramienta muy útil para este proceso: *WhatsApp Business*.\\\\\\\\n💡 Revisa la infografía que te compartimos en este mensaje para enterarte de más.\"}",
"modifiedOn": 1638721806995,
"reason": "Promotional Content",
"status": "REJECTED",
"templateType": "DOCUMENT",
"vertical": "comunicacion"
}
]
}
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
source | 918910567700 | |
sandbox | false | |
destination | 918286836492 | |
template | {"id": "007b7c0e-fc8d-4698-a9a8-3938151dd5da","params": ["monday","2020-12-20","apps"]} | |
src.name | GupshupDevAssistant01 |
|
Using this API, you can delete a template using the elementName
for it. You will need below details to start using this API.
NOTE: This action is irreversible. Once a template has been deleted, it cannot be restored.
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 | |
elementName | order_update |
|
this api will provide the access token for accessing particular app.
you can use this token to get app’s templates , submit templates, send messages etc.
you will need below details to start using this api.
1. partner token
Key | Value | Description |
---|---|---|
token | {{PARTNER_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
|
You have to first use this api to get the token, this will help you in accessing other apis.
currently expirey for the token is 24 hours.
Key | Value | Description |
---|---|---|
shahsharad1111@gmail.com | ||
password | sharad |
|
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
phone | 918286836492 | |
isBlocked | true |
|
Using this API, you can enable or disable template messaging for an App. You will need below details to start using this API.
Key | Value | Description |
---|---|---|
Content-Type | application/x-www-form-urlencoded | |
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
isHSMEnabled | true | Possible values: true or false
|
|
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
phone | 918286836492 | |
isBlocked | true |
|
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
phone | 918286831212 |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
|
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
|
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appID | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
phone | 918286836492 |
|
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
The response of this endpoint will be
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_TOKEN}} |
Key | Value | Description |
---|---|---|
apiKey | 7e411e0332704866c83b94df2eaa2054 | |
appName | assistant0092 |
|
This api will provide you the list of Apps which are linked to your account.
Required parameter is only ‘partner token’.
you will need app id and app access token in order to access app related apis and this api will help you get the id for the app.
Key | Value | Description |
---|---|---|
token | {{PARTNER_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Content-Type | application/x-www-form-urlencoded | |
Authorization | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97850d-add3-4557-1535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
callbackUrl | https://webhook.site/f9858e13-3fea-4561-b0de-9592dff5d970 | Learn how you can successfully set a callback URL for an app. |
|
Using this API, you can update the gupshup fee cap for an app
Key | Value | Description |
---|---|---|
Connection | keep-alive | |
token | {{PARTNER_APP_TOKEN}} |
Key | Value | Description |
---|---|---|
appId | 9e97650d-add3-4557-9535-4cdf47c3fa68 |
Key | Value | Description |
---|---|---|
cap | 100 | Values supported between: 50 to 750 |
|
Using this API you can get the inbound message logs for the specified duration.
Key | Value | Description |
---|---|---|
token | {{PARTNER_TOKEN}} |
Key | Value | Description |
---|---|---|
Id optional | 9e97a0d-add3-4as557-1535-4cdf47c3fa68 | Unique identifier for a message |
appId optional | as97850d-adad3-4557-1535-4cdf47c3asfa68 | Unique identifier for an app |
date | 02-05-2022 | date in DD-MM-YYYY format. Note: Data only gets updated every day at 8am IST / 11.30pm Brazil time / 4.30am Zimbabwe time. Hence you will not get logs for current day. |
start | 1651500199740 | The start time in EPOCH format. The difference between start and end time must be less than or equal to 10 minutes/ 600000 milliseconds. |
end | 1651500799740 | The end time in EPOCH format |
|
Using this API you can get the outbound message logs for the specified date.
Key | Value | Description |
---|---|---|
token | {{PARTNER_TOKEN}} |
Key | Value | Description |
---|---|---|
Id optional | 9e97a0d-add3-4as557-1535-4cdf47c3fa68 | Unique identifier for a message |
appId optional | as97850d-adad3-4557-1535-4cdf47c3asfa68 | Unique identifier for an app |
date | 02-05-2022 | date in DD-MM-YYYY format. Note: Data only gets updated every day at 8am IST / 11.30pm Brazil time / 4.30am Zimbabwe time. Hence you will not get logs for current day. |
|
Using this API you can get the daily usage breakdown for a particular app ranging between two dates.
Key | Value | Description |
---|---|---|
token | sk_19eew348befyg27057fa1ff999869f | Partner app token |
Key | Value | Description |
---|---|---|
from | 2022-03-01 | date in YYYY-MM-DD format. |
to | 2022-04-01 | date in YYYY-MM-DD format. |
Key | Value | Description |
---|---|---|
appId | 832a9f7-aa33-4aad-8b67-c23d81263 |
|
Using this API you can get the daily discount, daily bill, and the cumulative bill for a particular app ranging a month.
Key | Value | Description |
---|---|---|
token | sk_19eew348befyg27057fa1ff999869f | Partner app token |
Key | Value | Description |
---|---|---|
year | 2022 | Year in YYYY format. |
month | 04 | Month in MM format. |
Key | Value | Description |
---|---|---|
appId | 832a9f7-aa33-4aad-8b67-c23d81263 |
|
Key | Value | Description |
---|---|---|
Content-Type | application/x-www-form-urlencoded | |
Authorization | {{app_token}} |
Key | Value | Description |
---|---|---|
appId | 9e97850d-add3-4557-1535-4hdy7c3fa68 |
Key | Value | Description |
---|---|---|
enableOptinMessage | True | Enable or disable gupshup's automated opt-in message for an app. Possible values: True , False |
Status: 202 Accepted
|
Key | Value | Description |
---|---|---|
Content-Type | application/x-www-form-urlencoded | |
Authorization | {{app_token}} |
Key | Value | Description |
---|---|---|
appId | 9e97850d-add3-4557-1535-4hdy7c3fa68 |
Key | Value | Description |
---|---|---|
modes | READ | Update inbound events that you want to receive on your App's callback URL. You may provide all the values for which you want to receive events. If no values are provided, all events will be deselected. Possible values - DLR events: DELIVERED , READ , SENT , DELETED , and OTHERS . System events: TEMPLATE and ACCOUNT . |
Status: 204 Accepted
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|
Key | Value | Description |
---|---|---|
Authorization | {{PARTNER_APP_TOKEN}} |
|