# Read-only relationships

**URL:** <https://discuss.jsonapi.org/t/read-only-relationships/1047>\
**Category:** Uncategorized\
**Created:** [July 24, 2017, 7:06pm UTC](https://discuss.jsonapi.org/t/read-only-relationships/1047 "2017-07-24T19:06:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jgornick](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.jsonapi.org/jgornick/32/290_2.png) [@jgornick](https://discuss.jsonapi.org/u/jgornick)\
**Post date:** [July 24, 2017, 7:06pm UTC](https://discuss.jsonapi.org/t/read-only-relationships/1047/1 "2017-07-24T19:06:50Z")

</div>

If I have an entity called `job` and there are `logs` associated with that `job`, would those `logs` be considered a relationship resource object and would the relationship `self` link reference the relationship resource or the “related” resource? If we had a `/jobs/123/relationships/logs` resource, would it only support `GET` to retrieve a list of logs references?

Current Resources:

- A `job` is fetched like `GET /jobs/123`
- Job logs are fetch via `GET /jobs/123/logs`

Thanks!

---

<div class="post-metadata">

**Author:** ![michaelhibay](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.jsonapi.org/michaelhibay/32/405_2.png) [@michaelhibay](https://discuss.jsonapi.org/u/michaelhibay)\
**Post date:** [July 25, 2017, 7:51pm UTC](https://discuss.jsonapi.org/t/read-only-relationships/1047/2 "2017-07-25T19:51:28Z")

</div>

Trying to pick apart some stuff with this.

The self link should refer to the link context in the document which resulted in the message. Meaning the self link will refer to the relationship link from the main resource, using the path example you included `/jobs/123/relationships/logs`.

The related link should point to the canonical URI for the resource, which should probably NOT be a sub resource of `/jobs` if you have any other resources which may also have a log. However, if it is truly a sub resource then the related link should be `/jobs/123/logs/` as stated.

Nothing in the spec requires all resources to support all methods, so supporting whatever methods you want is no problem.
