Excluding relationships?

Why do you need the IDs? Why aren’t the relationship URLs enough?

Why wouldn’t you model that something like this:

{“data”:
“type”: “customer”,
“id”: “1234”,
“attributes”: {
“name”: “Jane Doe”
},
“relationships”: {
“transactions”: {
“links”: {
“self”: “/customers/1234/relationships/transactions”,
“related”: “/customers/1234/transactions”,
}
}
}
}

Then you GET customers/1234/transactions later when you need that data.