Template Management API

Manage your templates for email or SMS from your Software using this API

  • HTTP API Manage templates from any programming language.
  • 99.9% SLA, We optimize the performance of all servers.
SMS API

Programming languages

Click on the programming language and access examples to integrate the Template Management API with just copy and paste

API functionality

Add template to a group

API method that allows you to create a template for SMS, voice or email.
Parameter Description Compulsory / Optional
class=template Class requested: Class to which the request is made Compulsory
method=addtemplate 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
title Message title Compulsory
message Message Compulsory
type Type of message (Possible values: mobile, whatsapp or email) Compulsory

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

Parameters:

  • class : template
  • method : addtemplate
  • user : user
  • password : password
  • title : title test
  • message : title message
  • type : mobile

Request:

https://www.afilnet.com/api/http/?class=template&method=addtemplate&user=user&password=password&title=title test&message=title message&type=mobile

Get template list

API method that returns the list of active templates in your account.
Parameter Description Compulsory / Optional
class=template Class requested: Class to which the request is made Compulsory
method=gettemplates 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 message (Possible values: mobile, whatsapp or email) Optional
start Results are returned in 50s, you must indicate the offset here 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

Parameters:

  • class : template
  • method : gettemplates
  • user : user
  • password : password
  • type : mobile
  • start : 0

Request:

https://www.afilnet.com/api/http/?class=template&method=gettemplates&user=user&password=password&type=mobile&start=0

Get template

API method that returns the indicated template.
Parameter Description Compulsory / Optional
class=template Class requested: Class to which the request is made Compulsory
method=gettemplate 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
idtemplate template identifier Compulsory

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

Parameters:

  • class : template
  • method : gettemplate
  • user : user
  • password : password
  • idtemplate : 1000

Request:

https://www.afilnet.com/api/http/?class=template&method=gettemplate&user=user&password=password&idtemplate=1000

Delete template

API method that allows you to delete an active template in your account.
Parameter Description Compulsory / Optional
class=template Class requested: Class to which the request is made Compulsory
method=deletetemplate 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
idtemplate Template identifier Compulsory

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
NOT_ACCESS_TO_TEMPLATE You haven't access to the selected template
ERROR_ASSIGNED_EVENT you can't delete the group because exists events associated to this group

Parameters:

  • class : template
  • method : deletetemplate
  • user : user
  • password : password
  • idtemplate : 1000

Request:

https://www.afilnet.com/api/http/?class=template&method=deletetemplate&user=user&password=password&idtemplate=1000

Tools that enhance our Template Management API

SECURE API CONNECTION

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

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

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 Templates API

Follow the prompts to use the API

01

Request your free trial

To access the template management API, you must first be registered as an Afilnet client. Registration is easy and will only take a few minutes.

02

Integrate the Templates API

Integrate template management into your software using the code examples we provide.

03

Use the API unlimited

Make as many requests to our template management API as you like, with no restrictions.

04

Welcome to Afilnet!

Everything ready!, has managed to improve its communications with Afilnet. We are here to support our API when you need it

Try Afilnet for free!

Sign up for free and try Afilnet! We offer you a free trial of our services. *



(*) Promotion only valid for companies that have never used the Afilnet service before. When requesting the free balance, Afilnet may request to verify your company information


Bulk SMS · Email Marketing · Social network · Instant messaging · Certification · and much more
Continue IMPORTANT INFORMATION ABOUT COOKIES: If you continue to use this web we will assume that you accept the terms of use. You will find more information in our Cookies Policy.
Payment methods
Wire transfer
Credit card
Paypal
Western Union
Skrill
Crypto
Afilnet in your language

Copyright © 2024 Afilnet · All rights reserved