Hi!
I was trying out this API: https://pr-ark-codegen-1646.specs.preview.cogniteapp.com/v1.json.html#tag/Instances-(New)/operation/byExternalIdsInstances.
When i try to Retrieve a node by external id by giving source details as well, it works fine for a single View-ID pair. But when i try to do for more than one, I’m getting empty response.
Example: Say Id1 belongs to View1, and Id2 belongs to View2.
Querying with (Sources : View1, items : id1) as well as (Sources : View2, items : id2) gives correct response as expected. But when I try (Sources : [View1,View2], items : [id1,id2]), i get empty response. I was hoping it would provide information on both Id1 and Id2
Retrieve nodes/edges by their external ids API
Can you kindly provide your API requests and possibly share your model?
Hi
{
"sources": [
{
"source": {
"type": "view",
"space": "avocet-data-model-space-id",
"externalId": "Entity",
"version": "0_6"
}},
{
"source": {
"type": "view",
"space": "x86",
"externalId": "Entity",
"version": "1"
}
}
],
"items": [
{
"instanceType": "node",
"externalId": "well1",
"space": "avocet-data-model-space-id"
},
{
"instanceType": "node",
"externalId": "well1",
"space": "x86"
}
],
"includeTyping": false
}
data-model of “x86” space:

data-model of “avocet-data-model-space-id” space:

Jason
Hi
I have validated this is an issue and have raised a ticket to fix. I will let you know once remedied. Thank you for sharing.
Jason
Reply
Enter your username or e-mail address. We'll send you an e-mail with instructions to reset your password.