Integration to stpmex.com
Project description
STP client python3 client library
Cliente para el servicio SOAP de STP
Demo wsdl: https://demo.stpmex.com:7024/speidemo/webservices/SpeiActualizaServices?wsdl
Requerimientos
Python v3 o superior.
Instalación
Se puede instalar desde Pypi usando
pip install stpmex
Test
Para ejecutar los test utlizando el archivo Makefile
$ make test
Uso básico
Comenzar configurando el cliente con las credenciales
import stpmex
Obtener la llave PEM
PKEY_ADD = '/Users/test/prueba-key.pem'
with open(PKEY_ADD) as fp:
private_key = fp.read()
Utilizar configure() para configurar las credenciales a utilizar
stpmex.configure(wsdl_path='https://demo.stpmex.com:7024/speidemo/webservices/SpeiActualizaServices?wsdl', empresa='PRUEBA', priv_key=private_key, priv_key_passphrase='12345678', prefijo=9999)
Para crear una nueva orden, crear una instancia de Orden y llamar registra()
orden = stpmex.Orden(conceptoPago='Prueba', institucionOperante=stpmex.types.Institucion.STP.value, cuentaBeneficiario='846180000400000001', institucionContraparte=846, monto=1234, nombreBeneficiario='Benito Juárez')
orden.registra()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
stpmex-0.0.2.tar.gz
(4.5 kB
view hashes)
Built Distribution
stpmex-0.0.2-py3-none-any.whl
(5.2 kB
view hashes)