Skip to content

Using POST on related collection URLs #496

Closed

Description

@timabdulla

just to clarify, as this is not stated explicitly in the spec: is it ok to use POST on related collection URLs (e.g. /posts/1/comments) to create a new resource of the collection's type that is automatically linked to the related resource?

Activity

  1. bintoro commented on Mar 21, 2015

    @bintoro
    Contributor

    Absolutely.

    A resource can be created by sending a POST request to a URL that represents a collection of resources.

    A server may choose not to support resource creation at all, but if it does, I would certainly expect related collections to accept POST requests. AFAIK this is not a requirement, however.

  2. timabdulla commented on Mar 25, 2015

    @timabdulla
    Author

    thanks, that clarifies that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions