# Why are my response-relationships not recognized as relationship?

**URL:** https://discuss.emberjs.com/t/why-are-my-response-relationships-not-recognized-as-relationship/9277
**Category:** Ember Data
**Created:** [December 9, 2015, 3:16pm UTC](https://discuss.emberjs.com/t/why-are-my-response-relationships-not-recognized-as-relationship/9277 "2015-12-09T15:16:25Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![iamsebastian](https://avatars.discourse-cdn.com/v4/letter/i/7feea3/32.png) [@iamsebastian](https://discuss.emberjs.com/u/iamsebastian)
#### Post date: [December 9, 2015, 3:16pm UTC](https://discuss.emberjs.com/t/why-are-my-response-relationships-not-recognized-as-relationship/9277/1 "2015-12-09T15:16:25Z")

</div>

Hello,

I’m actually fresh to a new company and would like to “professionalize” their product from un-maintainable some-very-large-few-single-files-PHP project, over, to a maintainable, JSONAPI based resolution build upon Ember on client side, and Node/Express on server side.

My experience is based at least on two years of full-time node.js experience and about a year of angular before the dive-into node.js-backends. Actually I’m struggling around, with JSONAPI-compatible relationships.

I’ve tried to show you in a lighten version, what I’m done until now here: [Ember Twiddle](https://ember-twiddle.com/7f5c3017eba2dbeacdbf) (just look at the sources – not at the resulting html on the right side)

I’m trying to establish a connection between two models: `bank` and `user`. While the user has a `belongsTo` `bank-id` (/`bankId`), the `bank` does not has a inverse relationship.

The JSON, my API responds with actually, is there: [https://gist.github.com/iamsebastian/9afad6bc56fcede54e6b](https://gist.github.com/iamsebastian/9afad6bc56fcede54e6b)

As you can see, the `user` has a `bank-id` which I actually `deserialize` to {`bank-id -> bank`}, so ember-data get’s knowledge about, which models have to be connected here.

**Now** the question:  
All is working well, if I send out the `bank-id` as `user`’s attribute. But ember-data does **not connect** the two models, if I do not send out the `bank-id` property. But as far as I could read from the JSONAPI specification and the ember docs, the `belongsTo`-relationship between `bank` & `user` should be already established in because of this part of the response:

[https://gist.github.com/iamsebastian/9afad6bc56fcede54e6b#file-users\_response-json-L83-L93](https://gist.github.com/iamsebastian/9afad6bc56fcede54e6b#file-users_response-json-L83-L93)

The data is correctly parsed by ember and the adapters, like you will see here: ![screenshot from 2015-12-09 16-04-04](https://cloud.githubusercontent.com/assets/1620425/11688712/825a82a0-9e8e-11e5-9b4c-ce7883a70c32.png)

Feel free to ask me anything about that, if it would help to let you understand my question.

**Another awkward question** :  
I also could not get ember-data to _“auto-request”_ missing relationships if I removed the relationships from the API response and just transmitted the `bank-id` at the user, to let ember know, which `bank` should get requested via `https://host/api/bank/$id`. There was a _fulFilled_ promise attached to each user, but no visible try in the networks-tab of the inspector, where ember was requesting the missing record data of the related `bank`.
