I am able to update multiple same field groups via API | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Indra-2

SCHEMA ID :_adobequaptrsd.schemas.7567f6029e5ee4a77faf20dea2718677d7448af37a7XXXXXX

Successfully updated.

Request:

[{
"op": "add",
"path": "/allOf/-",
"value": {
}
},
{
"op": "add",
"path": "/allOf/-",
"value": {
}
}
]
 
Response:
{
"meta:altId": "_adobequaptrsd.schemas.7567f6029e5ee4a77faf20dea2718677d7448af3XXXXX",
"meta:resourceType": "schemas",
"version": "1.1",
"title": "Indra Luma CRM Schema Indra",
"type": "object",
"description": "Schema for CRM data of Luma Retail ",
"allOf": [
{
"type": "object",
"meta:xdmType": "object"
},
{
"type": "object",
"meta:xdmType": "object"
},
{
"type": "object",
"meta:xdmType": "object"
}
],
"refs": [
],
"imsOrg": "0XXXXXXXC40A495CD7@AdobeOrg",
"additionalInfo": {
"numberOfIdentities": 0,
"numberOfRelationShips": 0,
"classTitle": "XDM Individual Profile",
"behavior": "Record",
"hasRelationShip": false,
"profileEnabled": false
},
"meta:extensible": false,
"meta:abstract": false,
"meta:extends": [
],
"meta:xdmType": "object",
"meta:registryMetadata": {
"repo:createdDate": 1720495111007,
"repo:lastModifiedDate": 1720573766960,
"xdm:createdClientId": "ccfff59b397c4a40a86caa9158a47cca",
"xdm:lastModifiedClientId": "ccfff59b397cXXXXXXXXX",
"xdm:createdUserId": "4FFF1E40664AA86F0A495FC8@techacct.adobe.com",
"xdm:lastModifiedUserId": "4FFF1E40664AA86F0A495FC8@techacct.adobe.com",
"eTag": "057df4d51fe35671b750d21f2620d7c930d2240b349226392e6d7a63923b25b1",
"meta:globalLibVersion": "1.50.1"
},
"meta:containerId": "17429b70-10d5-41bb-829b-7010d5e1bbe0",
"meta:sandboxId": "17429b70-10d5-41bb-829b-7010d5e1bbe0",
"meta:sandboxType": "development",
"meta:tenantNamespace": "_adobequXXXX",
"meta:descriptorStatus": {
"result": []
}
}

4 replies

kautuk_sahni
Employee
September 16, 2024

@indra-2 Did you find the suggestion helpful? Please let us know if you require more information. Otherwise, please mark the answer as correct for posterity. If you've discovered a solution yourself, we would appreciate it if you could share it with the community. Thank you!

Kautuk Sahni
brekrut
Employee
August 9, 2024

Hello @indra-2 

 

I have reviewed the case you have provided.  It appears you have performed a patch command with the operation of add twice into a schema.  Your patch operation of add was to add in the XDM reference of profile-person-details.

 

Can you please provide the results of the full schema view of the schema created using the header value of accept:application/vnd.adobe.xed-full+json; version=1.

 

I would like to see how the objects have been created.

Indra-2
Indra-2AuthorAccepted solution
New Participant
August 9, 2024

SCHEMA ID :_adobequaptrsd.schemas.7567f6029e5ee4a77faf20dea2718677d7448af37a7XXXXXX

Successfully updated.

Request:

[{
"op": "add",
"path": "/allOf/-",
"value": {
}
},
{
"op": "add",
"path": "/allOf/-",
"value": {
}
}
]
 
Response:
{
"meta:altId": "_adobequaptrsd.schemas.7567f6029e5ee4a77faf20dea2718677d7448af3XXXXX",
"meta:resourceType": "schemas",
"version": "1.1",
"title": "Indra Luma CRM Schema Indra",
"type": "object",
"description": "Schema for CRM data of Luma Retail ",
"allOf": [
{
"type": "object",
"meta:xdmType": "object"
},
{
"type": "object",
"meta:xdmType": "object"
},
{
"type": "object",
"meta:xdmType": "object"
}
],
"refs": [
],
"imsOrg": "0XXXXXXXC40A495CD7@AdobeOrg",
"additionalInfo": {
"numberOfIdentities": 0,
"numberOfRelationShips": 0,
"classTitle": "XDM Individual Profile",
"behavior": "Record",
"hasRelationShip": false,
"profileEnabled": false
},
"meta:extensible": false,
"meta:abstract": false,
"meta:extends": [
],
"meta:xdmType": "object",
"meta:registryMetadata": {
"repo:createdDate": 1720495111007,
"repo:lastModifiedDate": 1720573766960,
"xdm:createdClientId": "ccfff59b397c4a40a86caa9158a47cca",
"xdm:lastModifiedClientId": "ccfff59b397cXXXXXXXXX",
"xdm:createdUserId": "4FFF1E40664AA86F0A495FC8@techacct.adobe.com",
"xdm:lastModifiedUserId": "4FFF1E40664AA86F0A495FC8@techacct.adobe.com",
"eTag": "057df4d51fe35671b750d21f2620d7c930d2240b349226392e6d7a63923b25b1",
"meta:globalLibVersion": "1.50.1"
},
"meta:containerId": "17429b70-10d5-41bb-829b-7010d5e1bbe0",
"meta:sandboxId": "17429b70-10d5-41bb-829b-7010d5e1bbe0",
"meta:sandboxType": "development",
"meta:tenantNamespace": "_adobequXXXX",
"meta:descriptorStatus": {
"result": []
}
}
brekrut
Employee
August 11, 2024

Thank you for your reply.  

I can see in your response there is a reference to the same mixin/field group twice in the same schema.  I can look into this being an enhancement request, but the same field group could be used in multiple location within a single schema.  

 

I would advise when creating schemas via an API to ensure your references are used as expected and double check them using the UI before marking them for profile.

DavidRoss91
New Participant
July 15, 2024

Hello @indra-2 

could you provide a little more context on what the expected outcome you are looking for here? Why are you wanting duplicate field groups in the schema?

 

David

Indra-2
Indra-2Author
New Participant
July 17, 2024

 api should not allow us to add duplicate field groups . But when I hit the api in postman two times, I see the duplicates field group added in UI . second time it should give me error.

 

 

DavidRoss91
New Participant
July 17, 2024

@indra-2 ok I understand now. It should be erroring out due to same field group id, name, etc. One thing I notice is that you are using an OOTB field group, to which i’m not entirely sure if that could be of any reason why. It may be worth logging a ticket with Adobe support referencing your sandbox and the specific issue. 

@brekrut 

Indra-2
Indra-2Author
New Participant
July 12, 2024