Documentations

We provide WhatsApp Business Api with native endpoints without any change so you can use WhatsApp Business Api Documentation. WhatsApp Business Api Documentation: https://developers.facebook.com/docs/whatsapp/api/reference


Requirements

Your instance url: https://instance-your_id.whatsapp.yapaytech.com

Api Key: your_api_key

Admin Api Key: your_admin_api_key

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/{{ endpoint }} \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
	    {{ body }}
     }'

Messages

/v1/messages

Use the messages node to send text messages, media/documents, Message Templates, and group messages to your customers.

https://developers.facebook.com/docs/whatsapp/api/messages

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/messages\
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "recipient_type": "individual" | "group",
  	"to": "whatsapp-id" | "whatsapp-group-id",
        "type": "text",
        "text":{
            "body": "your-message-content"
        }
    }'
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/messages\
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "recipient_type": "individual" | "group",
        "to": "whatsapp-id" | "whatsapp-group-id",
        "type": "audio" | "document" | "sticker" | "image" | "video",
        "audio": {
            "id": "your-media-id",
        }
        "document": {
            "id": "your-media-id",
            "caption": "your-document-caption-to-be-sent",
            "filename": "your-document-filename"
        }
        "document": {
            "link": "http(s)://the-url"
            "provider": {
                "name" : "provider-name"
            }
            "caption": "your-document-caption"
        }
        "video": {
            "link": "http(s)://the-url"
            "provider": {
                "name" : "provider-name"
            }
            "caption": "your-video-caption"
        }
        "document": {
            "link": "http(s)://the-url.pdf",
            "caption": "your-document-caption"
        }
        "video": {
            "id": "your-media-id",
            "caption": "your-video-caption"    
        }
        "image": {
            "link": "http(s)://the-url",
            "provider": {
                "name" : "provider-name"
            },
            "caption": "your-image-caption"
        }
        "image": {
            "id": "your-media-id",
            "caption": "your-image-caption"
        }
        "sticker": {
            "id": "your-media-id"
        }
        "sticker": {
            "link": "http(s)://the-url",
            "provider": {
                "name" : "provider-name"
            }
        }
    }'
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/messages\
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "recipient_type": "individual" | "group",
        "to": "whatsapp-id" | "whatsapp-group-id",
        "type": "hsm",
        "hsm": { 
            "namespace": "cdb2df51_9816_c754_c5a4_64cdabdcad3e",
            "element_name": "purchase_with_credit_card", 
            "language": {
                "policy": "deterministic",
                "code": "en_US"
            },
            "localizable_params": [ 
                { "default": "$10" }, 
                { "default": "1234" } 
            ]
        }
    }'
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/messages\
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "recipient_type": "individual" | "group",
        "to": "whatsapp-id" | "whatsapp-group-id",
        "type": "contacts",
        "contacts":[
            {
                "name": {
                    "first_name": "John",
                    "formatted_name": "John Smith",
                    "last_name": "Smith"
                },
                "phones": [
                    {
                        "phone": "+1 (940) 555-1234",
                        "type": "HOME"
                    },
                    {
                        "phone": "+1 (650) 555-1234",
                        "type": "WORK",
                        "wa_id": "16505551234"
                    }
                ], 
            }
        ]
    }'
            

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/messages\
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "recipient_type": "individual" | "group",
        "to": "whatsapp-id" | "whatsapp-group-id",
        "type": "location",
        "location": {
            "longitude": -122.425332,
            "latitude": 37.758056,
            "name": "Facebook HQ",
            "address": "1 Hacker Way, Menlo Park, CA 94025"
        }
    }'
            


Groups

/v1/groups

Use the groups node to create and manage groups. When you send a request to create a group, the response contains a group ID field that you can use to send messages to the group and accomplish other tasks.

https://developers.facebook.com/docs/whatsapp/api/groups

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/groups \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "subject": "your-group-subject"
    }'
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/groups \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/groups/your-group-id \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X PUT \
    https://xxx.whatsapp.yapaytech.com/v1/groups/your-group-id \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "subject": "new-group-subject"
    }'
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/groups/your-group-id/invite \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X DELETE \
    https://xxx.whatsapp.yapaytech.com/v1/groups/your-group-id/invite \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/groups/your-group-id/leave \
    -H 'Authorization: Api Key' \
    -H 'Content-Type: application/json' \
        


Settings

/v1/settings

Use the settings node to configure the WhatsApp Business API Client, your business profile, your profile, groups, your account, and to backup and restore data. You can also use the WhatsApp Web Business Tool to configure some settings for the WhatsApp Business API Client and your WhatsApp Account.

https://developers.facebook.com/docs/whatsapp/api/settings

    curl -X PATCH \
    https://xxx.whatsapp.yapaytech.com/v1/settings/application \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "callback_persist": true | false,
        "max_callback_backoff_delay_ms": "max-delay-in-ms",
        "media": {
            "auto_download": ["audio", "document", "voice", "video", "image", "sticker"]
        }
        "callback_backoff_delay_ms": "delay-in-ms",
        "on_call_pager": "on-call-pager-group-id",
        "pass_through": false | true,
        "sent_status": false | true,
        "heartbeat_interval": heartbeat-interval-in-secs,
        "unhealthy_interval": unhealthy-interval-in-secs,
        "webhooks": { 
            # see Webhooks Settings below
            "max_concurrent_requests": max-num-of-callback-requests,
            "url": "webhook.your-domain"
        },
        "axolotl_context_striping_disabled": false | true
    }'
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/settings/application \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X DELETE \
    https://xxx.whatsapp.yapaytech.com/v1/settings/application \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/settings/business/profile \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "address": "your-business-address",
        "description": "your-business-description",
        "email": "your-business-email",
        "vertical": "your-business-industry",
        "websites": [ "your-website-1", "your-website-2" ]
    }'
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/settings/business/profile \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X PATCH \
    https://xxx.whatsapp.yapaytech.com/v1/settings/profile/about \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "text": "your-profile-about-text"
    }'
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/settings/profile/about \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/settings/profile/photo \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: image/png' \
    --data-binary @your-path-to-image
        

    curl -X GET \
    https://xxx.whatsapp.yapaytech.com/v1/settings/profile/photo \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/settings/backup \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "password": "your-password"
    }'
        

    curl -X POST \
    https://xxx.whatsapp.yapaytech.com/v1/settings/restore \
    -H 'Authorization: Admin Api Key' \
    -H 'Content-Type: application/json' \
    -d '{
        "password": "your-password",
        "data": "your-encrypted-backup-data"
    }'