Change Log
Master
2.0.1
Fixed
- Fixed environment proxy
findmethod.
2.0.0
Added
- Added support for Environments
Changed
BREAKING CHANGES:
- In order to provide a better top-level client API,
space_idandenvironment_id, are now sent on the resource proxy call, rather than on the call itself. This allows for better reusability of proxies, which in the end provide a better developer experience. Resources that are not environment-aware, still have the parameter arrangement changed, so proxies are also reusable, but do not includeenvironment_id. Thespaces,users,organizationsandpersonal_access_tokensproxies still do not require any parameters as they are top level resources.
Before (this code will assume that the old code was also environment aware, so that the impact is more visible):
# Fetching all entries
client.entries.all(space_id, environment_id)
# Fetching a single entry
client.entries.find(space_id, environment_id, entry_id)
# If you wanted to find another entry, you'd have to repeat `space_id` and `environment_id`
client.entries.find(space_id, environment_id, another_entry_id)
Now:
# Fetching all entries
client.entries(space_id, environment_id).all
# Fetching a single entry
entries_proxy = client.entries(space_id, environment_id)
entries_proxy.find(entry_id)
# If you wanted to find another entry, you just reuse the resource proxy
entries_proxy.find(another_entry_id)
The proxies, apart from the parameter re-shuffling, have kept the same interface.
- Spaces do no longer have proxies for
entries,assets,content_types,ui_extensions,localesandeditor_interfaces. These can now be found underenvironments. - Space objects now have
environmentsas a proxy accessor. - Content Type Caching is now done when requesting Content Types, or when a property is missing on an Entry. Also
dynamic_entrieshas been updated to receive a hash ofspace_id => environment_idpairs.
Removed
all_publishedmethods for Entries and Assets have been removed.
1.10.1
Fixed
- Fixed an error when calling next page on
Contentful::Arraythat came from requests without query parameters. #143 - Fixed an issue with sending
defaulton newly created locales.
Added
- Added option to add a
fallback_codewhen creating locales.
1.10.0
Added
- Added better error messages for all possible API errors #95
1.9.0
Added
- Added option to disable Content Type caching completely.
- Added UI Extension Endpoint.
- Added Space Memberships Endpoint.
- Added Webhook Calls Endpoint.
- Added Webhook Health Endpoint.
- Added Content Type Snapshots Endpoint.
- Added Organizations Endpoint.
- Added User Endpoint.
- Added Personal Access Tokens Endpoint.
Changed
- Rewrote HTTP internals in order to allow base-level resources and simplified Client.
1.8.1
Added
- Added missing validation property for assets #121
1.8.0
Added
- Added
X-Contentful-User-Agentheader for more information.
1.7.0
Added
- Added support for Upload API
1.6.0
Added
- Added support for Snapshot API
1.5.0
Added
- Added support for Select Operator in Entries and Assets
1.4.0
Added
- Added support for Fallback Locales (
nilvalues get now removed from the requests on#updateand#create)
1.3.0
Added
- Added Rate Limit automatic handling
1.2.0
Added
- Add support for
::Contentful::Entryand::Contentful::Assetserialization when using the CDA SDK along side this client #105 - Add
:optionalproperty to Locale
1.1.0
Added
- Add Roles and Permissions Support
- Add Headers, Topics and Webhook Name Support
- Add Editor Interfaces Support
- Add
:omittedproperty to Content Type Fields
Changed
- Added Deprecation warning for
assets.all_publishedandentries.all_published. This methods will be completely removed soon.
1.0.1
Changed
- Changed locale selection priority when requesting fields #91
1.0.0
Breaking Changes
Clientis no longer a singleton. Therefore allResourceclass calls (Entry,Space,ContentType, etc...) require an instance of a client. The Client needs to be the first parameter of the call. As sending the client in every call is not a great solution, a shorthand for every resource class is present on the client. Calls can be done now like:client.entries.all. This works for every resource class, and all of the calls existing previously (all,find,create,all_published). Note:all_publishedis specific toEntry,AssetandContentType.- You can have as many instances of client, for as many users as you want.
Complete List of resource links on Client:
#entries#assets#spaces#content_types#locales#webhooks#api_keys
Fixed
- Removed code duplication between FieldAware and DynamicEntry #78
- Refactored FieldAware code to be simplified
Added
- Proxy Support #88
0.9.0
Added
- Added
#destroymethod to Locales - Added
ApiKeyclass, methods andSpaceassociations - Added
.all_publishedmethods forContentType,AssetandEntry - Locales can now update
:codevalue
Changed
- Changed documentation format to YARD
0.8.0
Added
- Added
:dynamic_entriesparameter on Client initialization - Added
FieldAwarefor Entries that don't have complete fields
Fixed
- Fixed
nilfields on Content Types no longer sent to API #79
0.7.3
Fixed
- Field names are no longer dependent on being present on
default_locale#70
0.7.2
Fixed
- Ensure that
Validation.typereturns correct value #59, #66 - Ensure that already existing
Spacereturns correctLocalefor#default_locale#60 - Remove unintended nested
Validation#49
0.7.1
Fixed
fields_for_queryshould only skipnilvalues #63, #64- Reinstate support for simple assignments to fields #61, #62
- Fix NULL/nil handling for entries #65
0.7.0
Added
Fixed
- Explicitly set displayField to nil when it is not existing #53, #54
- Merge values for default locale and current locale #58
0.6.1
Fixed
- Fix access to space default_locale instance variable #47
- Better handling of 503 responses from the API #48
- Do Not loose displayField on update when it is not set #52
0.6.0
Added
- Access request and response from Contentful::Management:Error #46
Fixed
- Handle 429 responses as errors #46
0.5.0
Added
- Allow setting a default locale when creating a space #43
Fixed
- Handle
UnprocessableEntity(HTTP 422) as its own error. #42
0.4.1
Fixed
- Handle 409 responses as errors #39
0.4.0
Fixed
- Return Keep attribute if it's already a hash #33
- Typo in header #34
- Items are nil when creating an array field for a content type #35
Added
raise_errorscan be enabled, disabled by default #38
0.3.1
Added
- Logging of requests
- Access to validations in responses
- Create validations through the API
Fixed
- Cleaner and better error handling
Other
- Cleaned the code
- Remove encoding strings from the source code files
0.2.1
Fixed
- Use array for symbols in entry fields
0.2.0
Fixed
- create entry with multiple locales, skip attributes for not localized fields in content types
- reload Assets
Added
- Add optional gzip encoding
0.1.0
Added
- Support for web hooks
- Image url to asset
Fixed
- remove implicit processing of assets.
- Gem is modifying nil #17
- rename asset.process_files to asset.process
Other
- Cleaning code
0.0.3
Added:
- More documentation
Fixed:
- next_page feature
- create entry with specific locale
- service unavailable error (503)
- reload method on objects
Other
- Code cleanup
0.0.2
Fixed
- Fix: Convert an Entry to a DynamicEntry after being created.
0.0.1
Added
- rdoc
- filter by content_type id
Fixed
- Headers not properly cleared between requests
- Create entries with custom identifier
Other
- Code cleanup
0.0.1-pre
- alpha pre-release