API authentication
Authenticate your users through the authentication API, improve the security of your software
- Multichannel, Compatible with SMS, Voice, WhatsAPP and Email.
- Customizable code, Generate codes with different types of characters.
- 99.9% SLA, We optimize the performance of all servers.
- Expiration, Indicate the expiration time of the codes you want.

Authentication API functionalities
OTP
Parameter | Description | Compulsory / Optional |
---|---|---|
class=otp | Class requested: Class to which the request is made | Compulsory |
method=generateotp | Class method requested: Method of the class to which the request is made | Compulsory |
user | User and e-mail of your Afilnet account | Compulsory |
password | Password of your Afilnet account | Compulsory |
type | Type of group (email or mobile) | Compulsory |
destination | Mobile number or destination email | Compulsory |
time | Number of days, weeks, months or years | Optional |
timetype | Type of time (Posible value: minutes, hours, days, weeks, months o years) | Optional |
length | Length of the password to generate | Optional |
otpformat | Format of the password to generate, if it includes all the characters, only numbers or only letters (all, numbers, letters) | Optional |
output | Output format of the result | Optional |
Answer:
- status
-
result (if status=success), here you will receive the following values:
- status
- code
- error (if status=error), here you will receive the error code
Error codes:
Code | Description |
---|---|
MISSING_USER | User or email not included |
MISSING_PASSWORD | Password not included |
MISSING_CLASS | Class not included |
MISSING_METHOD | Method not included |
MISSING_COMPULSORY_PARAM | Compulsory parameter not included |
INCORRECT_USER_PASSWORD | Incorrect user or password |
INCORRECT_CLASS | Incorrect class |
INCORRECT_METHOD | Incorrect method |
INCORRECT_TIME_TYPE | Incorrect type of time (possible values: minutes, hours, days, weeks, months or years) |
INCORRECT_TYPE | Incorrect type. The type must be mobile or email |
INCORRECT_FORMAT | The recipient's format is not correct (verify the recipient's email or number) |
INCORRECT_OTP_FORMAT | The OTP format to generate does not exist, this must be one of the following values: all, letters, numbers |
Parameters:
- class : otp
- method : generateotp
- user : user
- password : password
- type : number
- destination : 34600000000
- time : 1
- timetype : days
- length : 6
- otpformat : all
- output :
Request:
Verify OTP
Parameter | Description | Compulsory / Optional |
---|---|---|
class=otp | Class requested: Class to which the request is made | Compulsory |
method=verifyotp | Class method requested: Method of the class to which the request is made | Compulsory |
user | User and e-mail of your Afilnet account | Compulsory |
password | Password of your Afilnet account | Compulsory |
destination | Mobile number or destination email | Compulsory |
code | Password to verify | Optional |
output | Output format of the result | Optional |
Answer:
- status
-
result (if status=success), here you will receive the following values:
- No additional values will be sent to you
- error (if status=error), here you will receive the error code
Error codes:
Code | Description |
---|---|
MISSING_USER | User or email not included |
MISSING_PASSWORD | Password not included |
MISSING_CLASS | Class not included |
MISSING_METHOD | Method not included |
MISSING_COMPULSORY_PARAM | Compulsory parameter not included |
INCORRECT_USER_PASSWORD | Incorrect user or password |
INCORRECT_CLASS | Incorrect class |
INCORRECT_METHOD | Incorrect method |
CODE_NOT_FOUND | The code sent is incorrect or has expired |
Parameters:
- class : otp
- method : verifyotp
- user : user
- password : password
- destination : 34600000000
- code : A73HF3I
- output :
Request:
Tools that enhance our Authentication API

SECURE API CONNECTION
Security tailored to your business
Configure your API connections, create new accesses and manage existing ones.
Filter all API accesses by IP, add or remove enabled IPs to guarantee the security of your accesses.
Keep track of all connections made, API used and connection dates / time

MULTIPLE APIs
Connectivity tailored to your business
We offer you multiple APIs to connect with us, we have an HTTP API, BASIC AUTH, SOAP and JWT Authentication so that you can connect with us the way you want.
Connect with any of the APIs in a secure, simple and centralized way . Afilnet API is perfect for your software.

API Logs
Get to know each request in detail
Thanks to our logs you will be able to review all the requests made and the corresponding response from our API, which will allow you to consult details when you need them.
The information you can consult is the following:
- Source IP of the request
- Date & Time of the request
- API & Method being called
- Parameters sent to the API
- API response
- metadata
Steps to use the Authentication API
To use the Authentication API follow these steps
Register as a client
In order to access the authentication API, you must be an Afilnet client. Signing up will only take a few minutes.
Perform authentication integration
Integrate authentication in your Software thanks to the examples that we offer you. Contact us if you have any questions.
Request your free trial
We offer you a trial balance so you can integrate our authentication API at no cost.
Welcome to Afilnet!
Everything ready!, has managed to improve its communications with Afilnet. We are here to support our API when you need it