Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Contacts

URL: /contacts.ashx 

Parameter

Description

l

Login - login of SIP account

p

Password - password of sip account

cl

Contacts list - a list of contacts  in JSON format. An example of what this format should look like is provided below.

sm

Synchronization method - contact list synchronization method.
The currently accepted parameters are:

  • full - full synchronization of your phone contact list
  • update - updating selected telephone contacts
  • remove - deleting selected telephone contacts
  • verify - checking the number of contacts of the local database(device) with the global database(server)
rp

Response method - the parameter determines the method in which the response should be received. Accepted parameters:

  • http - a token is sent in response
  • sms - the response is sent in the form of SIP MESSAGE

    rp is an optional parameter, if it is missing, the SMS method will be used by default


Code will be received in response. The list of possible codes is below.

Kod

Description

200

OK

400

Incorrect parameters - one of the parameters has not been provided

403

Invalid HTTP method - only POST method accepted

404

Invalid JSON format

405

Server side error

406

The login and/or password are incorrect


cURL Request Example

--header 'User-Agent: vippie;ios;1.2.3' \
--header 'Content-Type: text/plain' \
--header 'Authorization: Basic YW5kOmFuZDJhMzJkaW0=' \
--header 'X-VIPPIE-DEVICE-ID: ff66fc693846285d' \
--header 'X-VIPPIE-DEVICE-NAME: iPhone8,1'



Sample JSON data exchange format for the address book - update and full methods.

...

When sending a list of contacts larger than 300, the list should be divided into smaller packages (e.g. 300 100 items each) and sent one by one. After sending the first package, we receive a token, we send the token to check whether there is already a JSON list, if so, after receiving it, we send the next package. We repeat the procedure until the entire book has been sent. During this time, you should update the contact list in the UI and show the RCS users every time the JSON list arrives.

...

Parameter

Description

l

Login - login of the SIP account

p

Password - password of the SIP account

method

getBlock - downloads the list of blocked contacts and the list of users who blocked me

cURL Request Example


--header 'User-Agent: vippie;ios;1.2.3' \
--header 'Content-Type: text/plain' \
--header 'Authorization: Basic YW5kOmFuZDJhMzJkaW0=' \
--header 'X-VIPPIE-DEVICE-ID: ff66fc693846285d' \
--header 'X-VIPPIE-DEVICE-NAME: iPhone8,1'


Return value

Code Block
{
  "in": [
    "login1",
    "login2",
    "login3"
  ],
  "out": [
    "login4",
    "login5",
    "login6"
  ]
}

...