wrtisans/stpmex-php

Maintainers

👁 pechanxur

Package info

github.com/wrtisans/stpmex-php

pkg:composer/wrtisans/stpmex-php

Statistics

Installs: 84

Dependents: 0

Suggesters: 0

Stars: 3

Open Issues: 0

v0.1.4 2021-09-27 03:14 UTC

Requires

Requires (Dev)

None

Suggests

None

Provides

None

Conflicts

None

Replaces

None

MIT 45bab84cf34a419c3596eb76cdffd2412b9c1d4e

stp

This package is auto-updated.

Last update: 2026-06-25 15:03:08 UTC


README

👁 StyleCI
👁 Total Downloads
👁 License

Installation

composer require wrtisans/stpmex-php

Usage

Client

Example:

<?php

use Wrtisans\STP\Client;

$account = '646180123400000001';
$key = file_get_contents('key.pem');
$passphrase = '12345678';
$live = false;

$client = new Client($account, $key, $passphrase, $live);

Account Service

Example:

<?php

use Wrtisans\STP\Client;

$client = new Client(...);

$client->account()->balance();

Catalogue Service

Example:

<?php

use Wrtisans\STP\Client;

$client = new Client(...);

$client->catalogue()->get();

Order Service

Example:

<?php

use Wrtisans\STP\Client;
use Wrtisans\STP\Catalogue\{
 AccountTypeCatalogue,
 FinancialInstitutionCatalogue
};

$client = new Client(...);

$client->order()->create([
 'claveRastreo' => '123456789000000000000000003',
 'conceptoPago' => 'wrtisans Payment',
 'emailBeneficiario' => 'john.doe@example.com',
 'cuentaBeneficiario' => '012345678987654321',
 'empresa' => 'wrtisans',
 'institucionContraparte' => FinancialInstitutionCatalogue::BANORTE_IXE,
 'institucionOperante' => FinancialInstitutionCatalogue::STP,
 'iva' => 16.00,
 'monto' => 1200.00,
 'nombreBeneficiario' => 'John Doe',
 'nombreOrdenante' => 'wrtisans SAPI de CV',
 'prioridad' => 1,
 'referenciaNumerica' => '1234567',
 'tipoCuentaBeneficiario' => AccountTypeCatalogue::CLABE,
 'tipoPago' => PaymentTypeCatalogue::THIRD_PARTIES,
 'medioEntrega' => 3,
]);

License

The STP Mexico PHP library is open-sourced software licensed under the MIT license.