+ Start a Discussion
Praneetha MurakondaPraneetha Murakonda 

Build Integration

Hi All,

I need to build integration with Unleashed api. I'm trying to get the response but,I'm getting error like 

18:23:26:196 USER_DEBUG [24]|DEBUG|{"Description":"(403) Forbidden.: Authentication denied - signature mismatch. Username: \u0027 abc@123.com\u0027;  OrganisationId: \u002757babb16-e109-461d-b993-87b6bd214557\u0027;  Signature: \u0027******\u0027;  Url: \u0027/Customers/\u0027","DebugInformation":null}

CodeSnippet:
HttpRequest req = new HttpRequest(); 
  req.setMethod('GET');
  req.setHeader('content-type', ' application/json');
  req.setHeader('Accept',' application/json ');
  req.setHeader('api-auth-id','57babb16-e109-461d-b993-87b6bd214557');
  req.setHeader('auth-signature-method','HMAC-SHA256');
  req.setHeader('api-auth-signature','1SMZNxnb9Tetc7MtDDxgOFUsB8zL2cGl2477ODH5AqEgpRt4N3tljd27omilAbyQGr3PqVPZstYIZKPC503w==');
  req.setEndpoint( 'https://api.unleashedsoftware.com/Customers/');
 
  Http http = new Http();
  try {

        HTTPResponse res = http.send(req);    
        res.getbody();
        System.debug(res.getbody());
      } catch(System.CalloutException e) {

}        

Please suggest how to resolve this error and get the response

Thanks!

SonamSonam (Salesforce Developers) 
Seems like the signature was generated incorrectly as per the guide:
https://api.unleashedsoftware.com/AuthenticationHelp Did you happen to check the sample code given on the above link?