getHashForPrimaryResource(resource) {
    this._createRequestedIncludesGraph(resource);

    let resourceHash = this.getHashForResource(resource);
    let hashWithRoot = { data: resourceHash };
    let addToIncludes = this.getAddToIncludesForResource(resource);

    return [hashWithRoot, addToIncludes];
  }
Use this hook to add top-level `links` data to JSON:API resource objects. The argument is the model being serialized.

    ```js
    // serializers/author.js
    import { JSONAPISerializer } from 'miragejs';

    export default JSONAPISerializer.extend({

      links(author) {
        return {
          'posts': {
            related: `/api/authors/${author.id}/posts`
          }
        };
      }

    });
    ```

    @method links
    @param model