Skip to main content

I am trying to fetch the product structure items by passing six required parameters as shown below API call. This is as per the API Doc and am using PostMan with a valid bearer token.

 

https://w.sandbox.maiaspace/main/ifsapplications/projection/v1/ProductStructureHandling.svc/ProdStructures(Contract='{Contract}',PartNo='{PartNo}',EngChgLevel='{EngChgLevel}',BomType='{BomType}',AlternativeNo='{AlternativeNo}',LineItemNo={LineItemNo})

 

 

i am getting this error message, even though i put the required element 

{

    "error": {

        "code": "REQUEST_ERROR",

        "message": "Malformed Request.",

        "details": "

            {

                "code": "INVALID_KEY_VALUE",

                "message": "The key value 'BomType' is invalid."

            }

        ]

    }

}

BomType

Manufacturing

I am on IFS Cloud 23R1.

Can you add the input json and add odata-debug=json as a parameter?
 


As now we are flying a bit blind


Hello 

thank you for your answer

here is the rpart of the request to the odata-debug

 "request": {

        "method": "GET",

        "uri": "https://xxxxxxx/main/ifsapplications/projection/v1/ProductStructureHandling.svc/ProdStructureHeads(Contract='TEST1',PartNo='L1',EngChgLevel='1',BomType='M')?odata-debug=json",

        "protocol": "HTTP/1.1"

    },

    "response": {

        "status": {

            "code": "400",

            "info": "Bad Request"

        },

        "headers": {

            "OData-Version": "4.0",

            "Content-Type": "application/json"

        },

        "body": "{\"error\":{\"code\":\"REQUEST_ERROR\",\"message\":\"Malformed Request.\",\"details\":{\"code\":\"INVALID_KEY_VALUE\",\"message\":\"The key value 'BomType' is invalid.\"}]}}"

    },

    "server": {

        "stacktrace": {

            "exceptions": 

                {

                    "class": "org.apache.olingo.server.core.uri.parser.UriParserSemanticException",

                    "message": "Value of key 'BomType' for entity 'IfsApp.ProductStructureHandling.ProdStructureHead' is not valid.",

                    "invocation": {

                        "class": "org.apache.olingo.server.core.uri.parser.ParserHelper",

                        "method": "keyValuePair",

                        "line": 450

                    }

                }

            ]

 

Does this help?


Since BomType is an enumeration you need to specify it like this in the URL to “ProductStructureHandling.svc/ProdStructures”:

…,BomType=IfsApp.ProductStructureHandling.ShopOrdCode'Manufacturing',...


That can be found in the metadata:

<Your URL>/main/ifsapplications/projection/v1/ProductStructureHandling.svc/$metadata

Thank you so much for you help 


Reply