Sha256: aad86156ed61d7a203d97a8d2ea6a9c4ed8ec845ecb069d576509e41ff1a6e1a
Contents?: true
Size: 588 Bytes
Versions: 13
Compression:
Stored size: 588 Bytes
Contents
# *Flexirest:* Root elements If your response comes back with a root node and you'd like to ignore it, you can define the mapping as: ```ruby class Feed < Flexirest::Base post :list, "/feed", ignore_root: "feed" end ``` Alternatively if you want to wrap your JSON request body in a root element, e.g.: ```json { "feed": { "id": 1 } } ``` You can do it like this: ```ruby class Feed < Flexirest::Base post :list, "/feed", wrap_root: "feed" end Feed.list(id: 1) ``` ----- [< Default parameters](default-parameters.md) | [Required parameters >](required-parameters.md)
Version data entries
13 entries across 13 versions & 1 rubygems