Skip to main content

XML Post API

Warning

This API method is under development, there may be changes to it. Please contact your customer representative to access the API method.

To search contacts in your address book using the POST method of the HTTP protocol in XML format, you can follow the instructions below.

Request URL

POSThttps://api.iletimerkezi.com/v1/search-contacts

Request Body

<request>
<authentication>
<key></key>
<hash></hash>
</authentication>
<search>
<key></key>
<page></page>
<rowCount></rowCount>
</search>
</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.

Contains the search criteria. Does not repeat. The sub-tags are as follows.

  • key: Represents the value to search for. Searches within the phone number, name, surname, and email fields in your address book.
  • page: Represents the search results page. It is not mandatory to send this in the request. The default value is 1.
  • rowCount: Specifies the number of contacts on a search results 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 contacts, additional requests should be made to query the subsequent pages.

Server Response

<response>
<status>
<code></code>
<message></message>
</status>
<contacts>
<contact>
<id></id>
<name><![CDATA[...]]></name>
<surname><![CDATA[...]]></surname>
<email><![CDATA[...]]></email>
<gsm></gsm>
<custom_fields>
<custom_field>
<id></id>
<value></value>
</custom_field>
</custom_fields>
<groups>
<id></id>
</groups>
</contact>
<contacts>
</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.

contacts

Contains the information of the contacts within the group. The sub-tags are as follows.

  • contact

    Contains the contact information. Repeats as many times as the number of contacts. The sub-tags are as follows.

    • id: Represents the unique numeric value of the contact.

    • name: Represents the contact's name.

    • surname: Represents the contact's surname.

    • email: Represents the contact's email address.

    • gsm: Represents the contact's mobile phone number.

    • custom_fields

      Represents the custom fields defined for the contact. The sub-tags are as follows.

      • custom_field

        Represents the custom field defined for the contact. Repeats as many times as the number of fields defined. The sub-tags are as follows.

        • id: The unique numeric value representing the custom field.
        • value: Represents the value stored for the contact in the custom field.
    • groups

      Contains the unique numeric values representing the groups to which the contact belongs. The sub-tags are as follows.

      • id: Represents the unique numeric value of the group.

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.
465Kişi bulunamadı.Eğer grup içerisinde herhangi bir kişi bulunamadıysa bu hatayı alırsınız.
471Arama terimi en az 3 karakter olmalıdır.Arama yaparken en az 3 karakterlik bir kelime girmeniz gerekmektedir.