CURL JavaScript (native) JavaScript (axios) Visual Basic.NET Python
Copy curl -X 'GET' \
'https://api.digicust.com/generic/api/<YOUR CUSTOMER ID>/<YOUR PROJECT ID>/cases/<YOUR CASE ID>' \
-H 'accept: application/json' \
-H 'Authorization: Bearer <YOUR ACCESS TOKEN>'
Copy var xhr = new XMLHttpRequest ();
xhr .open ( 'GET' , 'https://api.digicust.com/generic/api/<YOUR CUSTOMER ID>/<YOUR PROJECT ID>/cases/<YOUR CASE ID>' );
xhr .setRequestHeader ( 'Authorization' , 'Bearer <YOUR ACCESS TOKEN>' );
xhr .setRequestHeader ( 'Accept' , 'application/json' );
xhr . onreadystatechange = function () {
if ( xhr .readyState === 4 ) {
console .log ( xhr .status);
console .log ( xhr .responseText);
}
};
xhr .send ();
Copy const axios = require ( 'axios' );
axios ({
method : 'get' ,
url : 'https://api.digicust.com/generic/api/<YOUR CUSTOMER ID>/<YOUR PROJECT ID>/cases/<YOUR CASE ID>' ,
headers : {
'Authorization' : 'Bearer <YOUR ACCESS TOKEN>' ,
'Accept' : 'application/json' ,
} ,
})
.then ( function (response) {
console .log ( response .data);
})
.catch ( function (error) {
console .log (error);
});
Copy Imports System.Net
Imports System.IO
Dim request As HttpWebRequest = DirectCast(WebRequest.Create("https://api.digicust.com/generic/api/<YOUR CUSTOMER ID>/<YOUR PROJECT ID>/cases/<YOUR CASE ID>"), HttpWebRequest)
request.Method = "GET"
request.Headers("Authorization") = "Bearer <YOUR ACCESS TOKEN>"
request.Accept = "application/json"
Dim response As HttpWebResponse = DirectCast(request.GetResponse(), HttpWebResponse)
Dim reader As New StreamReader(response.GetResponseStream())
Console.WriteLine(reader.ReadToEnd())
Copy import requests
headers = {
'Authorization' : 'Bearer <YOUR ACCESS TOKEN>' ,
'Accept' : 'application/json' ,
}
response = requests . get ( 'https://api.digicust.com/generic/api/<YOUR CUSTOMER ID>/<YOUR PROJECT ID>/cases/<YOUR CASE ID>' , headers = headers)
print (response. json ())