Open
Description
Support for creating related objects via the create endpoints if the schema defines a nested model but does not have the primary key field defined for that.
This might be really useful especially with the OneToOneFields as it would remove the need to separately create the related object and the object and the related object(s) may be create with a single endpoint and call.
Updating existing related object:
related_single_object = {
"pk": 1
"description": "something"
}
Creating new related object:
related_single_object = {
"description": "something"
}
Updating existing related objects:
related_multiple_objects = [
{
"pk": 1
"description": "something"
},
{
"pk": 2
"description": "something"
},
]
Creating new related objects:
related_multiple_objects = [
{
"description": "something"
},
{
"description": "something"
},
]
Mixture of updating/creating:
related_multiple_objects = [
{
"pk": 1
"description": "something"
},
{
"description": "something"
},
]