Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ The file format of it is based on [Keep a Changelog](http://keepachangelog.com/e
For public Changelog covering all changes done to Pipedrive’s API, webhooks and app extensions platforms, see [public Changelog](https://pipedrive.readme.io/docs/changelog) with discussion area in [Developers Community](https://devcommunity.pipedrive.com/c/documentation/changelog/19).

## [Unreleased]
### Fixed
- Defined the properties of the `prices` array items in product variations (`price`, `cost`, `currency`, `direct_cost`, `notes`, plus `product_variation_id` in responses), which were previously an untyped object:
- Responses: `GET /api/v2/products/{id}/variations`, `POST /api/v2/products/{id}/variations`, `PATCH /api/v2/products/{id}/variations/{product_variation_id}`
- Request bodies: `POST /api/v2/products/{id}/variations`, `PATCH /api/v2/products/{id}/variations/{product_variation_id}` (`price` and `currency` are required)
- Changed the type of `archived_flag` from `number` to `integer` (still nullable, `0` or `1`) in `GET /v1/mailbox/mailThreads`, `GET /v1/mailbox/mailThreads/{id}` and `PUT /v1/mailbox/mailThreads/{id}` responses

## [36.1.1] - 2026-11-06
### Fixed
Expand Down
9 changes: 6 additions & 3 deletions src/versions/v2/models/add-product-variation-request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
*/


// May contain unused imports in some cases
// @ts-ignore
import { ProductVariationPriceRequest } from './product-variation-price-request';

/**
*
Expand All @@ -26,9 +29,9 @@ export interface AddProductVariationRequest {
*/
'name': string;
/**
* Array of objects, each containing: currency (string), price (number), cost (number, optional), direct_cost (number, optional), notes (string, optional). When prices is omitted altogether, a default price of 0, a default cost of 0, a default direct_cost of 0 and the user\'s default currency will be assigned.
* @type {Array<object>}
* Array of prices of the product variation. When prices is omitted altogether, a default price of 0, a default cost of 0, a default direct_cost of 0 and the user\'s default currency will be assigned.
* @type {Array<ProductVariationPriceRequest>}
*/
'prices'?: Array<object>;
'prices'?: Array<ProductVariationPriceRequest>;
}

49 changes: 49 additions & 0 deletions src/versions/v2/models/base-product-variation-price.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/* tslint:disable */
/* eslint-disable */
/**
* Pipedrive API v2
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 2.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/



/**
*
* @export
* @interface BaseProductVariationPrice
*/
export interface BaseProductVariationPrice {
/**
* The price of the product variation
* @type {number}
*/
'price'?: number;
/**
* The cost of the product variation
* @type {number}
*/
'cost'?: number;
/**
* The currency of the price
* @type {string}
*/
'currency'?: string;
/**
* The direct cost of the product variation
* @type {number}
*/
'direct_cost'?: number;
/**
* The notes about the price
* @type {string}
*/
'notes'?: string;
}

Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
*/


// May contain unused imports in some cases
// @ts-ignore
import { ProductVariationPrice } from './product-variation-price';

/**
*
Expand All @@ -36,9 +39,9 @@ export interface GetProductVariationsResponseDataInner {
*/
'product_id'?: number;
/**
* Array of objects, each containing: product_variation_id (number), currency (string), price (number), cost (number), direct_cost (number) , notes (string)
* @type {Array<object>}
* Array of prices of the product variation
* @type {Array<ProductVariationPrice>}
*/
'prices'?: Array<object>;
'prices'?: Array<ProductVariationPrice>;
}

4 changes: 4 additions & 0 deletions src/versions/v2/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ export * from './add-task-response';
export * from './base-product';
export * from './base-product-all-of';
export * from './base-product-all-of1';
export * from './base-product-variation-price';
export * from './base-response';
export * from './convert-lead-to-deal-request';
export * from './create-many-deal-product-request';
Expand Down Expand Up @@ -264,6 +265,9 @@ export * from './prices-array';
export * from './product-price';
export * from './product-price-request';
export * from './product-request';
export * from './product-variation-price';
export * from './product-variation-price-all-of';
export * from './product-variation-price-request';
export * from './project';
export * from './project-template';
export * from './stage-item';
Expand Down
29 changes: 29 additions & 0 deletions src/versions/v2/models/product-variation-price-all-of.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/* tslint:disable */
/* eslint-disable */
/**
* Pipedrive API v2
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 2.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/



/**
*
* @export
* @interface ProductVariationPriceAllOf
*/
export interface ProductVariationPriceAllOf {
/**
* The ID of the product variation
* @type {number}
*/
'product_variation_id'?: number;
}

26 changes: 26 additions & 0 deletions src/versions/v2/models/product-variation-price-request.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/* tslint:disable */
/* eslint-disable */
/**
* Pipedrive API v2
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 2.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/


// May contain unused imports in some cases
// @ts-ignore
import { BaseProductVariationPrice } from './base-product-variation-price';

/**
* @type ProductVariationPriceRequest
* @export
*/
export type ProductVariationPriceRequest = BaseProductVariationPrice;


29 changes: 29 additions & 0 deletions src/versions/v2/models/product-variation-price.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/* tslint:disable */
/* eslint-disable */
/**
* Pipedrive API v2
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 2.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/


// May contain unused imports in some cases
// @ts-ignore
import { BaseProductVariationPrice } from './base-product-variation-price';
// May contain unused imports in some cases
// @ts-ignore
import { ProductVariationPriceAllOf } from './product-variation-price-all-of';

/**
* @type ProductVariationPrice
* @export
*/
export type ProductVariationPrice = BaseProductVariationPrice & ProductVariationPriceAllOf;


9 changes: 6 additions & 3 deletions src/versions/v2/models/update-product-variation-request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
*/


// May contain unused imports in some cases
// @ts-ignore
import { ProductVariationPriceRequest } from './product-variation-price-request';

/**
*
Expand All @@ -26,9 +29,9 @@ export interface UpdateProductVariationRequest {
*/
'name'?: string;
/**
* Array of objects, each containing: currency (string), price (number), cost (number, optional), direct_cost (number, optional), notes (string, optional). When prices is omitted altogether, a default price of 0, a default cost of 0, a default direct_cost of 0 and the user\'s default currency will be assigned.
* @type {Array<object>}
* Array of prices of the product variation. When prices is omitted altogether, a default price of 0, a default cost of 0, a default direct_cost of 0 and the user\'s default currency will be assigned.
* @type {Array<ProductVariationPriceRequest>}
*/
'prices'?: Array<object>;
'prices'?: Array<ProductVariationPriceRequest>;
}

Loading