@coveo/push-api-client 1.6.8 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/dist/definitions/environment.d.ts +3 -3
  2. package/dist/definitions/fieldAnalyser/fieldAnalyser.d.ts +2 -10
  3. package/dist/definitions/fieldAnalyser/{utils.d.ts → fieldUtils.d.ts} +0 -0
  4. package/dist/definitions/fieldAnalyser/{utils.spec.d.ts → fieldsUtils.spec.d.ts} +0 -0
  5. package/dist/definitions/fieldAnalyser/inconsistencies.d.ts +1 -1
  6. package/dist/definitions/fieldAnalyser/typeUtils.d.ts +3 -0
  7. package/dist/definitions/{source.spec.d.ts → fieldAnalyser/typeUtils.spec.d.ts} +0 -0
  8. package/dist/definitions/help/fileConsumer.d.ts +26 -0
  9. package/dist/definitions/help/fileConsumer.spec.d.ts +1 -0
  10. package/dist/definitions/index.d.ts +6 -2
  11. package/dist/definitions/interfaces.d.ts +36 -0
  12. package/dist/definitions/source/batchUpdateDocumentsFromFile.d.ts +10 -0
  13. package/dist/definitions/{source.d.ts → source/push.d.ts} +34 -69
  14. package/dist/definitions/source/push.spec.d.ts +1 -0
  15. package/dist/definitions/source/securityIdenty.d.ts +42 -0
  16. package/dist/definitions/source/source.d.ts +5 -0
  17. package/dist/docs/assets/search.js +1 -1
  18. package/dist/docs/classes/AnySecurityIdentityBuilder.html +3 -3
  19. package/dist/docs/classes/DocumentBuilder.html +17 -17
  20. package/dist/docs/classes/FieldAnalyser.html +3 -3
  21. package/dist/docs/classes/GroupSecurityIdentityBuilder.html +3 -3
  22. package/dist/docs/classes/PushSource.html +43 -0
  23. package/dist/docs/classes/UserSecurityIdentityBuilder.html +3 -3
  24. package/dist/docs/classes/VirtualGroupSecurityIdentityBuilder.html +3 -3
  25. package/dist/docs/enums/PlatformEnvironment.html +1 -1
  26. package/dist/docs/enums/Region.html +1 -1
  27. package/dist/docs/enums/SourceVisibility.html +1 -1
  28. package/dist/docs/index.html +1 -1
  29. package/dist/docs/interfaces/BatchUpdateDocuments.html +1 -1
  30. package/dist/docs/interfaces/Document.html +14 -14
  31. package/dist/docs/interfaces/SecurityIdentity.html +4 -4
  32. package/dist/docs/interfaces/SecurityIdentityBuilder.html +1 -1
  33. package/dist/docs/interfaces/UploadBatchCallbackData.html +1 -1
  34. package/dist/docs/modules.html +3 -2
  35. package/dist/environment.js.map +1 -1
  36. package/dist/fieldAnalyser/fieldAnalyser.js +21 -62
  37. package/dist/fieldAnalyser/fieldAnalyser.js.map +1 -1
  38. package/dist/fieldAnalyser/fieldAnalyser.spec.js +15 -22
  39. package/dist/fieldAnalyser/fieldAnalyser.spec.js.map +1 -1
  40. package/dist/fieldAnalyser/{utils.js → fieldUtils.js} +1 -1
  41. package/dist/fieldAnalyser/fieldUtils.js.map +1 -0
  42. package/dist/fieldAnalyser/{utils.spec.js → fieldsUtils.spec.js} +4 -4
  43. package/dist/fieldAnalyser/fieldsUtils.spec.js.map +1 -0
  44. package/dist/fieldAnalyser/inconsistencies.js.map +1 -1
  45. package/dist/fieldAnalyser/typeUtils.js +39 -0
  46. package/dist/fieldAnalyser/typeUtils.js.map +1 -0
  47. package/dist/fieldAnalyser/typeUtils.spec.js +48 -0
  48. package/dist/fieldAnalyser/typeUtils.spec.js.map +1 -0
  49. package/dist/help/fileConsumer.js +100 -0
  50. package/dist/help/fileConsumer.js.map +1 -0
  51. package/dist/help/fileConsumer.spec.js +75 -0
  52. package/dist/help/fileConsumer.spec.js.map +1 -0
  53. package/dist/index.js +6 -3
  54. package/dist/index.js.map +1 -1
  55. package/dist/interfaces.js +3 -0
  56. package/dist/interfaces.js.map +1 -0
  57. package/dist/localtest.js +2 -2
  58. package/dist/localtest.js.map +1 -1
  59. package/dist/source/batchUpdateDocumentsFromFile.js +42 -0
  60. package/dist/source/batchUpdateDocumentsFromFile.js.map +1 -0
  61. package/dist/{source.js → source/push.js} +43 -128
  62. package/dist/source/push.js.map +1 -0
  63. package/dist/{source.spec.js → source/push.spec.js} +41 -27
  64. package/dist/source/push.spec.js.map +1 -0
  65. package/dist/source/securityIdenty.js +59 -0
  66. package/dist/source/securityIdenty.js.map +1 -0
  67. package/dist/source/source.js +9 -0
  68. package/dist/source/source.js.map +1 -0
  69. package/package.json +1 -1
  70. package/dist/docs/classes/Source.html +0 -45
  71. package/dist/docs/interfaces/BatchUpdateDocumentsFromFiles.html +0 -7
  72. package/dist/fieldAnalyser/utils.js.map +0 -1
  73. package/dist/fieldAnalyser/utils.spec.js.map +0 -1
  74. package/dist/source.js.map +0 -1
  75. package/dist/source.spec.js.map +0 -1
@@ -9,8 +9,8 @@ export declare enum PlatformEnvironment {
9
9
  export declare const DEFAULT_ENVIRONMENT: PlatformEnvironment.Prod;
10
10
  export declare const DEFAULT_REGION: Region.US;
11
11
  export declare type PlatformUrlOptions = {
12
- environment: PlatformEnvironment;
13
- region: Region;
12
+ environment?: PlatformEnvironment;
13
+ region?: Region;
14
14
  };
15
- export declare function platformUrl(options?: Partial<PlatformUrlOptions>): string;
15
+ export declare function platformUrl(options?: PlatformUrlOptions): string;
16
16
  export declare function castEnvironmentToPlatformClient(e: PlatformEnvironment): Environment;
@@ -1,7 +1,6 @@
1
- import PlatformClient, { FieldModel, FieldTypes } from '@coveord/platform-client';
1
+ import PlatformClient, { FieldModel } from '@coveord/platform-client';
2
2
  import { DocumentBuilder } from '..';
3
3
  import { Inconsistencies } from './inconsistencies';
4
- declare type FieldTypeMap = Map<FieldTypes, number>;
5
4
  export declare type FieldAnalyserReport = {
6
5
  fields: FieldModel[];
7
6
  inconsistencies: Inconsistencies;
@@ -12,7 +11,6 @@ export declare type FieldAnalyserReport = {
12
11
  */
13
12
  export declare class FieldAnalyser {
14
13
  private platformClient;
15
- private static fieldTypePrecedence;
16
14
  private inconsistencies;
17
15
  private missingFields;
18
16
  private existingFields;
@@ -31,14 +29,8 @@ export declare class FieldAnalyser {
31
29
  * @return {*} {FieldAnalyserReport}
32
30
  */
33
31
  report(): FieldAnalyserReport;
32
+ private removeInconsistentFields;
34
33
  private storeMetadata;
35
34
  private ensureExistingFields;
36
35
  private ensurePermanentId;
37
- private getFieldTypes;
38
- private storePossibleTypeInconsistencies;
39
- getMostProbableType(field: FieldTypeMap): FieldTypes;
40
- private typeCompare;
41
- private getGuessedTypeFromValue;
42
- private getSpecificNumericType;
43
36
  }
44
- export {};
@@ -1,5 +1,5 @@
1
1
  import { FieldTypes } from '@coveord/platform-client';
2
- export declare class Inconsistencies extends Map {
2
+ export declare class Inconsistencies extends Map<string, Set<FieldTypes>> {
3
3
  constructor();
4
4
  add(fieldName: string, types: FieldTypes[]): this;
5
5
  }
@@ -0,0 +1,3 @@
1
+ import { FieldTypes } from '@coveord/platform-client';
2
+ export declare function isValidTypeTransition(currentState: FieldTypes, nextState: FieldTypes): boolean;
3
+ export declare function getGuessedTypeFromValue(obj: unknown): FieldTypes;
@@ -0,0 +1,26 @@
1
+ import { BatchUpdateDocuments, UploadBatchCallbackData, ConcurrentProcessing } from '../interfaces';
2
+ import { AxiosResponse } from 'axios';
3
+ export declare type SuccessfulUploadCallback = (data: UploadBatchCallbackData) => void;
4
+ export declare type FailedUploadCallback = (err: unknown, value: UploadBatchCallbackData) => void;
5
+ /**
6
+ * Util class to help injesting documents through a list of files and uploading generated document batches.
7
+ */
8
+ export declare class FileConsumer {
9
+ private upload;
10
+ private processingConfig;
11
+ private static maxContentLength;
12
+ private cbSuccess;
13
+ private cbFail;
14
+ /**
15
+ * Creates an instance of FileConsumer.
16
+ * @param {(batch: BatchUpdateDocuments) => Promise<AxiosResponse>} upload the upload operation to apply to every document batch
17
+ * @param {Required<ConcurrentProcessing>} processingConfig
18
+ */
19
+ constructor(upload: (batch: BatchUpdateDocuments) => Promise<AxiosResponse>, processingConfig: Required<ConcurrentProcessing>);
20
+ consume(files: string[]): Promise<void>;
21
+ onSuccess(callback: SuccessfulUploadCallback): void;
22
+ onError(callback: FailedUploadCallback): void;
23
+ private splitByChunkAndUpload;
24
+ private uploadBatch;
25
+ private get accumulator();
26
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -1,6 +1,10 @@
1
1
  export * from './document';
2
- export { Source, SourceVisibility, BatchUpdateDocuments, UploadBatchCallback, UploadBatchCallbackData, BatchUpdateDocumentsFromFiles, } from './source';
2
+ export { Source } from './source/source';
3
+ export { PushSource } from './source/push';
4
+ export { SuccessfulUploadCallback, FailedUploadCallback, } from './help/fileConsumer';
5
+ export { UploadBatchCallbackData, BatchUpdateDocuments, BatchUpdateDocumentsFromFiles, } from './interfaces';
3
6
  export { FieldAnalyser } from './fieldAnalyser/fieldAnalyser';
4
7
  export { DocumentBuilder } from './documentBuilder';
5
8
  export * from './securityIdentityBuilder';
6
- export { PlatformEnvironment, Region } from './environment';
9
+ export { PlatformEnvironment, Region, PlatformUrlOptions } from './environment';
10
+ export { SourceVisibility } from '@coveord/platform-client';
@@ -0,0 +1,36 @@
1
+ import type { AxiosResponse } from 'axios';
2
+ import type { DocumentBuilder } from './documentBuilder';
3
+ export interface BatchUpdateDocuments {
4
+ addOrUpdate: DocumentBuilder[];
5
+ delete: {
6
+ documentId: string;
7
+ deleteChildren: boolean;
8
+ }[];
9
+ }
10
+ /**
11
+ *
12
+ * @param {string[]} files Files from which the documentBuilders were generated
13
+ * @param {DocumentBuilder[]} batch List of the uploaded DocumentBuilders
14
+ * @param {AxiosResponse} res Axios response
15
+ */
16
+ export interface UploadBatchCallbackData {
17
+ files: string[];
18
+ batch: DocumentBuilder[];
19
+ res?: AxiosResponse;
20
+ }
21
+ export interface BatchUpdateDocumentsOptions {
22
+ /**
23
+ * Whether to create fields required in the index based on the document batch metadata.
24
+ */
25
+ createFields?: boolean;
26
+ }
27
+ export interface ConcurrentProcessing {
28
+ /**
29
+ * The maximum number of requests to send concurrently to the Coveo platform.
30
+ * Increasing this value will increase the speed at which documents are pushed but will also consume more memory.
31
+ *
32
+ * The default value is set to 10.
33
+ */
34
+ maxConcurrent?: number;
35
+ }
36
+ export declare type BatchUpdateDocumentsFromFiles = BatchUpdateDocumentsOptions & ConcurrentProcessing;
@@ -0,0 +1,10 @@
1
+ import { BatchUpdateDocumentsFromFiles, FailedUploadCallback, SuccessfulUploadCallback } from '../index';
2
+ import type { PushSource } from './push';
3
+ export declare class BatchUpdateDocumentsFromFilesReturn {
4
+ private internalPromise;
5
+ private batchConsumer;
6
+ constructor(pushSource: PushSource, sourceId: string, filesOrDirectories: string[], options?: BatchUpdateDocumentsFromFiles);
7
+ onBatchUpload(cb: SuccessfulUploadCallback): this;
8
+ onBatchError(cb: FailedUploadCallback): this;
9
+ batch(): Promise<void>;
10
+ }
@@ -1,61 +1,29 @@
1
- import { SecurityIdentityAliasModel, SecurityIdentityBatchConfig, SecurityIdentityDelete, SecurityIdentityDeleteOptions, SecurityIdentityModel, SourceVisibility } from '@coveord/platform-client';
1
+ import { PlatformClient, SecurityIdentityAliasModel, SecurityIdentityBatchConfig, SecurityIdentityDelete, SecurityIdentityDeleteOptions, SecurityIdentityModel, SourceVisibility } from '@coveord/platform-client';
2
2
  export { SourceVisibility } from '@coveord/platform-client';
3
- import { AxiosResponse } from 'axios';
4
- import { DocumentBuilder } from './documentBuilder';
5
- import { PlatformUrlOptions } from './environment';
3
+ import { DocumentBuilder } from '../documentBuilder';
4
+ import { PlatformUrlOptions } from '../environment';
5
+ import { FieldAnalyser } from '../fieldAnalyser/fieldAnalyser';
6
+ import { SecurityIdentity } from './securityIdenty';
7
+ import { BatchUpdateDocuments, BatchUpdateDocumentsOptions, BatchUpdateDocumentsFromFiles } from '../interfaces';
8
+ import { BatchUpdateDocumentsFromFilesReturn } from './batchUpdateDocumentsFromFile';
6
9
  export declare type SourceStatus = 'REBUILD' | 'REFRESH' | 'INCREMENTAL' | 'IDLE';
7
- export interface BatchUpdateDocuments {
8
- addOrUpdate: DocumentBuilder[];
9
- delete: {
10
- documentId: string;
11
- deleteChildren: boolean;
12
- }[];
13
- }
14
- /**
15
- *
16
- * @param {string[]} files Files from which the documentBuilders were generated
17
- * @param {DocumentBuilder[]} batch List of the uploaded DocumentBuilders
18
- * @param {AxiosResponse} res Axios response
19
- */
20
- export interface UploadBatchCallbackData {
21
- files: string[];
22
- batch: DocumentBuilder[];
23
- res?: AxiosResponse;
24
- }
25
- export declare type UploadBatchCallback = (err: unknown | null, data: UploadBatchCallbackData) => void;
26
- export interface BatchUpdateDocumentsOptions {
27
- /**
28
- * Whether to create fields required in the index based on the document batch metadata.
29
- */
30
- createFields?: boolean;
31
- }
32
- export interface BatchUpdateDocumentsFromFiles extends BatchUpdateDocumentsOptions {
33
- /**
34
- * The maximum number of requests to send concurrently to the Coveo platform.
35
- * Increasing this value will increase the speed at which documents are pushed but will also consume more memory.
36
- *
37
- * The default value is set to 10.
38
- */
39
- maxConcurrent?: number;
40
- }
41
10
  /**
42
11
  * Manage a push source.
43
12
  *
44
13
  * Allows you to create a new push source, manage security identities and documents in a Coveo organization.
45
14
  */
46
- export declare class Source {
15
+ export declare class PushSource {
47
16
  private apikey;
48
17
  private organizationid;
49
- private platformClient;
18
+ platformClient: PlatformClient;
50
19
  private options;
51
20
  private static defaultOptions;
52
- private static maxContentLength;
53
21
  /**
54
22
  *
55
23
  * @param apikey An apiKey capable of pushing documents and managing sources in a Coveo organization. See [Manage API Keys](https://docs.coveo.com/en/1718).
56
24
  * @param organizationid The Coveo Organization identifier.
57
25
  */
58
- constructor(apikey: string, organizationid: string, options?: Partial<PlatformUrlOptions>);
26
+ constructor(apikey: string, organizationid: string, options?: PlatformUrlOptions);
59
27
  /**
60
28
  * Create a new push source
61
29
  * @param name The name of the source to create.
@@ -66,37 +34,36 @@ export declare class Source {
66
34
  id: string;
67
35
  }>;
68
36
  /**
69
- * Create or update a security identity. See [Adding a Single Security Identity](https://docs.coveo.com/en/167) and [Security Identity Models](https://docs.coveo.com/en/139).
70
- * @param securityProviderId
71
- * @param securityIdentity
72
- * @returns
37
+ * @deprecated use `identity.createSecurityIdentity`
38
+ *
39
+ * See {@link Source.identity}
73
40
  */
74
41
  createSecurityIdentity(securityProviderId: string, securityIdentity: SecurityIdentityModel): Promise<void>;
75
42
  /**
76
- * Create or update a security identity alias. See [Adding a Single Alias](https://docs.coveo.com/en/142) and [User Alias Definition Examples](https://docs.coveo.com/en/46).
77
- * @param securityProviderId
78
- * @param securityIdentityAlias
79
- * @returns
43
+ * @deprecated use `identity.createOrUpdateSecurityIdentityAlias`
44
+ *
45
+ * See {@link Source.identity}
80
46
  */
81
47
  createOrUpdateSecurityIdentityAlias(securityProviderId: string, securityIdentityAlias: SecurityIdentityAliasModel): Promise<void>;
82
48
  /**
83
- * Delete a security identity. See [Disabling a Single Security Identity](https://docs.coveo.com/en/84).
84
- * @param securityProviderId
85
- * @param securityIdentityToDelete
86
- * @returns
49
+ * @deprecated use `identity.deleteSecurityIdentity`
50
+ *
51
+ * See {@link Source.identity}
87
52
  */
88
53
  deleteSecurityIdentity(securityProviderId: string, securityIdentityToDelete: SecurityIdentityDelete): Promise<void>;
89
54
  /**
90
- * Delete old security identities. See [Disabling Old Security Identities](https://docs.coveo.com/en/33).
91
- * @param securityProviderId
92
- * @param batchDelete
93
- * @returns
55
+ * @deprecated use `identity.deleteOldSecurityIdentities`
56
+ *
57
+ * See {@link Source.identity}
94
58
  */
95
59
  deleteOldSecurityIdentities(securityProviderId: string, batchDelete: SecurityIdentityDeleteOptions): Promise<void>;
96
60
  /**
97
- * Manage batches of security identities. See [Manage Batches of Security Identities](https://docs.coveo.com/en/55).
61
+ * @deprecated use `identity.manageSecurityIdentities`
62
+ *
63
+ * See {@link Source.identity}
98
64
  */
99
65
  manageSecurityIdentities(securityProviderId: string, batchConfig: SecurityIdentityBatchConfig): Promise<void>;
66
+ get identity(): SecurityIdentity;
100
67
  /**
101
68
  * Adds or updates an individual item in a push source. See [Adding a Single Item in a Push Source](https://docs.coveo.com/en/133).
102
69
  * @param sourceID
@@ -104,14 +71,14 @@ export declare class Source {
104
71
  * @param {BatchUpdateDocumentsOptions} [{createFields = true}={}]
105
72
  * @returns
106
73
  */
107
- addOrUpdateDocument(sourceID: string, docBuilder: DocumentBuilder, { createFields: createFields }?: BatchUpdateDocumentsOptions): Promise<AxiosResponse<any, any>>;
74
+ addOrUpdateDocument(sourceID: string, docBuilder: DocumentBuilder, { createFields: createFields }?: BatchUpdateDocumentsOptions): Promise<import("axios").AxiosResponse<any, any>>;
108
75
  /**
109
76
  * Manage batches of items in a push source. See [Manage Batches of Items in a Push Source](https://docs.coveo.com/en/90)
110
77
  * @param sourceID
111
78
  * @param batch
112
79
  * @returns
113
80
  */
114
- batchUpdateDocuments(sourceID: string, batch: BatchUpdateDocuments, { createFields: createFields }?: BatchUpdateDocumentsOptions): Promise<AxiosResponse<any, any>>;
81
+ batchUpdateDocuments(sourceID: string, batch: BatchUpdateDocuments, { createFields: createFields }?: BatchUpdateDocumentsOptions): Promise<import("axios").AxiosResponse<any, any>>;
115
82
  /**
116
83
  *
117
84
  * Manage batches of items in a push source from a list of JSON files. See [Manage Batches of Items in a Push Source](https://docs.coveo.com/en/90)
@@ -120,7 +87,7 @@ export declare class Source {
120
87
  * @param {UploadBatchCallback} callback Callback executed when a batch of documents is either successfully uploaded or when an error occurs during the upload
121
88
  * @param {BatchUpdateDocumentsFromFiles} options
122
89
  */
123
- batchUpdateDocumentsFromFiles(sourceID: string, filesOrDirectories: string[], callback: UploadBatchCallback, options?: BatchUpdateDocumentsFromFiles): Promise<void>;
90
+ batchUpdateDocumentsFromFiles(sourceID: string, filesOrDirectories: string[], options?: BatchUpdateDocumentsFromFiles): BatchUpdateDocumentsFromFilesReturn;
124
91
  /**
125
92
  * Deletes a specific item from a Push source. Optionally, the child items of that item can also be deleted. See [Deleting an Item in a Push Source](https://docs.coveo.com/en/171).
126
93
  * @param sourceID
@@ -128,32 +95,30 @@ export declare class Source {
128
95
  * @param deleteChildren
129
96
  * @returns
130
97
  */
131
- deleteDocument(sourceID: string, documentId: string, deleteChildren?: boolean): Promise<AxiosResponse<any, any>>;
98
+ deleteDocument(sourceID: string, documentId: string, deleteChildren?: boolean): Promise<import("axios").AxiosResponse<any, any>>;
132
99
  /**
133
100
  * Deletes all items whose last update was made by a Push API operation whose orderingId is strictly lower than a specified value. See [Deleting Old Items in a Push Source](https://docs.coveo.com/en/131).
134
101
  * @param sourceID
135
102
  * @param olderThan
136
103
  * @returns
137
104
  */
138
- deleteDocumentsOlderThan(sourceID: string, olderThan: Date | string | number): Promise<AxiosResponse<any, any>>;
105
+ deleteDocumentsOlderThan(sourceID: string, olderThan: Date | string | number): Promise<import("axios").AxiosResponse<any, any>>;
139
106
  /**
140
107
  * Set the status of a push source. See [Updating the Status of a Push Source](https://docs.coveo.com/en/35/)
141
108
  * @param sourceID
142
109
  * @param status
143
110
  * @returns
144
111
  */
145
- setSourceStatus(sourceID: string, status: SourceStatus): Promise<AxiosResponse<any, any>>;
112
+ setSourceStatus(sourceID: string, status: SourceStatus): Promise<import("axios").AxiosResponse<any, any>>;
113
+ uploadBatch(sourceID: string, batch: BatchUpdateDocuments): Promise<import("axios").AxiosResponse<any, any>>;
146
114
  private get baseAPIURL();
147
115
  private getBaseAPIURLForDocuments;
148
116
  private get documentsAxiosConfig();
149
- private createFields;
117
+ createFields(analyser: FieldAnalyser): Promise<void>;
150
118
  private getFileContainerAxiosConfig;
151
119
  private get documentsRequestHeaders();
152
120
  private get authorizationHeader();
153
121
  private createFileContainer;
154
122
  private uploadContentToFileContainer;
155
123
  private pushFileContainerContent;
156
- private splitByChunkAndUpload;
157
- private uploadBatch;
158
- private get accumulator();
159
124
  }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,42 @@
1
+ import { PlatformClient, SecurityIdentityAliasModel, SecurityIdentityBatchConfig, SecurityIdentityDelete, SecurityIdentityDeleteOptions, SecurityIdentityModel } from '@coveord/platform-client';
2
+ export declare class SecurityIdentity {
3
+ private platformClient;
4
+ /**
5
+ *
6
+ * @param apikey An apiKey capable of pushing documents and managing sources in a Coveo organization. See [Manage API Keys](https://docs.coveo.com/en/1718).
7
+ * @param organizationid The Coveo Organization identifier.
8
+ */
9
+ constructor(platformClient: PlatformClient);
10
+ /**
11
+ * Create or update a security identity. See [Adding a Single Security Identity](https://docs.coveo.com/en/167) and [Security Identity Models](https://docs.coveo.com/en/139).
12
+ * @param securityProviderId
13
+ * @param securityIdentity
14
+ * @returns
15
+ */
16
+ createSecurityIdentity(securityProviderId: string, securityIdentity: SecurityIdentityModel): Promise<void>;
17
+ /**
18
+ * Create or update a security identity alias. See [Adding a Single Alias](https://docs.coveo.com/en/142) and [User Alias Definition Examples](https://docs.coveo.com/en/46).
19
+ * @param securityProviderId
20
+ * @param securityIdentityAlias
21
+ * @returns
22
+ */
23
+ createOrUpdateSecurityIdentityAlias(securityProviderId: string, securityIdentityAlias: SecurityIdentityAliasModel): Promise<void>;
24
+ /**
25
+ * Delete a security identity. See [Disabling a Single Security Identity](https://docs.coveo.com/en/84).
26
+ * @param securityProviderId
27
+ * @param securityIdentityToDelete
28
+ * @returns
29
+ */
30
+ deleteSecurityIdentity(securityProviderId: string, securityIdentityToDelete: SecurityIdentityDelete): Promise<void>;
31
+ /**
32
+ * Delete old security identities. See [Disabling Old Security Identities](https://docs.coveo.com/en/33).
33
+ * @param securityProviderId
34
+ * @param batchDelete
35
+ * @returns
36
+ */
37
+ deleteOldSecurityIdentities(securityProviderId: string, batchDelete: SecurityIdentityDeleteOptions): Promise<void>;
38
+ /**
39
+ * Manage batches of security identities. See [Manage Batches of Security Identities](https://docs.coveo.com/en/55).
40
+ */
41
+ manageSecurityIdentities(securityProviderId: string, batchConfig: SecurityIdentityBatchConfig): Promise<void>;
42
+ }
@@ -0,0 +1,5 @@
1
+ import { PushSource } from './push';
2
+ /**
3
+ * @deprecated This class has been replaced by {@link PushSource}
4
+ */
5
+ export declare const Source: typeof PushSource;