Skip to content
This repository was archived by the owner on Nov 8, 2024. It is now read-only.
This repository was archived by the owner on Nov 8, 2024. It is now read-only.

Resources affording other resources actions (linking) #288

@zdne

Description

@zdne

Given this blueprint (currently valid syntax):

# Author [/author/{id}]
- Parameters
    - id (number) - Id of the author
- Attributes
    - email (string) - Email of the author

## Retrieve Author [GET]
- Relation: self
- Response 200 (application/json)   
    - Attributes (Author)

I want to be able express that another resource affords the "Retrieve Author" action without the need to duplicate the "Retrieve Author".

For example like this:

# Blog Post [/blogpost/{id}]
- Parameters
    - id (number) - Id of the Blog Post
- Attributes
    - content (string) - Content of the Blog Post

## Retrieve [GET]
- Relation: self
- Response 200 (application/json)   
    - Attributes (Blog Post)

## Action Retrieve Gist Author 
- Relation: author (Author[self])

This enables linking of the resources and hence HATEOAS description.

To be addressed in draft APIB RFC

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions