pipedrive 32.2.0 → 33.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (381) hide show
  1. package/dist/esm/versions/v1/api/notes-api.d.ts +18 -2
  2. package/dist/esm/versions/v1/api/notes-api.js +15 -5
  3. package/dist/esm/versions/v1/api/project-boards-api.d.ts +117 -0
  4. package/dist/esm/versions/v1/api/project-boards-api.js +191 -0
  5. package/dist/esm/versions/v1/api/project-phases-api.d.ts +134 -0
  6. package/dist/esm/versions/v1/api/project-phases-api.js +200 -0
  7. package/dist/esm/versions/v1/api/project-templates-api.d.ts +0 -94
  8. package/dist/esm/versions/v1/api/project-templates-api.js +0 -136
  9. package/dist/esm/versions/v1/api/projects-api.d.ts +0 -77
  10. package/dist/esm/versions/v1/api/projects-api.js +0 -131
  11. package/dist/esm/versions/v1/api.d.ts +2 -0
  12. package/dist/esm/versions/v1/api.js +2 -0
  13. package/dist/esm/versions/v1/models/add-note-request-all-of.d.ts +10 -5
  14. package/dist/esm/versions/v1/models/add-note-request-all-of1.d.ts +10 -0
  15. package/dist/esm/versions/v1/models/add-note-request-all-of1.js +4 -0
  16. package/dist/esm/versions/v1/models/index.d.ts +1 -0
  17. package/dist/esm/versions/v1/models/index.js +1 -0
  18. package/dist/esm/versions/v1/models/note-request-all-of1.d.ts +5 -0
  19. package/dist/esm/versions/v1/models/note-task.d.ts +23 -0
  20. package/dist/esm/versions/v1/models/note-task.js +14 -0
  21. package/dist/esm/versions/v1/models/note.d.ts +16 -0
  22. package/dist/esm/versions/v2/api/beta-api.d.ts +1314 -0
  23. package/dist/esm/versions/v2/api/beta-api.js +1796 -0
  24. package/dist/esm/versions/v2/api/deal-installments-api.d.ts +294 -0
  25. package/dist/esm/versions/v2/api/deal-installments-api.js +374 -0
  26. package/dist/esm/versions/v2/api/deal-products-api.d.ts +482 -0
  27. package/dist/esm/versions/v2/api/deal-products-api.js +607 -0
  28. package/dist/esm/versions/v2/api/deals-api.d.ts +32 -696
  29. package/dist/esm/versions/v2/api/deals-api.js +54 -891
  30. package/dist/esm/versions/v2/api/organizations-api.d.ts +36 -4
  31. package/dist/esm/versions/v2/api/organizations-api.js +30 -10
  32. package/dist/esm/versions/v2/api/persons-api.d.ts +36 -4
  33. package/dist/esm/versions/v2/api/persons-api.js +30 -10
  34. package/dist/esm/versions/v2/api/project-boards-api.d.ts +266 -0
  35. package/dist/esm/versions/v2/api/project-boards-api.js +400 -0
  36. package/dist/esm/versions/v2/api/project-fields-api.d.ts +457 -0
  37. package/dist/esm/versions/v2/api/project-fields-api.js +636 -0
  38. package/dist/esm/versions/v2/api/project-phases-api.d.ts +283 -0
  39. package/dist/esm/versions/v2/api/project-phases-api.js +409 -0
  40. package/dist/esm/versions/v2/api/project-templates-api.d.ts +142 -0
  41. package/dist/esm/versions/v2/api/project-templates-api.js +203 -0
  42. package/dist/esm/versions/v2/api/projects-api.d.ts +644 -0
  43. package/dist/esm/versions/v2/api/projects-api.js +829 -0
  44. package/dist/esm/versions/v2/api/tasks-api.d.ts +333 -0
  45. package/dist/esm/versions/v2/api/tasks-api.js +437 -0
  46. package/dist/esm/versions/v2/api.d.ts +9 -0
  47. package/dist/esm/versions/v2/api.js +9 -0
  48. package/dist/esm/versions/v2/models/add-deal-request.d.ts +1 -1
  49. package/dist/esm/versions/v2/models/add-organization-request.d.ts +1 -1
  50. package/dist/esm/versions/v2/models/add-person-request.d.ts +1 -1
  51. package/dist/esm/versions/v2/models/add-product-request.d.ts +2 -2
  52. package/dist/esm/versions/v2/models/add-project-board-request.d.ts +28 -0
  53. package/dist/esm/versions/v2/models/add-project-board-request.js +14 -0
  54. package/dist/esm/versions/v2/models/add-project-field-request-important-fields.d.ts +29 -0
  55. package/dist/esm/versions/v2/models/add-project-field-request-important-fields.js +14 -0
  56. package/dist/esm/versions/v2/models/add-project-field-request-required-fields.d.ts +24 -0
  57. package/dist/esm/versions/v2/models/add-project-field-request-required-fields.js +14 -0
  58. package/dist/esm/versions/v2/models/add-project-field-request-ui-visibility.d.ts +29 -0
  59. package/dist/esm/versions/v2/models/add-project-field-request-ui-visibility.js +14 -0
  60. package/dist/esm/versions/v2/models/add-project-field-request.d.ts +71 -0
  61. package/dist/esm/versions/v2/models/add-project-field-request.js +31 -0
  62. package/dist/esm/versions/v2/models/add-project-field200-response.d.ts +29 -0
  63. package/dist/esm/versions/v2/models/add-project-field200-response.js +14 -0
  64. package/dist/esm/versions/v2/models/add-project-phase-request.d.ts +33 -0
  65. package/dist/esm/versions/v2/models/add-project-phase-request.js +14 -0
  66. package/dist/esm/versions/v2/models/add-project-request.d.ts +90 -0
  67. package/dist/esm/versions/v2/models/add-project-request.js +14 -0
  68. package/dist/esm/versions/v2/models/add-task-request.d.ts +83 -0
  69. package/dist/esm/versions/v2/models/add-task-request.js +21 -0
  70. package/dist/esm/versions/v2/models/add-task-response.d.ts +34 -0
  71. package/dist/esm/versions/v2/models/add-task-response.js +14 -0
  72. package/dist/esm/versions/v2/models/base-product-all-of.d.ts +55 -10
  73. package/dist/esm/versions/v2/models/base-product-all-of.js +5 -7
  74. package/dist/esm/versions/v2/models/base-product-all-of1.d.ts +32 -0
  75. package/dist/esm/versions/v2/models/base-product-all-of1.js +21 -0
  76. package/dist/esm/versions/v2/models/base-product.d.ts +2 -2
  77. package/dist/esm/versions/v2/models/deal.d.ts +1 -1
  78. package/dist/esm/versions/v2/models/delete-project-board-response-data.d.ts +23 -0
  79. package/dist/esm/versions/v2/models/delete-project-board-response-data.js +14 -0
  80. package/dist/esm/versions/v2/models/delete-project-board-response.d.ts +29 -0
  81. package/dist/esm/versions/v2/models/delete-project-board-response.js +14 -0
  82. package/dist/esm/versions/v2/models/delete-project-field200-response-data.d.ts +53 -0
  83. package/dist/esm/versions/v2/models/delete-project-field200-response-data.js +14 -0
  84. package/dist/esm/versions/v2/models/delete-project-field200-response.d.ts +29 -0
  85. package/dist/esm/versions/v2/models/delete-project-field200-response.js +14 -0
  86. package/dist/esm/versions/v2/models/delete-project-phase-response-data.d.ts +23 -0
  87. package/dist/esm/versions/v2/models/delete-project-phase-response-data.js +14 -0
  88. package/dist/esm/versions/v2/models/delete-project-phase-response.d.ts +29 -0
  89. package/dist/esm/versions/v2/models/delete-project-phase-response.js +14 -0
  90. package/dist/esm/versions/v2/models/delete-project-response-data.d.ts +23 -0
  91. package/dist/esm/versions/v2/models/delete-project-response-data.js +14 -0
  92. package/dist/esm/versions/v2/models/delete-project-response.d.ts +29 -0
  93. package/dist/esm/versions/v2/models/delete-project-response.js +14 -0
  94. package/dist/esm/versions/v2/models/delete-task-response-data.d.ts +23 -0
  95. package/dist/esm/versions/v2/models/delete-task-response-data.js +14 -0
  96. package/dist/esm/versions/v2/models/delete-task-response.d.ts +34 -0
  97. package/dist/esm/versions/v2/models/delete-task-response.js +14 -0
  98. package/dist/esm/versions/v2/models/get-persons-response-all-of.d.ts +3 -3
  99. package/dist/esm/versions/v2/models/get-project-boards-response-data-inner.d.ts +43 -0
  100. package/dist/esm/versions/v2/models/get-project-boards-response-data-inner.js +14 -0
  101. package/dist/esm/versions/v2/models/get-project-boards-response.d.ts +34 -0
  102. package/dist/esm/versions/v2/models/get-project-boards-response.js +14 -0
  103. package/dist/esm/versions/v2/models/get-project-changelog-response-data-inner.d.ts +52 -0
  104. package/dist/esm/versions/v2/models/get-project-changelog-response-data-inner.js +14 -0
  105. package/dist/esm/versions/v2/models/get-project-changelog-response.d.ts +35 -0
  106. package/dist/esm/versions/v2/models/get-project-changelog-response.js +14 -0
  107. package/dist/esm/versions/v2/models/get-project-fields200-response-data-inner-ui-visibility.d.ts +28 -0
  108. package/dist/esm/versions/v2/models/get-project-fields200-response-data-inner-ui-visibility.js +14 -0
  109. package/dist/esm/versions/v2/models/get-project-fields200-response-data-inner.d.ts +109 -0
  110. package/dist/esm/versions/v2/models/get-project-fields200-response-data-inner.js +48 -0
  111. package/dist/esm/versions/v2/models/get-project-fields200-response.d.ts +35 -0
  112. package/dist/esm/versions/v2/models/get-project-fields200-response.js +14 -0
  113. package/dist/esm/versions/v2/models/get-project-permitted-users-response.d.ts +28 -0
  114. package/dist/esm/versions/v2/models/get-project-permitted-users-response.js +14 -0
  115. package/dist/esm/versions/v2/models/get-project-phases-response-data-inner.d.ts +48 -0
  116. package/dist/esm/versions/v2/models/get-project-phases-response-data-inner.js +14 -0
  117. package/dist/esm/versions/v2/models/get-project-phases-response.d.ts +34 -0
  118. package/dist/esm/versions/v2/models/get-project-phases-response.js +14 -0
  119. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-deal.d.ts +28 -0
  120. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-deal.js +14 -0
  121. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-organization.d.ts +33 -0
  122. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-organization.js +14 -0
  123. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-owner.d.ts +23 -0
  124. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-owner.js +14 -0
  125. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-person.d.ts +28 -0
  126. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-person.js +14 -0
  127. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-phase.d.ts +28 -0
  128. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-phase.js +14 -0
  129. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item.d.ts +98 -0
  130. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner-item.js +14 -0
  131. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner.d.ts +29 -0
  132. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data-items-inner.js +14 -0
  133. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data.d.ts +24 -0
  134. package/dist/esm/versions/v2/models/get-project-search-response-all-of-data.js +14 -0
  135. package/dist/esm/versions/v2/models/get-project-search-response-all-of.d.ts +30 -0
  136. package/dist/esm/versions/v2/models/get-project-search-response-all-of.js +14 -0
  137. package/dist/esm/versions/v2/models/get-project-search-response.d.ts +18 -0
  138. package/dist/esm/versions/v2/models/get-project-search-response.js +14 -0
  139. package/dist/esm/versions/v2/models/get-project-template-response.d.ts +34 -0
  140. package/dist/esm/versions/v2/models/get-project-template-response.js +14 -0
  141. package/dist/esm/versions/v2/models/get-project-templates-response.d.ts +35 -0
  142. package/dist/esm/versions/v2/models/get-project-templates-response.js +14 -0
  143. package/dist/esm/versions/v2/models/get-projects-response-all-of.d.ts +30 -0
  144. package/dist/esm/versions/v2/models/get-projects-response-all-of.js +14 -0
  145. package/dist/esm/versions/v2/models/get-projects-response.d.ts +18 -0
  146. package/dist/esm/versions/v2/models/get-projects-response.js +14 -0
  147. package/dist/esm/versions/v2/models/get-task-response.d.ts +34 -0
  148. package/dist/esm/versions/v2/models/get-task-response.js +14 -0
  149. package/dist/esm/versions/v2/models/get-tasks-response-data-inner.d.ts +93 -0
  150. package/dist/esm/versions/v2/models/get-tasks-response-data-inner.js +14 -0
  151. package/dist/esm/versions/v2/models/get-tasks-response.d.ts +35 -0
  152. package/dist/esm/versions/v2/models/get-tasks-response.js +14 -0
  153. package/dist/esm/versions/v2/models/index.d.ts +63 -0
  154. package/dist/esm/versions/v2/models/index.js +63 -0
  155. package/dist/esm/versions/v2/models/organization-item.d.ts +1 -1
  156. package/dist/esm/versions/v2/models/person-im-inner.d.ts +33 -0
  157. package/dist/esm/versions/v2/models/person-im-inner.js +14 -0
  158. package/dist/esm/versions/v2/models/person-postal-address.d.ts +68 -0
  159. package/dist/esm/versions/v2/models/person-postal-address.js +14 -0
  160. package/dist/esm/versions/v2/models/person.d.ts +124 -0
  161. package/dist/esm/versions/v2/models/person.js +14 -0
  162. package/dist/esm/versions/v2/models/product-request.d.ts +1 -1
  163. package/dist/esm/versions/v2/models/project-template.d.ts +53 -0
  164. package/dist/esm/versions/v2/models/project-template.js +14 -0
  165. package/dist/esm/versions/v2/models/project.d.ts +115 -0
  166. package/dist/esm/versions/v2/models/project.js +14 -0
  167. package/dist/esm/versions/v2/models/update-deal-request.d.ts +1 -1
  168. package/dist/esm/versions/v2/models/update-organization-field-request.d.ts +0 -5
  169. package/dist/esm/versions/v2/models/update-organization-request.d.ts +1 -1
  170. package/dist/esm/versions/v2/models/update-project-board-request.d.ts +28 -0
  171. package/dist/esm/versions/v2/models/update-project-board-request.js +14 -0
  172. package/dist/esm/versions/v2/models/update-project-field-request.d.ts +41 -0
  173. package/dist/esm/versions/v2/models/update-project-field-request.js +14 -0
  174. package/dist/esm/versions/v2/models/update-project-phase-request.d.ts +33 -0
  175. package/dist/esm/versions/v2/models/update-project-phase-request.js +14 -0
  176. package/dist/esm/versions/v2/models/update-project-request.d.ts +90 -0
  177. package/dist/esm/versions/v2/models/update-project-request.js +14 -0
  178. package/dist/esm/versions/v2/models/update-task-request.d.ts +83 -0
  179. package/dist/esm/versions/v2/models/update-task-request.js +21 -0
  180. package/dist/esm/versions/v2/models/update-task-response.d.ts +34 -0
  181. package/dist/esm/versions/v2/models/update-task-response.js +14 -0
  182. package/dist/esm/versions/v2/models/upsert-person-response-data.d.ts +3 -3
  183. package/dist/esm/versions/v2/models/upsert-project-board-response.d.ts +29 -0
  184. package/dist/esm/versions/v2/models/upsert-project-board-response.js +14 -0
  185. package/dist/esm/versions/v2/models/upsert-project-phase-response.d.ts +29 -0
  186. package/dist/esm/versions/v2/models/upsert-project-phase-response.js +14 -0
  187. package/dist/esm/versions/v2/models/upsert-project-response-all-of.d.ts +24 -0
  188. package/dist/esm/versions/v2/models/upsert-project-response-all-of.js +14 -0
  189. package/dist/esm/versions/v2/models/upsert-project-response.d.ts +18 -0
  190. package/dist/esm/versions/v2/models/upsert-project-response.js +14 -0
  191. package/dist/versions/v1/api/notes-api.d.ts +18 -2
  192. package/dist/versions/v1/api/notes-api.js +15 -5
  193. package/dist/versions/v1/api/project-boards-api.d.ts +117 -0
  194. package/dist/versions/v1/api/project-boards-api.js +201 -0
  195. package/dist/versions/v1/api/project-phases-api.d.ts +134 -0
  196. package/dist/versions/v1/api/project-phases-api.js +210 -0
  197. package/dist/versions/v1/api/project-templates-api.d.ts +0 -94
  198. package/dist/versions/v1/api/project-templates-api.js +0 -136
  199. package/dist/versions/v1/api/projects-api.d.ts +0 -77
  200. package/dist/versions/v1/api/projects-api.js +0 -131
  201. package/dist/versions/v1/api.d.ts +2 -0
  202. package/dist/versions/v1/api.js +2 -0
  203. package/dist/versions/v1/models/add-note-request-all-of.d.ts +10 -5
  204. package/dist/versions/v1/models/add-note-request-all-of1.d.ts +10 -0
  205. package/dist/versions/v1/models/add-note-request-all-of1.js +5 -1
  206. package/dist/versions/v1/models/index.d.ts +1 -0
  207. package/dist/versions/v1/models/index.js +1 -0
  208. package/dist/versions/v1/models/note-request-all-of1.d.ts +5 -0
  209. package/dist/versions/v1/models/note-task.d.ts +23 -0
  210. package/dist/versions/v1/models/note-task.js +15 -0
  211. package/dist/versions/v1/models/note.d.ts +16 -0
  212. package/dist/versions/v2/api/beta-api.d.ts +1314 -0
  213. package/dist/versions/v2/api/beta-api.js +1806 -0
  214. package/dist/versions/v2/api/deal-installments-api.d.ts +294 -0
  215. package/dist/versions/v2/api/deal-installments-api.js +384 -0
  216. package/dist/versions/v2/api/deal-products-api.d.ts +482 -0
  217. package/dist/versions/v2/api/deal-products-api.js +617 -0
  218. package/dist/versions/v2/api/deals-api.d.ts +32 -696
  219. package/dist/versions/v2/api/deals-api.js +54 -891
  220. package/dist/versions/v2/api/organizations-api.d.ts +36 -4
  221. package/dist/versions/v2/api/organizations-api.js +30 -10
  222. package/dist/versions/v2/api/persons-api.d.ts +36 -4
  223. package/dist/versions/v2/api/persons-api.js +30 -10
  224. package/dist/versions/v2/api/project-boards-api.d.ts +266 -0
  225. package/dist/versions/v2/api/project-boards-api.js +410 -0
  226. package/dist/versions/v2/api/project-fields-api.d.ts +457 -0
  227. package/dist/versions/v2/api/project-fields-api.js +646 -0
  228. package/dist/versions/v2/api/project-phases-api.d.ts +283 -0
  229. package/dist/versions/v2/api/project-phases-api.js +419 -0
  230. package/dist/versions/v2/api/project-templates-api.d.ts +142 -0
  231. package/dist/versions/v2/api/project-templates-api.js +213 -0
  232. package/dist/versions/v2/api/projects-api.d.ts +644 -0
  233. package/dist/versions/v2/api/projects-api.js +839 -0
  234. package/dist/versions/v2/api/tasks-api.d.ts +333 -0
  235. package/dist/versions/v2/api/tasks-api.js +447 -0
  236. package/dist/versions/v2/api.d.ts +9 -0
  237. package/dist/versions/v2/api.js +9 -0
  238. package/dist/versions/v2/models/add-deal-request.d.ts +1 -1
  239. package/dist/versions/v2/models/add-organization-request.d.ts +1 -1
  240. package/dist/versions/v2/models/add-person-request.d.ts +1 -1
  241. package/dist/versions/v2/models/add-product-request.d.ts +2 -2
  242. package/dist/versions/v2/models/add-project-board-request.d.ts +28 -0
  243. package/dist/versions/v2/models/add-project-board-request.js +15 -0
  244. package/dist/versions/v2/models/add-project-field-request-important-fields.d.ts +29 -0
  245. package/dist/versions/v2/models/add-project-field-request-important-fields.js +15 -0
  246. package/dist/versions/v2/models/add-project-field-request-required-fields.d.ts +24 -0
  247. package/dist/versions/v2/models/add-project-field-request-required-fields.js +15 -0
  248. package/dist/versions/v2/models/add-project-field-request-ui-visibility.d.ts +29 -0
  249. package/dist/versions/v2/models/add-project-field-request-ui-visibility.js +15 -0
  250. package/dist/versions/v2/models/add-project-field-request.d.ts +71 -0
  251. package/dist/versions/v2/models/add-project-field-request.js +34 -0
  252. package/dist/versions/v2/models/add-project-field200-response.d.ts +29 -0
  253. package/dist/versions/v2/models/add-project-field200-response.js +15 -0
  254. package/dist/versions/v2/models/add-project-phase-request.d.ts +33 -0
  255. package/dist/versions/v2/models/add-project-phase-request.js +15 -0
  256. package/dist/versions/v2/models/add-project-request.d.ts +90 -0
  257. package/dist/versions/v2/models/add-project-request.js +15 -0
  258. package/dist/versions/v2/models/add-task-request.d.ts +83 -0
  259. package/dist/versions/v2/models/add-task-request.js +24 -0
  260. package/dist/versions/v2/models/add-task-response.d.ts +34 -0
  261. package/dist/versions/v2/models/add-task-response.js +15 -0
  262. package/dist/versions/v2/models/base-product-all-of.d.ts +55 -10
  263. package/dist/versions/v2/models/base-product-all-of.js +6 -8
  264. package/dist/versions/v2/models/base-product-all-of1.d.ts +32 -0
  265. package/dist/versions/v2/models/base-product-all-of1.js +24 -0
  266. package/dist/versions/v2/models/base-product.d.ts +2 -2
  267. package/dist/versions/v2/models/deal.d.ts +1 -1
  268. package/dist/versions/v2/models/delete-project-board-response-data.d.ts +23 -0
  269. package/dist/versions/v2/models/delete-project-board-response-data.js +15 -0
  270. package/dist/versions/v2/models/delete-project-board-response.d.ts +29 -0
  271. package/dist/versions/v2/models/delete-project-board-response.js +15 -0
  272. package/dist/versions/v2/models/delete-project-field200-response-data.d.ts +53 -0
  273. package/dist/versions/v2/models/delete-project-field200-response-data.js +15 -0
  274. package/dist/versions/v2/models/delete-project-field200-response.d.ts +29 -0
  275. package/dist/versions/v2/models/delete-project-field200-response.js +15 -0
  276. package/dist/versions/v2/models/delete-project-phase-response-data.d.ts +23 -0
  277. package/dist/versions/v2/models/delete-project-phase-response-data.js +15 -0
  278. package/dist/versions/v2/models/delete-project-phase-response.d.ts +29 -0
  279. package/dist/versions/v2/models/delete-project-phase-response.js +15 -0
  280. package/dist/versions/v2/models/delete-project-response-data.d.ts +23 -0
  281. package/dist/versions/v2/models/delete-project-response-data.js +15 -0
  282. package/dist/versions/v2/models/delete-project-response.d.ts +29 -0
  283. package/dist/versions/v2/models/delete-project-response.js +15 -0
  284. package/dist/versions/v2/models/delete-task-response-data.d.ts +23 -0
  285. package/dist/versions/v2/models/delete-task-response-data.js +15 -0
  286. package/dist/versions/v2/models/delete-task-response.d.ts +34 -0
  287. package/dist/versions/v2/models/delete-task-response.js +15 -0
  288. package/dist/versions/v2/models/get-persons-response-all-of.d.ts +3 -3
  289. package/dist/versions/v2/models/get-project-boards-response-data-inner.d.ts +43 -0
  290. package/dist/versions/v2/models/get-project-boards-response-data-inner.js +15 -0
  291. package/dist/versions/v2/models/get-project-boards-response.d.ts +34 -0
  292. package/dist/versions/v2/models/get-project-boards-response.js +15 -0
  293. package/dist/versions/v2/models/get-project-changelog-response-data-inner.d.ts +52 -0
  294. package/dist/versions/v2/models/get-project-changelog-response-data-inner.js +15 -0
  295. package/dist/versions/v2/models/get-project-changelog-response.d.ts +35 -0
  296. package/dist/versions/v2/models/get-project-changelog-response.js +15 -0
  297. package/dist/versions/v2/models/get-project-fields200-response-data-inner-ui-visibility.d.ts +28 -0
  298. package/dist/versions/v2/models/get-project-fields200-response-data-inner-ui-visibility.js +15 -0
  299. package/dist/versions/v2/models/get-project-fields200-response-data-inner.d.ts +109 -0
  300. package/dist/versions/v2/models/get-project-fields200-response-data-inner.js +51 -0
  301. package/dist/versions/v2/models/get-project-fields200-response.d.ts +35 -0
  302. package/dist/versions/v2/models/get-project-fields200-response.js +15 -0
  303. package/dist/versions/v2/models/get-project-permitted-users-response.d.ts +28 -0
  304. package/dist/versions/v2/models/get-project-permitted-users-response.js +15 -0
  305. package/dist/versions/v2/models/get-project-phases-response-data-inner.d.ts +48 -0
  306. package/dist/versions/v2/models/get-project-phases-response-data-inner.js +15 -0
  307. package/dist/versions/v2/models/get-project-phases-response.d.ts +34 -0
  308. package/dist/versions/v2/models/get-project-phases-response.js +15 -0
  309. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-deal.d.ts +28 -0
  310. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-deal.js +15 -0
  311. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-organization.d.ts +33 -0
  312. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-organization.js +15 -0
  313. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-owner.d.ts +23 -0
  314. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-owner.js +15 -0
  315. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-person.d.ts +28 -0
  316. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-person.js +15 -0
  317. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-phase.d.ts +28 -0
  318. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item-phase.js +15 -0
  319. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item.d.ts +98 -0
  320. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner-item.js +15 -0
  321. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner.d.ts +29 -0
  322. package/dist/versions/v2/models/get-project-search-response-all-of-data-items-inner.js +15 -0
  323. package/dist/versions/v2/models/get-project-search-response-all-of-data.d.ts +24 -0
  324. package/dist/versions/v2/models/get-project-search-response-all-of-data.js +15 -0
  325. package/dist/versions/v2/models/get-project-search-response-all-of.d.ts +30 -0
  326. package/dist/versions/v2/models/get-project-search-response-all-of.js +15 -0
  327. package/dist/versions/v2/models/get-project-search-response.d.ts +18 -0
  328. package/dist/versions/v2/models/get-project-search-response.js +15 -0
  329. package/dist/versions/v2/models/get-project-template-response.d.ts +34 -0
  330. package/dist/versions/v2/models/get-project-template-response.js +15 -0
  331. package/dist/versions/v2/models/get-project-templates-response.d.ts +35 -0
  332. package/dist/versions/v2/models/get-project-templates-response.js +15 -0
  333. package/dist/versions/v2/models/get-projects-response-all-of.d.ts +30 -0
  334. package/dist/versions/v2/models/get-projects-response-all-of.js +15 -0
  335. package/dist/versions/v2/models/get-projects-response.d.ts +18 -0
  336. package/dist/versions/v2/models/get-projects-response.js +15 -0
  337. package/dist/versions/v2/models/get-task-response.d.ts +34 -0
  338. package/dist/versions/v2/models/get-task-response.js +15 -0
  339. package/dist/versions/v2/models/get-tasks-response-data-inner.d.ts +93 -0
  340. package/dist/versions/v2/models/get-tasks-response-data-inner.js +15 -0
  341. package/dist/versions/v2/models/get-tasks-response.d.ts +35 -0
  342. package/dist/versions/v2/models/get-tasks-response.js +15 -0
  343. package/dist/versions/v2/models/index.d.ts +63 -0
  344. package/dist/versions/v2/models/index.js +63 -0
  345. package/dist/versions/v2/models/organization-item.d.ts +1 -1
  346. package/dist/versions/v2/models/person-im-inner.d.ts +33 -0
  347. package/dist/versions/v2/models/person-im-inner.js +15 -0
  348. package/dist/versions/v2/models/person-postal-address.d.ts +68 -0
  349. package/dist/versions/v2/models/person-postal-address.js +15 -0
  350. package/dist/versions/v2/models/person.d.ts +124 -0
  351. package/dist/versions/v2/models/person.js +15 -0
  352. package/dist/versions/v2/models/product-request.d.ts +1 -1
  353. package/dist/versions/v2/models/project-template.d.ts +53 -0
  354. package/dist/versions/v2/models/project-template.js +15 -0
  355. package/dist/versions/v2/models/project.d.ts +115 -0
  356. package/dist/versions/v2/models/project.js +15 -0
  357. package/dist/versions/v2/models/update-deal-request.d.ts +1 -1
  358. package/dist/versions/v2/models/update-organization-field-request.d.ts +0 -5
  359. package/dist/versions/v2/models/update-organization-request.d.ts +1 -1
  360. package/dist/versions/v2/models/update-project-board-request.d.ts +28 -0
  361. package/dist/versions/v2/models/update-project-board-request.js +15 -0
  362. package/dist/versions/v2/models/update-project-field-request.d.ts +41 -0
  363. package/dist/versions/v2/models/update-project-field-request.js +15 -0
  364. package/dist/versions/v2/models/update-project-phase-request.d.ts +33 -0
  365. package/dist/versions/v2/models/update-project-phase-request.js +15 -0
  366. package/dist/versions/v2/models/update-project-request.d.ts +90 -0
  367. package/dist/versions/v2/models/update-project-request.js +15 -0
  368. package/dist/versions/v2/models/update-task-request.d.ts +83 -0
  369. package/dist/versions/v2/models/update-task-request.js +24 -0
  370. package/dist/versions/v2/models/update-task-response.d.ts +34 -0
  371. package/dist/versions/v2/models/update-task-response.js +15 -0
  372. package/dist/versions/v2/models/upsert-person-response-data.d.ts +3 -3
  373. package/dist/versions/v2/models/upsert-project-board-response.d.ts +29 -0
  374. package/dist/versions/v2/models/upsert-project-board-response.js +15 -0
  375. package/dist/versions/v2/models/upsert-project-phase-response.d.ts +29 -0
  376. package/dist/versions/v2/models/upsert-project-phase-response.js +15 -0
  377. package/dist/versions/v2/models/upsert-project-response-all-of.d.ts +24 -0
  378. package/dist/versions/v2/models/upsert-project-response-all-of.js +15 -0
  379. package/dist/versions/v2/models/upsert-project-response.d.ts +18 -0
  380. package/dist/versions/v2/models/upsert-project-response.js +15 -0
  381. package/package.json +3 -2
@@ -108,80 +108,6 @@ const DealsApiAxiosParamCreator = function (configuration) {
108
108
  options: localVarRequestOptions,
109
109
  };
110
110
  }),
111
- /**
112
- * Adds a product to a deal, creating a new item called a deal-product.
113
- * @summary Add a product to a deal
114
- * @param {number} id The ID of the deal
115
- * @param {AddDealProductRequest} [AddDealProductRequest]
116
-
117
- * @throws {RequiredError}
118
- */
119
- addDealProduct: (id, AddDealProductRequest) => __awaiter(this, void 0, void 0, function* () {
120
- // verify required parameter 'id' is not null or undefined
121
- (0, common_1.assertParamExists)('addDealProduct', 'id', id);
122
- const localVarPath = `/deals/{id}/products`
123
- .replace(`{${"id"}}`, encodeURIComponent(String(id)));
124
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
125
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
126
- let baseOptions;
127
- if (configuration) {
128
- baseOptions = configuration.baseOptions;
129
- }
130
- const localVarRequestOptions = Object.assign({ method: 'POST' }, baseOptions);
131
- const localVarHeaderParameter = {};
132
- const localVarQueryParameter = {};
133
- // authentication api_key required
134
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
135
- // authentication oauth2 required
136
- // oauth required
137
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["products:full", "deals:full"], configuration);
138
- localVarHeaderParameter['Content-Type'] = 'application/json';
139
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
140
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
141
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
142
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(AddDealProductRequest, localVarRequestOptions, configuration);
143
- return {
144
- url: (0, common_1.toPathString)(localVarUrlObj),
145
- options: localVarRequestOptions,
146
- };
147
- }),
148
- /**
149
- * Adds multiple products to a deal in a single request. Maximum of 100 products allowed per request.
150
- * @summary Add multiple products to a deal
151
- * @param {number} id The ID of the deal
152
- * @param {CreateManyDealProductRequest} [CreateManyDealProductRequest]
153
-
154
- * @throws {RequiredError}
155
- */
156
- addManyDealProducts: (id, CreateManyDealProductRequest) => __awaiter(this, void 0, void 0, function* () {
157
- // verify required parameter 'id' is not null or undefined
158
- (0, common_1.assertParamExists)('addManyDealProducts', 'id', id);
159
- const localVarPath = `/deals/{id}/products/bulk`
160
- .replace(`{${"id"}}`, encodeURIComponent(String(id)));
161
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
162
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
163
- let baseOptions;
164
- if (configuration) {
165
- baseOptions = configuration.baseOptions;
166
- }
167
- const localVarRequestOptions = Object.assign({ method: 'POST' }, baseOptions);
168
- const localVarHeaderParameter = {};
169
- const localVarQueryParameter = {};
170
- // authentication api_key required
171
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
172
- // authentication oauth2 required
173
- // oauth required
174
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["products:full", "deals:full"], configuration);
175
- localVarHeaderParameter['Content-Type'] = 'application/json';
176
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
177
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
178
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
179
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(CreateManyDealProductRequest, localVarRequestOptions, configuration);
180
- return {
181
- url: (0, common_1.toPathString)(localVarUrlObj),
182
- options: localVarRequestOptions,
183
- };
184
- }),
185
111
  /**
186
112
  * Initiates a conversion of a deal to a lead. The return value is an ID of a job that was assigned to perform the conversion. Related entities (notes, files, emails, activities, ...) are transferred during the process to the target entity. There are exceptions for entities like invoices or history that are not transferred and remain linked to the original deal. If the conversion is successful, the deal is marked as deleted. To retrieve the created entity ID and the result of the conversion, call the <a href=\"https://developers.pipedrive.com/docs/api/v1/Deals#getDealConversionStatus\">/api/v2/deals/{deal_id}/convert/status/{conversion_id}</a> endpoint.
187
113
  * @summary Convert a deal to a lead
@@ -326,120 +252,6 @@ const DealsApiAxiosParamCreator = function (configuration) {
326
252
  options: localVarRequestOptions,
327
253
  };
328
254
  }),
329
- /**
330
- * Deletes a product attachment from a deal, using the `product_attachment_id`.
331
- * @summary Delete an attached product from a deal
332
- * @param {number} id The ID of the deal
333
- * @param {number} product_attachment_id The product attachment ID
334
-
335
- * @throws {RequiredError}
336
- */
337
- deleteDealProduct: (id, product_attachment_id) => __awaiter(this, void 0, void 0, function* () {
338
- // verify required parameter 'id' is not null or undefined
339
- (0, common_1.assertParamExists)('deleteDealProduct', 'id', id);
340
- // verify required parameter 'product_attachment_id' is not null or undefined
341
- (0, common_1.assertParamExists)('deleteDealProduct', 'product_attachment_id', product_attachment_id);
342
- const localVarPath = `/deals/{id}/products/{product_attachment_id}`
343
- .replace(`{${"id"}}`, encodeURIComponent(String(id)))
344
- .replace(`{${"product_attachment_id"}}`, encodeURIComponent(String(product_attachment_id)));
345
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
346
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
347
- let baseOptions;
348
- if (configuration) {
349
- baseOptions = configuration.baseOptions;
350
- }
351
- const localVarRequestOptions = Object.assign({ method: 'DELETE' }, baseOptions);
352
- const localVarHeaderParameter = {};
353
- const localVarQueryParameter = {};
354
- // authentication api_key required
355
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
356
- // authentication oauth2 required
357
- // oauth required
358
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:full", "products:full"], configuration);
359
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
360
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
361
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
362
- return {
363
- url: (0, common_1.toPathString)(localVarUrlObj),
364
- options: localVarRequestOptions,
365
- };
366
- }),
367
- /**
368
- * Removes an installment from a deal. Only available in Growth and above plans.
369
- * @summary Delete an installment from a deal
370
- * @param {number} id The ID of the deal
371
- * @param {number} installment_id The ID of the installment
372
-
373
- * @throws {RequiredError}
374
- */
375
- deleteInstallment: (id, installment_id) => __awaiter(this, void 0, void 0, function* () {
376
- // verify required parameter 'id' is not null or undefined
377
- (0, common_1.assertParamExists)('deleteInstallment', 'id', id);
378
- // verify required parameter 'installment_id' is not null or undefined
379
- (0, common_1.assertParamExists)('deleteInstallment', 'installment_id', installment_id);
380
- const localVarPath = `/deals/{id}/installments/{installment_id}`
381
- .replace(`{${"id"}}`, encodeURIComponent(String(id)))
382
- .replace(`{${"installment_id"}}`, encodeURIComponent(String(installment_id)));
383
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
384
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
385
- let baseOptions;
386
- if (configuration) {
387
- baseOptions = configuration.baseOptions;
388
- }
389
- const localVarRequestOptions = Object.assign({ method: 'DELETE' }, baseOptions);
390
- const localVarHeaderParameter = {};
391
- const localVarQueryParameter = {};
392
- // authentication api_key required
393
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
394
- // authentication oauth2 required
395
- // oauth required
396
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:read", "deals:full"], configuration);
397
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
398
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
399
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
400
- return {
401
- url: (0, common_1.toPathString)(localVarUrlObj),
402
- options: localVarRequestOptions,
403
- };
404
- }),
405
- /**
406
- * Deletes multiple products from a deal. If no product IDs are specified, up to 100 products will be removed from the deal. A maximum of 100 product IDs can be provided per request.
407
- * @summary Delete many products from a deal
408
- * @param {number} id The ID of the deal
409
- * @param {string} [ids] Comma-separated list of deal product IDs to delete. If not provided, all deal products will be deleted up to 100 items. Maximum 100 IDs allowed.
410
-
411
- * @throws {RequiredError}
412
- */
413
- deleteManyDealProducts: (id, ids) => __awaiter(this, void 0, void 0, function* () {
414
- // verify required parameter 'id' is not null or undefined
415
- (0, common_1.assertParamExists)('deleteManyDealProducts', 'id', id);
416
- const localVarPath = `/deals/{id}/products`
417
- .replace(`{${"id"}}`, encodeURIComponent(String(id)));
418
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
419
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
420
- let baseOptions;
421
- if (configuration) {
422
- baseOptions = configuration.baseOptions;
423
- }
424
- const localVarRequestOptions = Object.assign({ method: 'DELETE' }, baseOptions);
425
- const localVarHeaderParameter = {};
426
- const localVarQueryParameter = {};
427
- // authentication api_key required
428
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
429
- // authentication oauth2 required
430
- // oauth required
431
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["products:full", "deals:full"], configuration);
432
- if (ids !== undefined) {
433
- localVarQueryParameter['ids'] = ids;
434
- }
435
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
436
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
437
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
438
- return {
439
- url: (0, common_1.toPathString)(localVarUrlObj),
440
- options: localVarRequestOptions,
441
- };
442
- }),
443
255
  /**
444
256
  * Lists discounts attached to a deal.
445
257
  * @summary List discounts added to a deal
@@ -574,10 +386,12 @@ const DealsApiAxiosParamCreator = function (configuration) {
574
386
  * @param {number} id The ID of the deal
575
387
  * @param {'next_activity_id' | 'last_activity_id' | 'first_won_time' | 'products_count' | 'files_count' | 'notes_count' | 'followers_count' | 'email_messages_count' | 'activities_count' | 'done_activities_count' | 'undone_activities_count' | 'participants_count' | 'last_incoming_mail_time' | 'last_outgoing_mail_time' | 'smart_bcc_email' | 'source_lead_id'} [include_fields] Optional comma separated string array of additional fields to include
576
388
  * @param {string} [custom_fields] Optional comma separated string array of custom fields keys to include. If you are only interested in a particular set of custom fields, please use this parameter for faster results and smaller response.&lt;br/&gt;A maximum of 15 keys is allowed.
389
+ * @param {boolean} [include_option_labels] When provided with a \&#39;true\&#39; value, single option and multiple option custom fields values contain objects in the form of \&#39;{ id: number, label: string }\&#39; instead of plain id
390
+ * @param {boolean} [include_labels] When provided with \&#39;true\&#39; value, response will include an array of label objects in the form of \&#39;{ id: number, label: string }\&#39;
577
391
 
578
392
  * @throws {RequiredError}
579
393
  */
580
- getDeal: (id, include_fields, custom_fields) => __awaiter(this, void 0, void 0, function* () {
394
+ getDeal: (id, include_fields, custom_fields, include_option_labels, include_labels) => __awaiter(this, void 0, void 0, function* () {
581
395
  // verify required parameter 'id' is not null or undefined
582
396
  (0, common_1.assertParamExists)('getDeal', 'id', id);
583
397
  const localVarPath = `/deals/{id}`
@@ -602,6 +416,12 @@ const DealsApiAxiosParamCreator = function (configuration) {
602
416
  if (custom_fields !== undefined) {
603
417
  localVarQueryParameter['custom_fields'] = custom_fields;
604
418
  }
419
+ if (include_option_labels !== undefined) {
420
+ localVarQueryParameter['include_option_labels'] = include_option_labels;
421
+ }
422
+ if (include_labels !== undefined) {
423
+ localVarQueryParameter['include_labels'] = include_labels;
424
+ }
605
425
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
606
426
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
607
427
  localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
@@ -732,56 +552,6 @@ const DealsApiAxiosParamCreator = function (configuration) {
732
552
  options: localVarRequestOptions,
733
553
  };
734
554
  }),
735
- /**
736
- * Lists products attached to a deal.
737
- * @summary List products attached to a deal
738
- * @param {number} id The ID of the deal
739
- * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
740
- * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
741
- * @param {'id' | 'add_time' | 'update_time' | 'order_nr'} [sort_by] The field to sort by. Supported fields: &#x60;id&#x60;, &#x60;add_time&#x60;, &#x60;update_time&#x60;, &#x60;order_nr&#x60;.
742
- * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
743
-
744
- * @throws {RequiredError}
745
- */
746
- getDealProducts: (id, cursor, limit, sort_by, sort_direction) => __awaiter(this, void 0, void 0, function* () {
747
- // verify required parameter 'id' is not null or undefined
748
- (0, common_1.assertParamExists)('getDealProducts', 'id', id);
749
- const localVarPath = `/deals/{id}/products`
750
- .replace(`{${"id"}}`, encodeURIComponent(String(id)));
751
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
752
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
753
- let baseOptions;
754
- if (configuration) {
755
- baseOptions = configuration.baseOptions;
756
- }
757
- const localVarRequestOptions = Object.assign({ method: 'GET' }, baseOptions);
758
- const localVarHeaderParameter = {};
759
- const localVarQueryParameter = {};
760
- // authentication api_key required
761
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
762
- // authentication oauth2 required
763
- // oauth required
764
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["products:read", "products:full", "deals:read", "deals:full"], configuration);
765
- if (cursor !== undefined) {
766
- localVarQueryParameter['cursor'] = cursor;
767
- }
768
- if (limit !== undefined) {
769
- localVarQueryParameter['limit'] = limit;
770
- }
771
- if (sort_by !== undefined) {
772
- localVarQueryParameter['sort_by'] = sort_by;
773
- }
774
- if (sort_direction !== undefined) {
775
- localVarQueryParameter['sort_direction'] = sort_direction;
776
- }
777
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
778
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
779
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
780
- return {
781
- url: (0, common_1.toPathString)(localVarUrlObj),
782
- options: localVarRequestOptions,
783
- };
784
- }),
785
555
  /**
786
556
  * Returns data about all not archived deals.
787
557
  * @summary Get all deals
@@ -799,12 +569,14 @@ const DealsApiAxiosParamCreator = function (configuration) {
799
569
  * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
800
570
  * @param {'next_activity_id' | 'last_activity_id' | 'first_won_time' | 'products_count' | 'files_count' | 'notes_count' | 'followers_count' | 'email_messages_count' | 'activities_count' | 'done_activities_count' | 'undone_activities_count' | 'participants_count' | 'last_incoming_mail_time' | 'last_outgoing_mail_time' | 'smart_bcc_email' | 'source_lead_id'} [include_fields] Optional comma separated string array of additional fields to include
801
571
  * @param {string} [custom_fields] Optional comma separated string array of custom fields keys to include. If you are only interested in a particular set of custom fields, please use this parameter for faster results and smaller response.&lt;br/&gt;A maximum of 15 keys is allowed.
572
+ * @param {boolean} [include_option_labels] When provided with a \&#39;true\&#39; value, single option and multiple option custom fields values contain objects in the form of \&#39;{ id: number, label: string }\&#39; instead of plain id
573
+ * @param {boolean} [include_labels] When provided with \&#39;true\&#39; value, response will include an array of label objects in the form of \&#39;{ id: number, label: string }\&#39;
802
574
  * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
803
575
  * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
804
576
 
805
577
  * @throws {RequiredError}
806
578
  */
807
- getDeals: (filter_id, ids, owner_id, person_id, org_id, pipeline_id, stage_id, status, updated_since, updated_until, sort_by, sort_direction, include_fields, custom_fields, limit, cursor) => __awaiter(this, void 0, void 0, function* () {
579
+ getDeals: (filter_id, ids, owner_id, person_id, org_id, pipeline_id, stage_id, status, updated_since, updated_until, sort_by, sort_direction, include_fields, custom_fields, include_option_labels, include_labels, limit, cursor) => __awaiter(this, void 0, void 0, function* () {
808
580
  const localVarPath = `/deals`;
809
581
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
810
582
  const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -862,116 +634,18 @@ const DealsApiAxiosParamCreator = function (configuration) {
862
634
  if (custom_fields !== undefined) {
863
635
  localVarQueryParameter['custom_fields'] = custom_fields;
864
636
  }
865
- if (limit !== undefined) {
866
- localVarQueryParameter['limit'] = limit;
867
- }
868
- if (cursor !== undefined) {
869
- localVarQueryParameter['cursor'] = cursor;
870
- }
871
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
872
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
873
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
874
- return {
875
- url: (0, common_1.toPathString)(localVarUrlObj),
876
- options: localVarRequestOptions,
877
- };
878
- }),
879
- /**
880
- * Returns data about products attached to deals
881
- * @summary Get deal products of several deals
882
- * @param {Array<number>} deal_ids An array of integers with the IDs of the deals for which the attached products will be returned. A maximum of 100 deal IDs can be provided.
883
- * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
884
- * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
885
- * @param {'id' | 'deal_id' | 'add_time' | 'update_time' | 'order_nr'} [sort_by] The field to sort by. Supported fields: &#x60;id&#x60;, &#x60;deal_id&#x60;, &#x60;add_time&#x60;, &#x60;update_time&#x60;, &#x60;order_nr&#x60;.
886
- * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
887
-
888
- * @throws {RequiredError}
889
- */
890
- getDealsProducts: (deal_ids, cursor, limit, sort_by, sort_direction) => __awaiter(this, void 0, void 0, function* () {
891
- // verify required parameter 'deal_ids' is not null or undefined
892
- (0, common_1.assertParamExists)('getDealsProducts', 'deal_ids', deal_ids);
893
- const localVarPath = `/deals/products`;
894
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
895
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
896
- let baseOptions;
897
- if (configuration) {
898
- baseOptions = configuration.baseOptions;
899
- }
900
- const localVarRequestOptions = Object.assign({ method: 'GET' }, baseOptions);
901
- const localVarHeaderParameter = {};
902
- const localVarQueryParameter = {};
903
- // authentication api_key required
904
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
905
- // authentication oauth2 required
906
- // oauth required
907
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["products:read", "products:full", "deals:read", "deals:full"], configuration);
908
- if (deal_ids) {
909
- localVarQueryParameter['deal_ids'] = deal_ids;
637
+ if (include_option_labels !== undefined) {
638
+ localVarQueryParameter['include_option_labels'] = include_option_labels;
910
639
  }
911
- if (cursor !== undefined) {
912
- localVarQueryParameter['cursor'] = cursor;
640
+ if (include_labels !== undefined) {
641
+ localVarQueryParameter['include_labels'] = include_labels;
913
642
  }
914
643
  if (limit !== undefined) {
915
644
  localVarQueryParameter['limit'] = limit;
916
645
  }
917
- if (sort_by !== undefined) {
918
- localVarQueryParameter['sort_by'] = sort_by;
919
- }
920
- if (sort_direction !== undefined) {
921
- localVarQueryParameter['sort_direction'] = sort_direction;
922
- }
923
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
924
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
925
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
926
- return {
927
- url: (0, common_1.toPathString)(localVarUrlObj),
928
- options: localVarRequestOptions,
929
- };
930
- }),
931
- /**
932
- * Lists installments attached to a list of deals. Only available in Growth and above plans.
933
- * @summary List installments added to a list of deals
934
- * @param {Array<number>} deal_ids An array of integers with the IDs of the deals for which the attached installments will be returned. A maximum of 100 deal IDs can be provided.
935
- * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
936
- * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
937
- * @param {'id' | 'billing_date' | 'deal_id'} [sort_by] The field to sort by. Supported fields: &#x60;id&#x60;, &#x60;billing_date&#x60;, &#x60;deal_id&#x60;.
938
- * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
939
-
940
- * @throws {RequiredError}
941
- */
942
- getInstallments: (deal_ids, cursor, limit, sort_by, sort_direction) => __awaiter(this, void 0, void 0, function* () {
943
- // verify required parameter 'deal_ids' is not null or undefined
944
- (0, common_1.assertParamExists)('getInstallments', 'deal_ids', deal_ids);
945
- const localVarPath = `/deals/installments`;
946
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
947
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
948
- let baseOptions;
949
- if (configuration) {
950
- baseOptions = configuration.baseOptions;
951
- }
952
- const localVarRequestOptions = Object.assign({ method: 'GET' }, baseOptions);
953
- const localVarHeaderParameter = {};
954
- const localVarQueryParameter = {};
955
- // authentication api_key required
956
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
957
- // authentication oauth2 required
958
- // oauth required
959
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:read", "deals:full"], configuration);
960
- if (deal_ids) {
961
- localVarQueryParameter['deal_ids'] = deal_ids;
962
- }
963
646
  if (cursor !== undefined) {
964
647
  localVarQueryParameter['cursor'] = cursor;
965
648
  }
966
- if (limit !== undefined) {
967
- localVarQueryParameter['limit'] = limit;
968
- }
969
- if (sort_by !== undefined) {
970
- localVarQueryParameter['sort_by'] = sort_by;
971
- }
972
- if (sort_direction !== undefined) {
973
- localVarQueryParameter['sort_direction'] = sort_direction;
974
- }
975
649
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
976
650
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
977
651
  localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
@@ -1017,43 +691,6 @@ const DealsApiAxiosParamCreator = function (configuration) {
1017
691
  options: localVarRequestOptions,
1018
692
  };
1019
693
  }),
1020
- /**
1021
- * Adds an installment to a deal. An installment can only be added if the deal includes at least one one-time product. If the deal contains at least one recurring product, adding installments is not allowed. Only available in Growth and above plans.
1022
- * @summary Add an installment to a deal
1023
- * @param {number} id The ID of the deal
1024
- * @param {AddInstallmentRequestBody} [AddInstallmentRequestBody]
1025
-
1026
- * @throws {RequiredError}
1027
- */
1028
- postInstallment: (id, AddInstallmentRequestBody) => __awaiter(this, void 0, void 0, function* () {
1029
- // verify required parameter 'id' is not null or undefined
1030
- (0, common_1.assertParamExists)('postInstallment', 'id', id);
1031
- const localVarPath = `/deals/{id}/installments`
1032
- .replace(`{${"id"}}`, encodeURIComponent(String(id)));
1033
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
1034
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1035
- let baseOptions;
1036
- if (configuration) {
1037
- baseOptions = configuration.baseOptions;
1038
- }
1039
- const localVarRequestOptions = Object.assign({ method: 'POST' }, baseOptions);
1040
- const localVarHeaderParameter = {};
1041
- const localVarQueryParameter = {};
1042
- // authentication api_key required
1043
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
1044
- // authentication oauth2 required
1045
- // oauth required
1046
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:read", "deals:full"], configuration);
1047
- localVarHeaderParameter['Content-Type'] = 'application/json';
1048
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1049
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1050
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
1051
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(AddInstallmentRequestBody, localVarRequestOptions, configuration);
1052
- return {
1053
- url: (0, common_1.toPathString)(localVarUrlObj),
1054
- options: localVarRequestOptions,
1055
- };
1056
- }),
1057
694
  /**
1058
695
  * Searches all deals by title, notes and/or custom fields. This endpoint is a wrapper of <a href=\"https://developers.pipedrive.com/docs/api/v1/ItemSearch#searchItem\">/v1/itemSearch</a> with a narrower OAuth scope. Found deals can be filtered by the person ID and the organization ID.
1059
696
  * @summary Search deals
@@ -1109,114 +746,36 @@ const DealsApiAxiosParamCreator = function (configuration) {
1109
746
  localVarQueryParameter['include_fields'] = include_fields;
1110
747
  }
1111
748
  if (limit !== undefined) {
1112
- localVarQueryParameter['limit'] = limit;
1113
- }
1114
- if (cursor !== undefined) {
1115
- localVarQueryParameter['cursor'] = cursor;
1116
- }
1117
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1118
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1119
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
1120
- return {
1121
- url: (0, common_1.toPathString)(localVarUrlObj),
1122
- options: localVarRequestOptions,
1123
- };
1124
- }),
1125
- /**
1126
- * Edits a discount added to a deal, changing the deal value if the deal has one-time products attached.
1127
- * @summary Update a discount added to a deal
1128
- * @param {number} id The ID of the deal
1129
- * @param {string} discount_id The ID of the discount
1130
- * @param {UpdateAdditionalDiscountRequestBody} [UpdateAdditionalDiscountRequestBody]
1131
-
1132
- * @throws {RequiredError}
1133
- */
1134
- updateAdditionalDiscount: (id, discount_id, UpdateAdditionalDiscountRequestBody) => __awaiter(this, void 0, void 0, function* () {
1135
- // verify required parameter 'id' is not null or undefined
1136
- (0, common_1.assertParamExists)('updateAdditionalDiscount', 'id', id);
1137
- // verify required parameter 'discount_id' is not null or undefined
1138
- (0, common_1.assertParamExists)('updateAdditionalDiscount', 'discount_id', discount_id);
1139
- const localVarPath = `/deals/{id}/discounts/{discount_id}`
1140
- .replace(`{${"id"}}`, encodeURIComponent(String(id)))
1141
- .replace(`{${"discount_id"}}`, encodeURIComponent(String(discount_id)));
1142
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
1143
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1144
- let baseOptions;
1145
- if (configuration) {
1146
- baseOptions = configuration.baseOptions;
1147
- }
1148
- const localVarRequestOptions = Object.assign({ method: 'PATCH' }, baseOptions);
1149
- const localVarHeaderParameter = {};
1150
- const localVarQueryParameter = {};
1151
- // authentication api_key required
1152
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
1153
- // authentication oauth2 required
1154
- // oauth required
1155
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:read", "deals:full"], configuration);
1156
- localVarHeaderParameter['Content-Type'] = 'application/json';
1157
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1158
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1159
- localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
1160
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(UpdateAdditionalDiscountRequestBody, localVarRequestOptions, configuration);
1161
- return {
1162
- url: (0, common_1.toPathString)(localVarUrlObj),
1163
- options: localVarRequestOptions,
1164
- };
1165
- }),
1166
- /**
1167
- * Updates the properties of a deal.
1168
- * @summary Update a deal
1169
- * @param {number} id The ID of the deal
1170
- * @param {UpdateDealRequest} [UpdateDealRequest]
1171
-
1172
- * @throws {RequiredError}
1173
- */
1174
- updateDeal: (id, UpdateDealRequest) => __awaiter(this, void 0, void 0, function* () {
1175
- // verify required parameter 'id' is not null or undefined
1176
- (0, common_1.assertParamExists)('updateDeal', 'id', id);
1177
- const localVarPath = `/deals/{id}`
1178
- .replace(`{${"id"}}`, encodeURIComponent(String(id)));
1179
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
1180
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1181
- let baseOptions;
1182
- if (configuration) {
1183
- baseOptions = configuration.baseOptions;
1184
- }
1185
- const localVarRequestOptions = Object.assign({ method: 'PATCH' }, baseOptions);
1186
- const localVarHeaderParameter = {};
1187
- const localVarQueryParameter = {};
1188
- // authentication api_key required
1189
- yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
1190
- // authentication oauth2 required
1191
- // oauth required
1192
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:full"], configuration);
1193
- localVarHeaderParameter['Content-Type'] = 'application/json';
749
+ localVarQueryParameter['limit'] = limit;
750
+ }
751
+ if (cursor !== undefined) {
752
+ localVarQueryParameter['cursor'] = cursor;
753
+ }
1194
754
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1195
755
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1196
756
  localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
1197
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(UpdateDealRequest, localVarRequestOptions, configuration);
1198
757
  return {
1199
758
  url: (0, common_1.toPathString)(localVarUrlObj),
1200
759
  options: localVarRequestOptions,
1201
760
  };
1202
761
  }),
1203
762
  /**
1204
- * Updates the details of the product that has been attached to a deal.
1205
- * @summary Update the product attached to a deal
763
+ * Edits a discount added to a deal, changing the deal value if the deal has one-time products attached.
764
+ * @summary Update a discount added to a deal
1206
765
  * @param {number} id The ID of the deal
1207
- * @param {number} product_attachment_id The ID of the deal-product (the ID of the product attached to the deal)
1208
- * @param {UpdateDealProductRequest} [UpdateDealProductRequest]
766
+ * @param {string} discount_id The ID of the discount
767
+ * @param {UpdateAdditionalDiscountRequestBody} [UpdateAdditionalDiscountRequestBody]
1209
768
 
1210
769
  * @throws {RequiredError}
1211
770
  */
1212
- updateDealProduct: (id, product_attachment_id, UpdateDealProductRequest) => __awaiter(this, void 0, void 0, function* () {
771
+ updateAdditionalDiscount: (id, discount_id, UpdateAdditionalDiscountRequestBody) => __awaiter(this, void 0, void 0, function* () {
1213
772
  // verify required parameter 'id' is not null or undefined
1214
- (0, common_1.assertParamExists)('updateDealProduct', 'id', id);
1215
- // verify required parameter 'product_attachment_id' is not null or undefined
1216
- (0, common_1.assertParamExists)('updateDealProduct', 'product_attachment_id', product_attachment_id);
1217
- const localVarPath = `/deals/{id}/products/{product_attachment_id}`
773
+ (0, common_1.assertParamExists)('updateAdditionalDiscount', 'id', id);
774
+ // verify required parameter 'discount_id' is not null or undefined
775
+ (0, common_1.assertParamExists)('updateAdditionalDiscount', 'discount_id', discount_id);
776
+ const localVarPath = `/deals/{id}/discounts/{discount_id}`
1218
777
  .replace(`{${"id"}}`, encodeURIComponent(String(id)))
1219
- .replace(`{${"product_attachment_id"}}`, encodeURIComponent(String(product_attachment_id)));
778
+ .replace(`{${"discount_id"}}`, encodeURIComponent(String(discount_id)));
1220
779
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
1221
780
  const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1222
781
  let baseOptions;
@@ -1230,34 +789,30 @@ const DealsApiAxiosParamCreator = function (configuration) {
1230
789
  yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
1231
790
  // authentication oauth2 required
1232
791
  // oauth required
1233
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["products:full", "deals:full"], configuration);
792
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:read", "deals:full"], configuration);
1234
793
  localVarHeaderParameter['Content-Type'] = 'application/json';
1235
794
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1236
795
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1237
796
  localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
1238
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(UpdateDealProductRequest, localVarRequestOptions, configuration);
797
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(UpdateAdditionalDiscountRequestBody, localVarRequestOptions, configuration);
1239
798
  return {
1240
799
  url: (0, common_1.toPathString)(localVarUrlObj),
1241
800
  options: localVarRequestOptions,
1242
801
  };
1243
802
  }),
1244
803
  /**
1245
- * Edits an installment added to a deal. Only available in Growth and above plans.
1246
- * @summary Update an installment added to a deal
804
+ * Updates the properties of a deal.
805
+ * @summary Update a deal
1247
806
  * @param {number} id The ID of the deal
1248
- * @param {number} installment_id The ID of the installment
1249
- * @param {UpdateInstallmentRequestBody} [UpdateInstallmentRequestBody]
807
+ * @param {UpdateDealRequest} [UpdateDealRequest]
1250
808
 
1251
809
  * @throws {RequiredError}
1252
810
  */
1253
- updateInstallment: (id, installment_id, UpdateInstallmentRequestBody) => __awaiter(this, void 0, void 0, function* () {
811
+ updateDeal: (id, UpdateDealRequest) => __awaiter(this, void 0, void 0, function* () {
1254
812
  // verify required parameter 'id' is not null or undefined
1255
- (0, common_1.assertParamExists)('updateInstallment', 'id', id);
1256
- // verify required parameter 'installment_id' is not null or undefined
1257
- (0, common_1.assertParamExists)('updateInstallment', 'installment_id', installment_id);
1258
- const localVarPath = `/deals/{id}/installments/{installment_id}`
1259
- .replace(`{${"id"}}`, encodeURIComponent(String(id)))
1260
- .replace(`{${"installment_id"}}`, encodeURIComponent(String(installment_id)));
813
+ (0, common_1.assertParamExists)('updateDeal', 'id', id);
814
+ const localVarPath = `/deals/{id}`
815
+ .replace(`{${"id"}}`, encodeURIComponent(String(id)));
1261
816
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
1262
817
  const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1263
818
  let baseOptions;
@@ -1271,12 +826,12 @@ const DealsApiAxiosParamCreator = function (configuration) {
1271
826
  yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "x-api-token", configuration);
1272
827
  // authentication oauth2 required
1273
828
  // oauth required
1274
- yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:read", "deals:full"], configuration);
829
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["deals:full"], configuration);
1275
830
  localVarHeaderParameter['Content-Type'] = 'application/json';
1276
831
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1277
832
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1278
833
  localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
1279
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(UpdateInstallmentRequestBody, localVarRequestOptions, configuration);
834
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(UpdateDealRequest, localVarRequestOptions, configuration);
1280
835
  return {
1281
836
  url: (0, common_1.toPathString)(localVarUrlObj),
1282
837
  options: localVarRequestOptions,
@@ -1319,34 +874,6 @@ const DealsApiFp = function (configuration) {
1319
874
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1320
875
  });
1321
876
  },
1322
- /**
1323
- * Adds a product to a deal, creating a new item called a deal-product.
1324
- * @summary Add a product to a deal
1325
- * @param {number} id The ID of the deal
1326
- * @param {AddDealProductRequest} [AddDealProductRequest]
1327
-
1328
- * @throws {RequiredError}
1329
- */
1330
- addDealProduct(id, AddDealProductRequest) {
1331
- return __awaiter(this, void 0, void 0, function* () {
1332
- const localVarAxiosArgs = yield localVarAxiosParamCreator.addDealProduct(id, AddDealProductRequest);
1333
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1334
- });
1335
- },
1336
- /**
1337
- * Adds multiple products to a deal in a single request. Maximum of 100 products allowed per request.
1338
- * @summary Add multiple products to a deal
1339
- * @param {number} id The ID of the deal
1340
- * @param {CreateManyDealProductRequest} [CreateManyDealProductRequest]
1341
-
1342
- * @throws {RequiredError}
1343
- */
1344
- addManyDealProducts(id, CreateManyDealProductRequest) {
1345
- return __awaiter(this, void 0, void 0, function* () {
1346
- const localVarAxiosArgs = yield localVarAxiosParamCreator.addManyDealProducts(id, CreateManyDealProductRequest);
1347
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1348
- });
1349
- },
1350
877
  /**
1351
878
  * Initiates a conversion of a deal to a lead. The return value is an ID of a job that was assigned to perform the conversion. Related entities (notes, files, emails, activities, ...) are transferred during the process to the target entity. There are exceptions for entities like invoices or history that are not transferred and remain linked to the original deal. If the conversion is successful, the deal is marked as deleted. To retrieve the created entity ID and the result of the conversion, call the <a href=\"https://developers.pipedrive.com/docs/api/v1/Deals#getDealConversionStatus\">/api/v2/deals/{deal_id}/convert/status/{conversion_id}</a> endpoint.
1352
879
  * @summary Convert a deal to a lead
@@ -1401,48 +928,6 @@ const DealsApiFp = function (configuration) {
1401
928
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1402
929
  });
1403
930
  },
1404
- /**
1405
- * Deletes a product attachment from a deal, using the `product_attachment_id`.
1406
- * @summary Delete an attached product from a deal
1407
- * @param {number} id The ID of the deal
1408
- * @param {number} product_attachment_id The product attachment ID
1409
-
1410
- * @throws {RequiredError}
1411
- */
1412
- deleteDealProduct(id, product_attachment_id) {
1413
- return __awaiter(this, void 0, void 0, function* () {
1414
- const localVarAxiosArgs = yield localVarAxiosParamCreator.deleteDealProduct(id, product_attachment_id);
1415
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1416
- });
1417
- },
1418
- /**
1419
- * Removes an installment from a deal. Only available in Growth and above plans.
1420
- * @summary Delete an installment from a deal
1421
- * @param {number} id The ID of the deal
1422
- * @param {number} installment_id The ID of the installment
1423
-
1424
- * @throws {RequiredError}
1425
- */
1426
- deleteInstallment(id, installment_id) {
1427
- return __awaiter(this, void 0, void 0, function* () {
1428
- const localVarAxiosArgs = yield localVarAxiosParamCreator.deleteInstallment(id, installment_id);
1429
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1430
- });
1431
- },
1432
- /**
1433
- * Deletes multiple products from a deal. If no product IDs are specified, up to 100 products will be removed from the deal. A maximum of 100 product IDs can be provided per request.
1434
- * @summary Delete many products from a deal
1435
- * @param {number} id The ID of the deal
1436
- * @param {string} [ids] Comma-separated list of deal product IDs to delete. If not provided, all deal products will be deleted up to 100 items. Maximum 100 IDs allowed.
1437
-
1438
- * @throws {RequiredError}
1439
- */
1440
- deleteManyDealProducts(id, ids) {
1441
- return __awaiter(this, void 0, void 0, function* () {
1442
- const localVarAxiosArgs = yield localVarAxiosParamCreator.deleteManyDealProducts(id, ids);
1443
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1444
- });
1445
- },
1446
931
  /**
1447
932
  * Lists discounts attached to a deal.
1448
933
  * @summary List discounts added to a deal
@@ -1490,12 +975,14 @@ const DealsApiFp = function (configuration) {
1490
975
  * @param {number} id The ID of the deal
1491
976
  * @param {'next_activity_id' | 'last_activity_id' | 'first_won_time' | 'products_count' | 'files_count' | 'notes_count' | 'followers_count' | 'email_messages_count' | 'activities_count' | 'done_activities_count' | 'undone_activities_count' | 'participants_count' | 'last_incoming_mail_time' | 'last_outgoing_mail_time' | 'smart_bcc_email' | 'source_lead_id'} [include_fields] Optional comma separated string array of additional fields to include
1492
977
  * @param {string} [custom_fields] Optional comma separated string array of custom fields keys to include. If you are only interested in a particular set of custom fields, please use this parameter for faster results and smaller response.&lt;br/&gt;A maximum of 15 keys is allowed.
978
+ * @param {boolean} [include_option_labels] When provided with a \&#39;true\&#39; value, single option and multiple option custom fields values contain objects in the form of \&#39;{ id: number, label: string }\&#39; instead of plain id
979
+ * @param {boolean} [include_labels] When provided with \&#39;true\&#39; value, response will include an array of label objects in the form of \&#39;{ id: number, label: string }\&#39;
1493
980
 
1494
981
  * @throws {RequiredError}
1495
982
  */
1496
- getDeal(id, include_fields, custom_fields) {
983
+ getDeal(id, include_fields, custom_fields, include_option_labels, include_labels) {
1497
984
  return __awaiter(this, void 0, void 0, function* () {
1498
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getDeal(id, include_fields, custom_fields);
985
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getDeal(id, include_fields, custom_fields, include_option_labels, include_labels);
1499
986
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1500
987
  });
1501
988
  },
@@ -1543,23 +1030,6 @@ const DealsApiFp = function (configuration) {
1543
1030
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1544
1031
  });
1545
1032
  },
1546
- /**
1547
- * Lists products attached to a deal.
1548
- * @summary List products attached to a deal
1549
- * @param {number} id The ID of the deal
1550
- * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
1551
- * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
1552
- * @param {'id' | 'add_time' | 'update_time' | 'order_nr'} [sort_by] The field to sort by. Supported fields: &#x60;id&#x60;, &#x60;add_time&#x60;, &#x60;update_time&#x60;, &#x60;order_nr&#x60;.
1553
- * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
1554
-
1555
- * @throws {RequiredError}
1556
- */
1557
- getDealProducts(id, cursor, limit, sort_by, sort_direction) {
1558
- return __awaiter(this, void 0, void 0, function* () {
1559
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getDealProducts(id, cursor, limit, sort_by, sort_direction);
1560
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1561
- });
1562
- },
1563
1033
  /**
1564
1034
  * Returns data about all not archived deals.
1565
1035
  * @summary Get all deals
@@ -1577,48 +1047,16 @@ const DealsApiFp = function (configuration) {
1577
1047
  * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
1578
1048
  * @param {'next_activity_id' | 'last_activity_id' | 'first_won_time' | 'products_count' | 'files_count' | 'notes_count' | 'followers_count' | 'email_messages_count' | 'activities_count' | 'done_activities_count' | 'undone_activities_count' | 'participants_count' | 'last_incoming_mail_time' | 'last_outgoing_mail_time' | 'smart_bcc_email' | 'source_lead_id'} [include_fields] Optional comma separated string array of additional fields to include
1579
1049
  * @param {string} [custom_fields] Optional comma separated string array of custom fields keys to include. If you are only interested in a particular set of custom fields, please use this parameter for faster results and smaller response.&lt;br/&gt;A maximum of 15 keys is allowed.
1050
+ * @param {boolean} [include_option_labels] When provided with a \&#39;true\&#39; value, single option and multiple option custom fields values contain objects in the form of \&#39;{ id: number, label: string }\&#39; instead of plain id
1051
+ * @param {boolean} [include_labels] When provided with \&#39;true\&#39; value, response will include an array of label objects in the form of \&#39;{ id: number, label: string }\&#39;
1580
1052
  * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
1581
1053
  * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
1582
1054
 
1583
1055
  * @throws {RequiredError}
1584
1056
  */
1585
- getDeals(filter_id, ids, owner_id, person_id, org_id, pipeline_id, stage_id, status, updated_since, updated_until, sort_by, sort_direction, include_fields, custom_fields, limit, cursor) {
1586
- return __awaiter(this, void 0, void 0, function* () {
1587
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getDeals(filter_id, ids, owner_id, person_id, org_id, pipeline_id, stage_id, status, updated_since, updated_until, sort_by, sort_direction, include_fields, custom_fields, limit, cursor);
1588
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1589
- });
1590
- },
1591
- /**
1592
- * Returns data about products attached to deals
1593
- * @summary Get deal products of several deals
1594
- * @param {Array<number>} deal_ids An array of integers with the IDs of the deals for which the attached products will be returned. A maximum of 100 deal IDs can be provided.
1595
- * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
1596
- * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
1597
- * @param {'id' | 'deal_id' | 'add_time' | 'update_time' | 'order_nr'} [sort_by] The field to sort by. Supported fields: &#x60;id&#x60;, &#x60;deal_id&#x60;, &#x60;add_time&#x60;, &#x60;update_time&#x60;, &#x60;order_nr&#x60;.
1598
- * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
1599
-
1600
- * @throws {RequiredError}
1601
- */
1602
- getDealsProducts(deal_ids, cursor, limit, sort_by, sort_direction) {
1603
- return __awaiter(this, void 0, void 0, function* () {
1604
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getDealsProducts(deal_ids, cursor, limit, sort_by, sort_direction);
1605
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1606
- });
1607
- },
1608
- /**
1609
- * Lists installments attached to a list of deals. Only available in Growth and above plans.
1610
- * @summary List installments added to a list of deals
1611
- * @param {Array<number>} deal_ids An array of integers with the IDs of the deals for which the attached installments will be returned. A maximum of 100 deal IDs can be provided.
1612
- * @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
1613
- * @param {number} [limit] For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed.
1614
- * @param {'id' | 'billing_date' | 'deal_id'} [sort_by] The field to sort by. Supported fields: &#x60;id&#x60;, &#x60;billing_date&#x60;, &#x60;deal_id&#x60;.
1615
- * @param {'asc' | 'desc'} [sort_direction] The sorting direction. Supported values: &#x60;asc&#x60;, &#x60;desc&#x60;.
1616
-
1617
- * @throws {RequiredError}
1618
- */
1619
- getInstallments(deal_ids, cursor, limit, sort_by, sort_direction) {
1057
+ getDeals(filter_id, ids, owner_id, person_id, org_id, pipeline_id, stage_id, status, updated_since, updated_until, sort_by, sort_direction, include_fields, custom_fields, include_option_labels, include_labels, limit, cursor) {
1620
1058
  return __awaiter(this, void 0, void 0, function* () {
1621
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getInstallments(deal_ids, cursor, limit, sort_by, sort_direction);
1059
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getDeals(filter_id, ids, owner_id, person_id, org_id, pipeline_id, stage_id, status, updated_since, updated_until, sort_by, sort_direction, include_fields, custom_fields, include_option_labels, include_labels, limit, cursor);
1622
1060
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1623
1061
  });
1624
1062
  },
@@ -1636,20 +1074,6 @@ const DealsApiFp = function (configuration) {
1636
1074
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1637
1075
  });
1638
1076
  },
1639
- /**
1640
- * Adds an installment to a deal. An installment can only be added if the deal includes at least one one-time product. If the deal contains at least one recurring product, adding installments is not allowed. Only available in Growth and above plans.
1641
- * @summary Add an installment to a deal
1642
- * @param {number} id The ID of the deal
1643
- * @param {AddInstallmentRequestBody} [AddInstallmentRequestBody]
1644
-
1645
- * @throws {RequiredError}
1646
- */
1647
- postInstallment(id, AddInstallmentRequestBody) {
1648
- return __awaiter(this, void 0, void 0, function* () {
1649
- const localVarAxiosArgs = yield localVarAxiosParamCreator.postInstallment(id, AddInstallmentRequestBody);
1650
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1651
- });
1652
- },
1653
1077
  /**
1654
1078
  * Searches all deals by title, notes and/or custom fields. This endpoint is a wrapper of <a href=\"https://developers.pipedrive.com/docs/api/v1/ItemSearch#searchItem\">/v1/itemSearch</a> with a narrower OAuth scope. Found deals can be filtered by the person ID and the organization ID.
1655
1079
  * @summary Search deals
@@ -1700,36 +1124,6 @@ const DealsApiFp = function (configuration) {
1700
1124
  return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1701
1125
  });
1702
1126
  },
1703
- /**
1704
- * Updates the details of the product that has been attached to a deal.
1705
- * @summary Update the product attached to a deal
1706
- * @param {number} id The ID of the deal
1707
- * @param {number} product_attachment_id The ID of the deal-product (the ID of the product attached to the deal)
1708
- * @param {UpdateDealProductRequest} [UpdateDealProductRequest]
1709
-
1710
- * @throws {RequiredError}
1711
- */
1712
- updateDealProduct(id, product_attachment_id, UpdateDealProductRequest) {
1713
- return __awaiter(this, void 0, void 0, function* () {
1714
- const localVarAxiosArgs = yield localVarAxiosParamCreator.updateDealProduct(id, product_attachment_id, UpdateDealProductRequest);
1715
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1716
- });
1717
- },
1718
- /**
1719
- * Edits an installment added to a deal. Only available in Growth and above plans.
1720
- * @summary Update an installment added to a deal
1721
- * @param {number} id The ID of the deal
1722
- * @param {number} installment_id The ID of the installment
1723
- * @param {UpdateInstallmentRequestBody} [UpdateInstallmentRequestBody]
1724
-
1725
- * @throws {RequiredError}
1726
- */
1727
- updateInstallment(id, installment_id, UpdateInstallmentRequestBody) {
1728
- return __awaiter(this, void 0, void 0, function* () {
1729
- const localVarAxiosArgs = yield localVarAxiosParamCreator.updateInstallment(id, installment_id, UpdateInstallmentRequestBody);
1730
- return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1731
- });
1732
- },
1733
1127
  };
1734
1128
  };
1735
1129
  exports.DealsApiFp = DealsApiFp;
@@ -1760,26 +1154,6 @@ const DealsApiFactory = function (configuration, basePath, axios) {
1760
1154
  addDealFollower(requestParameters) {
1761
1155
  return localVarFp.addDealFollower(requestParameters.id, requestParameters.AddDealFollowerRequest).then((request) => request(axios, basePath));
1762
1156
  },
1763
- /**
1764
- * Adds a product to a deal, creating a new item called a deal-product.
1765
- * @summary Add a product to a deal
1766
- * @param {DealsApiAddDealProductRequest} requestParameters Request parameters.
1767
-
1768
- * @throws {RequiredError}
1769
- */
1770
- addDealProduct(requestParameters) {
1771
- return localVarFp.addDealProduct(requestParameters.id, requestParameters.AddDealProductRequest).then((request) => request(axios, basePath));
1772
- },
1773
- /**
1774
- * Adds multiple products to a deal in a single request. Maximum of 100 products allowed per request.
1775
- * @summary Add multiple products to a deal
1776
- * @param {DealsApiAddManyDealProductsRequest} requestParameters Request parameters.
1777
-
1778
- * @throws {RequiredError}
1779
- */
1780
- addManyDealProducts(requestParameters) {
1781
- return localVarFp.addManyDealProducts(requestParameters.id, requestParameters.CreateManyDealProductRequest).then((request) => request(axios, basePath));
1782
- },
1783
1157
  /**
1784
1158
  * Initiates a conversion of a deal to a lead. The return value is an ID of a job that was assigned to perform the conversion. Related entities (notes, files, emails, activities, ...) are transferred during the process to the target entity. There are exceptions for entities like invoices or history that are not transferred and remain linked to the original deal. If the conversion is successful, the deal is marked as deleted. To retrieve the created entity ID and the result of the conversion, call the <a href=\"https://developers.pipedrive.com/docs/api/v1/Deals#getDealConversionStatus\">/api/v2/deals/{deal_id}/convert/status/{conversion_id}</a> endpoint.
1785
1159
  * @summary Convert a deal to a lead
@@ -1820,36 +1194,6 @@ const DealsApiFactory = function (configuration, basePath, axios) {
1820
1194
  deleteDealFollower(requestParameters) {
1821
1195
  return localVarFp.deleteDealFollower(requestParameters.id, requestParameters.follower_id).then((request) => request(axios, basePath));
1822
1196
  },
1823
- /**
1824
- * Deletes a product attachment from a deal, using the `product_attachment_id`.
1825
- * @summary Delete an attached product from a deal
1826
- * @param {DealsApiDeleteDealProductRequest} requestParameters Request parameters.
1827
-
1828
- * @throws {RequiredError}
1829
- */
1830
- deleteDealProduct(requestParameters) {
1831
- return localVarFp.deleteDealProduct(requestParameters.id, requestParameters.product_attachment_id).then((request) => request(axios, basePath));
1832
- },
1833
- /**
1834
- * Removes an installment from a deal. Only available in Growth and above plans.
1835
- * @summary Delete an installment from a deal
1836
- * @param {DealsApiDeleteInstallmentRequest} requestParameters Request parameters.
1837
-
1838
- * @throws {RequiredError}
1839
- */
1840
- deleteInstallment(requestParameters) {
1841
- return localVarFp.deleteInstallment(requestParameters.id, requestParameters.installment_id).then((request) => request(axios, basePath));
1842
- },
1843
- /**
1844
- * Deletes multiple products from a deal. If no product IDs are specified, up to 100 products will be removed from the deal. A maximum of 100 product IDs can be provided per request.
1845
- * @summary Delete many products from a deal
1846
- * @param {DealsApiDeleteManyDealProductsRequest} requestParameters Request parameters.
1847
-
1848
- * @throws {RequiredError}
1849
- */
1850
- deleteManyDealProducts(requestParameters) {
1851
- return localVarFp.deleteManyDealProducts(requestParameters.id, requestParameters.ids).then((request) => request(axios, basePath));
1852
- },
1853
1197
  /**
1854
1198
  * Lists discounts attached to a deal.
1855
1199
  * @summary List discounts added to a deal
@@ -1878,7 +1222,7 @@ const DealsApiFactory = function (configuration, basePath, axios) {
1878
1222
  * @throws {RequiredError}
1879
1223
  */
1880
1224
  getDeal(requestParameters) {
1881
- return localVarFp.getDeal(requestParameters.id, requestParameters.include_fields, requestParameters.custom_fields).then((request) => request(axios, basePath));
1225
+ return localVarFp.getDeal(requestParameters.id, requestParameters.include_fields, requestParameters.custom_fields, requestParameters.include_option_labels, requestParameters.include_labels).then((request) => request(axios, basePath));
1882
1226
  },
1883
1227
  /**
1884
1228
  * Returns information about the conversion. Status is always present and its value (not_started, running, completed, failed, rejected) represents the current state of the conversion. Lead ID is only present if the conversion was successfully finished. This data is only temporary and removed after a few days.
@@ -1910,16 +1254,6 @@ const DealsApiFactory = function (configuration, basePath, axios) {
1910
1254
  getDealFollowersChangelog(requestParameters) {
1911
1255
  return localVarFp.getDealFollowersChangelog(requestParameters.id, requestParameters.limit, requestParameters.cursor).then((request) => request(axios, basePath));
1912
1256
  },
1913
- /**
1914
- * Lists products attached to a deal.
1915
- * @summary List products attached to a deal
1916
- * @param {DealsApiGetDealProductsRequest} requestParameters Request parameters.
1917
-
1918
- * @throws {RequiredError}
1919
- */
1920
- getDealProducts(requestParameters) {
1921
- return localVarFp.getDealProducts(requestParameters.id, requestParameters.cursor, requestParameters.limit, requestParameters.sort_by, requestParameters.sort_direction).then((request) => request(axios, basePath));
1922
- },
1923
1257
  /**
1924
1258
  * Returns data about all not archived deals.
1925
1259
  * @summary Get all deals
@@ -1928,27 +1262,7 @@ const DealsApiFactory = function (configuration, basePath, axios) {
1928
1262
  * @throws {RequiredError}
1929
1263
  */
1930
1264
  getDeals(requestParameters = {}) {
1931
- return localVarFp.getDeals(requestParameters.filter_id, requestParameters.ids, requestParameters.owner_id, requestParameters.person_id, requestParameters.org_id, requestParameters.pipeline_id, requestParameters.stage_id, requestParameters.status, requestParameters.updated_since, requestParameters.updated_until, requestParameters.sort_by, requestParameters.sort_direction, requestParameters.include_fields, requestParameters.custom_fields, requestParameters.limit, requestParameters.cursor).then((request) => request(axios, basePath));
1932
- },
1933
- /**
1934
- * Returns data about products attached to deals
1935
- * @summary Get deal products of several deals
1936
- * @param {DealsApiGetDealsProductsRequest} requestParameters Request parameters.
1937
-
1938
- * @throws {RequiredError}
1939
- */
1940
- getDealsProducts(requestParameters) {
1941
- return localVarFp.getDealsProducts(requestParameters.deal_ids, requestParameters.cursor, requestParameters.limit, requestParameters.sort_by, requestParameters.sort_direction).then((request) => request(axios, basePath));
1942
- },
1943
- /**
1944
- * Lists installments attached to a list of deals. Only available in Growth and above plans.
1945
- * @summary List installments added to a list of deals
1946
- * @param {DealsApiGetInstallmentsRequest} requestParameters Request parameters.
1947
-
1948
- * @throws {RequiredError}
1949
- */
1950
- getInstallments(requestParameters) {
1951
- return localVarFp.getInstallments(requestParameters.deal_ids, requestParameters.cursor, requestParameters.limit, requestParameters.sort_by, requestParameters.sort_direction).then((request) => request(axios, basePath));
1265
+ return localVarFp.getDeals(requestParameters.filter_id, requestParameters.ids, requestParameters.owner_id, requestParameters.person_id, requestParameters.org_id, requestParameters.pipeline_id, requestParameters.stage_id, requestParameters.status, requestParameters.updated_since, requestParameters.updated_until, requestParameters.sort_by, requestParameters.sort_direction, requestParameters.include_fields, requestParameters.custom_fields, requestParameters.include_option_labels, requestParameters.include_labels, requestParameters.limit, requestParameters.cursor).then((request) => request(axios, basePath));
1952
1266
  },
1953
1267
  /**
1954
1268
  * Adds a discount to a deal, changing the deal value if the deal has one-time products attached.
@@ -1960,16 +1274,6 @@ const DealsApiFactory = function (configuration, basePath, axios) {
1960
1274
  postAdditionalDiscount(requestParameters) {
1961
1275
  return localVarFp.postAdditionalDiscount(requestParameters.id, requestParameters.AddAdditionalDiscountRequestBody).then((request) => request(axios, basePath));
1962
1276
  },
1963
- /**
1964
- * Adds an installment to a deal. An installment can only be added if the deal includes at least one one-time product. If the deal contains at least one recurring product, adding installments is not allowed. Only available in Growth and above plans.
1965
- * @summary Add an installment to a deal
1966
- * @param {DealsApiPostInstallmentRequest} requestParameters Request parameters.
1967
-
1968
- * @throws {RequiredError}
1969
- */
1970
- postInstallment(requestParameters) {
1971
- return localVarFp.postInstallment(requestParameters.id, requestParameters.AddInstallmentRequestBody).then((request) => request(axios, basePath));
1972
- },
1973
1277
  /**
1974
1278
  * Searches all deals by title, notes and/or custom fields. This endpoint is a wrapper of <a href=\"https://developers.pipedrive.com/docs/api/v1/ItemSearch#searchItem\">/v1/itemSearch</a> with a narrower OAuth scope. Found deals can be filtered by the person ID and the organization ID.
1975
1279
  * @summary Search deals
@@ -2000,26 +1304,6 @@ const DealsApiFactory = function (configuration, basePath, axios) {
2000
1304
  updateDeal(requestParameters) {
2001
1305
  return localVarFp.updateDeal(requestParameters.id, requestParameters.UpdateDealRequest).then((request) => request(axios, basePath));
2002
1306
  },
2003
- /**
2004
- * Updates the details of the product that has been attached to a deal.
2005
- * @summary Update the product attached to a deal
2006
- * @param {DealsApiUpdateDealProductRequest} requestParameters Request parameters.
2007
-
2008
- * @throws {RequiredError}
2009
- */
2010
- updateDealProduct(requestParameters) {
2011
- return localVarFp.updateDealProduct(requestParameters.id, requestParameters.product_attachment_id, requestParameters.UpdateDealProductRequest).then((request) => request(axios, basePath));
2012
- },
2013
- /**
2014
- * Edits an installment added to a deal. Only available in Growth and above plans.
2015
- * @summary Update an installment added to a deal
2016
- * @param {DealsApiUpdateInstallmentRequest} requestParameters Request parameters.
2017
-
2018
- * @throws {RequiredError}
2019
- */
2020
- updateInstallment(requestParameters) {
2021
- return localVarFp.updateInstallment(requestParameters.id, requestParameters.installment_id, requestParameters.UpdateInstallmentRequestBody).then((request) => request(axios, basePath));
2022
- },
2023
1307
  };
2024
1308
  };
2025
1309
  exports.DealsApiFactory = DealsApiFactory;
@@ -2052,28 +1336,6 @@ class DealsApi extends base_1.BaseAPI {
2052
1336
  addDealFollower(requestParameters) {
2053
1337
  return (0, exports.DealsApiFp)(this.configuration).addDealFollower(requestParameters.id, requestParameters.AddDealFollowerRequest).then((request) => request(this.axios, this.basePath));
2054
1338
  }
2055
- /**
2056
- * Adds a product to a deal, creating a new item called a deal-product.
2057
- * @summary Add a product to a deal
2058
- * @param {DealsApiAddDealProductRequest} requestParameters Request parameters.
2059
-
2060
- * @throws {RequiredError}
2061
- * @memberof DealsApi
2062
- */
2063
- addDealProduct(requestParameters) {
2064
- return (0, exports.DealsApiFp)(this.configuration).addDealProduct(requestParameters.id, requestParameters.AddDealProductRequest).then((request) => request(this.axios, this.basePath));
2065
- }
2066
- /**
2067
- * Adds multiple products to a deal in a single request. Maximum of 100 products allowed per request.
2068
- * @summary Add multiple products to a deal
2069
- * @param {DealsApiAddManyDealProductsRequest} requestParameters Request parameters.
2070
-
2071
- * @throws {RequiredError}
2072
- * @memberof DealsApi
2073
- */
2074
- addManyDealProducts(requestParameters) {
2075
- return (0, exports.DealsApiFp)(this.configuration).addManyDealProducts(requestParameters.id, requestParameters.CreateManyDealProductRequest).then((request) => request(this.axios, this.basePath));
2076
- }
2077
1339
  /**
2078
1340
  * Initiates a conversion of a deal to a lead. The return value is an ID of a job that was assigned to perform the conversion. Related entities (notes, files, emails, activities, ...) are transferred during the process to the target entity. There are exceptions for entities like invoices or history that are not transferred and remain linked to the original deal. If the conversion is successful, the deal is marked as deleted. To retrieve the created entity ID and the result of the conversion, call the <a href=\"https://developers.pipedrive.com/docs/api/v1/Deals#getDealConversionStatus\">/api/v2/deals/{deal_id}/convert/status/{conversion_id}</a> endpoint.
2079
1341
  * @summary Convert a deal to a lead
@@ -2118,39 +1380,6 @@ class DealsApi extends base_1.BaseAPI {
2118
1380
  deleteDealFollower(requestParameters) {
2119
1381
  return (0, exports.DealsApiFp)(this.configuration).deleteDealFollower(requestParameters.id, requestParameters.follower_id).then((request) => request(this.axios, this.basePath));
2120
1382
  }
2121
- /**
2122
- * Deletes a product attachment from a deal, using the `product_attachment_id`.
2123
- * @summary Delete an attached product from a deal
2124
- * @param {DealsApiDeleteDealProductRequest} requestParameters Request parameters.
2125
-
2126
- * @throws {RequiredError}
2127
- * @memberof DealsApi
2128
- */
2129
- deleteDealProduct(requestParameters) {
2130
- return (0, exports.DealsApiFp)(this.configuration).deleteDealProduct(requestParameters.id, requestParameters.product_attachment_id).then((request) => request(this.axios, this.basePath));
2131
- }
2132
- /**
2133
- * Removes an installment from a deal. Only available in Growth and above plans.
2134
- * @summary Delete an installment from a deal
2135
- * @param {DealsApiDeleteInstallmentRequest} requestParameters Request parameters.
2136
-
2137
- * @throws {RequiredError}
2138
- * @memberof DealsApi
2139
- */
2140
- deleteInstallment(requestParameters) {
2141
- return (0, exports.DealsApiFp)(this.configuration).deleteInstallment(requestParameters.id, requestParameters.installment_id).then((request) => request(this.axios, this.basePath));
2142
- }
2143
- /**
2144
- * Deletes multiple products from a deal. If no product IDs are specified, up to 100 products will be removed from the deal. A maximum of 100 product IDs can be provided per request.
2145
- * @summary Delete many products from a deal
2146
- * @param {DealsApiDeleteManyDealProductsRequest} requestParameters Request parameters.
2147
-
2148
- * @throws {RequiredError}
2149
- * @memberof DealsApi
2150
- */
2151
- deleteManyDealProducts(requestParameters) {
2152
- return (0, exports.DealsApiFp)(this.configuration).deleteManyDealProducts(requestParameters.id, requestParameters.ids).then((request) => request(this.axios, this.basePath));
2153
- }
2154
1383
  /**
2155
1384
  * Lists discounts attached to a deal.
2156
1385
  * @summary List discounts added to a deal
@@ -2182,7 +1411,7 @@ class DealsApi extends base_1.BaseAPI {
2182
1411
  * @memberof DealsApi
2183
1412
  */
2184
1413
  getDeal(requestParameters) {
2185
- return (0, exports.DealsApiFp)(this.configuration).getDeal(requestParameters.id, requestParameters.include_fields, requestParameters.custom_fields).then((request) => request(this.axios, this.basePath));
1414
+ return (0, exports.DealsApiFp)(this.configuration).getDeal(requestParameters.id, requestParameters.include_fields, requestParameters.custom_fields, requestParameters.include_option_labels, requestParameters.include_labels).then((request) => request(this.axios, this.basePath));
2186
1415
  }
2187
1416
  /**
2188
1417
  * Returns information about the conversion. Status is always present and its value (not_started, running, completed, failed, rejected) represents the current state of the conversion. Lead ID is only present if the conversion was successfully finished. This data is only temporary and removed after a few days.
@@ -2217,17 +1446,6 @@ class DealsApi extends base_1.BaseAPI {
2217
1446
  getDealFollowersChangelog(requestParameters) {
2218
1447
  return (0, exports.DealsApiFp)(this.configuration).getDealFollowersChangelog(requestParameters.id, requestParameters.limit, requestParameters.cursor).then((request) => request(this.axios, this.basePath));
2219
1448
  }
2220
- /**
2221
- * Lists products attached to a deal.
2222
- * @summary List products attached to a deal
2223
- * @param {DealsApiGetDealProductsRequest} requestParameters Request parameters.
2224
-
2225
- * @throws {RequiredError}
2226
- * @memberof DealsApi
2227
- */
2228
- getDealProducts(requestParameters) {
2229
- return (0, exports.DealsApiFp)(this.configuration).getDealProducts(requestParameters.id, requestParameters.cursor, requestParameters.limit, requestParameters.sort_by, requestParameters.sort_direction).then((request) => request(this.axios, this.basePath));
2230
- }
2231
1449
  /**
2232
1450
  * Returns data about all not archived deals.
2233
1451
  * @summary Get all deals
@@ -2237,29 +1455,7 @@ class DealsApi extends base_1.BaseAPI {
2237
1455
  * @memberof DealsApi
2238
1456
  */
2239
1457
  getDeals(requestParameters = {}) {
2240
- return (0, exports.DealsApiFp)(this.configuration).getDeals(requestParameters.filter_id, requestParameters.ids, requestParameters.owner_id, requestParameters.person_id, requestParameters.org_id, requestParameters.pipeline_id, requestParameters.stage_id, requestParameters.status, requestParameters.updated_since, requestParameters.updated_until, requestParameters.sort_by, requestParameters.sort_direction, requestParameters.include_fields, requestParameters.custom_fields, requestParameters.limit, requestParameters.cursor).then((request) => request(this.axios, this.basePath));
2241
- }
2242
- /**
2243
- * Returns data about products attached to deals
2244
- * @summary Get deal products of several deals
2245
- * @param {DealsApiGetDealsProductsRequest} requestParameters Request parameters.
2246
-
2247
- * @throws {RequiredError}
2248
- * @memberof DealsApi
2249
- */
2250
- getDealsProducts(requestParameters) {
2251
- return (0, exports.DealsApiFp)(this.configuration).getDealsProducts(requestParameters.deal_ids, requestParameters.cursor, requestParameters.limit, requestParameters.sort_by, requestParameters.sort_direction).then((request) => request(this.axios, this.basePath));
2252
- }
2253
- /**
2254
- * Lists installments attached to a list of deals. Only available in Growth and above plans.
2255
- * @summary List installments added to a list of deals
2256
- * @param {DealsApiGetInstallmentsRequest} requestParameters Request parameters.
2257
-
2258
- * @throws {RequiredError}
2259
- * @memberof DealsApi
2260
- */
2261
- getInstallments(requestParameters) {
2262
- return (0, exports.DealsApiFp)(this.configuration).getInstallments(requestParameters.deal_ids, requestParameters.cursor, requestParameters.limit, requestParameters.sort_by, requestParameters.sort_direction).then((request) => request(this.axios, this.basePath));
1458
+ return (0, exports.DealsApiFp)(this.configuration).getDeals(requestParameters.filter_id, requestParameters.ids, requestParameters.owner_id, requestParameters.person_id, requestParameters.org_id, requestParameters.pipeline_id, requestParameters.stage_id, requestParameters.status, requestParameters.updated_since, requestParameters.updated_until, requestParameters.sort_by, requestParameters.sort_direction, requestParameters.include_fields, requestParameters.custom_fields, requestParameters.include_option_labels, requestParameters.include_labels, requestParameters.limit, requestParameters.cursor).then((request) => request(this.axios, this.basePath));
2263
1459
  }
2264
1460
  /**
2265
1461
  * Adds a discount to a deal, changing the deal value if the deal has one-time products attached.
@@ -2272,17 +1468,6 @@ class DealsApi extends base_1.BaseAPI {
2272
1468
  postAdditionalDiscount(requestParameters) {
2273
1469
  return (0, exports.DealsApiFp)(this.configuration).postAdditionalDiscount(requestParameters.id, requestParameters.AddAdditionalDiscountRequestBody).then((request) => request(this.axios, this.basePath));
2274
1470
  }
2275
- /**
2276
- * Adds an installment to a deal. An installment can only be added if the deal includes at least one one-time product. If the deal contains at least one recurring product, adding installments is not allowed. Only available in Growth and above plans.
2277
- * @summary Add an installment to a deal
2278
- * @param {DealsApiPostInstallmentRequest} requestParameters Request parameters.
2279
-
2280
- * @throws {RequiredError}
2281
- * @memberof DealsApi
2282
- */
2283
- postInstallment(requestParameters) {
2284
- return (0, exports.DealsApiFp)(this.configuration).postInstallment(requestParameters.id, requestParameters.AddInstallmentRequestBody).then((request) => request(this.axios, this.basePath));
2285
- }
2286
1471
  /**
2287
1472
  * Searches all deals by title, notes and/or custom fields. This endpoint is a wrapper of <a href=\"https://developers.pipedrive.com/docs/api/v1/ItemSearch#searchItem\">/v1/itemSearch</a> with a narrower OAuth scope. Found deals can be filtered by the person ID and the organization ID.
2288
1473
  * @summary Search deals
@@ -2316,27 +1501,5 @@ class DealsApi extends base_1.BaseAPI {
2316
1501
  updateDeal(requestParameters) {
2317
1502
  return (0, exports.DealsApiFp)(this.configuration).updateDeal(requestParameters.id, requestParameters.UpdateDealRequest).then((request) => request(this.axios, this.basePath));
2318
1503
  }
2319
- /**
2320
- * Updates the details of the product that has been attached to a deal.
2321
- * @summary Update the product attached to a deal
2322
- * @param {DealsApiUpdateDealProductRequest} requestParameters Request parameters.
2323
-
2324
- * @throws {RequiredError}
2325
- * @memberof DealsApi
2326
- */
2327
- updateDealProduct(requestParameters) {
2328
- return (0, exports.DealsApiFp)(this.configuration).updateDealProduct(requestParameters.id, requestParameters.product_attachment_id, requestParameters.UpdateDealProductRequest).then((request) => request(this.axios, this.basePath));
2329
- }
2330
- /**
2331
- * Edits an installment added to a deal. Only available in Growth and above plans.
2332
- * @summary Update an installment added to a deal
2333
- * @param {DealsApiUpdateInstallmentRequest} requestParameters Request parameters.
2334
-
2335
- * @throws {RequiredError}
2336
- * @memberof DealsApi
2337
- */
2338
- updateInstallment(requestParameters) {
2339
- return (0, exports.DealsApiFp)(this.configuration).updateInstallment(requestParameters.id, requestParameters.installment_id, requestParameters.UpdateInstallmentRequestBody).then((request) => request(this.axios, this.basePath));
2340
- }
2341
1504
  }
2342
1505
  exports.DealsApi = DealsApi;