Skip to content
DaDaPush Client For PHP
PHP Shell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.openapi-generator
docs
src
test/Api
.openapi-generator-ignore
.php_cs
README.md
composer.json
git_push.sh
phpunit.xml.dist

README.md

DaDaPushClient

DaDaPush: Real-time Notifications App

Send real-time notifications through our API without coding and maintaining your own app for iOS or Android devices.

This PHP package is automatically generated by the OpenAPI Generator project:

  • API version: v1
  • Package version: 1.0.0
  • Build package: org.openapitools.codegen.languages.PhpClientCodegen For more information, please visit https://www.dadapush.com

Requirements

PHP 5.5 and later

Installation & Usage

Composer

To install the bindings via Composer, add the following to composer.json:

{
    "require": {
        "dadapush/dadapush-php-client": "1.0.0"
    }
}

or use git repo

{
  "repositories": [
    {
      "type": "vcs",
      "url": "https://github.com/dadapush/dadapush-php-client.git"
    }
  ],
  "require": {
    "dadapush/dadapush-php-client": "*@dev"
  }
}

Then run composer install

Manual Installation

Download the files and include autoload.php:

    require_once('/path/to/DaDaPushClient/vendor/autoload.php');

Tests

To run the unit tests:

composer install
./vendor/bin/phpunit

Getting Started

Please follow the installation procedure and then run the following:

<?php
require_once(__DIR__ . '/vendor/autoload.php');



$apiInstance = new DaDaPushClient\Api\DaDaPushMessageApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$body = new \DaDaPushClient\Model\MessagePushRequest(); // \DaDaPushClient\Model\MessagePushRequest | body
$x_channel_token = 'x_channel_token_example'; // string | see: https://www.dadapush.com/channel/list

try {
    $result = $apiInstance->createMessage($body, $x_channel_token);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling DaDaPushMessageApi->createMessage: ', $e->getMessage(), PHP_EOL;
}

?>

Documentation for API Endpoints

All URIs are relative to https://www.dadapush.com

Class Method HTTP request Description
DaDaPushMessageApi createMessage POST /api/v1/message push Message to a Channel
DaDaPushMessageApi deleteMessage DELETE /api/v1/message/{messageId} delete a Channel Message
DaDaPushMessageApi getMessage GET /api/v1/message/{messageId} get a Channel Message
DaDaPushMessageApi getMessages GET /api/v1/messages get Message List

Documentation For Models

Author

contacts@dadapush.com

You can’t perform that action at this time.