ThreeTZ developer Guide

DEMO

Download DEMO source code (PHP)

Version 1.0.0, 2016/01/01
Community & support forum

What is tz number

A one-time TZ number is an automatically generated numeric or alphanumeric string of characters that authenticates the user for a single transaction or session.
 

The benefits of tz number

Free alernative solution for paid mobile sms for worldwide users.

1. TZ number as Captcha, stop bots

2. One time TZ number for 2-step verification

3. Send free html messages to your members who are using ThreeTZ app.

 

How TZ number works?

Every app users have their unique mid by mobile device, developer obtain their mid with one time TZ number by API. If the mid is existed or match your records, the user is verified.
 

How to get TZ number?

1. install threetz app : http://www.threetz.com
2. open threetz app online and click get
 

Integrate TZ number with your website

Before you do the integration

1. install threetz app into your smart phone : http://www.threetz.com
2. Sign up as a ThreeTZ developer with your TZ number to get API code for your sites :
http://otp.threetz.com/developers/

 

 

API Url & Parameters ( * required)

API url (POST or GET)

http://otp.threetz.com/api/get_aid_by_seq.php

  Parameter Name Type Note
* seq TZ Number Integer (6) one time 6 digits TZ number from users
* id Developers ID String Your Developers ID
* domain domain String Text format like:
www.domain.com
domain.com
subdomain.domain.com
* key key for domain String Your domain key

Feedback

Success: mid for android (15 characters) or mid for ios (36 characters)
Failure : -1

 

Use TZ number as Captcha, stop bots

1. Obtain unique mid by TZ number
check if TZ number return a valid mid

demo code:

if(isset($_GET['seq'])) {
$seq = $_GET['seq'];//TZ number submitted by user
$id='your registered developer ID';//your registered developer ID
$domain='your registered domain';//your registered domain
$key='key for the registered domain';//key for the registered domain

$postUrl = "http://otp.threetz.com/api/get_aid_by_seq.php?id=$id&domain=$domain&key=$key&seq=$seq";
$mid = file_get_contents($postUrl);
if(strlen($mid)==15 || strlen($mid)==36){
echo "mid=".$mid;
exit;
} else {
echo "TZ number [ ".$seq." ] is invalid or expired。Please get TZ number again !!";
}
}

demo demo download
 

Do 2-step verification

1.check if TZ number return a valid mid
2. if match the user mid records

demo code:

if(isset($_GET['seq'])) {
$seq = $_GET['seq'];//TZ number submitted by user
$id='your registered developer ID';//your registered developer ID
$domain='your registered domain';//your registered domain
$key='key for the registered domain';//key for the registered domain

$postUrl = "http://otp.threetz.com/api/get_aid_by_seq.php?id=$id&domain=$domain&key=$key&seq=$seq";
$mid = file_get_contents($postUrl);
if(strlen($mid)==15 || strlen($mid)==36){

/* check if this $mid match the reocrd of your member with your own code. */


} else {
echo "TZ number [ ".$seq." ] is invalid or expired。Please get TZ number again !!";
}
}

demo demo download
 

How to send message to your members who used ThreeTZ app.

Login as developer and choose a site from your list to send message
 
http://www.threetz.com