2017 © Pedro Peláez
 

library tipimail

PHP API library for the tipimail email as a service platform

image

tipimail/tipimail

PHP API library for the tipimail email as a service platform

  • Friday, December 9, 2016
  • by gauthierdhu
  • Repository
  • 3 Watchers
  • 1 Stars
  • 4,352 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 2 Versions
  • 9 % Grown

The README.md

Tipimail PHP Library

This is the Tipimail PHP SDK. This SDK contains methods for easily interacting with your Tipimail account. You can send emails, manage your account and retrieve your statistics., (*1)

You will find examples in this Readme to get you started. If you need more help, please see our official API documentation at https://docs.tipimail.com/en/integrate/api (French version at https://docs.tipimail.com/fr/integrate/api - All Tipimail documentation at https://docs.tipimail.com)., (*2)

Prerequisites

Make sure to have the following details:, (*3)

  • Tipimail API User
  • Tipimail API Secret key
  • PHP >= 5.3

Installation

The preferred method of installation is via Composer or Packagist. Run the following command to install the package:, (*4)

# Install Composer
curl -sS https://getcomposer.org/installer | php

# Download Tipimail SDK
php composer.phar require tipimail/tipimail

Integrate Tipimail

Next, Compose create an autoloader file, in your application, to automatically load the Tipimail SDK in your project. You just have to add this line:, (*5)

require 'vendor/autoload.php';
use Tipimail\Tipimail;
use Tipimail\Exceptions;

You just have to add your credentials to start using the SDK:, (*6)

$tipimail = new Tipimail('API user', 'API key');

Usage

Now, you can use the SDK to do a lot of action with Tipimail: * Send emails * Retrieve your analytics * Manage your account, (*7)

We return exceptions if the program occurs an error. So we advice to use try/catch feature., (*8)

Examples

Get stats from email send

// StatisticsSends
/*
object(StatisticsSends)[14]
  private 'error' => int 198
  private 'rejected' => int 0
  private 'requested' => int 197573
  private 'deferred' => int 11
  private 'scheduled' => int 0
  private 'filtered' => int 14
  private 'delivered' => int 188148
  private 'hardbounced' => int 1232
  private 'softbounced' => int 87240
  private 'open' => int 909
  private 'click' => int 191
  private 'read' => int 0
  private 'unsubscribed' => int 4
  private 'complaint' => int 68
  private 'opener' => int 603
  private 'clicker' => int 87
*/
try {
    $result = $tipimail->getStatisticsService()->getSends(null, null, null, null, null);
    var_dump($result);
}
catch(Exceptions\TipimailException $e) {

}

Get details from a message ID

// StatisticsMessagedetails
// /analytics/message/{messageid}
/*
object(StatisticsMessageDetails)[15]
  private 'id' => string '562a35f99932f6e1a6998ed3' (length=24)
  private 'apiKey' => string '3262b4f287869bbc8ed24d7767f0000b' (length=32)
  private 'createdDate' => string '1445606904' (length=10)
  private 'lastStateDate' => string '1445606905' (length=10)
  private 'msg' =>
    object(StatisticsMessageInfo)[16]
      private 'from' => string 'support@tipimail.com' (length=20)
      private 'email' => string 'test@sbr27.net' (length=14)
      private 'subject' => string 'Tipimail-checker' (length=16)
      private 'size' => int 184
  private 'lastState' => string 'delivered' (length=9)
  private 'open' => int 0
  private 'click' => int 0
*/
try {
    $result = $tipimail->getStatisticsService()->getMessageDetail('562a35f99932f6e1a6998ed3');
    var_dump($result);
}
catch(Exceptions\TipimailException $e) {

}

Support, issue and Feedback

Several resources are available to help you: * Our documentation website for additional information about our API. * If you find a bug, please submit the issue in Github directly (tipimail-php-library Issues). * If you need additional assistance, contact our support by emails or phone at https://www.tipimail.com/support., (*9)

The Versions

09/12 2016

dev-master

9999999-dev https://github.com/tipimail/tipimail-php-library.git

PHP API library for the tipimail email as a service platform

  Sources   Download

Apache-2.0

The Requires

  • php >=5.3.0

 

by Tipimail

api email transactional

09/12 2016

0.1.59

0.1.59.0 https://github.com/tipimail/tipimail-php-library.git

PHP API library for the tipimail email as a service platform

  Sources   Download

Apache-2.0

The Requires

  • php >=5.3.0

 

by Tipimail

api email transactional