# Should Id be mandatory in relationships and included nodes for the POST request?

**URL:** <https://discuss.jsonapi.org/t/should-id-be-mandatory-in-relationships-and-included-nodes-for-the-post-request/1993>\
**Category:** Uncategorized\
**Created:** [July 6, 2020, 7:14am UTC](https://discuss.jsonapi.org/t/should-id-be-mandatory-in-relationships-and-included-nodes-for-the-post-request/1993 "2020-07-06T07:14:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gaurav](https://avatars.discourse-cdn.com/v4/letter/g/b487fb/32.png) [@Gaurav](https://discuss.jsonapi.org/u/Gaurav)\
**Post date:** [July 6, 2020, 7:14am UTC](https://discuss.jsonapi.org/t/should-id-be-mandatory-in-relationships-and-included-nodes-for-the-post-request/1993/1 "2020-07-06T07:14:17Z")

</div>

I’ve checked the JSON API document for creating resources. But I found that Id is required in the POST request as well for relationships which should not be.

for example, there are two entities, “company” and “company\_address”. One company has one company\_address, and company\_address can’t exist without a related company.  
How can I create a new company with a new company\_address in a single POST request?

I’ve also tried a ruby library [josnapi\_parameters](https://github.com/visualitypl/jsonapi_parameters) for deserializing the request parameters, but if I do not pass the `id` in the relationship for nested attributes it is not forming the request params correctly.

I couldn’t find any solution for that. I would highly appreciate some feedback.

Thank you!
