Skip to main content

XML Post API

If you want to retrieve the list of phone numbers you have blocked using the POST method of the HTTP protocol in XML format, you can follow the instructions below.

Request URL

POSThttps://api.iletimerkezi.com/v1/get-blacklist

Request Body

<request>
<authentication>
<key></key>
<hash></hash>
</authentication>
<blacklist>
<filter>
<start></start>
<end></end>
</filter>
<page></page>
<rowCount></rowCount>
</blacklist>
</request>

Definitions

The request sent to the server must be wrapped in the request tag. The definitions of its sub-tags are as follows:

authentication

Contains information about the transaction status. The values ​​returned with this tag can also be obtained by looking at the header information of the HTTP response. This tag is returned as standard in every request made. Its subtags are as follows

  • key: After logging into your iletimerkezi.com panel, the API Key that you can create from the settings section should be written in this field. It is mandatory to send it when making a request.

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

blacklist

Contains the filter and pagination parameters required for paging.

  • filter: Used to filter search results. It is not mandatory to send this in the request.

    • start: Represents the start date of blocked numbers. It is not mandatory to send this in the request. It should be in Y-m-d H:i:s format (2024-09-27 01:10:00).
    • end: Represents the end date of blocked numbers. It is not mandatory to send this in the request. It should be in Y-m-d H:i:s format (2024-09-27 23:59:59).
  • page: Represents the search result page. It is not mandatory to send this in the request. The default value is 1.

  • rowCount: Specifies the number of entries per search result page. It is not mandatory to send this in the request. The default value is 1000. The maximum value is 1000. If there are more than 1000 entries, additional requests should be made to query the subsequent search result pages.

Server Response

<?xml version="1.0" encoding="UTF-8"?>
<response>
<status>
<code></code>
<message></message>
</status>
<blacklist>
<count></count>
<number></number>
<number></number>
<number></number>
<number></number>
</blacklist>
</response>

Definitions

The response from the server is always wrapped in the response tag. The definitions of its sub-tags are as follows:

status

Contains information about the transaction status. The values ​​returned with this tag can also be obtained by looking at the header information of the HTTP response. This tag is returned as standard in every request made. Its subtags are as follows

  • code: It is a numeric value indicating the process status.
  • message: Contains information message about the process status.

blacklist

Represents the list of blocked numbers. The sub-tags are as follows:

  • count: Represents the total number of blocked contacts.
  • number: Contains the information of blocked numbers.

Error Codes

The following table lists the error codes that the API can return.

Error CodeMessageDescription
400İstek çözümlenemediPOST ettiğiniz XML'in yapısındaki hatadan kaynaklanır. Bu hatalar genellikle, yanlış yazılan XML etiketi, düzgün kapatılmayan XML etiketi veya CDATA kullanılmadan XML'in yapısını bozabilecek bir karakterin kullanımından kaynaklanır.
401Üyelik bilgileri hatalıPOST ettiğiniz XML'in authentication etiketi içerisinde göndermiş olduğunuz bilgileri doğrulayamadığımızda bu hatayı veriyoruz, eğer hesabınızda sabit IP tanımladıysanız ve farklı bir IP üzerinden istek yapıyorsanız yine bu hatayı alırsınız.
404API istek yapılan yönteme sahip değilEğer bu hatayı alıyorsanız istek yaptığınız adresi tekrar kontrol edin yanlış bir adrese istek yapıyor olabilirsiniz.

Sample Request

<request>
<authentication>
<key></key>
<hash></hash>
</authentication>
<blacklist>
<page>1</page>
<rowCount>30</rowCount>
</blacklist>
</request>

Sample Successful Response

<?xml version="1.0" encoding="UTF-8"?>
<response>
<status>
<code>200</code>
<message>Successful operation</message>
</status>
<blacklist>
<count>334</count>
<number>+905558650220</number>
<number>+905558650220</number>
<number>+905558650220</number>
<number>+905558650220</number>
</blacklist>
</response>

Sample Error Response

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