0

I am working with the SF Commerce Cloud Connector package. We've been struggling to get this set up right. At first, when we made our calls we were getting this error:

[
    {
        "errorCode": "NOT_FOUND",
        "message": "Could not find a match for URL"
    }
]

Our endpoint was like this: /services/apexrest/Order/Placement

But based on my searches it seemed like I had to add the namespace prefix to the endpoint like so:

/services/apexrest/NSSCCConnector/Order/Placement

and that seems to work. I am actually successfully submitting orders into my org, BUT I get this response back:

{
    "recordId": null,
    "objectType": null,
    "errors": {
        "typeOfError": "System.ListException",
        "status": "500",
        "errorMessage": "List index out of bounds: 0",
        "errorLine": "87"
    }
}

I can't understand why I'm getting an error back if the call was successful? Thanks in advance for anyone who can help on this.

Here is the message I am sending:

{
    "order_no": "00000121",
    "status": "Draft",
    "order_total": 1758,
    "scc_sync_status": "Created"
}
  • Most likely, it was not fully successful. There are ways for a developer to allow a partial successfully, although this is usually by accident. you should probably report this as a bug, because ideally this should not happen. – sfdcfox Apr 4 at 18:53
  • @sfdcfox thanks, but where would I report it? Also, what do you suppose the issue is? Missing required fields? – garek007 Apr 4 at 19:04
  • To Salesforce or whoever manages the package. As far as what's missing, it sounds like maybe it's expecting line items or something? We'd probably have to see what a sample message you're sending looks like. – sfdcfox Apr 4 at 19:10
  • Thanks @sfdcfox I've updated the post to include the body I'm sending. This is working with the commerce cloud connector. Makes sense actually, it might be looking for products placed as well. I will post this to the github for this project. – garek007 Apr 4 at 19:13
  • The odd thing is that the Postman sample calls show the body in the exact same way, nothing else, so I'd imagine the installed package should be handling any other required fields. – garek007 Apr 5 at 15:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.