This file contains all notable changes to this project. This project adheres to Semantic Versioning.
This change log follows the conventions of keepachangelog.com.
- Rollback Deal to be back to version v1
- Deal, Organization, Person, Pipeline, Product, Stage and User now support API v2.
- New
use_fields_versionmethod in Fields module to override API version specifically for fields operations - Fields-specific version override functionality that allows resources to use different API versions for fields vs general operations
fields_api_versionmethod to query the fields-specific API version
- Activity resource now uses
use_fields_version :v1instead ofuse_version :v1to override version only for fields operations - Activity general operations now use v2 API while fields operations continue to use v1 API as required by Pipedrive
- Fix bugs introduced with version 2 where the base URL for v1 was broken.
- Add GitHub Actions workflow
- BREAKING change: Minimum ruby version updated to 2.7.
- Added options for using new V2 API endpoints. Resource
Pipedrive::Activityswitched to new V2 endpoint. - Documentation updates with information on V1/V2 API endpoint switching.
- BREAKING change: Generated
delete_*method has been refactored to receive theidof the record to be dettached or deleted - instead of the resource per se -, for instance:deal.delete_product(attached_product_id). This is because the API behaves different depending on the endpoint, like in case of#DELETE /deals/{id}/products/{product_attachment_id}that receives an id corresponding to the attachment id (not a product, but a different record).
- Modify
has_manyto generate methods toaddanddeleteresources. ie.add_participant,add_product,delete_product - Add
Pipedrive::Participantresource and add the association toPipedrive::Deal - BREAKING CHANGE: Removed
delete_attached_productin favor ofdelete_productpassing a hash of params instead of an instance ofPipedrive::Resource - BREAKING CHANGE:
add_productchanged method signature because of the changes introduced inhas_many
- The codebase paginates until fetching all the fields so the diccionary of custom fields is complete (checkout
lib/pipedrive/fieldsfor more info)
- Update
LeadLabelresource to use PATCH method (as according to the API doc)
- Add the capability to override the HTTP method used to update a resource
- Update
Leadresource to use PATCH method (as according to the API doc)
- Added
findmethod for user to work for thefindendpoint of the Pipedrive API
- Implement
empty?(orno_content?) method on all the models when the response is No content (204 HTTP code) - Add option to treat 204 HTTP code (No Content) as 404 HTTP code (Not found)
- Add
find_by_dealmethod toSubscriptionto allow finding of subscriptions bydeal_id.
- Add the new resource
Pipedrive::OrganizationField - Add activities (as a
has_manyrelationship) toPipedrive::Person - Provide better error information also maping the status code to a class according to https://pipedrive.readme.io/docs/core-api-concepts-http-status-codes (check lib/pipedrive/errors.rb)
- Add
Subscriptionresource with additionalcreate_recurring,update_recurringandcancel_recurringmethods. - Changed faraday dependency to allow more flexibility
- Add
delete_attached_productmethod toDeal - Add metadata to
has_manyrelations that store the returned data(API) without transformation, as it is.
- Add
dealstoPerson
- Add
Pipedrive.debug_http_bodyfor debugging the http payload - Fix bugs with
POST/PUTendpoints
- Add
Pipedrive.debugso basic debug info is not displayed out of the box. - Add
Pipedrive.debug_httpfor debugging http traffic. - Fix bug in some resources when no fields filtering was provided.
- Fix bug introduced by v1.2.0 where
has_manyremoved the chance to pass extra parameters.
- Some endpoints like
deals/:id/productsallow to expand the response withinclude_product_datathat include an attrproductwith all the data - including the custon fields - of the products. The deafult for that option isfalseor0. I personally think this is redundant, so this version overrides this behavior by passingtrueor1and deleging the attrproductby merging its content with the body itself, at the end/productsshould returnproducts. On future versions this option would be passed to thehas_manymethod, likehas_many :products, class_name: "Product", include_data: false
- Add Lead, LeadLabel, LeadLabel and Goal models.
- Add capability to merge organizations, people and deals. See the doc here.
- Fixes unitialized constant error when the class_name within has_many definition doesn't contain the namespace
- Initial release