@salesforce/lds-adapters-marketing-prospect 1.347.1 → 1.348.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/es/es2018/marketing-prospect.js +193 -22
- package/dist/es/es2018/types/src/generated/adapters/getPostConversionEntries.d.ts +43 -0
- package/dist/es/es2018/types/src/generated/artifacts/main.d.ts +1 -0
- package/dist/es/es2018/types/src/generated/artifacts/sfdc.d.ts +3 -1
- package/dist/es/es2018/types/src/generated/resources/postConnectProspectConversion.d.ts +31 -0
- package/dist/es/es2018/types/src/generated/types/ConversionEntriesRepresentation.d.ts +4 -1
- package/dist/es/es2018/types/src/generated/types/ConversionPostInputRepresentation.d.ts +86 -0
- package/package.json +3 -3
- package/sfdc/index.js +210 -24
- package/src/raml/api.raml +77 -0
- package/src/raml/luvio.raml +8 -0
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$
|
|
7
|
+
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$2, typeCheckConfig as typeCheckConfig$2, StoreKeyMap, createResourceParams as createResourceParams$2 } from '@luvio/engine';
|
|
8
8
|
|
|
9
9
|
const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
|
|
10
10
|
const { keys: ObjectKeys, create: ObjectCreate } = Object;
|
|
@@ -129,7 +129,7 @@ function validate$1(obj, path = 'ConversionEntryRepresentation') {
|
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
const TTL = 60000;
|
|
132
|
-
const VERSION = "
|
|
132
|
+
const VERSION = "407aa680ebc397cf36cc1727ac369a87";
|
|
133
133
|
function validate(obj, path = 'ConversionEntriesRepresentation') {
|
|
134
134
|
const v_error = (() => {
|
|
135
135
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
@@ -150,6 +150,23 @@ function validate(obj, path = 'ConversionEntriesRepresentation') {
|
|
|
150
150
|
return new TypeError(message);
|
|
151
151
|
}
|
|
152
152
|
}
|
|
153
|
+
if (obj.postConversionEntries !== undefined) {
|
|
154
|
+
const obj_postConversionEntries = obj.postConversionEntries;
|
|
155
|
+
const path_postConversionEntries = path + '.postConversionEntries';
|
|
156
|
+
if (!ArrayIsArray(obj_postConversionEntries)) {
|
|
157
|
+
return new TypeError('Expected "array" but received "' + typeof obj_postConversionEntries + '" (at "' + path_postConversionEntries + '")');
|
|
158
|
+
}
|
|
159
|
+
for (let i = 0; i < obj_postConversionEntries.length; i++) {
|
|
160
|
+
const obj_postConversionEntries_item = obj_postConversionEntries[i];
|
|
161
|
+
const path_postConversionEntries_item = path_postConversionEntries + '[' + i + ']';
|
|
162
|
+
const referencepath_postConversionEntries_itemValidationError = validate$1(obj_postConversionEntries_item, path_postConversionEntries_item);
|
|
163
|
+
if (referencepath_postConversionEntries_itemValidationError !== null) {
|
|
164
|
+
let message = 'Object doesn\'t match ConversionEntryRepresentation (at "' + path_postConversionEntries_item + '")\n';
|
|
165
|
+
message += referencepath_postConversionEntries_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
166
|
+
return new TypeError(message);
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
}
|
|
153
170
|
})();
|
|
154
171
|
return v_error === undefined ? null : v_error;
|
|
155
172
|
}
|
|
@@ -157,7 +174,7 @@ const RepresentationType = 'ConversionEntriesRepresentation';
|
|
|
157
174
|
function normalize(input, existing, path, luvio, store, timestamp) {
|
|
158
175
|
return input;
|
|
159
176
|
}
|
|
160
|
-
const select$
|
|
177
|
+
const select$2 = function ConversionEntriesRepresentationSelect() {
|
|
161
178
|
return {
|
|
162
179
|
kind: 'Fragment',
|
|
163
180
|
version: VERSION,
|
|
@@ -193,22 +210,22 @@ function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
|
|
|
193
210
|
});
|
|
194
211
|
}
|
|
195
212
|
|
|
196
|
-
function select(luvio, params) {
|
|
197
|
-
return select$
|
|
213
|
+
function select$1(luvio, params) {
|
|
214
|
+
return select$2();
|
|
198
215
|
}
|
|
199
|
-
function keyBuilder$
|
|
216
|
+
function keyBuilder$3(luvio, params) {
|
|
200
217
|
return keyPrefix + '::ConversionEntriesRepresentation:(' + 'contactMap:' + params.queryParams.contactMap + ',' + 'leadMap:' + params.queryParams.leadMap + ',' + 'owner:' + params.queryParams.owner + ',' + 'personAccountMap:' + params.queryParams.personAccountMap + ',' + 'prospectId:' + params.queryParams.prospectId + ',' + 'status:' + params.queryParams.status + ')';
|
|
201
218
|
}
|
|
202
|
-
function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
|
|
203
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$
|
|
219
|
+
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
220
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$3(luvio, resourceParams));
|
|
204
221
|
}
|
|
205
|
-
function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
|
|
222
|
+
function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
|
|
206
223
|
const { body } = response;
|
|
207
|
-
const key = keyBuilder$
|
|
224
|
+
const key = keyBuilder$3(luvio, resourceParams);
|
|
208
225
|
luvio.storeIngest(key, ingest, body);
|
|
209
226
|
const snapshot = luvio.storeLookup({
|
|
210
227
|
recordId: key,
|
|
211
|
-
node: select(),
|
|
228
|
+
node: select$1(),
|
|
212
229
|
variables: {},
|
|
213
230
|
}, snapshotRefresh);
|
|
214
231
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -219,8 +236,8 @@ function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
219
236
|
deepFreeze(snapshot.data);
|
|
220
237
|
return snapshot;
|
|
221
238
|
}
|
|
222
|
-
function ingestError(luvio, params, error, snapshotRefresh) {
|
|
223
|
-
const key = keyBuilder$
|
|
239
|
+
function ingestError$1(luvio, params, error, snapshotRefresh) {
|
|
240
|
+
const key = keyBuilder$3(luvio, params);
|
|
224
241
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
225
242
|
const storeMetadataParams = {
|
|
226
243
|
ttl: TTL,
|
|
@@ -231,7 +248,7 @@ function ingestError(luvio, params, error, snapshotRefresh) {
|
|
|
231
248
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
232
249
|
return errorSnapshot;
|
|
233
250
|
}
|
|
234
|
-
function createResourceRequest(config) {
|
|
251
|
+
function createResourceRequest$1(config) {
|
|
235
252
|
const headers = {};
|
|
236
253
|
return {
|
|
237
254
|
baseUri: '/services/data/v64.0',
|
|
@@ -245,7 +262,7 @@ function createResourceRequest(config) {
|
|
|
245
262
|
};
|
|
246
263
|
}
|
|
247
264
|
|
|
248
|
-
const adapterName = 'getConversionEntries';
|
|
265
|
+
const adapterName$1 = 'getConversionEntries';
|
|
249
266
|
const getConversionEntries_ConfigPropertyMetadata = [
|
|
250
267
|
generateParamConfigMetadata('contactMap', false, 1 /* QueryParameter */, 0 /* String */),
|
|
251
268
|
generateParamConfigMetadata('leadMap', false, 1 /* QueryParameter */, 0 /* String */),
|
|
@@ -254,15 +271,169 @@ const getConversionEntries_ConfigPropertyMetadata = [
|
|
|
254
271
|
generateParamConfigMetadata('prospectId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
255
272
|
generateParamConfigMetadata('status', false, 1 /* QueryParameter */, 0 /* String */),
|
|
256
273
|
];
|
|
257
|
-
const getConversionEntries_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getConversionEntries_ConfigPropertyMetadata);
|
|
258
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
274
|
+
const getConversionEntries_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getConversionEntries_ConfigPropertyMetadata);
|
|
275
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$2(getConversionEntries_ConfigPropertyMetadata);
|
|
276
|
+
function keyBuilder$2(luvio, config) {
|
|
277
|
+
const resourceParams = createResourceParams$1(config);
|
|
278
|
+
return keyBuilder$3(luvio, resourceParams);
|
|
279
|
+
}
|
|
280
|
+
function typeCheckConfig$1(untrustedConfig) {
|
|
281
|
+
const config = {};
|
|
282
|
+
typeCheckConfig$2(untrustedConfig, config, getConversionEntries_ConfigPropertyMetadata);
|
|
283
|
+
return config;
|
|
284
|
+
}
|
|
285
|
+
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
286
|
+
if (!untrustedIsObject(untrustedConfig)) {
|
|
287
|
+
return null;
|
|
288
|
+
}
|
|
289
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
290
|
+
validateConfig(untrustedConfig, configPropertyNames);
|
|
291
|
+
}
|
|
292
|
+
const config = typeCheckConfig$1(untrustedConfig);
|
|
293
|
+
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
294
|
+
return null;
|
|
295
|
+
}
|
|
296
|
+
return config;
|
|
297
|
+
}
|
|
298
|
+
function adapterFragment$1(luvio, config) {
|
|
299
|
+
createResourceParams$1(config);
|
|
300
|
+
return select$1();
|
|
301
|
+
}
|
|
302
|
+
function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
|
|
303
|
+
const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
|
|
304
|
+
config,
|
|
305
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
306
|
+
});
|
|
307
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
308
|
+
}
|
|
309
|
+
function onFetchResponseError$1(luvio, config, resourceParams, response) {
|
|
310
|
+
const snapshot = ingestError$1(luvio, resourceParams, response, {
|
|
311
|
+
config,
|
|
312
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
313
|
+
});
|
|
314
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
315
|
+
}
|
|
316
|
+
function buildNetworkSnapshot$1(luvio, config, options) {
|
|
317
|
+
const resourceParams = createResourceParams$1(config);
|
|
318
|
+
const request = createResourceRequest$1(resourceParams);
|
|
319
|
+
return luvio.dispatchResourceRequest(request, options)
|
|
320
|
+
.then((response) => {
|
|
321
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
|
|
322
|
+
const cache = new StoreKeyMap();
|
|
323
|
+
getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
|
|
324
|
+
return cache;
|
|
325
|
+
});
|
|
326
|
+
}, (response) => {
|
|
327
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
|
|
328
|
+
});
|
|
329
|
+
}
|
|
330
|
+
function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
|
|
331
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
|
|
332
|
+
}
|
|
333
|
+
function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
|
|
334
|
+
const { luvio, config } = context;
|
|
335
|
+
const selector = {
|
|
336
|
+
recordId: keyBuilder$2(luvio, config),
|
|
337
|
+
node: adapterFragment$1(luvio, config),
|
|
338
|
+
variables: {},
|
|
339
|
+
};
|
|
340
|
+
const cacheSnapshot = storeLookup(selector, {
|
|
341
|
+
config,
|
|
342
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
343
|
+
});
|
|
344
|
+
return cacheSnapshot;
|
|
345
|
+
}
|
|
346
|
+
const getConversionEntriesAdapterFactory = (luvio) => function Prospect__getConversionEntries(untrustedConfig, requestContext) {
|
|
347
|
+
const config = validateAdapterConfig$1(untrustedConfig, getConversionEntries_ConfigPropertyNames);
|
|
348
|
+
// Invalid or incomplete config
|
|
349
|
+
if (config === null) {
|
|
350
|
+
return null;
|
|
351
|
+
}
|
|
352
|
+
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
353
|
+
buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
|
|
354
|
+
};
|
|
355
|
+
|
|
356
|
+
function select(luvio, params) {
|
|
357
|
+
return select$2();
|
|
358
|
+
}
|
|
359
|
+
function keyBuilder$1(luvio, params) {
|
|
360
|
+
return keyPrefix + '::ConversionEntriesRepresentation:(' + 'accountName:' + params.body.accountName + '::' + 'contactFirstName:' + params.body.contactFirstName + '::' + 'contactLastName:' + params.body.contactLastName + '::' + 'contactSalutation:' + params.body.contactSalutation + '::' + 'convertedStatus:' + params.body.convertedStatus + '::' + 'createOpportunity:' + params.body.createOpportunity + '::' + 'existingAccountId:' + params.body.existingAccountId + '::' + 'existingContactId:' + params.body.existingContactId + '::' + 'existingLeadId:' + params.body.existingLeadId + '::' + 'existingOpportunityId:' + params.body.existingOpportunityId + '::' + 'leadCompany:' + params.body.leadCompany + '::' + 'leadFirstName:' + params.body.leadFirstName + '::' + 'leadLastName:' + params.body.leadLastName + '::' + 'leadSalutation:' + params.body.leadSalutation + '::' + 'opportunityName:' + params.body.opportunityName + '::' + 'ownerId:' + params.body.ownerId + '::' + 'prospectId:' + params.body.prospectId + ')';
|
|
361
|
+
}
|
|
362
|
+
function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
|
|
363
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
|
|
364
|
+
}
|
|
365
|
+
function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
|
|
366
|
+
const { body } = response;
|
|
367
|
+
const key = keyBuilder$1(luvio, resourceParams);
|
|
368
|
+
luvio.storeIngest(key, ingest, body);
|
|
369
|
+
const snapshot = luvio.storeLookup({
|
|
370
|
+
recordId: key,
|
|
371
|
+
node: select(),
|
|
372
|
+
variables: {},
|
|
373
|
+
}, snapshotRefresh);
|
|
374
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
375
|
+
if (snapshot.state !== 'Fulfilled') {
|
|
376
|
+
throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
deepFreeze(snapshot.data);
|
|
380
|
+
return snapshot;
|
|
381
|
+
}
|
|
382
|
+
function ingestError(luvio, params, error, snapshotRefresh) {
|
|
383
|
+
const key = keyBuilder$1(luvio, params);
|
|
384
|
+
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
385
|
+
const storeMetadataParams = {
|
|
386
|
+
ttl: TTL,
|
|
387
|
+
namespace: keyPrefix,
|
|
388
|
+
version: VERSION,
|
|
389
|
+
representationName: RepresentationType
|
|
390
|
+
};
|
|
391
|
+
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
392
|
+
return errorSnapshot;
|
|
393
|
+
}
|
|
394
|
+
function createResourceRequest(config) {
|
|
395
|
+
const headers = {};
|
|
396
|
+
return {
|
|
397
|
+
baseUri: '/services/data/v64.0',
|
|
398
|
+
basePath: '/connect/ProspectConversion',
|
|
399
|
+
method: 'post',
|
|
400
|
+
body: config.body,
|
|
401
|
+
urlParams: {},
|
|
402
|
+
queryParams: {},
|
|
403
|
+
headers,
|
|
404
|
+
priority: 'normal',
|
|
405
|
+
};
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
const adapterName = 'getPostConversionEntries';
|
|
409
|
+
const getPostConversionEntries_ConfigPropertyMetadata = [
|
|
410
|
+
generateParamConfigMetadata('accountName', true, 2 /* Body */, 0 /* String */),
|
|
411
|
+
generateParamConfigMetadata('contactFirstName', true, 2 /* Body */, 0 /* String */),
|
|
412
|
+
generateParamConfigMetadata('contactLastName', true, 2 /* Body */, 0 /* String */),
|
|
413
|
+
generateParamConfigMetadata('contactSalutation', true, 2 /* Body */, 0 /* String */),
|
|
414
|
+
generateParamConfigMetadata('convertedStatus', true, 2 /* Body */, 0 /* String */),
|
|
415
|
+
generateParamConfigMetadata('createOpportunity', true, 2 /* Body */, 1 /* Boolean */),
|
|
416
|
+
generateParamConfigMetadata('existingAccountId', true, 2 /* Body */, 0 /* String */),
|
|
417
|
+
generateParamConfigMetadata('existingContactId', true, 2 /* Body */, 0 /* String */),
|
|
418
|
+
generateParamConfigMetadata('existingLeadId', true, 2 /* Body */, 0 /* String */),
|
|
419
|
+
generateParamConfigMetadata('existingOpportunityId', true, 2 /* Body */, 0 /* String */),
|
|
420
|
+
generateParamConfigMetadata('leadCompany', true, 2 /* Body */, 0 /* String */),
|
|
421
|
+
generateParamConfigMetadata('leadFirstName', true, 2 /* Body */, 0 /* String */),
|
|
422
|
+
generateParamConfigMetadata('leadLastName', true, 2 /* Body */, 0 /* String */),
|
|
423
|
+
generateParamConfigMetadata('leadSalutation', true, 2 /* Body */, 0 /* String */),
|
|
424
|
+
generateParamConfigMetadata('opportunityName', true, 2 /* Body */, 0 /* String */),
|
|
425
|
+
generateParamConfigMetadata('ownerId', true, 2 /* Body */, 0 /* String */),
|
|
426
|
+
generateParamConfigMetadata('prospectId', true, 2 /* Body */, 0 /* String */),
|
|
427
|
+
];
|
|
428
|
+
const getPostConversionEntries_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getPostConversionEntries_ConfigPropertyMetadata);
|
|
429
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$2(getPostConversionEntries_ConfigPropertyMetadata);
|
|
259
430
|
function keyBuilder(luvio, config) {
|
|
260
431
|
const resourceParams = createResourceParams(config);
|
|
261
432
|
return keyBuilder$1(luvio, resourceParams);
|
|
262
433
|
}
|
|
263
434
|
function typeCheckConfig(untrustedConfig) {
|
|
264
435
|
const config = {};
|
|
265
|
-
typeCheckConfig$
|
|
436
|
+
typeCheckConfig$2(untrustedConfig, config, getPostConversionEntries_ConfigPropertyMetadata);
|
|
266
437
|
return config;
|
|
267
438
|
}
|
|
268
439
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -311,7 +482,7 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
311
482
|
});
|
|
312
483
|
}
|
|
313
484
|
function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
|
|
314
|
-
return buildNetworkSnapshotCachePolicy$
|
|
485
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot, 'get', false);
|
|
315
486
|
}
|
|
316
487
|
function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
317
488
|
const { luvio, config } = context;
|
|
@@ -326,8 +497,8 @@ function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
|
326
497
|
});
|
|
327
498
|
return cacheSnapshot;
|
|
328
499
|
}
|
|
329
|
-
const
|
|
330
|
-
const config = validateAdapterConfig(untrustedConfig,
|
|
500
|
+
const getPostConversionEntriesAdapterFactory = (luvio) => function Prospect__getPostConversionEntries(untrustedConfig, requestContext) {
|
|
501
|
+
const config = validateAdapterConfig(untrustedConfig, getPostConversionEntries_ConfigPropertyNames);
|
|
331
502
|
// Invalid or incomplete config
|
|
332
503
|
if (config === null) {
|
|
333
504
|
return null;
|
|
@@ -336,4 +507,4 @@ const getConversionEntriesAdapterFactory = (luvio) => function Prospect__getConv
|
|
|
336
507
|
buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
|
|
337
508
|
};
|
|
338
509
|
|
|
339
|
-
export { getConversionEntriesAdapterFactory };
|
|
510
|
+
export { getConversionEntriesAdapterFactory, getPostConversionEntriesAdapterFactory };
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { AdapterConfigMetadata as $64$luvio_engine_AdapterConfigMetadata, Luvio as $64$luvio_engine_Luvio, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Fragment as $64$luvio_engine_Fragment, Snapshot as $64$luvio_engine_Snapshot, FetchResponse as $64$luvio_engine_FetchResponse, ErrorResponse as $64$luvio_engine_ErrorResponse, DispatchResourceRequestContext as $64$luvio_engine_DispatchResourceRequestContext, CoercedAdapterRequestContext as $64$luvio_engine_CoercedAdapterRequestContext, StoreLookup as $64$luvio_engine_StoreLookup, AdapterFactory as $64$luvio_engine_AdapterFactory } from '@luvio/engine';
|
|
2
|
+
import { Untrusted as adapter$45$utils_Untrusted, AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig } from './adapter-utils';
|
|
3
|
+
import { ResourceRequestConfig as resources_postConnectProspectConversion_ResourceRequestConfig } from '../resources/postConnectProspectConversion';
|
|
4
|
+
import { ConversionEntriesRepresentation as types_ConversionEntriesRepresentation_ConversionEntriesRepresentation } from '../types/ConversionEntriesRepresentation';
|
|
5
|
+
export declare const adapterName = "getPostConversionEntries";
|
|
6
|
+
export declare const getPostConversionEntries_ConfigPropertyMetadata: $64$luvio_engine_AdapterConfigMetadata[];
|
|
7
|
+
export declare const getPostConversionEntries_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
|
|
8
|
+
export interface GetPostConversionEntriesConfig {
|
|
9
|
+
accountName: string;
|
|
10
|
+
contactFirstName: string;
|
|
11
|
+
contactLastName: string;
|
|
12
|
+
contactSalutation: string;
|
|
13
|
+
convertedStatus: string;
|
|
14
|
+
createOpportunity: boolean;
|
|
15
|
+
existingAccountId: string;
|
|
16
|
+
existingContactId: string;
|
|
17
|
+
existingLeadId: string;
|
|
18
|
+
existingOpportunityId: string;
|
|
19
|
+
leadCompany: string;
|
|
20
|
+
leadFirstName: string;
|
|
21
|
+
leadLastName: string;
|
|
22
|
+
leadSalutation: string;
|
|
23
|
+
opportunityName: string;
|
|
24
|
+
ownerId: string;
|
|
25
|
+
prospectId: string;
|
|
26
|
+
}
|
|
27
|
+
export declare const createResourceParams: (config: GetPostConversionEntriesConfig) => resources_postConnectProspectConversion_ResourceRequestConfig;
|
|
28
|
+
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig): string;
|
|
29
|
+
export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig): $64$luvio_engine_NormalizedKeyMetadata;
|
|
30
|
+
export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<GetPostConversionEntriesConfig>): adapter$45$utils_Untrusted<GetPostConversionEntriesConfig>;
|
|
31
|
+
export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): GetPostConversionEntriesConfig | null;
|
|
32
|
+
export declare function adapterFragment(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig): $64$luvio_engine_Fragment;
|
|
33
|
+
export declare function buildCachedSnapshot(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig): $64$luvio_engine_Snapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, any>;
|
|
34
|
+
export declare function onFetchResponseSuccess(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig, resourceParams: resources_postConnectProspectConversion_ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation>): Promise<import("@luvio/engine").FulfilledSnapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, any>>;
|
|
35
|
+
export declare function onFetchResponseError(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig, resourceParams: resources_postConnectProspectConversion_ResourceRequestConfig, response: $64$luvio_engine_ErrorResponse): Promise<import("@luvio/engine").ErrorSnapshot>;
|
|
36
|
+
export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: GetPostConversionEntriesConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<$64$luvio_engine_Snapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, any>>;
|
|
37
|
+
export type BuildSnapshotContext = {
|
|
38
|
+
luvio: $64$luvio_engine_Luvio;
|
|
39
|
+
config: GetPostConversionEntriesConfig;
|
|
40
|
+
};
|
|
41
|
+
export declare function buildNetworkSnapshotCachePolicy(context: BuildSnapshotContext, coercedAdapterRequestContext: $64$luvio_engine_CoercedAdapterRequestContext): Promise<$64$luvio_engine_Snapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, any>>;
|
|
42
|
+
export declare function buildCachedSnapshotCachePolicy(context: BuildSnapshotContext, storeLookup: $64$luvio_engine_StoreLookup<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation>): $64$luvio_engine_Snapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, any>;
|
|
43
|
+
export declare const getPostConversionEntriesAdapterFactory: $64$luvio_engine_AdapterFactory<GetPostConversionEntriesConfig, types_ConversionEntriesRepresentation_ConversionEntriesRepresentation>;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
declare let getConversionEntries: any;
|
|
2
|
+
declare let getPostConversionEntries: any;
|
|
2
3
|
declare let getConversionEntries_imperative: any;
|
|
3
|
-
|
|
4
|
+
declare let getPostConversionEntries_imperative: any;
|
|
5
|
+
export { getConversionEntries, getPostConversionEntries, getConversionEntries_imperative, getPostConversionEntries_imperative, };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Luvio as $64$luvio_engine_Luvio, Fragment as $64$luvio_engine_Fragment, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, FetchResponse as $64$luvio_engine_FetchResponse, SnapshotRefresh as $64$luvio_engine_SnapshotRefresh, FulfilledSnapshot as $64$luvio_engine_FulfilledSnapshot, StaleSnapshot as $64$luvio_engine_StaleSnapshot, PendingSnapshot as $64$luvio_engine_PendingSnapshot, ErrorResponse as $64$luvio_engine_ErrorResponse, ErrorSnapshot as $64$luvio_engine_ErrorSnapshot, ResourceRequest as $64$luvio_engine_ResourceRequest } from '@luvio/engine';
|
|
2
|
+
import { ConversionEntriesRepresentation as types_ConversionEntriesRepresentation_ConversionEntriesRepresentation } from '../types/ConversionEntriesRepresentation';
|
|
3
|
+
export interface ResourceRequestConfig {
|
|
4
|
+
body: {
|
|
5
|
+
accountName: string;
|
|
6
|
+
contactFirstName: string;
|
|
7
|
+
contactLastName: string;
|
|
8
|
+
contactSalutation: string;
|
|
9
|
+
convertedStatus: string;
|
|
10
|
+
createOpportunity: boolean;
|
|
11
|
+
existingAccountId: string;
|
|
12
|
+
existingContactId: string;
|
|
13
|
+
existingLeadId: string;
|
|
14
|
+
existingOpportunityId: string;
|
|
15
|
+
leadCompany: string;
|
|
16
|
+
leadFirstName: string;
|
|
17
|
+
leadLastName: string;
|
|
18
|
+
leadSalutation: string;
|
|
19
|
+
opportunityName: string;
|
|
20
|
+
ownerId: string;
|
|
21
|
+
prospectId: string;
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
|
|
25
|
+
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): string;
|
|
26
|
+
export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_NormalizedKeyMetadata;
|
|
27
|
+
export declare function getResponseCacheKeys(storeKeyMap: any, luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: types_ConversionEntriesRepresentation_ConversionEntriesRepresentation): void;
|
|
28
|
+
export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation>, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation, any>;
|
|
29
|
+
export declare function ingestError(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig, error: $64$luvio_engine_ErrorResponse, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_ConversionEntriesRepresentation_ConversionEntriesRepresentation>): $64$luvio_engine_ErrorSnapshot;
|
|
30
|
+
export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
|
|
31
|
+
export default createResourceRequest;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ConversionEntryRepresentation as ConversionEntryRepresentation_ConversionEntryRepresentation } from './ConversionEntryRepresentation';
|
|
2
2
|
import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, BaseFragment as $64$luvio_engine_BaseFragment, ResourceIngest as $64$luvio_engine_ResourceIngest, StoreLink as $64$luvio_engine_StoreLink, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
|
|
3
3
|
export declare const TTL = 60000;
|
|
4
|
-
export declare const VERSION = "
|
|
4
|
+
export declare const VERSION = "407aa680ebc397cf36cc1727ac369a87";
|
|
5
5
|
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
6
6
|
export declare const RepresentationType: string;
|
|
7
7
|
export declare function normalize(input: ConversionEntriesRepresentation, existing: ConversionEntriesRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): ConversionEntriesRepresentationNormalized;
|
|
@@ -18,6 +18,8 @@ export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableSto
|
|
|
18
18
|
export interface ConversionEntriesRepresentationNormalized {
|
|
19
19
|
/** The list of entries */
|
|
20
20
|
conversionEntries: Array<$64$luvio_engine_StoreLink>;
|
|
21
|
+
/** The list of entries for post request */
|
|
22
|
+
postConversionEntries?: Array<$64$luvio_engine_StoreLink>;
|
|
21
23
|
}
|
|
22
24
|
/**
|
|
23
25
|
* Represents the list of entries in the Prospect to Lead Conversion
|
|
@@ -27,4 +29,5 @@ export interface ConversionEntriesRepresentationNormalized {
|
|
|
27
29
|
*/
|
|
28
30
|
export interface ConversionEntriesRepresentation {
|
|
29
31
|
conversionEntries: Array<ConversionEntryRepresentation_ConversionEntryRepresentation>;
|
|
32
|
+
postConversionEntries?: Array<ConversionEntryRepresentation_ConversionEntryRepresentation>;
|
|
30
33
|
}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { KeyMetadata as $64$luvio_engine_KeyMetadata, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Luvio as $64$luvio_engine_Luvio, IngestPath as $64$luvio_engine_IngestPath, Store as $64$luvio_engine_Store, FragmentSelection as $64$luvio_engine_FragmentSelection, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap } from '@luvio/engine';
|
|
2
|
+
export declare const TTL = 60000;
|
|
3
|
+
export declare const VERSION = "a37572f25d119ffd6df138c18478a2cf";
|
|
4
|
+
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
5
|
+
export declare const RepresentationType: string;
|
|
6
|
+
export interface KeyParams extends $64$luvio_engine_KeyMetadata {
|
|
7
|
+
prospectId: string;
|
|
8
|
+
}
|
|
9
|
+
export type ConversionPostInputRepresentationNormalizedKeyMetadata = KeyParams & $64$luvio_engine_NormalizedKeyMetadata;
|
|
10
|
+
export type PartialConversionPostInputRepresentationNormalizedKeyMetadata = Partial<KeyParams> & $64$luvio_engine_NormalizedKeyMetadata;
|
|
11
|
+
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: KeyParams): string;
|
|
12
|
+
export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: KeyParams): ConversionPostInputRepresentationNormalizedKeyMetadata;
|
|
13
|
+
export declare function keyBuilderFromType(luvio: $64$luvio_engine_Luvio, object: ConversionPostInputRepresentation): string;
|
|
14
|
+
export declare function keyBuilderFromType_StructuredKey(luvio: $64$luvio_engine_Luvio, object: ConversionPostInputRepresentation): $64$luvio_engine_NormalizedKeyMetadata;
|
|
15
|
+
export declare function normalize(input: ConversionPostInputRepresentation, existing: ConversionPostInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): ConversionPostInputRepresentationNormalized;
|
|
16
|
+
export declare const select: () => $64$luvio_engine_FragmentSelection;
|
|
17
|
+
export declare function equals(existing: ConversionPostInputRepresentationNormalized, incoming: ConversionPostInputRepresentationNormalized): boolean;
|
|
18
|
+
export declare const ingest: $64$luvio_engine_ResourceIngest;
|
|
19
|
+
export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableStoreKeyMetadataMap, luvio: $64$luvio_engine_Luvio, input: ConversionPostInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): void;
|
|
20
|
+
/**
|
|
21
|
+
* An Input Representation on Prospect Conversion Request
|
|
22
|
+
*
|
|
23
|
+
* Keys:
|
|
24
|
+
* prospectId (string): prospectId
|
|
25
|
+
*/
|
|
26
|
+
export interface ConversionPostInputRepresentationNormalized {
|
|
27
|
+
/** AccountName input for Conversion to Account */
|
|
28
|
+
accountName: string;
|
|
29
|
+
/** FirstName input for Conversion to Contact */
|
|
30
|
+
contactFirstName: string;
|
|
31
|
+
/** LastName input for Conversion to Contact */
|
|
32
|
+
contactLastName: string;
|
|
33
|
+
/** Salutation input for Conversion to Contact */
|
|
34
|
+
contactSalutation: string;
|
|
35
|
+
/** Converted Status */
|
|
36
|
+
convertedStatus: string;
|
|
37
|
+
/** Boolean which decides whether the prospect should be allowed to convert to opportunity */
|
|
38
|
+
createOpportunity: boolean;
|
|
39
|
+
/** Existing Account ID for conversion to Account */
|
|
40
|
+
existingAccountId: string;
|
|
41
|
+
/** Existing Contact ID for conversion to Contact */
|
|
42
|
+
existingContactId: string;
|
|
43
|
+
/** Existing Lead ID for conversion to Lead */
|
|
44
|
+
existingLeadId: string;
|
|
45
|
+
/** Existing Opportunity Id for conversion to Opportunity when CreateOpportunity is true */
|
|
46
|
+
existingOpportunityId: string;
|
|
47
|
+
/** Company input for Conversion to Lead */
|
|
48
|
+
leadCompany: string;
|
|
49
|
+
/** FirstName for Conversion to Lead */
|
|
50
|
+
leadFirstName: string;
|
|
51
|
+
/** LastName input for Conversion to Lead */
|
|
52
|
+
leadLastName: string;
|
|
53
|
+
/** Salutation input for Conversion to Lead */
|
|
54
|
+
leadSalutation: string;
|
|
55
|
+
/** OpportunityName for conversion to Opportunity when CreateOpportunity is true */
|
|
56
|
+
opportunityName: string;
|
|
57
|
+
/** Owner ID which will be assigned to the entity post conversion */
|
|
58
|
+
ownerId: string;
|
|
59
|
+
/** ProspectId */
|
|
60
|
+
prospectId: string;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* An Input Representation on Prospect Conversion Request
|
|
64
|
+
*
|
|
65
|
+
* Keys:
|
|
66
|
+
* prospectId (string): prospectId
|
|
67
|
+
*/
|
|
68
|
+
export interface ConversionPostInputRepresentation {
|
|
69
|
+
accountName: string;
|
|
70
|
+
contactFirstName: string;
|
|
71
|
+
contactLastName: string;
|
|
72
|
+
contactSalutation: string;
|
|
73
|
+
convertedStatus: string;
|
|
74
|
+
createOpportunity: boolean;
|
|
75
|
+
existingAccountId: string;
|
|
76
|
+
existingContactId: string;
|
|
77
|
+
existingLeadId: string;
|
|
78
|
+
existingOpportunityId: string;
|
|
79
|
+
leadCompany: string;
|
|
80
|
+
leadFirstName: string;
|
|
81
|
+
leadLastName: string;
|
|
82
|
+
leadSalutation: string;
|
|
83
|
+
opportunityName: string;
|
|
84
|
+
ownerId: string;
|
|
85
|
+
prospectId: string;
|
|
86
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-adapters-marketing-prospect",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.348.0",
|
|
4
4
|
"description": "Prospect Conversion to Leads",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"main": "dist/es/es2018/marketing-prospect.js",
|
|
@@ -40,10 +40,10 @@
|
|
|
40
40
|
"test:unit": "jest"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@salesforce/lds-bindings": "^1.
|
|
43
|
+
"@salesforce/lds-bindings": "^1.348.0"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"@salesforce/lds-compiler-plugins": "^1.
|
|
46
|
+
"@salesforce/lds-compiler-plugins": "^1.348.0"
|
|
47
47
|
},
|
|
48
48
|
"nx": {
|
|
49
49
|
"targets": {
|
package/sfdc/index.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
/* proxy-compat-disable */
|
|
15
15
|
import { createInstrumentedAdapter, createLDSAdapter, createWireAdapterConstructor, createImperativeAdapter } from 'force/ldsBindings';
|
|
16
16
|
import { withDefaultLuvio } from 'force/ldsEngine';
|
|
17
|
-
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$
|
|
17
|
+
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$2, typeCheckConfig as typeCheckConfig$2, StoreKeyMap, createResourceParams as createResourceParams$2 } from 'force/luvioEngine';
|
|
18
18
|
|
|
19
19
|
const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
|
|
20
20
|
const { keys: ObjectKeys, create: ObjectCreate } = Object;
|
|
@@ -139,7 +139,7 @@ function validate$1(obj, path = 'ConversionEntryRepresentation') {
|
|
|
139
139
|
}
|
|
140
140
|
|
|
141
141
|
const TTL = 60000;
|
|
142
|
-
const VERSION = "
|
|
142
|
+
const VERSION = "407aa680ebc397cf36cc1727ac369a87";
|
|
143
143
|
function validate(obj, path = 'ConversionEntriesRepresentation') {
|
|
144
144
|
const v_error = (() => {
|
|
145
145
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
@@ -160,6 +160,23 @@ function validate(obj, path = 'ConversionEntriesRepresentation') {
|
|
|
160
160
|
return new TypeError(message);
|
|
161
161
|
}
|
|
162
162
|
}
|
|
163
|
+
if (obj.postConversionEntries !== undefined) {
|
|
164
|
+
const obj_postConversionEntries = obj.postConversionEntries;
|
|
165
|
+
const path_postConversionEntries = path + '.postConversionEntries';
|
|
166
|
+
if (!ArrayIsArray(obj_postConversionEntries)) {
|
|
167
|
+
return new TypeError('Expected "array" but received "' + typeof obj_postConversionEntries + '" (at "' + path_postConversionEntries + '")');
|
|
168
|
+
}
|
|
169
|
+
for (let i = 0; i < obj_postConversionEntries.length; i++) {
|
|
170
|
+
const obj_postConversionEntries_item = obj_postConversionEntries[i];
|
|
171
|
+
const path_postConversionEntries_item = path_postConversionEntries + '[' + i + ']';
|
|
172
|
+
const referencepath_postConversionEntries_itemValidationError = validate$1(obj_postConversionEntries_item, path_postConversionEntries_item);
|
|
173
|
+
if (referencepath_postConversionEntries_itemValidationError !== null) {
|
|
174
|
+
let message = 'Object doesn\'t match ConversionEntryRepresentation (at "' + path_postConversionEntries_item + '")\n';
|
|
175
|
+
message += referencepath_postConversionEntries_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
176
|
+
return new TypeError(message);
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
}
|
|
163
180
|
})();
|
|
164
181
|
return v_error === undefined ? null : v_error;
|
|
165
182
|
}
|
|
@@ -167,7 +184,7 @@ const RepresentationType = 'ConversionEntriesRepresentation';
|
|
|
167
184
|
function normalize(input, existing, path, luvio, store, timestamp) {
|
|
168
185
|
return input;
|
|
169
186
|
}
|
|
170
|
-
const select$
|
|
187
|
+
const select$2 = function ConversionEntriesRepresentationSelect() {
|
|
171
188
|
return {
|
|
172
189
|
kind: 'Fragment',
|
|
173
190
|
version: VERSION,
|
|
@@ -203,22 +220,22 @@ function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
|
|
|
203
220
|
});
|
|
204
221
|
}
|
|
205
222
|
|
|
206
|
-
function select(luvio, params) {
|
|
207
|
-
return select$
|
|
223
|
+
function select$1(luvio, params) {
|
|
224
|
+
return select$2();
|
|
208
225
|
}
|
|
209
|
-
function keyBuilder$
|
|
226
|
+
function keyBuilder$3(luvio, params) {
|
|
210
227
|
return keyPrefix + '::ConversionEntriesRepresentation:(' + 'contactMap:' + params.queryParams.contactMap + ',' + 'leadMap:' + params.queryParams.leadMap + ',' + 'owner:' + params.queryParams.owner + ',' + 'personAccountMap:' + params.queryParams.personAccountMap + ',' + 'prospectId:' + params.queryParams.prospectId + ',' + 'status:' + params.queryParams.status + ')';
|
|
211
228
|
}
|
|
212
|
-
function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
|
|
213
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$
|
|
229
|
+
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
230
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$3(luvio, resourceParams));
|
|
214
231
|
}
|
|
215
|
-
function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
|
|
232
|
+
function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
|
|
216
233
|
const { body } = response;
|
|
217
|
-
const key = keyBuilder$
|
|
234
|
+
const key = keyBuilder$3(luvio, resourceParams);
|
|
218
235
|
luvio.storeIngest(key, ingest, body);
|
|
219
236
|
const snapshot = luvio.storeLookup({
|
|
220
237
|
recordId: key,
|
|
221
|
-
node: select(),
|
|
238
|
+
node: select$1(),
|
|
222
239
|
variables: {},
|
|
223
240
|
}, snapshotRefresh);
|
|
224
241
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -229,8 +246,8 @@ function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
229
246
|
deepFreeze(snapshot.data);
|
|
230
247
|
return snapshot;
|
|
231
248
|
}
|
|
232
|
-
function ingestError(luvio, params, error, snapshotRefresh) {
|
|
233
|
-
const key = keyBuilder$
|
|
249
|
+
function ingestError$1(luvio, params, error, snapshotRefresh) {
|
|
250
|
+
const key = keyBuilder$3(luvio, params);
|
|
234
251
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
235
252
|
const storeMetadataParams = {
|
|
236
253
|
ttl: TTL,
|
|
@@ -241,7 +258,7 @@ function ingestError(luvio, params, error, snapshotRefresh) {
|
|
|
241
258
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
242
259
|
return errorSnapshot;
|
|
243
260
|
}
|
|
244
|
-
function createResourceRequest(config) {
|
|
261
|
+
function createResourceRequest$1(config) {
|
|
245
262
|
const headers = {};
|
|
246
263
|
return {
|
|
247
264
|
baseUri: '/services/data/v64.0',
|
|
@@ -255,7 +272,7 @@ function createResourceRequest(config) {
|
|
|
255
272
|
};
|
|
256
273
|
}
|
|
257
274
|
|
|
258
|
-
const adapterName = 'getConversionEntries';
|
|
275
|
+
const adapterName$1 = 'getConversionEntries';
|
|
259
276
|
const getConversionEntries_ConfigPropertyMetadata = [
|
|
260
277
|
generateParamConfigMetadata('contactMap', false, 1 /* QueryParameter */, 0 /* String */),
|
|
261
278
|
generateParamConfigMetadata('leadMap', false, 1 /* QueryParameter */, 0 /* String */),
|
|
@@ -264,15 +281,169 @@ const getConversionEntries_ConfigPropertyMetadata = [
|
|
|
264
281
|
generateParamConfigMetadata('prospectId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
265
282
|
generateParamConfigMetadata('status', false, 1 /* QueryParameter */, 0 /* String */),
|
|
266
283
|
];
|
|
267
|
-
const getConversionEntries_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getConversionEntries_ConfigPropertyMetadata);
|
|
268
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
284
|
+
const getConversionEntries_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getConversionEntries_ConfigPropertyMetadata);
|
|
285
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$2(getConversionEntries_ConfigPropertyMetadata);
|
|
286
|
+
function keyBuilder$2(luvio, config) {
|
|
287
|
+
const resourceParams = createResourceParams$1(config);
|
|
288
|
+
return keyBuilder$3(luvio, resourceParams);
|
|
289
|
+
}
|
|
290
|
+
function typeCheckConfig$1(untrustedConfig) {
|
|
291
|
+
const config = {};
|
|
292
|
+
typeCheckConfig$2(untrustedConfig, config, getConversionEntries_ConfigPropertyMetadata);
|
|
293
|
+
return config;
|
|
294
|
+
}
|
|
295
|
+
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
296
|
+
if (!untrustedIsObject(untrustedConfig)) {
|
|
297
|
+
return null;
|
|
298
|
+
}
|
|
299
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
300
|
+
validateConfig(untrustedConfig, configPropertyNames);
|
|
301
|
+
}
|
|
302
|
+
const config = typeCheckConfig$1(untrustedConfig);
|
|
303
|
+
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
304
|
+
return null;
|
|
305
|
+
}
|
|
306
|
+
return config;
|
|
307
|
+
}
|
|
308
|
+
function adapterFragment$1(luvio, config) {
|
|
309
|
+
createResourceParams$1(config);
|
|
310
|
+
return select$1();
|
|
311
|
+
}
|
|
312
|
+
function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
|
|
313
|
+
const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
|
|
314
|
+
config,
|
|
315
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
316
|
+
});
|
|
317
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
318
|
+
}
|
|
319
|
+
function onFetchResponseError$1(luvio, config, resourceParams, response) {
|
|
320
|
+
const snapshot = ingestError$1(luvio, resourceParams, response, {
|
|
321
|
+
config,
|
|
322
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
323
|
+
});
|
|
324
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
325
|
+
}
|
|
326
|
+
function buildNetworkSnapshot$1(luvio, config, options) {
|
|
327
|
+
const resourceParams = createResourceParams$1(config);
|
|
328
|
+
const request = createResourceRequest$1(resourceParams);
|
|
329
|
+
return luvio.dispatchResourceRequest(request, options)
|
|
330
|
+
.then((response) => {
|
|
331
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
|
|
332
|
+
const cache = new StoreKeyMap();
|
|
333
|
+
getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
|
|
334
|
+
return cache;
|
|
335
|
+
});
|
|
336
|
+
}, (response) => {
|
|
337
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
|
|
338
|
+
});
|
|
339
|
+
}
|
|
340
|
+
function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
|
|
341
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
|
|
342
|
+
}
|
|
343
|
+
function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
|
|
344
|
+
const { luvio, config } = context;
|
|
345
|
+
const selector = {
|
|
346
|
+
recordId: keyBuilder$2(luvio, config),
|
|
347
|
+
node: adapterFragment$1(luvio, config),
|
|
348
|
+
variables: {},
|
|
349
|
+
};
|
|
350
|
+
const cacheSnapshot = storeLookup(selector, {
|
|
351
|
+
config,
|
|
352
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
353
|
+
});
|
|
354
|
+
return cacheSnapshot;
|
|
355
|
+
}
|
|
356
|
+
const getConversionEntriesAdapterFactory = (luvio) => function Prospect__getConversionEntries(untrustedConfig, requestContext) {
|
|
357
|
+
const config = validateAdapterConfig$1(untrustedConfig, getConversionEntries_ConfigPropertyNames);
|
|
358
|
+
// Invalid or incomplete config
|
|
359
|
+
if (config === null) {
|
|
360
|
+
return null;
|
|
361
|
+
}
|
|
362
|
+
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
363
|
+
buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
|
|
364
|
+
};
|
|
365
|
+
|
|
366
|
+
function select(luvio, params) {
|
|
367
|
+
return select$2();
|
|
368
|
+
}
|
|
369
|
+
function keyBuilder$1(luvio, params) {
|
|
370
|
+
return keyPrefix + '::ConversionEntriesRepresentation:(' + 'accountName:' + params.body.accountName + '::' + 'contactFirstName:' + params.body.contactFirstName + '::' + 'contactLastName:' + params.body.contactLastName + '::' + 'contactSalutation:' + params.body.contactSalutation + '::' + 'convertedStatus:' + params.body.convertedStatus + '::' + 'createOpportunity:' + params.body.createOpportunity + '::' + 'existingAccountId:' + params.body.existingAccountId + '::' + 'existingContactId:' + params.body.existingContactId + '::' + 'existingLeadId:' + params.body.existingLeadId + '::' + 'existingOpportunityId:' + params.body.existingOpportunityId + '::' + 'leadCompany:' + params.body.leadCompany + '::' + 'leadFirstName:' + params.body.leadFirstName + '::' + 'leadLastName:' + params.body.leadLastName + '::' + 'leadSalutation:' + params.body.leadSalutation + '::' + 'opportunityName:' + params.body.opportunityName + '::' + 'ownerId:' + params.body.ownerId + '::' + 'prospectId:' + params.body.prospectId + ')';
|
|
371
|
+
}
|
|
372
|
+
function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
|
|
373
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
|
|
374
|
+
}
|
|
375
|
+
function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
|
|
376
|
+
const { body } = response;
|
|
377
|
+
const key = keyBuilder$1(luvio, resourceParams);
|
|
378
|
+
luvio.storeIngest(key, ingest, body);
|
|
379
|
+
const snapshot = luvio.storeLookup({
|
|
380
|
+
recordId: key,
|
|
381
|
+
node: select(),
|
|
382
|
+
variables: {},
|
|
383
|
+
}, snapshotRefresh);
|
|
384
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
385
|
+
if (snapshot.state !== 'Fulfilled') {
|
|
386
|
+
throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
deepFreeze(snapshot.data);
|
|
390
|
+
return snapshot;
|
|
391
|
+
}
|
|
392
|
+
function ingestError(luvio, params, error, snapshotRefresh) {
|
|
393
|
+
const key = keyBuilder$1(luvio, params);
|
|
394
|
+
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
395
|
+
const storeMetadataParams = {
|
|
396
|
+
ttl: TTL,
|
|
397
|
+
namespace: keyPrefix,
|
|
398
|
+
version: VERSION,
|
|
399
|
+
representationName: RepresentationType
|
|
400
|
+
};
|
|
401
|
+
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
402
|
+
return errorSnapshot;
|
|
403
|
+
}
|
|
404
|
+
function createResourceRequest(config) {
|
|
405
|
+
const headers = {};
|
|
406
|
+
return {
|
|
407
|
+
baseUri: '/services/data/v64.0',
|
|
408
|
+
basePath: '/connect/ProspectConversion',
|
|
409
|
+
method: 'post',
|
|
410
|
+
body: config.body,
|
|
411
|
+
urlParams: {},
|
|
412
|
+
queryParams: {},
|
|
413
|
+
headers,
|
|
414
|
+
priority: 'normal',
|
|
415
|
+
};
|
|
416
|
+
}
|
|
417
|
+
|
|
418
|
+
const adapterName = 'getPostConversionEntries';
|
|
419
|
+
const getPostConversionEntries_ConfigPropertyMetadata = [
|
|
420
|
+
generateParamConfigMetadata('accountName', true, 2 /* Body */, 0 /* String */),
|
|
421
|
+
generateParamConfigMetadata('contactFirstName', true, 2 /* Body */, 0 /* String */),
|
|
422
|
+
generateParamConfigMetadata('contactLastName', true, 2 /* Body */, 0 /* String */),
|
|
423
|
+
generateParamConfigMetadata('contactSalutation', true, 2 /* Body */, 0 /* String */),
|
|
424
|
+
generateParamConfigMetadata('convertedStatus', true, 2 /* Body */, 0 /* String */),
|
|
425
|
+
generateParamConfigMetadata('createOpportunity', true, 2 /* Body */, 1 /* Boolean */),
|
|
426
|
+
generateParamConfigMetadata('existingAccountId', true, 2 /* Body */, 0 /* String */),
|
|
427
|
+
generateParamConfigMetadata('existingContactId', true, 2 /* Body */, 0 /* String */),
|
|
428
|
+
generateParamConfigMetadata('existingLeadId', true, 2 /* Body */, 0 /* String */),
|
|
429
|
+
generateParamConfigMetadata('existingOpportunityId', true, 2 /* Body */, 0 /* String */),
|
|
430
|
+
generateParamConfigMetadata('leadCompany', true, 2 /* Body */, 0 /* String */),
|
|
431
|
+
generateParamConfigMetadata('leadFirstName', true, 2 /* Body */, 0 /* String */),
|
|
432
|
+
generateParamConfigMetadata('leadLastName', true, 2 /* Body */, 0 /* String */),
|
|
433
|
+
generateParamConfigMetadata('leadSalutation', true, 2 /* Body */, 0 /* String */),
|
|
434
|
+
generateParamConfigMetadata('opportunityName', true, 2 /* Body */, 0 /* String */),
|
|
435
|
+
generateParamConfigMetadata('ownerId', true, 2 /* Body */, 0 /* String */),
|
|
436
|
+
generateParamConfigMetadata('prospectId', true, 2 /* Body */, 0 /* String */),
|
|
437
|
+
];
|
|
438
|
+
const getPostConversionEntries_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getPostConversionEntries_ConfigPropertyMetadata);
|
|
439
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$2(getPostConversionEntries_ConfigPropertyMetadata);
|
|
269
440
|
function keyBuilder(luvio, config) {
|
|
270
441
|
const resourceParams = createResourceParams(config);
|
|
271
442
|
return keyBuilder$1(luvio, resourceParams);
|
|
272
443
|
}
|
|
273
444
|
function typeCheckConfig(untrustedConfig) {
|
|
274
445
|
const config = {};
|
|
275
|
-
typeCheckConfig$
|
|
446
|
+
typeCheckConfig$2(untrustedConfig, config, getPostConversionEntries_ConfigPropertyMetadata);
|
|
276
447
|
return config;
|
|
277
448
|
}
|
|
278
449
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -321,7 +492,7 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
321
492
|
});
|
|
322
493
|
}
|
|
323
494
|
function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
|
|
324
|
-
return buildNetworkSnapshotCachePolicy$
|
|
495
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot, 'get', false);
|
|
325
496
|
}
|
|
326
497
|
function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
327
498
|
const { luvio, config } = context;
|
|
@@ -336,8 +507,8 @@ function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
|
336
507
|
});
|
|
337
508
|
return cacheSnapshot;
|
|
338
509
|
}
|
|
339
|
-
const
|
|
340
|
-
const config = validateAdapterConfig(untrustedConfig,
|
|
510
|
+
const getPostConversionEntriesAdapterFactory = (luvio) => function Prospect__getPostConversionEntries(untrustedConfig, requestContext) {
|
|
511
|
+
const config = validateAdapterConfig(untrustedConfig, getPostConversionEntries_ConfigPropertyNames);
|
|
341
512
|
// Invalid or incomplete config
|
|
342
513
|
if (config === null) {
|
|
343
514
|
return null;
|
|
@@ -347,28 +518,43 @@ const getConversionEntriesAdapterFactory = (luvio) => function Prospect__getConv
|
|
|
347
518
|
};
|
|
348
519
|
|
|
349
520
|
let getConversionEntries;
|
|
521
|
+
let getPostConversionEntries;
|
|
350
522
|
// Imperative GET Adapters
|
|
351
523
|
let getConversionEntries_imperative;
|
|
524
|
+
let getPostConversionEntries_imperative;
|
|
352
525
|
// Adapter Metadata
|
|
353
526
|
const getConversionEntriesMetadata = {
|
|
354
527
|
apiFamily: 'Prospect',
|
|
355
528
|
name: 'getConversionEntries',
|
|
356
529
|
ttl: 60000,
|
|
357
530
|
};
|
|
531
|
+
const getPostConversionEntriesMetadata = {
|
|
532
|
+
apiFamily: 'Prospect',
|
|
533
|
+
name: 'getPostConversionEntries',
|
|
534
|
+
ttl: 60000,
|
|
535
|
+
};
|
|
358
536
|
// Notify Update Available
|
|
359
537
|
function bindExportsTo(luvio) {
|
|
360
538
|
// LDS Adapters
|
|
361
539
|
const getConversionEntries_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getConversionEntries', getConversionEntriesAdapterFactory), getConversionEntriesMetadata);
|
|
540
|
+
const getPostConversionEntries_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPostConversionEntries', getPostConversionEntriesAdapterFactory), getPostConversionEntriesMetadata);
|
|
362
541
|
return {
|
|
363
542
|
getConversionEntries: createWireAdapterConstructor(luvio, getConversionEntries_ldsAdapter, getConversionEntriesMetadata),
|
|
543
|
+
getPostConversionEntries: createWireAdapterConstructor(luvio, getPostConversionEntries_ldsAdapter, getPostConversionEntriesMetadata),
|
|
364
544
|
// Imperative GET Adapters
|
|
365
545
|
getConversionEntries_imperative: createImperativeAdapter(luvio, getConversionEntries_ldsAdapter, getConversionEntriesMetadata),
|
|
546
|
+
getPostConversionEntries_imperative: createImperativeAdapter(luvio, getPostConversionEntries_ldsAdapter, getPostConversionEntriesMetadata),
|
|
366
547
|
// Notify Update Availables
|
|
367
548
|
};
|
|
368
549
|
}
|
|
369
550
|
withDefaultLuvio((luvio) => {
|
|
370
|
-
({
|
|
551
|
+
({
|
|
552
|
+
getConversionEntries,
|
|
553
|
+
getPostConversionEntries,
|
|
554
|
+
getConversionEntries_imperative,
|
|
555
|
+
getPostConversionEntries_imperative,
|
|
556
|
+
} = bindExportsTo(luvio));
|
|
371
557
|
});
|
|
372
558
|
|
|
373
|
-
export { getConversionEntries, getConversionEntries_imperative };
|
|
374
|
-
// version: 1.
|
|
559
|
+
export { getConversionEntries, getConversionEntries_imperative, getPostConversionEntries, getPostConversionEntries_imperative };
|
|
560
|
+
// version: 1.348.0-4aa8c0c0cb
|
package/src/raml/api.raml
CHANGED
|
@@ -34,6 +34,12 @@ types:
|
|
|
34
34
|
type: array
|
|
35
35
|
items:
|
|
36
36
|
type: ConversionEntryRepresentation
|
|
37
|
+
postConversionEntries:
|
|
38
|
+
description: The list of entries for post request
|
|
39
|
+
type: array
|
|
40
|
+
required: false
|
|
41
|
+
items:
|
|
42
|
+
type: ConversionEntryRepresentation
|
|
37
43
|
ConversionEntryRepresentation:
|
|
38
44
|
description: Represents an individual entry in the Conversion
|
|
39
45
|
type: object
|
|
@@ -62,6 +68,64 @@ types:
|
|
|
62
68
|
prospectId:
|
|
63
69
|
description: prospectId
|
|
64
70
|
type: string
|
|
71
|
+
ConversionPostInputRepresentation:
|
|
72
|
+
description: An Input Representation on Prospect Conversion Request
|
|
73
|
+
type: object
|
|
74
|
+
properties:
|
|
75
|
+
accountName:
|
|
76
|
+
description: AccountName input for Conversion to Account
|
|
77
|
+
type: string
|
|
78
|
+
contactFirstName:
|
|
79
|
+
description: FirstName input for Conversion to Contact
|
|
80
|
+
type: string
|
|
81
|
+
contactLastName:
|
|
82
|
+
description: LastName input for Conversion to Contact
|
|
83
|
+
type: string
|
|
84
|
+
contactSalutation:
|
|
85
|
+
description: Salutation input for Conversion to Contact
|
|
86
|
+
type: string
|
|
87
|
+
convertedStatus:
|
|
88
|
+
description: Converted Status
|
|
89
|
+
type: string
|
|
90
|
+
createOpportunity:
|
|
91
|
+
description: Boolean which decides whether the prospect should be allowed
|
|
92
|
+
to convert to opportunity
|
|
93
|
+
type: boolean
|
|
94
|
+
existingAccountId:
|
|
95
|
+
description: Existing Account ID for conversion to Account
|
|
96
|
+
type: string
|
|
97
|
+
existingContactId:
|
|
98
|
+
description: Existing Contact ID for conversion to Contact
|
|
99
|
+
type: string
|
|
100
|
+
existingLeadId:
|
|
101
|
+
description: Existing Lead ID for conversion to Lead
|
|
102
|
+
type: string
|
|
103
|
+
existingOpportunityId:
|
|
104
|
+
description: Existing Opportunity Id for conversion to Opportunity when CreateOpportunity
|
|
105
|
+
is true
|
|
106
|
+
type: string
|
|
107
|
+
leadCompany:
|
|
108
|
+
description: Company input for Conversion to Lead
|
|
109
|
+
type: string
|
|
110
|
+
leadFirstName:
|
|
111
|
+
description: FirstName for Conversion to Lead
|
|
112
|
+
type: string
|
|
113
|
+
leadLastName:
|
|
114
|
+
description: LastName input for Conversion to Lead
|
|
115
|
+
type: string
|
|
116
|
+
leadSalutation:
|
|
117
|
+
description: Salutation input for Conversion to Lead
|
|
118
|
+
type: string
|
|
119
|
+
opportunityName:
|
|
120
|
+
description: OpportunityName for conversion to Opportunity when CreateOpportunity
|
|
121
|
+
is true
|
|
122
|
+
type: string
|
|
123
|
+
ownerId:
|
|
124
|
+
description: Owner ID which will be assigned to the entity post conversion
|
|
125
|
+
type: string
|
|
126
|
+
prospectId:
|
|
127
|
+
description: ProspectId
|
|
128
|
+
type: string
|
|
65
129
|
/connect/ProspectConversion:
|
|
66
130
|
get:
|
|
67
131
|
displayName: getProspectEntries
|
|
@@ -91,3 +155,16 @@ types:
|
|
|
91
155
|
status:
|
|
92
156
|
type: string
|
|
93
157
|
required: false
|
|
158
|
+
post:
|
|
159
|
+
displayName: postProspectEntries
|
|
160
|
+
description: Convert Prospect
|
|
161
|
+
responses:
|
|
162
|
+
'200':
|
|
163
|
+
description: Success
|
|
164
|
+
body:
|
|
165
|
+
application/json:
|
|
166
|
+
type: ConversionEntriesRepresentation
|
|
167
|
+
body:
|
|
168
|
+
application/json:
|
|
169
|
+
type: ConversionPostInputRepresentation
|
|
170
|
+
(oas-body-name): conversionRequestBody
|
package/src/raml/luvio.raml
CHANGED
|
@@ -15,7 +15,15 @@ types:
|
|
|
15
15
|
(luvio.key):
|
|
16
16
|
leadId: leadId
|
|
17
17
|
(luvio.ttl): 60000
|
|
18
|
+
ConversionPostInputRepresentation:
|
|
19
|
+
(luvio.key):
|
|
20
|
+
prospectId: prospectId
|
|
21
|
+
(luvio.ttl): 60000
|
|
18
22
|
/connect/ProspectConversion:
|
|
19
23
|
get:
|
|
20
24
|
(luvio.adapter):
|
|
21
25
|
name: getConversionEntries
|
|
26
|
+
post:
|
|
27
|
+
(luvio.method): get
|
|
28
|
+
(luvio.adapter):
|
|
29
|
+
name: getPostConversionEntries
|