Skip to main content

Getting a strange error when trying to use two INT REST APIs which are working fine through Aurena. But not working when I try to run it through Postman using basic authentication.

 

Could you kindly go through the below scenario and help me resolve the issue?

 

Below is the Scenario:

  • I am trying to deliver customer order lines using the available rest APIs from the documentation.
  • I am using IFS Apps 10 Update 16
  • I am trying to use REST API with basic authentication
  • REST API - https://:ifshost]/int/ifsapplications/projection/v1/DeliverCustomerOrderLines.svc/DeliverLines
  • Payload
    {
    "OrderNo": "M1132",
    "LineNo": "1",
    "RelNo": "4",
    "LineItemNo": 0
    }
  • Authentication - Basic
  • Projection DeliverCustomerOrderLines.svc is included in compatibility mode and permissions are properly set (the same user name and setup works fine for other REST APIs)

  • Error:

    {
    "error": {
    "code": "DATABASE_ERROR",
    "message": "Database error occurred. Contact administrator.",
    "details": "
    {
    "code": 20181,
    "message": "ORA-20181: DeliverCustomerOrderLines.ACCESS_FAILURE: Arguments used to execute current operation are not allowed."
    }
    ]
    }
    }
  • Screenshot of the documentation:

     

  • Same thing happens for another REST API as well
  • REST API - https://pifshost]/int/ifsapplications/projection/v1/DeliverCustomerOrderLineWithDifferences.svc/DeliverNonInvLineWithDiff
  • Everything else is same and the Error will look like the following:
    {
    "error": {
    "code": "DATABASE_ERROR",
    "message": "Database error occurred. Contact administrator.",
    "details": l
    {
    "code": 20181,
    "message": "ORA-20181: DeliverCustomerOrderLineWithDifferences.ACCESS_FAILURE: Arguments used to execute current operation are not allowed."
    }
    ]
    }
    }
  • Screenshot of the documentation:

     

Finally cracked the issue! Thanks @izryShiran for your insights too!

  • The issue is due to my integration user doesn’t have access to the site where the data is from.
  • The error message is so generic it’s hard to guess that it could have been an issue with data access.
  • When I send only data that my integration user can access or if I give access to the site of the data I was testing, the issue disappeared! 😀 
  • Below are some screenshots of the db code related to this error;

 

 

Hope these findings will help understand this error better in the future 😅

 

 


Reply