D
D
Dmitry G2017-09-07 19:02:44
API
Dmitry G, 2017-09-07 19:02:44

How to translate the POST syntax of the sending service into the POST of the receiving one?

The request is generated on the site and sent by POST in the following form:
'from' => 'bmbullet',
'id' => '246067', // Unique ID of the request
'page_id' => '124145', // ID of the page from which request was left
'name' => 'name', // Value of the field "Name"
'email' => '[email protected]', // Value of the field "Email"
'phone' => '+7123456789', / / Value of the "Phone" field
'created_ip' => '', // IP address and User-Agent of the sender of the request
'utm_label' => [
'utm_key' => 'utm_value'
], // Array of UTM tags
The receiving service wants to see this syntax:
dialer_id - auto-dialing number to which to add the task
phones - phone numbers, maximum 5. Separated by commas, or json substring (if passed in json_request)
Optional data:
contact_id - contact number from CRM Oki-Toki
bp_id - process number from CRM Oki-Toki
date - time for which calls are assigned, in the format 21.02.2017 12:00:00
import_id - import number
priority priority from 0 to 2
region region in time zone format. e.g. Europe/Kiev
ttl task lifetime, in seconds
user_id user number to which the task will be assigned
details - json substring with additional information, for example {“name”:”John”, “order”:”12”}
Do I need to place somewhere on a third party a script that will "translate"? Or are there any easier options?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
mrWan, 2017-09-08
@mrWan

$newPost['phones '] = $oldPost['phone'];

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question