Skip to content

All APIs that Zalo Page opens for a third-party to interact with their fans on Zalo Page

Notifications You must be signed in to change notification settings

zalopage/Zalo-Sdk-Php

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Zalo-Sdk-Php

Installation

Using Composer

  php composer.phar require zalopage/zalo-sdk-php

Example

  try {
    $factory = new ZaloServiceFactory($pageId, $secretKey);
  
    $messageService = $factory->getZaloMessageService();
  
    $zaloPageResult = $messageService->sendTextMessageByPhoneNum($phone, $message, $sms, $isNotify);
  
    if ($zaloPageResult >= 0) {
      echo "Success";
    }
  
  } catch (ZaloSdkException $ex) {
    $error['code'] = $ex->getZaloSdkExceptionErrorCode();
    $error['message'] = $ex->getZaloSdkExceptionMessage();
  } catch (\Exception $ex) {
    $error['code'] = 500;
    $error['message'] = $ex->getMessage();
  }

Credits:

About

All APIs that Zalo Page opens for a third-party to interact with their fans on Zalo Page

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages