We have a API callout from aura component which gets invoked on a button press. Our org has about 150+ users using it. Nowadays , few users are complaining of API not getting called from aura components intermittently.[Checked from the server side , it does not get request] Is this some scaling issue or there is a limit on API callouts from Aura components. Code used for calling api -
callApi : function(component,helper,jForm){
let resource = component.get("v.resourceInfo");
var urlEndpoint = resourceInfo['url'];
$.ajax({
url: urlEndpoint,
data: jForm,
isProcessData: false,
isContentType: false,
mimeType: "multipart/form-data",
type: 'POST',
headers:{
"Authorization" : "Basic " + resource['api_key']
},
error: function(error) {
component.set("v.error",error['statusText']);
component.set("v.showSpinner",false);
},
success: function(data) {
var obj = JSON.parse(data);
if(resourceInfo['user'] == undefined ){
let stringJson = JSON.stringify(obj['msg']['file']) ;
if(stringJson){
attachmentURL = '[' + stringJson + ']';
}
} else {
let stringJson = JSON.stringify(obj['attachment']) ;
if(stringJson){
attachmentURL = '[' + stringJson + ']';
}
}
}
});
}
P.S. - code does not work in one of the production org but works everywhere else.
Checked from the server side
, did you mean you are able to check at the server were the service is hosted?