Wednesday, November 7, 2018

Web Services Error - The specified key is invalid (INVALID_KEY_OR_REF)

The response of Error code INVALID_KEY_OR_REF with the message The specified key is invalid differs from similar INVALID_KEY_OR_REF errors as it does not specify the key or ref as a Invalid <record type> reference key ### message would.

The cause of the The specified key is invalid error message is that the request contains no internal or external id reference.

Sample of an incorrect request that would cause the error due to internalId or externalId missing:

platformMsgs:get>
   platformMsgs:baseRef xsi:type="s0:RecordRef" type="customer" />
/platformMsgs:get>

Sample of a correct request containing the internalId reference:

platformMsgs:get>
   platformMsgs:baseRef xsi:type="s0:RecordRef" internalId="42" type="customer" />
/platformMsgs:get>

No comments:

Post a Comment