How to add a track via dj with a query?

I want to make a bot that will add music.
Searching, I found this query
post("/includes/back.php?func=add_track&channel=" + id, {
 url: $("#url").val(),
 author: $("#author").val()
 }

And there is a function
function add_track(id) {
 if ($("#url").val() && $("#author").val()) {
 Cookies.set('author_dj', $("#author").val(), {
 expires: 365,
 path: "
});
$("#add_track_b").button('disable');
 $("#add_track_b").button('option', 'label', '<img src="/template/img/wait_m.gif">');
 $.post("/includes/back.php?func=add_track&channel=" + id, {
 url: $("#url").val(),
 author: $("#author").val()
 }, function(data) {
 var info = JSON.parse(data);
 if (info.pay) {
 iarray.robokassa_url = info.robokassa_url;
 iarray.freekassa_url = info.freekassa_url;
 iarray.unitpay_url = info.unitpay_url;
 iarray.unitpay_url3 = info.unitpay_url3;
 iarray.unitpay_id = info.pay;
 iarray.unitpay_desc = info.desc;
 iarray.unitpay_sum = info.sum3;
$("#wm_form").html(info.webmoney_form);
 $('#tabs-demo').tabs('option', 'active', 2);
 } else {
 if (info.success == 1) {
playlist(id);
 $(".new-track-1 a").click();
$("#add_track_b").button('enable');
 } else {
d_error(info.error);
$("#add_track_b").button('enable');
}
}
$("#url").val("");
 $("#add_track_b").button('option', 'label', '<img src="/template/img/send-music.png"> Send');
 }).fail(function(xhr) {
location.reload();
});
 } else {
 d_error("Fill all fields!");
}
}

But I don't quite understand how it works... Help)
Write using python requests
April 3rd 20 at 18:41
1 answer
April 3rd 20 at 18:43
Solution
DECIDED!
POST url: https://twitch-dj.ru/includes/back.php?func=add_tr... channel%
Parameters = {
url: "%Link video%", //Might be needed without ""
author:"%Author%"
}

Find more questions by tags JavaScriptAPI