Skip to main content

Get API

If you want to send SMS with the GET method of the HTTP protocol, you can follow the instructions below. In general, you can integrate the settings in the SMS integration panels of ready-made software or hardware/devices such as firewall into the Ileti Merkezi with the help of the documentation here.

Address to request

GEThttps://api.iletimerkezi.com/v1/send-sms/get/

Request Parameters

https://api.iletimerkezi.com/v1/send-sms/get/?key=API_KEY&hash=API_HASH&text=Lorem%20ipsum%20dolor%20sit%20amet&receipents=5301234569,5301234570&sender=APITEST&iys=1&iysList=BIREYSEL
Hint

After you write your own values ​​in the request parameters, you can try the integration by typing the url address into the address field of your browser. If you get an error, you can see how the error can be resolved in the status and error codes section.

Definitions

The descriptions of the parameters sent in the request are as follows:

  • key: API Key that you can create from the settings section should be written in this field after logging in to your iletimerkezi.com panel. It is required to be sent when making a request.

  • hash: After logging into your iletimerkezi.com panel, the hash generated using the API Key and Secret Key that you can create from the settings section should be written in this field. It is required to be sent when making a request.

  • text: Contains the text of the SMS to be sent. It is required to be sent when making a request. The URL must be encoded.

Hint

If you are not integrating with a ready-made panel or if you are making a panel for sms integration into your own software, you should encode these values ​​as your message text in the "text" field may contain characters that may corrupt the url address.

Every software language has built-in functions that do this encoding.

&text=Example of unencoded message text

After #encode, the message text should appear as follows
&text=Unencoded%20%C5%9F%20message%20text%20%C3%B6rne%C4%9Fi

For more detailed information

  • receipents: Contains the recipient's mobile phone number. The number format should be 5xxxxxxxxx. If more than one recipient is to be defined for the specified message text, the numbers must be separated by commas. It is required to be sent when making a request.

  • sender: It is the header information, consisting of maximum 11 characters, defined from the iletimerkezi.com administration panel and approved by iletimerkezi.com. The sent message is sent to the receiver with the header specified with this parameter. It is required to be sent when making a request. The URL must be encoded.

  • iys: Indicates whether the message will be queried over the Message Management System (İYS). If you send this value as 1 (true), your messages will be queried via IYS, if you send it as 0 (false), it will not be queried. It is required to be sent when making a request.

Hint

This value should legally be 1 if you are sending a commercial message. Otherwise, penalties may apply.

Click for detailed information about İYS.

  • iysList: Indicates the list you want to be queried via the Message Management System (İYS). If you have sent the iys value as 1, that is, if you want your message to be queried via IYS, it is mandatory to send the iysList value as BIREYSEL or TACIR. If you are sending the iys value as 0, this field will be ignored.

Sample Request

https://api.iletimerkezi.com/v1/send-sms/get/?key=3ea65b1e8baxxxx&hash=XXXX&text=Lorem%20ipsum%20dolor%20sit%20amet&receipents=5301234569,5301234570&sender=APITEST&iys=1&iysList=BIREYSEL

Server Response

<response>
<status>
<code></code>
<message></message>
</status>
<order>
<id></id>
</order>
</response>

Definitions

The response from the server is always wrapped in the response tag. The definition of this tag, its subtags, is as follows:

status

Contains information about the transaction status. The values ​​returned by this tag can also be obtained by looking at the header information of the HTTP response. This tag is returned by default on every request made. The alt tags are as follows

  • code: It is the numerical value that indicates the operation status.
  • message: Contains an informational message about the transaction status.

order

Contains the order information created if the transaction was completed successfully. If the operation fails, this tag is not returned. The order tag is not a repeatable tag. Only one order can be submitted per request. The alt tag is as follows:

  • id: Unique numeric value representing the order. By storing the "id" value in your own systems, you can use it when querying the report of the order, and when canceling the order if you have made a post-dated delivery.

Error Codes

If the result of the request is negative, the error codes and messages that will be returned to you by the server are as follows.

codemessageDescription
401Incorrect membership informationkey, hash tag, we give this error when we cannot verify the information you have sent, if you have defined a fixed IP in your account and you are requesting from a different IP, you will get this error again.
402Insufficient balanceIf the balance in your account is not enough to send this order, we give this error.
450sent bnot suitable for useIf the value you sent with the sender tag is not approved in your account, you will get this error, you need to send it as defined in your account. Usually, the changes that cause this error are lowercase and uppercase letters or sending extra space values.
451Repeating orderIf you want to resend the same message text to the same recipients within 10 minutes, the system will return this error to you, so that there is no spam and the same messages are not sent to the same people by mistake. If you need such a transmission, you can differentiate the text of the message by typing the current hour and minute in the message text.
452Message recipients are incorrectIf the phone numbers you sent with the receipents tag are missing or cannot be verified, we give this error. At the same time, if you are sure that the mobile phone number you want to message is correct, you can still get this error if you have added the mobile phone number to your number blocking list.
453Order size exceededIf the text of the message you sent with the text tag is more than seven (7) SMS lengths according to your character encoding, this error will return.
454Message text is emptyIf the text of the message you sent in the text parameter does not contain any value, your message will not be sent and this error message will be returned.

Example Successful Response

<?xml version="1.0" encoding="UTF-8"?>
<response>
<status>
<code>200</code>
<message>Operation Successful</message>
</status>
<order>
<id>323223</id>
</order>
</response>

Example Incorrect Answer

<?xml version="1.0" encoding="UTF-8"?>
<response>
<status>
<code>401</code>
<message>Membership information is incorrect</message>
</status>
</response>