Answer the question
In order to leave comments, you need to log in
How to get recorded_audio from this json?
There is json, you need to take recorded_audio from it.
[{"action_type": null, "button_num": null, "call_id": 20110440096793, "created": "2020-11-04T14:19:03.870Z", "dial_status": 1, "dial_status_display": "\u041e\u0448\u0438\u0431\u043a\u0430 \u043f\u0440\u0438 \u0432\u044b\u0437\u043e\u0432\u0435 \u0430\u0431\u043e\u043d\u0435\u043d\u0442\u0430", "phone": "+79374080780", "recorded_audio": "https://zvonok.com/directcdr/6b98300086400a0746554ebe8141a790/2061208294/20110440096793/20110440096793.1.mp3", "status": "attempts_exc", "status_display": "\u041f\u043e\u043f\u044b\u0442\u043a\u0438 \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u043b\u0438\u0441\u044c", "updated": "2020-11-04T14:19:26.955Z", "completed": "2020-11-04T14:19:14.006Z", "user_choice": null, "user_choice_display": null, "duration": 0.0, "audioclip_id": null, "ivr_data": null, "cost": "0", "currency": "RUB"}]
Answer the question
In order to leave comments, you need to log in
$json = '[{"action_type": null, "button_num": null, "call_id": 20110440096793, "created": "2020-11-04T14:19:03.870Z", "dial_status": 1, "dial_status_display": "\u041e\u0448\u0438\u0431\u043a\u0430 \u043f\u0440\u0438 \u0432\u044b\u0437\u043e\u0432\u0435 \u0430\u0431\u043e\u043d\u0435\u043d\u0442\u0430", "phone": "+79374080780", "recorded_audio": "https://zvonok.com/directcdr/6b98300086400a0746554...", "status": "attempts_exc", "status_display": "\u041f\u043e\u043f\u044b\u0442\u043a\u0438 \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u043b\u0438\u0441\u044c", "updated": "2020-11-04T14:19:26.955Z", "completed": "2020-11-04T14:19:14.006Z", "user_choice": null, "user_choice_display": null, "duration": 0.0, "audioclip_id": null, "ivr_data": null, "cost": "0", "currency": "RUB"}]';
$records = json_decode($json, true);
$audio = $records[0]['recorded_audio']
<?php
$json = '{"action_type": null, "button_num": null, "call_id": 20110440096793, "created": "2020-11-04T14:19:03.870Z", "dial_status": 1, "dial_status_display": "\u041e\u0448\u0438\u0431\u043a\u0430 \u043f\u0440\u0438 \u0432\u044b\u0437\u043e\u0432\u0435 \u0430\u0431\u043e\u043d\u0435\u043d\u0442\u0430", "phone": "+79374080780", "recorded_audio": "https://zvonok.com/directcdr/6b98300086400a0746554...", "status": "attempts_exc", "status_display": "\u041f\u043e\u043f\u044b\u0442\u043a\u0438 \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u043b\u0438\u0441\u044c", "updated": "2020-11-04T14:19:26.955Z", "completed": "2020-11-04T14:19:14.006Z", "user_choice": null, "user_choice_display": null, "duration": 0.0, "audioclip_id": null, "ivr_data": null, "cost": "0", "currency": "RUB"}';
$recorded_audio = json_decode($json, 1)['recorded_audio'];
echo $recorded_audio;
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question