Versions Compared

Key

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

...

Code Block
languagejs
$.ajax({
    url: "https://localhost:9094/api/v1/ticket/79343564-147f-4a2a-ac2a-182d7a55f802/mssp/IdHubTest1/ds/creator",
    type: "POST",
    dataType: "json",
    contentType: "application/json",
    data: JSON.stringify({phoneNumber : "380934000227", positionId : "4504", serviceId : "SIGN_DSTU"})
}).done(function (jsonResponse, textStatus, xhr) {
    message = jsonResponse.message;
}).fail(function (xhr) {
    try {
        var jsonResponse = JSON.parse(xhr.responseText);
        message = jsonResponse.message;
        failureCause = jsonResponse.failureCause;
    } catch (e) {
        message = (xhr.responseText == undefined) ? "Ошибка при инициировании создания мобильной ЭП." : xhr.responseText;
    }
})