Skip to content

Latest commit

 

History

History
856 lines (646 loc) · 83.3 KB

CHANGELOG.md

File metadata and controls

856 lines (646 loc) · 83.3 KB

1.4.1 (Next)

Features

  • Your contribution here.

Fixes

1.4.0 (2020/07/10)

Features

  • #1520: Un-deprecate stream-like objects - @urkle.
  • #2060: Drop support for Ruby 2.4 - @dblock.
  • #2060: Upgraded Rubocop to 0.84.0 - @dblock.
  • #2077: Simplify logic for defining declared params - @dnesteryuk.
  • #2076: Make route information available for hooks when the automatically generated endpoints are invoked - @anakinj.

Fixes

  • #2067: Coerce empty String to nil for all primitive types except String - @petekinnecom.
  • #2064: Fix Ruby 2.7 deprecation warning in Grape::Middleware::Base#initialize - @skarger.
  • #2072: Fix Grape.eager_load! and compile! - @stanhu.
  • #2084: Fix memory leak in path normalization - @fcheung.

1.3.3 (2020/05/23)

Features

Fixes

1.3.2 (2020/04/12)

Features

Fixes

  • #2033: Ensure Float params are correctly coerced to BigDecimal - @tlconnor.
  • #2031: Fix a regression with an array of a custom type - @dnesteryuk.
  • #2026: Fix a regression in coerce_with when coercion returns nil - @misdoro.
  • #2025: Fix Decimal type category - @kdoya.
  • #2019: Avoid coercing parameter with multiple types to an empty Array - @stanhu.

1.3.1 (2020/03/11)

Features

Fixes

1.3.0 (2020/01/11)

Features

Fixes

1.2.5 (2019/12/01)

Features

  • #1931: Introduces LazyBlock to generate expressions that will executed at mount time - @myxoh.
  • #1918: Helper methods to access controller context from middleware - @NikolayRys.
  • #1915: Micro optimizations in allocating hashes and arrays - @dnesteryuk.
  • #1904: Allows Grape to load files on startup rather than on the first call - @myxoh.
  • #1907: Adds outside configuration to Grape with configure - @unleashy.
  • #1914: Run specs in random order - @splattael.

Fixes

  • #1917: Update access to rack constant - @NikolayRys.
  • #1916: Drop old appraisals - @NikolayRys.
  • #1911: Make sure Grape::Valiations::AtLeastOneOfValidator properly treats nested params in errors - @dnesteryuk.
  • #1893: Allows Grape::API to behave like a Rack::app in some instances where it was misbehaving - @myxoh.
  • #1898: Refactor ValidatorFactory to improve memory allocation - @Bhacaz.
  • #1900: Define boolean for Grape::Api::Instance - @Bhacaz.
  • #1903: Allow nested params renaming (Hash/Array) - @bikolya.
  • #1913: Fix multiple params validators to return correct messages for nested params - @bikolya.
  • #1926: Fixes configuration within given or mounted blocks - @myxoh.
  • #1937: Fix bloat in released gem - @dblock.

1.2.4 (2019/06/13)

Features

  • #1888: Makes the configuration hash widely available - @myxoh.
  • #1864: Adds finally on the API - @myxoh.
  • #1869: Fix issue with empty headers after error! method call - @anaumov.

Fixes

1.2.3 (2019/01/16)

Features

Fixes

  • #1852: allow_blank called after as when the original param is not blank - @glaucocustodio.
  • #1844: Enforce :tempfile to be a Tempfile object in File validator - @Nyangawa.

1.2.2 (2018/12/07)

Features

Fixes

1.2.1 (2018/11/28)

Fixes

  • #1825: to_s on a mounted class now responses with the API name - @myxoh.

1.2.0 (2018/11/26)

Features

  • #1813: Add ruby 2.5 support, drop 2.2. Update rails version in travis - @darren987469.
  • #1803: Adds the ability to re-mount all endpoints in any location - @myxoh.
  • #1795: Fix vendor/subtype parsing of an invalid Accept header - @bschmeck.
  • #1791: Support summary, hidden, deprecated, is_array, nickname, produces, consumes, tags options in desc block - @darren987469.

Fixes

1.1.0 (2018/8/4)

Features

  • #1759: Instrument serialization as 'format_response.grape' - @zvkemp.

Fixes

1.0.3 (2018/4/23)

Fixes

  • #1755: Fix shared params with exactly_one_of - @milgner.
  • #1740: Fix dependent parameter validation using given when parameter is a Hash - @jvortmann.
  • #1737: Fix translating error when passing symbols as params in custom validations - @mlzhuyi.
  • #1749: Allow rescue from non-StandardError exceptions - @dm1try.
  • #1750: Fix a circular dependency warning due to router being loaded by API - @salasrod.
  • #1752: Fix include_missing behavior for aliased parameters - @jonasoberschweiber.
  • #1754: Allow rescue from non-StandardError exceptions to use default error handling - @jelkster.
  • #1756: Allow custom Grape exception handlers when the built-in exception handling is enabled - @soylent.

1.0.2 (2018/1/10)

Features

Fixes

  • #1710: Fix wrong transformation of empty Array in declared params - @pablonahuelgomez.
  • #1722: Fix catch-all hiding multiple versions of an endpoint after the first definition - @zherr.
  • #1724: Optional nested array validation - @ericproulx.
  • #1725: Fix rescue_from :all documentation - @Jelkster.
  • #1726: Improved startup performance during API method generation - @jkowens.
  • #1727: Fix infinite loop when mounting endpoint with same superclass - @jkowens.

1.0.1 (2017/9/8)

Features

Fixes

  • #1652: Fix missing backtrace that was not being bubbled up to the error_formatter - @dcsg.
  • #1661: Handle deeply-nested dependencies correctly - @rnubel, @jnardone.
  • #1679: Treat StandardError from explicit values validator proc as false - @jlfaber.

1.0.0 (2017/7/3)

Features

  • #1594: Replace Hashie::Mash parameters with ActiveSupport::HashWithIndifferentAccess - @james2m, @dblock.
  • #1622: Add except_values validator to replace except option of values validator - @jlfaber.
  • #1635: Instrument validators with ActiveSupport::Notifications - @ktimothy.
  • #1646: Add ability to include an array of modules as helpers - @pablonahuelgomez.
  • #1623: Removed multi_json and multi_xml dependencies - @dblock.
  • #1650: Add extra specs for Boolean type field - @tiarly.

Fixes

  • #1648: Declared now returns declared options using the class that params is set to use - @thogg4.
  • #1632: Silence warnings - @thogg4.
  • #1615: Fix default and type validator when values is a Hash with no value attribute - @jlfaber.
  • #1625: Handle given correctly when nested in Array params - @rnubel, @avellable.
  • #1649: Don't share validator instances between requests - @anakinj.

0.19.2 (2017/4/12)

Features

  • #1555: Added code coverage w/Coveralls - @dblock.
  • #1568: Add proc option to values validator to allow custom checks - @jlfaber.
  • #1575: Include nil values for missing nested params in declared - @thogg4.
  • #1585: Bugs in declared method - make sure correct options var is used and respect include missing for non children params - @thogg4.

Fixes

  • #1570: Make versioner consider the mount destination path - @namusyaka.
  • #1579: Fix delete status with a return value - @eproulx-petalmd.
  • #1559: You can once again pass nil to optional attributes with values validation set - @ghiculescu.
  • #1562: Fix rainbow gem installation failure above ruby 2.3.3 on travis-ci - @brucehsu.
  • #1561: Fix performance issue introduced by duplicated calls in StackableValue#[] - @brucehsu.
  • #1564: Fix declared params bug with nested namespaces - @bmarini.
  • #1567: Fix values validator when value is empty array and apply except to input array - @jlfaber.
  • #1569, #1511: Upgrade mustermann-grape to 1.0.0 - @namusyaka.
  • #1589: #726: Use default_format when Content-type is missing and respond with 406 when Content-type is invalid - @inclooder.

0.19.1 (2017/1/9)

Features

Fixes

0.19.0 (2016/12/18)

Features

  • #1503: Allowed use of regexp validator with arrays - @akoltun.
  • #1507: Added group attributes for parameter definitions - @304.
  • #1532: Set 204 as default status for DELETE - @LeFnord.

Fixes

0.18.0 (2016/10/7)

Features

Fixes

  • #1498: Fix: skip validations in inactive given blocks - @jlfaber.
  • #1479: Fix: support inserting middleware before/after anonymous classes in the middleware stack - @rosa.
  • #1488: Fix: ensure calling before filters when receiving OPTIONS request - @namusyaka, @jlfaber.
  • #1493: Fix: coercion and lambda fails params validation - @jonmchan.

0.17.0 (2016/7/29)

Features

  • #1393: Middleware can be inserted before or after default Grape middleware - @ridiculous.
  • #1390: Allowed inserting middleware at arbitrary points in the middleware stack - @rosa.
  • #1366: Stored message_key on Grape::Exceptions::Validation - @mkou.
  • #1398: Added rescue_from :grape_exceptions - allow Grape to use the built-in Grape::Exception handing and use rescue :all behavior for everything else - @mmclead.
  • #1443: Extended given to receive a Proc - @glaucocustodio.
  • #1455: Added an automated PR linter - @orta.

Fixes

  • #1463: Fix array indicies in error messages - @ffloyd.
  • #1465: Fix 'before' being called twice when using not allowed method - @jsteinberg.
  • #1446: Fix for env inside before when using not allowed method - @leifg.
  • #1438: Try to dup non-frozen default params with each use - @jlfaber.
  • #1430: Fix for declared(params) inside route_param - @Arkanain.
  • #1405: Fix priority of rescue_from clauses applying - @hedgesky.
  • #1365: Fix finding exception handler in error middleware - @ktimothy.
  • #1380: Fix allow_blank: false for Time attributes with valid values causes NoMethodError - @ipkes.
  • #1384: Fix parameter validation with an empty optional nested Array - @ipkes.
  • #1414: Fix multiple version definitions for path versioning - @304.
  • #1415: Fix declared(params, include_parent_namespaces: false) - @304.
  • #1421: Avoid polluting Grape::Middleware::Error - @namusyaka.
  • #1422: Concat parent declared params with current one - @plukevdh, @rnubel, @namusyaka.

0.16.2 (2016/4/12)

Features

Fixes

0.16.1 (2016/4/3)

Features

Fixes

0.15.0 (2016/3/8)

Features

  • #1227: Store message_key on Grape::Exceptions::Validation - @stjhimy.
  • #1232: Helpers are now available inside rescue_from - @namusyaka.
  • #1237: Allow multiple parameters in given, which behaves as if the scopes were nested in the inputted order - @ochagata.
  • #1238: Call after of middleware on error - @namusyaka.
  • #1243: Add header support for middleware - @namusyaka.
  • #1252: Allow default to be a subset or equal to allowed values without raising IncompatibleOptionValues - @jeradphelps.
  • #1255: Allow param type definition in route_param - @namusyaka.
  • #1257: Allow Proc, Symbol or String in rescue_from with: ... - @namusyaka.
  • #1280: Support Rack::Sendfile middleware - @lfidnl.
  • #1285: Add a warning for errors appearing in after callbacks - @gregormelhorn.
  • #1295: Add custom validation messages for parameter exceptions - @railsmith.

Fixes

  • #1216: Fix JSON error response when calling error! with non-Strings - @jrforrest.
  • #1225: Fix given with nested params not returning correct declared params - @JanStevens.
  • #1249: Don't fail even if invalid type value is passed to default validator - @namusyaka.
  • #1266: Fix Allow header including OPTIONS when do_not_route_options! is active - @arempe93.
  • #1270: Fix param versioning with a custom parameter - @wshatch.
  • #1282: Fix specs circular dependency - @304.
  • #1283: Fix 500 error for xml format when method is not allowed - @304.
  • #1197: Fix using JSON and Array[JSON] as groups when parameter is optional - @lukeivers.

0.14.0 (2015/12/07)

Features

  • #1218: Provide array index context in errors - @towanda.
  • #1196: Allow multiple before_each blocks - @huynhquancam.
  • #1190: Bypass formatting for statuses with no entity-body - @tylerdooling.
  • #1188: Allow parameters with more than one type - @dslh.
  • #1179: Allow all RFC6838 valid characters in header vendor - @suan.
  • #1170: Allow dashes and periods in header vendor - @suan.
  • #1167: Convenience wrapper type: File for validating multipart file parameters - @dslh.
  • #1167: Refactor and extend coercion and type validation system - @dslh.
  • #1163: First-class JSON parameter type - @dslh.
  • #1161: Custom parameter coercion using coerce_with - @dslh.

Fixes

  • #1194: Redirect as plain text with message - @tylerdooling.
  • #1185: Use formatters for custom vendored content types - @tylerdooling.
  • #1156: Fixed no implicit conversion of Symbol into Integer with nested values validation - @quickpay.
  • #1153: Fixes boolean declaration in an external file - @towanda.
  • #1142: Makes #declared unavailable to before filters - @jrforrest.
  • #1114: Fix regression which broke identical endpoints with different versions - @suan.
  • #1109: Memoize Virtus attribute and fix memory leak - @marshall-lee.
  • #1101: Fix: Incorrect media-type Accept header now correctly returns 406 with strict: true - @elliotlarson.
  • #1108: Raise a warning when desc is called with options hash and block - @rngtng.

0.13.0 (2015/8/10)

Features

  • #1039: Added support for custom parameter types - @rnubel.
  • #1047: Adds given to DSL::Parameters, allowing for dependent params - @rnubel.
  • #1064: Add public Grape::Exception::ValidationErrors#full_messages - @romanlehnert.
  • #1079: Added stream method to take advantage of Rack::Chunked - @zbelzer.
  • #1086: Added ActiveSupport::Notifications instrumentation - @wagenet.

Fixes

  • #1062: Fix: Grape::Exceptions::ValidationErrors will include headers set by header - @yairgo.
  • #1038: Avoid dup-ing the String class when used in inherited params - @rnubel.
  • #1042: Fix coercion of complex arrays - @dim.
  • #1045: Do not convert Rack::Response to Rack::Response in middleware - @dmitry.
  • #1048: Only dup InheritableValues, remove support for deep_dup - @toddmazierski.
  • #1052: Reset description[:params] when resetting validations - @marshall-lee.
  • #1088: Support ActiveSupport 3.x by explicitly requiring Hash#except - @wagenet.
  • #1096: Fix coercion on booleans - @towanda.

0.12.0 (2015/6/18)

Features

  • #995: Added support for coercion to Set or Set[Other] - @jordansexton @u2.
  • #980: Grape is now eager-loaded - @u2.
  • #956: Support present with Grape::Presenters::Presenter - @u2.
  • #974: Added error! to rescue_from blocks - @whatasunnyday.
  • #950: Status method can now accept one of Rack::Utils status code symbols (:ok, :found, :bad_request, etc.) - @dabrorius.
  • #952: Status method now raises error when called with invalid status code - @dabrorius.
  • #957: Regexp validator now supports allow_blank, nil value behavior changed - @calfzhou.
  • #962: The default attribute with false value is documented now - @ajvondrak.
  • #1026: Added file method, explicitly setting a file-like response object - @dblock.

Fixes

  • #994: Fixed optional Array params default to Hash - @u2.
  • #988: Fixed duplicate identical endpoints - @u2.
  • #936: Fixed default params processing for optional groups - @dm1try.
  • #942: Fixed forced presence for optional params when based on a reused entity that was also required in another context - @croeck.
  • #1001: Fixed calling endpoint with specified format with format in its path - @hodak.
  • #1005: Fixed the Grape::Middleware::Globals - @urkle.
  • #1012: Fixed allow_blank: false with a Boolean value of false - @mfunaro.
  • #1023: Fixes unexpected behavior with present and an object that responds to merge but isn't a Hash - @dblock.
  • #1017: Fixed undefined method stringify_keys with nested mutual exclusive params - @quickpay.

0.11.0 (2015/2/23)

  • #925: Fixed toplevel constant DateTime referenced by Virtus::Attribute::DateTime - @u2.
  • #916: Added DateTime/Date/Numeric/Boolean type support allow_blank - @u2.
  • #871: Fixed Grape::Middleware::Base#response - @galathius.
  • #559: Added support for Rack 1.6.0, which parses requests larger than 128KB - @myitcv.
  • #876: Call to declared(params) now returns a Hashie::Mash - @rodzyn.
  • #879: The route_info value is no longer included in params Hash - @rodzyn.
  • #881: Fixed Grape::Validations::ValuesValidator support for Range type - @ajvondrak.
  • #901: Fix: callbacks defined in a version block are only called for the routes defined in that block - @kushkella.
  • #886: Group of parameters made to require an explicit type of Hash or Array - @jrichter1.
  • #912: Extended the :using feature for param documentation to optional fields - @croeck.
  • #906: Fix: invalid body parse errors are not rescued by handlers - @croeck.
  • #913: Fix: Invalid accept headers are not processed by rescue handlers - @croeck.
  • #913: Fix: Invalid accept headers cause internal processing errors (500) when http_codes are defined - @croeck.
  • #917: Use HTTPS for rubygems.org - @O-I.

0.10.1 (2014/12/28)

  • #868, #862, #861: Fixed version, prefix, and other settings being overridden or changing scope when mounting API - @yesmeck.
  • #864: Fixed declared(params, include_missing: false) now returning attributes with nil and false values - @ppadron.

0.10.0 (2014/12/19)

  • #803, #820: Added all_or_none_of parameter validator - @loveltyoic, @natecj.
  • #774: Extended mutually_exclusive, exactly_one_of, at_least_one_of to work inside any kind of group: requires or optional, Hash or Array - @ShPakvel.
  • #743: Added allow_blank parameter validator to validate non-empty strings - @elado.
  • #745: Removed atom+xml, rss+xml, and jsonapi content-types - @akabraham.
  • #745: Added :binary, application/octet-stream content-type - @akabraham.
  • #757: Changed desc can now be used with a block syntax - @dspaeth-faber.
  • #779: Fixed using values with a default proc - @ShPakvel.
  • #799: Fixed custom validators with required Hash, Array types - @bwalex.
  • #784: Fixed present to not overwrite the previously added contents of the response body whebn called more than once - @mfunaro.
  • #809: Removed automatic (.:format) suffix on paths if you're using only one format (e.g., with format :json, /path will respond with JSON but /path.xml will be a 404) - @ajvondrak.
  • #816: Added ability to filter out missing params if params is a nested hash with declared(params, include_missing: false) - @georgimitev.
  • #819: Allowed both desc and description in the params DSL - @mzikherman.
  • #821: Fixed passing string value when hash is expected in params - @rebelact.
  • #824: Validate array params against list of acceptable values - @dnd.
  • #813: Routing methods dsl refactored to get rid of explicit paths parameter - @AlexYankee.
  • #826: Find coerce_type for Array when not specified - @manovotn.
  • #645: Invoking body false will return 204 No Content - @dblock.
  • #801: Only evaluate permitted parameter values and default lazily on each request when declared as a proc - @dblock.
  • #679: Fixed OPTIONS method returning 404 when combined with prefix - @dblock.
  • #679: Fixed unsupported methods returning 404 instead of 405 when combined with prefix - @dblock.

0.9.0 (2014/8/27)

Features

Fixes

  • #687: Fix: mutually_exclusive and exactly_one_of validation error messages now label parameters as strings, consistently with requires and optional - @dblock.

0.8.0 (2014/7/10)

Features

  • #639: Added support for blocks with reusable params - @mibon.
  • #637: Added support for exactly_one_of parameter validation - @Morred.
  • #626: Added support for mutually_exclusive parameters - @oliverbarnes.
  • #617: Running tests on Ruby 2.1.1, Rubinius 2.1 and 2.2, Ruby and JRuby HEAD - @dblock.
  • #397: Adds Grape::Endpoint.before_each to allow easy helper stubbing - @mbleigh.
  • #673: Avoid requiring non-existent fields when using Grape::Entity documentation - @qqshfox.

Fixes

  • #671: Allow required param with predefined set of values to be nil inside optional group - @dm1try.
  • #651: The rescue_from keyword now properly defaults to rescuing subclasses of exceptions - @xevix.
  • #614: Params with nil value are now refused by RegexpValidator - @dm1try.
  • #494: Fixed performance issue with requests carrying a large payload - @dblock.
  • #619: Convert specs to RSpec 3 syntax with Transpec - @danielspector.
  • #632: Grape::Endpoint#present causes ActiveRecord to make an extra query during entity's detection - @fixme.

0.7.0 (2014/4/2)

Features

  • #558: Support lambda-based values for params - @wpschallenger.
  • #510: Support lambda-based default values for params - @myitcv.
  • #511: Added required option for OAuth2 middleware - @bcm.
  • #520: Use default_error_status to specify the default status code returned from error! - @salimane.
  • #525: The default status code returned from error! has been changed from 403 to 500 - @dblock.
  • #526: Allowed specifying headers in error! - @dblock.
  • #527: The before_validation callback is now a distinct one - @myitcv.
  • #530: Added ability to restrict declared(params) to the local endpoint with include_parent_namespaces: false - @myitcv.
  • #531: Helpers are now available to auth middleware, executing in the context of the endpoint - @joelvh.
  • #540: Ruby 2.1.0 is now supported - @salimane.
  • #544: The rescue_from keyword now handles subclasses of exceptions by default - @xevix.
  • #545: Added type (Array or Hash) support to requires, optional and group - @bwalex.
  • #550: Added possibility to define reusable params - @dm1try.
  • #560: Use Grape::Entity documentation to define required and optional parameters with requires using: - @reynardmh.
  • #572: Added documentation support to requires, optional and group parameters - @johnallen3d.

Fixes

  • #600: Don't use an Entity constant that is available in the namespace as presenter - @fuksito.
  • #590: Fix issue where endpoint param of type Integer cannot set values array - @xevix.
  • #586: Do not repeat the same validation error messages - @kiela.
  • #508: Allow parameters, such as content encoding, in content_type - @dm1try.
  • #492: Don't allow to have nil value when a param is required and has a list of allowed values - @Antti.
  • #495: Fixed ParamsScope#params for parameters nested inside arrays - @asross.
  • #498: Dry'ed up options and headers logic, allow headers to be passed to OPTIONS requests - @karlfreeman.
  • #500: Skip entity auto-detection when explicitely passed - @yaneq.
  • #503: Calling declared(params) from child namespace fails to include parent namespace defined params - @myitcv.
  • #512: Don't create Grape::Request multiple times - @dblock.
  • #538: Fixed default values for grouped params - @dm1try.
  • #549: Fixed handling of invalid version headers to return 406 if a header cannot be parsed - @bwalex.
  • #557: Pass content_types option to Grape::Middleware::Error to fix the content-type header for custom formats - @bernd.
  • #585: Fix after boot thread-safety issue - @etehtsea.
  • #587: Fix oauth2 middleware compatibility with draft-ietf-oauth-v2-31 spec - @etehtsea.
  • #610: Fixed group keyword was not working with type parameter - @klausmeyer.

0.6.1 (2013/10/19)

Features

Fixes

  • #477: Fixed default_error_formatter which takes a format symbol - @vad4msiu.

Development

  • Implemented Rubocop, a Ruby code static code analyzer - @dblock.

0.6.0 (2013/9/16)

Features

  • Grape is no longer tested against Ruby 1.8.7 - @dblock.
  • #442: Enable incrementally building on top of a previous API version - @dblock.
  • #442: API version can now take an array of multiple versions - @dblock.
  • #444: Added :en as fallback locale for I18n - @aew.
  • #448: Adding POST style parameters for DELETE requests - @dquimper.
  • #450: Added option to pass an exception handler lambda as an argument to rescue_from - @robertopedroso.
  • #443: Let requires and optional take blocks that initialize new scopes - @asross.
  • #452: Added with as a hash option to specify handlers for rescue_from and error_formatter - @robertopedroso.
  • #433, #462: Validation errors are now collected and Grape::Exceptions::ValidationErrors is raised - @stevschmid.

Fixes

  • #428: Removes memoization from Grape::Request params to prevent middleware from freezing parameter values before Formatter can get them - @mbleigh.

0.5.0 (2013/6/14)

Features

  • #344: Added parser :type, nil which disables input parsing for a given content-type - @dblock.
  • #381: Added cascade false option at API level to remove the X-Cascade: true header from the API response - @dblock.
  • #392: Extracted headers and params from Endpoint to Grape::Request - @niedhui.
  • #376: Added route_param, syntax sugar for quick declaration of route parameters - @mbleigh.
  • #390: Added default value for an optional parameter - @oivoodoo.
  • #403: Added support for versioning using the Accept-Version header - @politician.
  • #407: Specifying default_format will also set the default POST/PUT data parser to the given format - @dblock.
  • #241: Present with multiple entities using an optional Symbol - @niedhui.

Fixes

  • #378: Fix: stop rescuing all exceptions during formatting - @kbarrette.
  • #380: Fix: Formatter#read_body_input when transfer encoding is chunked - @paulnicholon.
  • #347: Fix: handling non-hash body params - @paulnicholon.
  • #394: Fix: path version no longer overwrites a version parameter - @tmornini.
  • #412: Fix: specifying content_type will also override the selection of the data formatter - @dblock.
  • #383: Fix: Mounted APIs aren't inheriting settings (including before and after filters) - @seanmoon.
  • #408: Fix: Goliath passes request header keys as symbols not strings - @bobek.
  • #417: Fix: Rails 4 does not rewind input, causes POSTed data to be empty - @dblock.
  • #423: Fix: Grape::Endpoint#declared now correctly handles nested params (ie. declared with group) - @jbarreneche.
  • #427: Fix: declared(params) breaks when params contains array - @timhabermaas.

0.4.1 (2013/4/1)

  • #375: Fix: throwing an :error inside a middleware doesn't respect the format settings - @dblock.

0.4.0 (2013/3/17)

  • #356: Fix: presenting collections other than Array (eg. ActiveRecord::Relation) - @zimbatm.
  • #352: Fix: using Rack::JSONP with Grape::Entity responses - @deckchair.
  • #347: Grape will accept any valid JSON as PUT or POST, including strings, symbols and arrays - @qqshfox, @dblock.
  • #347: JSON format APIs always return valid JSON, eg. strings are now returned as "string" and no longer string - @dblock.
  • Raw body input from POST and PUT requests (env['rack.input'].read) is now available in api.request.input - @dblock.
  • Parsed body input from POST and PUT requests is now available in api.request.body - @dblock.
  • #343: Fix: return Content-Type: text/plain with error 405 - @gustavosaume, @wyattisimo.
  • #357: Grape now requires Rack 1.3.0 or newer - @jhecking.
  • #320: API namespace now supports requirements - @niedhui.
  • #353: Revert to standard Ruby logger formatter, require active_support/all if you want old behavior - @rhunter, @dblock.
  • Fix: undefined method 'call' for nil:NilClass for an API method implementation without a block, now returns an empty string - @dblock.

0.3.2 (2013/2/28)

  • #355: Relax dependency constraint on Hashie - @reset.

0.3.1 (2013/2/25)

0.3.0 (2013/02/21)

  • #294: Extracted Grape::Entity into a grape-entity gem - @agileanimal.
  • #340, #342: Added :cascade option to version to allow disabling of rack/mount cascade behavior - @dieb.
  • #333: Added support for validation of arrays in params - @flyerhzm.
  • #306: Added I18n support for all Grape exceptions - @niedhui.
  • #309: Added XML support to the entity presenter - @johnnyiller, @dblock.
  • #131: Added instructions for Grape API reloading in Rails - @jyn, @dblock.
  • #317: Added headers that returns a hash of parsed HTTP request headers - @dblock.
  • #332: Grape::Exceptions::Validation now contains full nested parameter names - @alovak.
  • #328: API version can now be specified as both String and Symbol - @dblock.
  • #190: When you add a GET route for a resource, a route for the HEAD method will also be added automatically. You can disable this behavior with do_not_route_head! - @dblock.
  • Added do_not_route_options!, which disables the automatic creation of the OPTIONS route - @dblock.
  • #309: An XML format API will return an error instead of returning a string representation of the response if the latter cannot be converted to XML - @dblock.
  • A formatter that raises an exception will cause the API to return a 500 error - @dblock.
  • #322: When returning a 406 status, Grape will include the requested format or content-type in the response body - @dblock.
  • #60: Fix: mounting of a Grape API onto a path - @dblock.
  • #335: Fix: request body parameters from a PATCH request not available in params - @FreakenK.

0.2.6 (2013/01/11)

  • Fix: support content-type with character set when parsing POST and PUT input - @dblock.
  • Fix: CVE-2013-0175, multi_xml parse vulnerability, require multi_xml 0.5.2 - @dblock.

0.2.5 (2013/01/10)

  • Added support for custom parsers via parser, in addition to built-in multipart, JSON and XML parsers - @dblock.
  • Removed body_params, data sent via a POST or PUT with a supported content-type is merged into params - @dblock.
  • Setting format will automatically remove other content-types by calling content_type - @dblock.
  • Setting content_type will prevent any input data other than the matching content-type or any Rack-supported form and parseable media types (application/x-www-form-urlencoded, multipart/form-data, multipart/related and multipart/mixed) from being parsed - @dblock.
  • #305: Fix: presenting arrays of objects via represent or when auto-detecting an Entity constant in the objects being presented - @brandonweiss.
  • #306: Added i18n support for validation error messages - @niedhui.

0.2.4 (2013/01/06)

  • #297: Added default_error_formatter - @dblock.
  • #297: Setting format will automatically set default_error_formatter - @dblock.
  • #295: Storing original API source block in endpoint's source attribute - @dblock.
  • #293: Added options to cookies.delete, enables passing a path - @inst.
  • #174: The value of env['PATH_INFO'] is no longer altered with path versioning - @dblock.
  • #296: Fix: ArgumentError with default error formatter - @dblock.
  • #298: Fix: subsequent calls to body_params would fail due to IO read - @justinmcp.
  • #301: Fix: symbol memory leak in cookie and formatter middleware - @dblock.
  • #300: Fix Grape::API.routes to include mounted api routes - @aiwilliams.
  • #302: Fix: removed redundant autoload entries - @ugisozols.
  • #172: Fix: MultiJson deprecated methods warnings - @dblock.
  • #133: Fix: header-based versioning with use of prefix - @seanmoon, @dblock.
  • #280: Fix: grouped parameters mangled in route_params hash - @marcusg, @dblock.
  • #304: Fix: present x, :with => Entity returns class references with format :json - @dblock.
  • #196: Fix: root requests don't work with prefix - @dblock.

0.2.3 (2012/12/24)

  • #179: Using content_type will remove all default content-types - @dblock.
  • #265: Fix: Moved ValidationError into Grape::Exceptions - @thepumpkin1979.
  • #269: Fix: LocalJumpError will not be raised when using explict return in API methods - @simulacre.
  • #86: Fix Path-based versioning not recognizing / route - @walski.
  • #273: Disabled formatting via serializable_hash and added support for format :serializable_hash - @dblock.
  • #277: Added a DSL to declare formatter in API settings - @tim-vandecasteele.
  • #284: Added a DSL to declare error_formatter in API settings - @dblock.
  • #285: Removed error_format from API settings, now matches request format - @dblock.
  • #290: The default error format for XML is now error/message instead of hash/error - @dpsk.
  • #44: Pass env into formatters to enable templating - @dblock.

0.2.2 (2012/12/10)

Features

Fixes

  • #248: Fix: API version returns last version set - @narkoz.
  • #242: Fix: permanent redirect status should be 301, was 304 - @adamgotterer.
  • #211: Fix: custom validations are no longer triggered when optional and parameter is not present - @adamgotterer.
  • #210: Fix: Endpoint#body_params causing undefined method 'size' - @adamgotterer.
  • #205: Fix: Corrected parsing of empty JSON body on POST/PUT - @tim-vandecasteele.
  • #181: Fix: Corrected JSON serialization of nested hashes containing Grape::Entity instances - @benrosenblum.
  • #203: Added a check to Entity#serializable_hash that verifies an entity exists on an object - @adamgotterer.
  • #208: Entity#serializable_hash must also check if attribute is generated by a user supplied block - @ppadron.
  • #252: Resources that don't respond to a requested HTTP method return 405 (Method Not Allowed) instead of 404 (Not Found) - @simulacre.

0.2.1 (2012/7/11)

  • #186: Fix: helpers allow multiple calls with modules and blocks - @ppadron.
  • #188: Fix: multi-method routes append '(.:format)' only once - @kainosnoema.
  • #64, #180: Added support to GET request bodies as parameters - @bobbytables.
  • #175: Added support for API versioning based on a request parameter - @jackcasey.
  • #168: Fix: Formatter can parse symbol keys in the headers hash - @netmask.
  • #169: Silence multi_json deprecation warnings - @whiteley.
  • #166: Added support for redirect, including permanent and temporary - @allenwei.
  • #159: Added :requirements to routes, allowing to use reserved characters in paths - @gaiottino.
  • #156: Added support for adding formatters to entities - @bobbytables.
  • #183: Added ability to include documentation in entities - @flah00.
  • #189: HEAD requests no longer return a body - @stephencelis.
  • #97: Allow overriding Content-Type - @dblock.

0.2.0 (2012/3/28)

  • Added support for inheriting exposures from entities - @bobbytables.
  • Extended formatting with default_format - @dblock.
  • Added support for cookies - @lukaszsliwa.
  • Added support for declaring additional content-types - @joeyAghion.
  • Added support for HTTP PATCH - @LTe.
  • Added support for describing, documenting and reflecting APIs - @dblock.
  • Added support for anchoring and vendoring - @jwkoelewijn.
  • Added support for HTTP OPTIONS - @grimen.
  • Added support for silencing logger - @evansj.
  • Added support for helper modules - @freelancing-god.
  • Added support for Accept header-based versioning - @jch, @rodzyn.
  • Added support for mounting APIs and other Rack applications within APIs - @mbleigh.
  • Added entities, multiple object representations - @mbleigh.
  • Added ability to handle XML in the incoming request body - @jwillis.
  • Added support for a configurable logger - @mbleigh.
  • Added support for before and after filters - @mbleigh.
  • Extended rescue_from, which can now take a block - @dblock.

0.1.5 (2011/6/14)

  • Extended exception handling to all exceptions - @dblock.
  • Added support for returning JSON objects from within error blocks - @dblock.
  • Added support for handling incoming JSON in body - @tedkulp.
  • Added support for HTTP digest authentication - @daddz.

0.1.4 (2011/4/8)

  • Allow multiple definitions of the same endpoint under multiple versions - @chrisrhoden.
  • Added support for multipart URL parameters - @mcastilho.
  • Added support for custom formatters - @spraints.

0.1.3 (2011/1/10)

  • Added support for JSON format in route matching - @aiwilliams.
  • Added suport for custom middleware - @mbleigh.

0.1.1 (2010/11/14)

  • Endpoints properly reset between each request - @mbleigh.

0.1.0 (2010/11/13)