Get a signmii

Getting a signmii returns the encoding of a digital digest which is timestamped and serialized.

Generating 1 signmii by program costs 1 credit. To buy credit units, click on the cart Credit in the banner of your home page.

IMPORTANT: Always keep the original file and its signmii together on your system.

Download the code of the sendget function defined in the file sendhttp.php. Copy the file in the space of your application.

NOTE: See the page Call the service API for a description of the sendget function.

loginYour identification code.
passwordYour password.
sha1SHA1 digital digest to encode.

sha1 is a SHA1 digest in hexadecimal, a string of 40 characters composed with digits and the letters a to f or A to F.

Add the file getsignmii.php with the following content:

  1. require_once 'sendhttp.php';

Loads the code of the sendget function provided by iZend.

  1. function getsignmii($login, $password, $sha1) {

Defines the function getsignmii. $login is your identification code. $password is your password. $sha1 is the SHA1 digest to encode.

  1.     $curl = 'https://signmii.com/api/getsignmii';
  2.     $args = array(
  3.         'login'     => $login,
  4.         'password'  => $password,
  5.         'sha1'      => $sha1,
  6.     );

Sets $curl to the URL of the getsignmii action. Fills the array $args with the parameters of the getsignmii action. NOTE: Replace http by https in the URL to encrypt the communication.

  1.     $response=sendget($curl, $args);

Sends the HTTP request with sendget.

  1.     if (!$response or $response[0] != 200) {
  2.         return false;
  3.     }

If $response is false, the server is unreachable. If $response[0] doesn't contain the HTTP return code 200 Ok, an execution error has occurred. In case of error, getsignmii returns false.

  1.     return $response[2];
  2. }

Returns the body of the response, i.e. the signmii.


Assuming you have saved the files sendhttp.php and getcredit.php in the current directory, run PHP in interactive mode, generate a SHA1 digest with the PHP function sha1, load the getcredit function and call it with your identification code, your password and the SHA1 in argument:

$ php -a
php > $sha1=sha1('signmii');
php > echo $sha1;
php > require_once 'getsignmii.php';
php > $signmii=getsignmii('abcdef', 'ABCDEF', $sha1);
php > echo $signmii;
php > quit

Check your credit, Check a signmii and Download a QR


Your comment:
[p] [b] [i] [u] [s] [quote] [pre] [br] [code] [url] [email] strip help 2000

Enter a maximum of 2000 characters.
Improve the presentation of your text with the following formatting tags:
[p]paragraph[/p], [b]bold[/b], [i]italics[/i], [u]underline[/u], [s]strike[/s], [quote]citation[/quote], [pre]as is[/pre], [br]line break,
[url]http://www.izend.org[/url], [url=http://www.izend.org]site[/url], [email]izend@izend.org[/email], [email=izend@izend.org]izend[/email],
[code]commande[/code], [code=langage]code source en c, java, php, html, javascript, xml, css, sql, bash, dos, make, etc.[/code].