How to create a relation to a record from another table in a post request

Hi there,

How do I create the relationship to a record from another table in a post request?

I am creating a record with data from a registered customer device with a post request to the "Installed Base" custom module.
The Accounts module has a one-to-many relation with the "Installed Base" module.




The following body creates a new record in the Installed Base table, but does not create a relation to the Accounts record.
I thought it would be enough to pass the account ID in the request.

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
{
"deleted": false,
"quantity": "1",
"serial_number": "27289",
"source_id": "302238023232",
"product_model": "alpha",
"purchase_date": "2025-03-11",
"timestamp": "2025-03-11T11:14:00+01:00",
"accounts": {
"id": "12686878-0363-11e7-b361-14187763417d"
}
}
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX



How do I manage to create a relation? Anyone have a tip?

Thanks!
Steffen