pipedrive 24.2.0 → 26.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.
- package/dist/esm/versions/v1/api/activities-api.d.ts +40 -40
- package/dist/esm/versions/v1/api/activities-api.js +40 -40
- package/dist/esm/versions/v1/api/deals-api.d.ts +413 -91
- package/dist/esm/versions/v1/api/deals-api.js +419 -90
- package/dist/esm/versions/v1/api/item-search-api.d.ts +8 -8
- package/dist/esm/versions/v1/api/item-search-api.js +8 -8
- package/dist/esm/versions/v1/api/leads-api.d.ts +100 -14
- package/dist/esm/versions/v1/api/leads-api.js +107 -14
- package/dist/esm/versions/v1/api/notes-api.d.ts +18 -2
- package/dist/esm/versions/v1/api/notes-api.js +15 -5
- package/dist/esm/versions/v1/api/organizations-api.d.ts +71 -71
- package/dist/esm/versions/v1/api/organizations-api.js +70 -70
- package/dist/esm/versions/v1/api/persons-api.d.ts +59 -59
- package/dist/esm/versions/v1/api/persons-api.js +58 -58
- package/dist/esm/versions/v1/api/pipelines-api.d.ts +28 -28
- package/dist/esm/versions/v1/api/pipelines-api.js +28 -28
- package/dist/esm/versions/v1/api/products-api.d.ts +24 -24
- package/dist/esm/versions/v1/api/products-api.js +24 -24
- package/dist/esm/versions/v1/api/stages-api.d.ts +36 -36
- package/dist/esm/versions/v1/api/stages-api.js +36 -36
- package/dist/esm/versions/v1/api/subscriptions-api.d.ts +36 -36
- package/dist/esm/versions/v1/api/subscriptions-api.js +36 -36
- package/dist/esm/versions/v1/api/webhooks-api.d.ts +4 -4
- package/dist/esm/versions/v1/api/webhooks-api.js +4 -4
- package/dist/esm/versions/v1/base.d.ts +2 -3
- package/dist/esm/versions/v1/configuration.d.ts +2 -2
- package/dist/esm/versions/v1/models/add-note-request-all-of.d.ts +9 -4
- package/dist/esm/versions/v1/models/add-note-request-all-of1.d.ts +10 -0
- package/dist/esm/versions/v1/models/add-note-request-all-of1.js +4 -0
- package/dist/esm/versions/v1/models/add-webhook-request.d.ts +5 -6
- package/dist/esm/versions/v1/models/add-webhook-request.js +4 -5
- package/dist/esm/versions/v1/models/get-deal-search-response-all-of-data-items-inner-item.d.ts +5 -0
- package/dist/esm/versions/v1/models/index.d.ts +1 -0
- package/dist/esm/versions/v1/models/index.js +1 -0
- package/dist/esm/versions/v1/models/note-project.d.ts +23 -0
- package/dist/esm/versions/v1/models/note-project.js +14 -0
- package/dist/esm/versions/v1/models/note-request-all-of1.d.ts +5 -0
- package/dist/esm/versions/v1/models/note.d.ts +16 -0
- package/dist/esm/versions/v1/models/user-access.d.ts +3 -2
- package/dist/esm/versions/v1/models/user-access.js +4 -3
- package/dist/esm/versions/v1/models/user-access1.d.ts +3 -2
- package/dist/esm/versions/v1/models/user-access1.js +4 -3
- package/dist/esm/versions/v2/api/activities-api.d.ts +15 -7
- package/dist/esm/versions/v2/api/activities-api.js +12 -7
- package/dist/esm/versions/v2/api/beta-api.d.ts +194 -2532
- package/dist/esm/versions/v2/api/beta-api.js +263 -2928
- package/dist/esm/versions/v2/api/deals-api.d.ts +509 -4
- package/dist/esm/versions/v2/api/deals-api.js +589 -4
- package/dist/esm/versions/v2/api/leads-api.d.ts +111 -0
- package/dist/esm/versions/v2/api/leads-api.js +146 -1
- package/dist/esm/versions/v2/api/organizations-api.d.ts +237 -0
- package/dist/esm/versions/v2/api/organizations-api.js +301 -0
- package/dist/esm/versions/v2/api/persons-api.d.ts +245 -8
- package/dist/esm/versions/v2/api/persons-api.js +309 -8
- package/dist/esm/versions/v2/api/products-api.d.ts +237 -0
- package/dist/esm/versions/v2/api/products-api.js +301 -0
- package/dist/esm/versions/v2/api/users-api.d.ts +103 -0
- package/dist/esm/versions/v2/api/users-api.js +140 -0
- package/dist/esm/versions/v2/api.d.ts +1 -0
- package/dist/esm/versions/v2/api.js +1 -0
- package/dist/esm/versions/v2/base.d.ts +2 -3
- package/dist/esm/versions/v2/configuration.d.ts +2 -2
- package/dist/esm/versions/v2/models/activity-item.d.ts +5 -0
- package/dist/esm/versions/v2/models/activity-item1.d.ts +5 -0
- package/dist/esm/versions/v2/models/add-convert-deal-to-lead-response-data.d.ts +23 -0
- package/dist/esm/versions/v2/models/add-convert-deal-to-lead-response-data.js +14 -0
- package/dist/esm/versions/v2/models/add-convert-deal-to-lead-response.d.ts +34 -0
- package/dist/esm/versions/v2/models/add-convert-deal-to-lead-response.js +14 -0
- package/dist/esm/versions/v2/models/add-convert-lead-to-deal-response.d.ts +34 -0
- package/dist/esm/versions/v2/models/add-convert-lead-to-deal-response.js +14 -0
- package/dist/esm/versions/v2/models/add-deal-follower-request.d.ts +23 -0
- package/dist/esm/versions/v2/models/add-deal-follower-request.js +14 -0
- package/dist/esm/versions/v2/models/add-follower-response-all-of.d.ts +24 -0
- package/dist/esm/versions/v2/models/add-follower-response-all-of.js +14 -0
- package/dist/esm/versions/v2/models/add-follower-response.d.ts +18 -0
- package/dist/esm/versions/v2/models/add-follower-response.js +14 -0
- package/dist/esm/versions/v2/models/add-person-request.d.ts +12 -0
- package/dist/esm/versions/v2/models/add-person-request.js +6 -1
- package/dist/esm/versions/v2/models/convert-lead-to-deal-request.d.ts +28 -0
- package/dist/esm/versions/v2/models/convert-lead-to-deal-request.js +14 -0
- package/dist/esm/versions/v2/models/deal-item.d.ts +5 -0
- package/dist/esm/versions/v2/models/deal-item1.d.ts +5 -0
- package/dist/esm/versions/v2/models/delete-follower-response-data.d.ts +23 -0
- package/dist/esm/versions/v2/models/delete-follower-response-data.js +14 -0
- package/dist/esm/versions/v2/models/delete-follower-response.d.ts +29 -0
- package/dist/esm/versions/v2/models/delete-follower-response.js +14 -0
- package/dist/esm/versions/v2/models/follower-changelog-item.d.ts +38 -0
- package/dist/esm/versions/v2/models/follower-changelog-item.js +14 -0
- package/dist/esm/versions/v2/models/follower-item.d.ts +28 -0
- package/dist/esm/versions/v2/models/follower-item.js +14 -0
- package/dist/esm/versions/v2/models/follower-item1.d.ts +28 -0
- package/dist/esm/versions/v2/models/follower-item1.js +14 -0
- package/dist/esm/versions/v2/models/get-convert-response.d.ts +43 -0
- package/dist/esm/versions/v2/models/get-convert-response.js +14 -0
- package/dist/esm/versions/v2/models/get-convert-response1-data.d.ts +46 -0
- package/dist/esm/versions/v2/models/get-convert-response1-data.js +20 -0
- package/dist/esm/versions/v2/models/get-convert-response1.d.ts +34 -0
- package/dist/esm/versions/v2/models/get-convert-response1.js +14 -0
- package/dist/esm/versions/v2/models/get-deal-search-response-all-of-data-items-inner-item.d.ts +5 -0
- package/dist/esm/versions/v2/models/get-follower-changelogs-response-all-of.d.ts +30 -0
- package/dist/esm/versions/v2/models/get-follower-changelogs-response-all-of.js +14 -0
- package/dist/esm/versions/v2/models/get-follower-changelogs-response.d.ts +18 -0
- package/dist/esm/versions/v2/models/get-follower-changelogs-response.js +14 -0
- package/dist/esm/versions/v2/models/get-followers-response-all-of.d.ts +30 -0
- package/dist/esm/versions/v2/models/get-followers-response-all-of.js +14 -0
- package/dist/esm/versions/v2/models/get-followers-response.d.ts +18 -0
- package/dist/esm/versions/v2/models/get-followers-response.js +14 -0
- package/dist/esm/versions/v2/models/index.d.ts +19 -0
- package/dist/esm/versions/v2/models/index.js +19 -0
- package/dist/esm/versions/v2/models/update-person-request.d.ts +12 -0
- package/dist/esm/versions/v2/models/update-person-request.js +6 -1
- package/dist/versions/v1/api/activities-api.d.ts +40 -40
- package/dist/versions/v1/api/activities-api.js +40 -40
- package/dist/versions/v1/api/deals-api.d.ts +413 -91
- package/dist/versions/v1/api/deals-api.js +419 -90
- package/dist/versions/v1/api/item-search-api.d.ts +8 -8
- package/dist/versions/v1/api/item-search-api.js +8 -8
- package/dist/versions/v1/api/leads-api.d.ts +100 -14
- package/dist/versions/v1/api/leads-api.js +107 -14
- package/dist/versions/v1/api/notes-api.d.ts +18 -2
- package/dist/versions/v1/api/notes-api.js +15 -5
- package/dist/versions/v1/api/organizations-api.d.ts +71 -71
- package/dist/versions/v1/api/organizations-api.js +70 -70
- package/dist/versions/v1/api/persons-api.d.ts +59 -59
- package/dist/versions/v1/api/persons-api.js +58 -58
- package/dist/versions/v1/api/pipelines-api.d.ts +28 -28
- package/dist/versions/v1/api/pipelines-api.js +28 -28
- package/dist/versions/v1/api/products-api.d.ts +24 -24
- package/dist/versions/v1/api/products-api.js +24 -24
- package/dist/versions/v1/api/stages-api.d.ts +36 -36
- package/dist/versions/v1/api/stages-api.js +36 -36
- package/dist/versions/v1/api/subscriptions-api.d.ts +36 -36
- package/dist/versions/v1/api/subscriptions-api.js +36 -36
- package/dist/versions/v1/api/webhooks-api.d.ts +4 -4
- package/dist/versions/v1/api/webhooks-api.js +4 -4
- package/dist/versions/v1/base.d.ts +2 -3
- package/dist/versions/v1/configuration.d.ts +2 -2
- package/dist/versions/v1/models/add-note-request-all-of.d.ts +9 -4
- package/dist/versions/v1/models/add-note-request-all-of1.d.ts +10 -0
- package/dist/versions/v1/models/add-note-request-all-of1.js +5 -1
- package/dist/versions/v1/models/add-webhook-request.d.ts +5 -6
- package/dist/versions/v1/models/add-webhook-request.js +4 -5
- package/dist/versions/v1/models/get-deal-search-response-all-of-data-items-inner-item.d.ts +5 -0
- package/dist/versions/v1/models/index.d.ts +1 -0
- package/dist/versions/v1/models/index.js +1 -0
- package/dist/versions/v1/models/note-project.d.ts +23 -0
- package/dist/versions/v1/models/note-project.js +15 -0
- package/dist/versions/v1/models/note-request-all-of1.d.ts +5 -0
- package/dist/versions/v1/models/note.d.ts +16 -0
- package/dist/versions/v1/models/user-access.d.ts +3 -2
- package/dist/versions/v1/models/user-access.js +4 -3
- package/dist/versions/v1/models/user-access1.d.ts +3 -2
- package/dist/versions/v1/models/user-access1.js +4 -3
- package/dist/versions/v2/api/activities-api.d.ts +15 -7
- package/dist/versions/v2/api/activities-api.js +12 -7
- package/dist/versions/v2/api/beta-api.d.ts +194 -2532
- package/dist/versions/v2/api/beta-api.js +265 -2930
- package/dist/versions/v2/api/deals-api.d.ts +509 -4
- package/dist/versions/v2/api/deals-api.js +589 -4
- package/dist/versions/v2/api/leads-api.d.ts +111 -0
- package/dist/versions/v2/api/leads-api.js +145 -0
- package/dist/versions/v2/api/organizations-api.d.ts +237 -0
- package/dist/versions/v2/api/organizations-api.js +301 -0
- package/dist/versions/v2/api/persons-api.d.ts +245 -8
- package/dist/versions/v2/api/persons-api.js +309 -8
- package/dist/versions/v2/api/products-api.d.ts +237 -0
- package/dist/versions/v2/api/products-api.js +301 -0
- package/dist/versions/v2/api/users-api.d.ts +103 -0
- package/dist/versions/v2/api/users-api.js +150 -0
- package/dist/versions/v2/api.d.ts +1 -0
- package/dist/versions/v2/api.js +1 -0
- package/dist/versions/v2/base.d.ts +2 -3
- package/dist/versions/v2/configuration.d.ts +2 -2
- package/dist/versions/v2/models/activity-item.d.ts +5 -0
- package/dist/versions/v2/models/activity-item1.d.ts +5 -0
- package/dist/versions/v2/models/add-convert-deal-to-lead-response-data.d.ts +23 -0
- package/dist/versions/v2/models/add-convert-deal-to-lead-response-data.js +15 -0
- package/dist/versions/v2/models/add-convert-deal-to-lead-response.d.ts +34 -0
- package/dist/versions/v2/models/add-convert-deal-to-lead-response.js +15 -0
- package/dist/versions/v2/models/add-convert-lead-to-deal-response.d.ts +34 -0
- package/dist/versions/v2/models/add-convert-lead-to-deal-response.js +15 -0
- package/dist/versions/v2/models/add-deal-follower-request.d.ts +23 -0
- package/dist/versions/v2/models/add-deal-follower-request.js +15 -0
- package/dist/versions/v2/models/add-follower-response-all-of.d.ts +24 -0
- package/dist/versions/v2/models/add-follower-response-all-of.js +15 -0
- package/dist/versions/v2/models/add-follower-response.d.ts +18 -0
- package/dist/versions/v2/models/add-follower-response.js +15 -0
- package/dist/versions/v2/models/add-person-request.d.ts +12 -0
- package/dist/versions/v2/models/add-person-request.js +7 -0
- package/dist/versions/v2/models/convert-lead-to-deal-request.d.ts +28 -0
- package/dist/versions/v2/models/convert-lead-to-deal-request.js +15 -0
- package/dist/versions/v2/models/deal-item.d.ts +5 -0
- package/dist/versions/v2/models/deal-item1.d.ts +5 -0
- package/dist/versions/v2/models/delete-follower-response-data.d.ts +23 -0
- package/dist/versions/v2/models/delete-follower-response-data.js +15 -0
- package/dist/versions/v2/models/delete-follower-response.d.ts +29 -0
- package/dist/versions/v2/models/delete-follower-response.js +15 -0
- package/dist/versions/v2/models/follower-changelog-item.d.ts +38 -0
- package/dist/versions/v2/models/follower-changelog-item.js +15 -0
- package/dist/versions/v2/models/follower-item.d.ts +28 -0
- package/dist/versions/v2/models/follower-item.js +15 -0
- package/dist/versions/v2/models/follower-item1.d.ts +28 -0
- package/dist/versions/v2/models/follower-item1.js +15 -0
- package/dist/versions/v2/models/get-convert-response.d.ts +43 -0
- package/dist/versions/v2/models/get-convert-response.js +15 -0
- package/dist/versions/v2/models/get-convert-response1-data.d.ts +46 -0
- package/dist/versions/v2/models/get-convert-response1-data.js +23 -0
- package/dist/versions/v2/models/get-convert-response1.d.ts +34 -0
- package/dist/versions/v2/models/get-convert-response1.js +15 -0
- package/dist/versions/v2/models/get-deal-search-response-all-of-data-items-inner-item.d.ts +5 -0
- package/dist/versions/v2/models/get-follower-changelogs-response-all-of.d.ts +30 -0
- package/dist/versions/v2/models/get-follower-changelogs-response-all-of.js +15 -0
- package/dist/versions/v2/models/get-follower-changelogs-response.d.ts +18 -0
- package/dist/versions/v2/models/get-follower-changelogs-response.js +15 -0
- package/dist/versions/v2/models/get-followers-response-all-of.d.ts +30 -0
- package/dist/versions/v2/models/get-followers-response-all-of.js +15 -0
- package/dist/versions/v2/models/get-followers-response.d.ts +18 -0
- package/dist/versions/v2/models/get-followers-response.js +15 -0
- package/dist/versions/v2/models/index.d.ts +19 -0
- package/dist/versions/v2/models/index.js +19 -0
- package/dist/versions/v2/models/update-person-request.d.ts +12 -0
- package/dist/versions/v2/models/update-person-request.js +7 -0
- package/package.json +1 -1
@@ -39,7 +39,7 @@ const base_1 = require("../base");
|
|
39
39
|
const PersonsApiAxiosParamCreator = function (configuration) {
|
40
40
|
return {
|
41
41
|
/**
|
42
|
-
* Adds a new person.
|
42
|
+
* Adds a new person. If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
43
43
|
* @summary Add a new person
|
44
44
|
* @param {AddPersonRequest} [AddPersonRequest]
|
45
45
|
|
@@ -71,6 +71,43 @@ const PersonsApiAxiosParamCreator = function (configuration) {
|
|
71
71
|
options: localVarRequestOptions,
|
72
72
|
};
|
73
73
|
}),
|
74
|
+
/**
|
75
|
+
* Adds a user as a follower to the person.
|
76
|
+
* @summary Add a follower to a person
|
77
|
+
* @param {number} id The ID of the person
|
78
|
+
* @param {AddDealFollowerRequest} [AddDealFollowerRequest]
|
79
|
+
|
80
|
+
* @throws {RequiredError}
|
81
|
+
*/
|
82
|
+
addPersonFollower: (id, AddDealFollowerRequest) => __awaiter(this, void 0, void 0, function* () {
|
83
|
+
// verify required parameter 'id' is not null or undefined
|
84
|
+
(0, common_1.assertParamExists)('addPersonFollower', 'id', id);
|
85
|
+
const localVarPath = `/persons/{id}/followers`
|
86
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
87
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
88
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
89
|
+
let baseOptions;
|
90
|
+
if (configuration) {
|
91
|
+
baseOptions = configuration.baseOptions;
|
92
|
+
}
|
93
|
+
const localVarRequestOptions = Object.assign({ method: 'POST' }, baseOptions);
|
94
|
+
const localVarHeaderParameter = {};
|
95
|
+
const localVarQueryParameter = {};
|
96
|
+
// authentication api_key required
|
97
|
+
yield (0, common_1.setApiKeyToObject)(localVarQueryParameter, "api_token", configuration);
|
98
|
+
// authentication oauth2 required
|
99
|
+
// oauth required
|
100
|
+
yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["contacts:full"], configuration);
|
101
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
102
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
103
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
104
|
+
localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
|
105
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(AddDealFollowerRequest, localVarRequestOptions, configuration);
|
106
|
+
return {
|
107
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
108
|
+
options: localVarRequestOptions,
|
109
|
+
};
|
110
|
+
}),
|
74
111
|
/**
|
75
112
|
* Marks a person as deleted. After 30 days, the person will be permanently deleted.
|
76
113
|
* @summary Delete a person
|
@@ -105,6 +142,44 @@ const PersonsApiAxiosParamCreator = function (configuration) {
|
|
105
142
|
options: localVarRequestOptions,
|
106
143
|
};
|
107
144
|
}),
|
145
|
+
/**
|
146
|
+
* Deletes a user follower from the person.
|
147
|
+
* @summary Delete a follower from a person
|
148
|
+
* @param {number} id The ID of the person
|
149
|
+
* @param {number} follower_id The ID of the following user
|
150
|
+
|
151
|
+
* @throws {RequiredError}
|
152
|
+
*/
|
153
|
+
deletePersonFollower: (id, follower_id) => __awaiter(this, void 0, void 0, function* () {
|
154
|
+
// verify required parameter 'id' is not null or undefined
|
155
|
+
(0, common_1.assertParamExists)('deletePersonFollower', 'id', id);
|
156
|
+
// verify required parameter 'follower_id' is not null or undefined
|
157
|
+
(0, common_1.assertParamExists)('deletePersonFollower', 'follower_id', follower_id);
|
158
|
+
const localVarPath = `/persons/{id}/followers/{follower_id}`
|
159
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)))
|
160
|
+
.replace(`{${"follower_id"}}`, encodeURIComponent(String(follower_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: 'DELETE' }, baseOptions);
|
168
|
+
const localVarHeaderParameter = {};
|
169
|
+
const localVarQueryParameter = {};
|
170
|
+
// authentication api_key required
|
171
|
+
yield (0, common_1.setApiKeyToObject)(localVarQueryParameter, "api_token", configuration);
|
172
|
+
// authentication oauth2 required
|
173
|
+
// oauth required
|
174
|
+
yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["contacts:full"], configuration);
|
175
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
176
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
177
|
+
localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
|
178
|
+
return {
|
179
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
180
|
+
options: localVarRequestOptions,
|
181
|
+
};
|
182
|
+
}),
|
108
183
|
/**
|
109
184
|
* Returns the details of a specific person. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
110
185
|
* @summary Get details of a person
|
@@ -147,6 +222,90 @@ const PersonsApiAxiosParamCreator = function (configuration) {
|
|
147
222
|
options: localVarRequestOptions,
|
148
223
|
};
|
149
224
|
}),
|
225
|
+
/**
|
226
|
+
* Lists users who are following the person.
|
227
|
+
* @summary List followers of a person
|
228
|
+
* @param {number} id The ID of the person
|
229
|
+
* @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.
|
230
|
+
* @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
|
231
|
+
|
232
|
+
* @throws {RequiredError}
|
233
|
+
*/
|
234
|
+
getPersonFollowers: (id, limit, cursor) => __awaiter(this, void 0, void 0, function* () {
|
235
|
+
// verify required parameter 'id' is not null or undefined
|
236
|
+
(0, common_1.assertParamExists)('getPersonFollowers', 'id', id);
|
237
|
+
const localVarPath = `/persons/{id}/followers`
|
238
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
239
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
240
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
241
|
+
let baseOptions;
|
242
|
+
if (configuration) {
|
243
|
+
baseOptions = configuration.baseOptions;
|
244
|
+
}
|
245
|
+
const localVarRequestOptions = Object.assign({ method: 'GET' }, baseOptions);
|
246
|
+
const localVarHeaderParameter = {};
|
247
|
+
const localVarQueryParameter = {};
|
248
|
+
// authentication api_key required
|
249
|
+
yield (0, common_1.setApiKeyToObject)(localVarQueryParameter, "api_token", configuration);
|
250
|
+
// authentication oauth2 required
|
251
|
+
// oauth required
|
252
|
+
yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["contacts:read", "contacts:full"], configuration);
|
253
|
+
if (limit !== undefined) {
|
254
|
+
localVarQueryParameter['limit'] = limit;
|
255
|
+
}
|
256
|
+
if (cursor !== undefined) {
|
257
|
+
localVarQueryParameter['cursor'] = cursor;
|
258
|
+
}
|
259
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
260
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
261
|
+
localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
|
262
|
+
return {
|
263
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
264
|
+
options: localVarRequestOptions,
|
265
|
+
};
|
266
|
+
}),
|
267
|
+
/**
|
268
|
+
* Lists changelogs about users have followed the person.
|
269
|
+
* @summary List followers changelog of a person
|
270
|
+
* @param {number} id The ID of the person
|
271
|
+
* @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.
|
272
|
+
* @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
|
273
|
+
|
274
|
+
* @throws {RequiredError}
|
275
|
+
*/
|
276
|
+
getPersonFollowersChangelog: (id, limit, cursor) => __awaiter(this, void 0, void 0, function* () {
|
277
|
+
// verify required parameter 'id' is not null or undefined
|
278
|
+
(0, common_1.assertParamExists)('getPersonFollowersChangelog', 'id', id);
|
279
|
+
const localVarPath = `/persons/{id}/followers/changelog`
|
280
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
281
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
282
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
283
|
+
let baseOptions;
|
284
|
+
if (configuration) {
|
285
|
+
baseOptions = configuration.baseOptions;
|
286
|
+
}
|
287
|
+
const localVarRequestOptions = Object.assign({ method: 'GET' }, baseOptions);
|
288
|
+
const localVarHeaderParameter = {};
|
289
|
+
const localVarQueryParameter = {};
|
290
|
+
// authentication api_key required
|
291
|
+
yield (0, common_1.setApiKeyToObject)(localVarQueryParameter, "api_token", configuration);
|
292
|
+
// authentication oauth2 required
|
293
|
+
// oauth required
|
294
|
+
yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["contacts:read", "contacts:full"], configuration);
|
295
|
+
if (limit !== undefined) {
|
296
|
+
localVarQueryParameter['limit'] = limit;
|
297
|
+
}
|
298
|
+
if (cursor !== undefined) {
|
299
|
+
localVarQueryParameter['cursor'] = cursor;
|
300
|
+
}
|
301
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
302
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
303
|
+
localVarRequestOptions.headers = Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions);
|
304
|
+
return {
|
305
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
306
|
+
options: localVarRequestOptions,
|
307
|
+
};
|
308
|
+
}),
|
150
309
|
/**
|
151
310
|
* Returns data about all persons. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
152
311
|
* @summary Get all persons
|
@@ -286,7 +445,7 @@ const PersonsApiAxiosParamCreator = function (configuration) {
|
|
286
445
|
};
|
287
446
|
}),
|
288
447
|
/**
|
289
|
-
* Updates the properties of a person.
|
448
|
+
* Updates the properties of a person. <br>If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
290
449
|
* @summary Update a person
|
291
450
|
* @param {number} id The ID of the person
|
292
451
|
* @param {UpdatePersonRequest} [UpdatePersonRequest]
|
@@ -333,7 +492,7 @@ const PersonsApiFp = function (configuration) {
|
|
333
492
|
const localVarAxiosParamCreator = (0, exports.PersonsApiAxiosParamCreator)(configuration);
|
334
493
|
return {
|
335
494
|
/**
|
336
|
-
* Adds a new person.
|
495
|
+
* Adds a new person. If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
337
496
|
* @summary Add a new person
|
338
497
|
* @param {AddPersonRequest} [AddPersonRequest]
|
339
498
|
|
@@ -345,6 +504,20 @@ const PersonsApiFp = function (configuration) {
|
|
345
504
|
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
346
505
|
});
|
347
506
|
},
|
507
|
+
/**
|
508
|
+
* Adds a user as a follower to the person.
|
509
|
+
* @summary Add a follower to a person
|
510
|
+
* @param {number} id The ID of the person
|
511
|
+
* @param {AddDealFollowerRequest} [AddDealFollowerRequest]
|
512
|
+
|
513
|
+
* @throws {RequiredError}
|
514
|
+
*/
|
515
|
+
addPersonFollower(id, AddDealFollowerRequest) {
|
516
|
+
return __awaiter(this, void 0, void 0, function* () {
|
517
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.addPersonFollower(id, AddDealFollowerRequest);
|
518
|
+
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
519
|
+
});
|
520
|
+
},
|
348
521
|
/**
|
349
522
|
* Marks a person as deleted. After 30 days, the person will be permanently deleted.
|
350
523
|
* @summary Delete a person
|
@@ -358,6 +531,20 @@ const PersonsApiFp = function (configuration) {
|
|
358
531
|
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
359
532
|
});
|
360
533
|
},
|
534
|
+
/**
|
535
|
+
* Deletes a user follower from the person.
|
536
|
+
* @summary Delete a follower from a person
|
537
|
+
* @param {number} id The ID of the person
|
538
|
+
* @param {number} follower_id The ID of the following user
|
539
|
+
|
540
|
+
* @throws {RequiredError}
|
541
|
+
*/
|
542
|
+
deletePersonFollower(id, follower_id) {
|
543
|
+
return __awaiter(this, void 0, void 0, function* () {
|
544
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.deletePersonFollower(id, follower_id);
|
545
|
+
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
546
|
+
});
|
547
|
+
},
|
361
548
|
/**
|
362
549
|
* Returns the details of a specific person. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
363
550
|
* @summary Get details of a person
|
@@ -373,6 +560,36 @@ const PersonsApiFp = function (configuration) {
|
|
373
560
|
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
374
561
|
});
|
375
562
|
},
|
563
|
+
/**
|
564
|
+
* Lists users who are following the person.
|
565
|
+
* @summary List followers of a person
|
566
|
+
* @param {number} id The ID of the person
|
567
|
+
* @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.
|
568
|
+
* @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
|
569
|
+
|
570
|
+
* @throws {RequiredError}
|
571
|
+
*/
|
572
|
+
getPersonFollowers(id, limit, cursor) {
|
573
|
+
return __awaiter(this, void 0, void 0, function* () {
|
574
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.getPersonFollowers(id, limit, cursor);
|
575
|
+
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
576
|
+
});
|
577
|
+
},
|
578
|
+
/**
|
579
|
+
* Lists changelogs about users have followed the person.
|
580
|
+
* @summary List followers changelog of a person
|
581
|
+
* @param {number} id The ID of the person
|
582
|
+
* @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.
|
583
|
+
* @param {string} [cursor] For pagination, the marker (an opaque string value) representing the first item on the next page
|
584
|
+
|
585
|
+
* @throws {RequiredError}
|
586
|
+
*/
|
587
|
+
getPersonFollowersChangelog(id, limit, cursor) {
|
588
|
+
return __awaiter(this, void 0, void 0, function* () {
|
589
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.getPersonFollowersChangelog(id, limit, cursor);
|
590
|
+
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
|
591
|
+
});
|
592
|
+
},
|
376
593
|
/**
|
377
594
|
* Returns data about all persons. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
378
595
|
* @summary Get all persons
|
@@ -417,7 +634,7 @@ const PersonsApiFp = function (configuration) {
|
|
417
634
|
});
|
418
635
|
},
|
419
636
|
/**
|
420
|
-
* Updates the properties of a person.
|
637
|
+
* Updates the properties of a person. <br>If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
421
638
|
* @summary Update a person
|
422
639
|
* @param {number} id The ID of the person
|
423
640
|
* @param {UpdatePersonRequest} [UpdatePersonRequest]
|
@@ -441,7 +658,7 @@ const PersonsApiFactory = function (configuration, basePath, axios) {
|
|
441
658
|
const localVarFp = (0, exports.PersonsApiFp)(configuration);
|
442
659
|
return {
|
443
660
|
/**
|
444
|
-
* Adds a new person.
|
661
|
+
* Adds a new person. If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
445
662
|
* @summary Add a new person
|
446
663
|
* @param {PersonsApiAddPersonRequest} requestParameters Request parameters.
|
447
664
|
|
@@ -450,6 +667,16 @@ const PersonsApiFactory = function (configuration, basePath, axios) {
|
|
450
667
|
addPerson(requestParameters = {}) {
|
451
668
|
return localVarFp.addPerson(requestParameters.AddPersonRequest).then((request) => request(axios, basePath));
|
452
669
|
},
|
670
|
+
/**
|
671
|
+
* Adds a user as a follower to the person.
|
672
|
+
* @summary Add a follower to a person
|
673
|
+
* @param {PersonsApiAddPersonFollowerRequest} requestParameters Request parameters.
|
674
|
+
|
675
|
+
* @throws {RequiredError}
|
676
|
+
*/
|
677
|
+
addPersonFollower(requestParameters) {
|
678
|
+
return localVarFp.addPersonFollower(requestParameters.id, requestParameters.AddDealFollowerRequest).then((request) => request(axios, basePath));
|
679
|
+
},
|
453
680
|
/**
|
454
681
|
* Marks a person as deleted. After 30 days, the person will be permanently deleted.
|
455
682
|
* @summary Delete a person
|
@@ -460,6 +687,16 @@ const PersonsApiFactory = function (configuration, basePath, axios) {
|
|
460
687
|
deletePerson(requestParameters) {
|
461
688
|
return localVarFp.deletePerson(requestParameters.id).then((request) => request(axios, basePath));
|
462
689
|
},
|
690
|
+
/**
|
691
|
+
* Deletes a user follower from the person.
|
692
|
+
* @summary Delete a follower from a person
|
693
|
+
* @param {PersonsApiDeletePersonFollowerRequest} requestParameters Request parameters.
|
694
|
+
|
695
|
+
* @throws {RequiredError}
|
696
|
+
*/
|
697
|
+
deletePersonFollower(requestParameters) {
|
698
|
+
return localVarFp.deletePersonFollower(requestParameters.id, requestParameters.follower_id).then((request) => request(axios, basePath));
|
699
|
+
},
|
463
700
|
/**
|
464
701
|
* Returns the details of a specific person. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
465
702
|
* @summary Get details of a person
|
@@ -470,6 +707,26 @@ const PersonsApiFactory = function (configuration, basePath, axios) {
|
|
470
707
|
getPerson(requestParameters) {
|
471
708
|
return localVarFp.getPerson(requestParameters.id, requestParameters.include_fields, requestParameters.custom_fields).then((request) => request(axios, basePath));
|
472
709
|
},
|
710
|
+
/**
|
711
|
+
* Lists users who are following the person.
|
712
|
+
* @summary List followers of a person
|
713
|
+
* @param {PersonsApiGetPersonFollowersRequest} requestParameters Request parameters.
|
714
|
+
|
715
|
+
* @throws {RequiredError}
|
716
|
+
*/
|
717
|
+
getPersonFollowers(requestParameters) {
|
718
|
+
return localVarFp.getPersonFollowers(requestParameters.id, requestParameters.limit, requestParameters.cursor).then((request) => request(axios, basePath));
|
719
|
+
},
|
720
|
+
/**
|
721
|
+
* Lists changelogs about users have followed the person.
|
722
|
+
* @summary List followers changelog of a person
|
723
|
+
* @param {PersonsApiGetPersonFollowersChangelogRequest} requestParameters Request parameters.
|
724
|
+
|
725
|
+
* @throws {RequiredError}
|
726
|
+
*/
|
727
|
+
getPersonFollowersChangelog(requestParameters) {
|
728
|
+
return localVarFp.getPersonFollowersChangelog(requestParameters.id, requestParameters.limit, requestParameters.cursor).then((request) => request(axios, basePath));
|
729
|
+
},
|
473
730
|
/**
|
474
731
|
* Returns data about all persons. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
475
732
|
* @summary Get all persons
|
@@ -491,7 +748,7 @@ const PersonsApiFactory = function (configuration, basePath, axios) {
|
|
491
748
|
return localVarFp.searchPersons(requestParameters.term, requestParameters.fields, requestParameters.exact_match, requestParameters.organization_id, requestParameters.include_fields, requestParameters.limit, requestParameters.cursor).then((request) => request(axios, basePath));
|
492
749
|
},
|
493
750
|
/**
|
494
|
-
* Updates the properties of a person.
|
751
|
+
* Updates the properties of a person. <br>If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
495
752
|
* @summary Update a person
|
496
753
|
* @param {PersonsApiUpdatePersonRequest} requestParameters Request parameters.
|
497
754
|
|
@@ -511,7 +768,7 @@ exports.PersonsApiFactory = PersonsApiFactory;
|
|
511
768
|
*/
|
512
769
|
class PersonsApi extends base_1.BaseAPI {
|
513
770
|
/**
|
514
|
-
* Adds a new person.
|
771
|
+
* Adds a new person. If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
515
772
|
* @summary Add a new person
|
516
773
|
* @param {PersonsApiAddPersonRequest} requestParameters Request parameters.
|
517
774
|
|
@@ -521,6 +778,17 @@ class PersonsApi extends base_1.BaseAPI {
|
|
521
778
|
addPerson(requestParameters = {}) {
|
522
779
|
return (0, exports.PersonsApiFp)(this.configuration).addPerson(requestParameters.AddPersonRequest).then((request) => request(this.axios, this.basePath));
|
523
780
|
}
|
781
|
+
/**
|
782
|
+
* Adds a user as a follower to the person.
|
783
|
+
* @summary Add a follower to a person
|
784
|
+
* @param {PersonsApiAddPersonFollowerRequest} requestParameters Request parameters.
|
785
|
+
|
786
|
+
* @throws {RequiredError}
|
787
|
+
* @memberof PersonsApi
|
788
|
+
*/
|
789
|
+
addPersonFollower(requestParameters) {
|
790
|
+
return (0, exports.PersonsApiFp)(this.configuration).addPersonFollower(requestParameters.id, requestParameters.AddDealFollowerRequest).then((request) => request(this.axios, this.basePath));
|
791
|
+
}
|
524
792
|
/**
|
525
793
|
* Marks a person as deleted. After 30 days, the person will be permanently deleted.
|
526
794
|
* @summary Delete a person
|
@@ -532,6 +800,17 @@ class PersonsApi extends base_1.BaseAPI {
|
|
532
800
|
deletePerson(requestParameters) {
|
533
801
|
return (0, exports.PersonsApiFp)(this.configuration).deletePerson(requestParameters.id).then((request) => request(this.axios, this.basePath));
|
534
802
|
}
|
803
|
+
/**
|
804
|
+
* Deletes a user follower from the person.
|
805
|
+
* @summary Delete a follower from a person
|
806
|
+
* @param {PersonsApiDeletePersonFollowerRequest} requestParameters Request parameters.
|
807
|
+
|
808
|
+
* @throws {RequiredError}
|
809
|
+
* @memberof PersonsApi
|
810
|
+
*/
|
811
|
+
deletePersonFollower(requestParameters) {
|
812
|
+
return (0, exports.PersonsApiFp)(this.configuration).deletePersonFollower(requestParameters.id, requestParameters.follower_id).then((request) => request(this.axios, this.basePath));
|
813
|
+
}
|
535
814
|
/**
|
536
815
|
* Returns the details of a specific person. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
537
816
|
* @summary Get details of a person
|
@@ -543,6 +822,28 @@ class PersonsApi extends base_1.BaseAPI {
|
|
543
822
|
getPerson(requestParameters) {
|
544
823
|
return (0, exports.PersonsApiFp)(this.configuration).getPerson(requestParameters.id, requestParameters.include_fields, requestParameters.custom_fields).then((request) => request(this.axios, this.basePath));
|
545
824
|
}
|
825
|
+
/**
|
826
|
+
* Lists users who are following the person.
|
827
|
+
* @summary List followers of a person
|
828
|
+
* @param {PersonsApiGetPersonFollowersRequest} requestParameters Request parameters.
|
829
|
+
|
830
|
+
* @throws {RequiredError}
|
831
|
+
* @memberof PersonsApi
|
832
|
+
*/
|
833
|
+
getPersonFollowers(requestParameters) {
|
834
|
+
return (0, exports.PersonsApiFp)(this.configuration).getPersonFollowers(requestParameters.id, requestParameters.limit, requestParameters.cursor).then((request) => request(this.axios, this.basePath));
|
835
|
+
}
|
836
|
+
/**
|
837
|
+
* Lists changelogs about users have followed the person.
|
838
|
+
* @summary List followers changelog of a person
|
839
|
+
* @param {PersonsApiGetPersonFollowersChangelogRequest} requestParameters Request parameters.
|
840
|
+
|
841
|
+
* @throws {RequiredError}
|
842
|
+
* @memberof PersonsApi
|
843
|
+
*/
|
844
|
+
getPersonFollowersChangelog(requestParameters) {
|
845
|
+
return (0, exports.PersonsApiFp)(this.configuration).getPersonFollowersChangelog(requestParameters.id, requestParameters.limit, requestParameters.cursor).then((request) => request(this.axios, this.basePath));
|
846
|
+
}
|
546
847
|
/**
|
547
848
|
* Returns data about all persons. Fields `ims`, `postal_address`, `notes`, `birthday`, and `job_title` are only included if contact sync is enabled for the company.
|
548
849
|
* @summary Get all persons
|
@@ -566,7 +867,7 @@ class PersonsApi extends base_1.BaseAPI {
|
|
566
867
|
return (0, exports.PersonsApiFp)(this.configuration).searchPersons(requestParameters.term, requestParameters.fields, requestParameters.exact_match, requestParameters.organization_id, requestParameters.include_fields, requestParameters.limit, requestParameters.cursor).then((request) => request(this.axios, this.basePath));
|
567
868
|
}
|
568
869
|
/**
|
569
|
-
* Updates the properties of a person.
|
870
|
+
* Updates the properties of a person. <br>If the company uses the [Campaigns product](https://pipedrive.readme.io/docs/campaigns-in-pipedrive-api), then this endpoint will also accept and return the `marketing_status` field.
|
570
871
|
* @summary Update a person
|
571
872
|
* @param {PersonsApiUpdatePersonRequest} requestParameters Request parameters.
|
572
873
|
|