Skip to content
Branch: master
Go to file
Code

Latest commit

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 

README.md

#Nancy.Siren

A library to extend your response payload with the Siren hypermedia media type

{
    "class": [
        "order"
    ],
    "properties": {
        "orderNumber": 6534,
        "itemCount": 6,
        "status": "Completed"
    },
    "entities": [
        {
            "class": [
                "collection"
            ],
            "rel": [
                "http://localhost:8080/rels/order-items/"
            ],
            "href": "http://localhost:8080/orders/6534/items"
        }
    ],
    "actions": [
        {
            "name": "delete-order",
            "title": "Delete Order",
            "method": "DELETE",
            "href": "http://localhost:8080/orders/6534/"
        },
        {
            "name": "add-to-order",
            "title": "Add Item To Order",
            "method": "POST",
            "href": "http://localhost:8080/orders/6534/",
            "type": "application/json",
            "fields": [
                {
                    "name": "productCode",
                    "type": "text"
                },
                {
                    "name": "quantity",
                    "type": "number"
                }
            ]
        }
    ],
    "links": [
        {
            "rel": [
                "self"
            ],
            "href": "http://localhost:8080/orders/6534"
        }
    ]
}

About

Allows you to return Siren hypermedia payloads when using the correct Accept header in your Nancy application

Resources

License

Releases

No releases published

Languages

You can’t perform that action at this time.