8.0.3 (2022-06-24)
- deps: update dependency superagent to v8 (afc8a97)
8.0.2 (2022-05-16)
- deps: update dependency jsonpath-plus to ^0.20.0 (cb070cf)
- deps: update dependency jsonpath-plus to v6 (ed828fd)
- deps: update dependency url-template to v3 (d215b7d)
- dependency updates that were merged when CI was failing to trigger (0434605)
8.0.1 (2022-02-04)
- deps: update dependency superagent to v7 (cc5c3d6)
8.0.0 (2022-02-03)
- node-versions: dropped support for EOL versions (cae9dd9)
- node-versions: versions of node that have reached EOL are no longer supported
7.0.1 (2020-06-05)
7.0.0 (2020-02-28)
- build: split the gruntfile to enable running the build separately (c487b18)
- dependencies: bumped to the latest version of several packages (f03ef4b)
- node-version: dropped support for node v8, which has reached EOL (14b6b44)
- engines: defined
engines
to match tested node versions (6f0f108)
- limited the files included in the build to minimum required (b59a7b3)
- node-versions: stopped building against unsupported node versions (b36aa83)
- publish: dropped bower support (2915d6d)
- limited the published files to those used by the public api. use of private files could break with this change
- node-version: node v8 has reached EOL and is no longer supported
- engines: the engines property now limits supported node versions to v8 and above
- publish: bower is being dropped as a supported platform
- node-versions: dropped support for end-of-life'ed versions of node
7.0.0-alpha.7 (2020-02-21)
- limited the files included in the build to minimum required (b59a7b3)
- limited the published files to those used by the public api. use of private files could break with this change
7.0.0-alpha.6 (2020-02-11)
- node-version: dropped support for node v8, which has reached EOL (14b6b44)
- node-version: node v8 has reached EOL and is no longer supported
7.0.0-alpha.5 (2019-06-15)
- engines: defined
engines
to match tested node versions (6f0f108)
- engines: the engines property now limits supported node versions to v8 and above
7.0.0-alpha.4 (2019-06-15)
- build: split the gruntfile to enable running the build separately (c487b18)
7.0.0-alpha.3 (2019-06-15)
- dependencies: bumped to the latest version of several packages (f03ef4b)
7.0.0-alpha.2 (2019-06-15)
- publish: dropped bower support (2915d6d)
- publish: bower is being dropped as a supported platform
7.0.0-alpha.1 (2019-06-15)
- node-versions: stopped building against unsupported node versions (b36aa83)
- node-versions: dropped support for end-of-life'ed versions of node
- 0.0.1 2013-10-02: Initial release
- 0.1.0 2013-10-11:
- New fluent API
- Add
get
,post
,put
,patch
anddelete
- 0.2.0 2013-10-25:
- Support for hypertext application language (HAL)
- Add
getUri
- Add
withRequestOptions
- 0.2.1 2013-10-25:
- Documentation fixes
- 0.3.0 2013-11-17:
- Browser build in addition to Node.js module (by browserify)
- 0.4.0 2013-11-21:
- Use Halfred instead of Halbert to parse HAL to reduce size of browser build.
- 0.5.0 2013-11-23:
- Make individual elements of HAL link arrays and embedded arrays available by using array indexing notation
- 0.6.0 2013-11-25:
- Further reduce browserified size
- 0.7.0 2013-12-05:
- Select HAL links by secondary key
- 0.8.0 2014-04-30:
- Support absolute URLs, absolute URL paths and relative URLs (#3)
- Fix: Also resolve URI templates when no template params are given (makes sense for templates with optional components)
- Fix: Now works for cases where the entry point has a pathname other than
/
. (thanks to @eins78)
- 0.8.2 2014-06-12:
- Fix corrupted browser build (#10)
- Can now be installed via bower (thanks to @chadly)
- 0.8.3 2014-06-19:
- Fix bower release (#11)
- 0.9.0 2014-06-27:
- Add HAL curie resolution (#12)
- 0.10.0 2014-10-01:
- Add query string handling for client side (#16) (thanks to @craigspaeth)
- 0.11.0 2014-11-14:
- Add ability to set a custom request library (#18) (thanks to @subvertnormality/@bbc-contentdiscovery)
- 0.12.0 2014-11-29:
- Deal with cases where body comes as arg but not in response (#19) (thanks to @subvertnormality/@bbc-contentdiscovery)
- 0.13.0 2014-12-01:
- Reduce size of browser build by 33%. The minified version now has 37k instead of 55k (still too much, but also much better than before)
- 0.14.0 2014-12-05:
- 0.15.0 2014-12-06:
- Content type detection (#6)
- 1.0.0 2015-02-27:
- Media Type Plug-ins. You can now register your own media types and plug-ins to process them.
- HAL is no longer supported by Traverson out of the box. If you want to use HAL, you now have to use the traverson-hal plug-in.
- Traverson uses content type detection by default now. You can still force media types by calling
setMediaType
or shortcuts likejson()
/jsonHal()
on the request builder. - New method
setMediaType
to force arbitrary media types (as long as a matching media type plug-in is registered). - New methods
json()
/jsonHal()
as shortcuts forsetMediaType('application/json')
/setMediaType('application/hal+json')
. - The properties
traverson.json
andtraverson.jsonHal
(that is, using propertiesjson
/jsonHal
on thetraverson
object) are deprecated as of 1.0.0 (but they still work). Instead, use the methodsjson()
/jsonHal()
on the request builder object. Thus,traverson.json.from(url)
becomestraverson.from(url).json()
andtraverson.jsonHal.from(url)
becomestraverson.from(url).jsonHal()
. You can also omitjson()
/jsonHal()
completely and use content negotiation. - Entry points (methods on the traverson object) have been restructured (see api.markdown for details).
- Cloning a request builder (to share configuration between link traversals) is now more explicit (method
newRequest()
on a request builder instance). del()
has been renamed todelete()
.del()
is kept as an alias for backward compatibility.- New method
addRequestOptions
to add request options (HTTP headers etc.) without resetting the ones that have been set already (#33) (thanks to @xogeny) - Lots of documenation updates. Also new API reference documentation.
- 1.1.0 2015-03-02:
- Abort link traversals (and HTTP requests) (#27). This feature is to be considered experimental in this version.
- Specify request options per step by passing in an array to
withRequestOptions
oraddRequestOptions
(#25). - Fix for subsequent error that ate the original error if a problem occured before or during the first HTTP request (#23).
- Fix: Copy contentNegotiation flag correctly to cloned request builder (
newRequest()
). - Add methods to request builder to query the current configuration.
- Posting with content type application/x-www-form-urlencoded works now (#31).
- 1.2.0 2015-03-15:
- Huge refactoring of Traverson's internals. To the best of my knowledge, this did not break anything (the test coverage on Traverson is pretty good). You probably should take this version for a test ride before pushing it to production, though.
- The method
getUri
has been renamed togetUrl
.getUri
is now deprecated, but is kept as an alias forgetUrl
. - The API for media type plug-ins has changed. The property
uri
in the step object that media type plug-ins return has been renamed tourl
. Media type plug-ins that return a step object with anuri
attribute still work, but this attribute is considered to be deprecated. Support for it will be removed in version 2.0.0. - An undocumented behaviour has been removed: In case of an error, the callback has sometimes been called with more than one argument (the error), namely with the last response and the last URL that had been accessed before the error occured. If you relied on this behaviour, then this is a breaking change for you.
- Added
preferEmbeddedResources()
.
- 1.2.1 2015-03-15:
- Include browser build in npm release (for users using npm for client side packages but not using Browserify but script tags or RequireJS).
- 2.0.0 2015-04-07:
- Continue link traversals with
continue
(see API docs, also see GitHub issues #7, #24, #40 and traverson-hal/#4). - Fix for wrong resolution of URLs for HAL and root URLs with path (#38, thanks to @xogeny)
- Breaking changes (probably irrelevant for most users):
- The methods callback passed to
post
,put
,patch
anddelete
no longer receive the URL that had been visited last as their third parameter. The callback signature is nowcallback(err, response, traversal)
for these methods.
- The methods callback passed to
- Continue link traversals with
- 2.0.1 2015-05-04:
- Fixes a bug when cloning a continued traversal (via
continue
) withnewRequest
.
- Fixes a bug when cloning a continued traversal (via
- 2.1.0 2015-08-27:
- Ability to convert response bodies to JavaScript objects at the end of the traversal is now also available for
post()/put()/patch()/delete()
via configuration methodconvertResponseToObject()
, not only forget()
. (#44, thanks to @jinder for the suggestion). - Improved error message when a JSONPath expression denotes a property that does not have type string; for example, if the property has type object. (#43, thanks to @Baiteman for reporting).
- Ability to convert response bodies to JavaScript objects at the end of the traversal is now also available for
- 3.0.0 2015-09-15:
- Breaking change for media type plug-ins: the API for media type plug-ins has changed. The
findNextStep
method takes different parameters now:XyzAdapter.prototype.findNextStep = function(t, link) { ... }
wheret
represents the link traversal process andlink
is always an object that represents what to do in the next step in the traversal. See Implementing Media Type Plug-ins in the user guide for details. - Breaking change: Multiple consecutive calls to
follow(...)
for the same traversal now add links to the list of link relations instead of overwriting the old list with a new list. This is probably irrelevant because until now, there was no reason to call follow multiple times for one traversal. - Ability to follow the location header instead of a link relation in the body, method
followLocationHeader
(#45, thanks to @xogeny for the idea)
- Breaking change for media type plug-ins: the API for media type plug-ins has changed. The
- 3.1.0 2015-11-10:
- Support for setting
withCrendentials
flag on XHR object (only in browser) (#48, thanks to @ricardoecosta)
- Support for setting
- 3.1.1 2015-12-21:
- Update from JSONPath 0.10 to jsonpath-plus 0.13. (See traverson-angular/#20)
- 3.1.2 2016-01-22:
- Fix
Cannot read property 'step' of undefined
in case a step of the traversal can not be processed (#52).
- Fix
- 3.1.3 2016-02-01:
- Do not mutate original link array (#53, thanks to @dimik).
- 3.2.0 2016-09-02:
- 5.0.0 2016-12-20:
- Drop support for Node.js 0.10 and 0.12. Node.js versions 4 to 7 are tested and officially supported.
- All
Error
objects created by Traverson now have thename
property set, see API docs on error names. (traverson-hal/#21 and traverson-hal/#22, thanks to @mimol91) - Remark: There is no version 4.x of Traverson. We skipped from version 3.x to 5.0.0 to align version numbers of Traverson and traverson-hal.
- 6.0.0 2017-02-10:
- Breaking change: Traverson now sets
Accept
andContent-Type
headers automatically when the media type has been set explicitly (#37). This might be a breaking change for users that- do set the media type via
.setMediaType('...')
,.json()
or.jsonHal()
, - do not set headers explicitly (via
.withRequestOptions
or.addRequestOptions
) and - whose backends do not cope well when
Accept
and/orContent-Type
headers are set toapplication/json
orapplication/hal+json
respectively.
- do set the media type via
- Support for link headers (#84 and #85, thanks to @iunanua and @anderruiz)
- Fix an error where content negotiation would fail with the wrong error message when receiving an unknown media type (#82, thanks to @Malax for the report and the analysis)
- Breaking change: Traverson now sets
- 6.0.1 2017-02-10:
- 6.0.2 2017-04-05:
- Fix bogus character in source code breaking browserify build (#94, thanks to @simon-scherzinger).
- 6.0.3 2017-04-21:
- Allow falsy values as payload in HTTP POST/PUT/PATCH requests (#95).
- 6.0.4 2018-07-19:
- Update to latest version of
request
(#104, thanks to @travi).
- Update to latest version of
- 6.1.0 2018-09-10:
- Add option
sendRawPayload
to skip payload stringification for non-JSON MIME types (#103.
- Add option
- 6.1.1 2018-09-14:
- Enable usage of Traverson in React Native (without JSONPath support) (#114, thanks to @simon-scherzinger)
- Fix wrong HTTP method in error message for convertResponseToObject case.