Download the PHP package multiservicios-web/valida-curp without Composer
On this page you can find all versions of the php package multiservicios-web/valida-curp. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package valida-curp
ValidaCurp Client
[]()
[
]()
-
This library can validate, calculate and gain CURP information in México.
- Copyright (c) Multiservicios Web JCA S.A. de C.V., https://multiservicios-web.com.mx
- More information: https://valida-curp.com.mx
- License: MIT (https://opensource.org/license/MIT)
1. Requirements
- PHP 7.2 or later
2. Installation
You can install this library via composer by following this command:
3. Account
3.1. Create an account
Create an account by following this link: https://valida-curp.tawk.help/article/registro-de-usuario
3.2. Create a project
Create a project by following this link: https://valida-curp.tawk.help/article/creaci%C3%B3n-de-proyecto
3.3. Get a token
Get your token by following this link: https://valida-curp.tawk.help/article/obtener-token-llave-privada-proyecto
4. Usage
4.1. include "autoload" file and import the library
4.2. Create an instance
The constructor receives as first parameter the token of the project.
4.3. (Optional) setVersion API
You can set the API version to query. You can set 1 or 2. The default value is 2.
5. Methods
5.1. To validate CURP
The method "isValid()" takes a CURP as a parameter. To validate the structure CURP.
Response
5.2. To get CURP data
The method "getData()" takes a CURP as a parameter. To consult the CURP information in RENAPO.
Response
5.3. To calculate a CURP
The method "calculate()" takes an array as parameter. To calculate the structure of a CURP with provided data. Receives an array with the following elements: [names, lastName, secondLastName, birthDay, birthMonth, birthYear, gender, entity]
Response
5.4. To get entities
The method "getEntities()" doesn't take any parameters. To get the list of entities.
Response
6. Full example
To see the full example click on this link https://github.com/hckdrkmx/validaCurp-client/blob/main/index.php
7. Credits
- Copyright (c) Multiservicios Web JCA S.A. de C.V., https://multiservicios-web.com.mx
- Author: Joel Rojas [email protected]
- Grammatical corrections: Yesenia Armendáriz
8. License
This project is released under the MIT License. See the LICENSE file for details.