@squidcloud/client 1.0.318 → 1.0.320
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/cjs/index.js +1 -1
- package/dist/internal-common/src/public-types/query.public-types.d.ts +2 -2
- package/dist/internal-common/src/types/ai-matchmaking.types.d.ts +20 -1
- package/dist/typescript-client/src/ai-matchmaking-client.d.ts +16 -2
- package/dist/typescript-client/src/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -35,8 +35,8 @@ export interface CompositeCondition<Doc extends DocumentData = any> {
|
|
|
35
35
|
}
|
|
36
36
|
export declare function isSimpleCondition(condition: Condition): condition is SimpleCondition;
|
|
37
37
|
type CompositeConditionOperator = '>=' | '<=' | '>' | '<';
|
|
38
|
-
export declare const ARRAY_OPERATORS:
|
|
39
|
-
export declare const ALL_OPERATORS:
|
|
38
|
+
export declare const ARRAY_OPERATORS: readonly ["in", "not in", "array_includes_some", "array_includes_all", "array_not_includes"];
|
|
39
|
+
export declare const ALL_OPERATORS: readonly ["in", "not in", "array_includes_some", "array_includes_all", "array_not_includes", "==", "!=", ">=", "<=", ">", "<", "like", "not like", "like_cs", "not like_cs"];
|
|
40
40
|
/** An operator in a query condition. */
|
|
41
41
|
export type Operator = (typeof ALL_OPERATORS)[number];
|
|
42
42
|
/** A definition of a sort by a filed. */
|
|
@@ -2,14 +2,29 @@ import { MmEntity, MmEntityMatch, MmFindMatchesOptions, MmListEntitiesOptions, M
|
|
|
2
2
|
export interface MmCreateMatchMakerRequest {
|
|
3
3
|
matchMaker: MmMatchMaker;
|
|
4
4
|
}
|
|
5
|
+
export interface MmDeleteMatchMakerRequest {
|
|
6
|
+
matchMakerId: string;
|
|
7
|
+
}
|
|
8
|
+
export interface MmGetMatchMakerRequest {
|
|
9
|
+
matchMakerId: string;
|
|
10
|
+
}
|
|
11
|
+
export interface MmGetMatchMakerResponse {
|
|
12
|
+
matchMaker: MmMatchMaker | undefined;
|
|
13
|
+
}
|
|
5
14
|
export interface MmDeleteEntityRequest {
|
|
15
|
+
matchMakerId: string;
|
|
6
16
|
entityId: string;
|
|
7
17
|
}
|
|
8
18
|
export interface MmInsertEntityRequest {
|
|
9
19
|
matchMakerId: string;
|
|
10
20
|
entity: MmEntity;
|
|
11
21
|
}
|
|
22
|
+
export interface MmInsertEntitiesRequest {
|
|
23
|
+
matchMakerId: string;
|
|
24
|
+
entities: Array<MmEntity>;
|
|
25
|
+
}
|
|
12
26
|
export interface MmFindMatchesRequest {
|
|
27
|
+
matchMakerId: string;
|
|
13
28
|
entityId: string;
|
|
14
29
|
options: MmFindMatchesOptions;
|
|
15
30
|
}
|
|
@@ -29,6 +44,10 @@ export interface MmListEntitiesRequest {
|
|
|
29
44
|
categoryId: string;
|
|
30
45
|
options: MmListEntitiesOptions;
|
|
31
46
|
}
|
|
32
|
-
export interface
|
|
47
|
+
export interface MmGetEntityRequest {
|
|
33
48
|
matchMakerId: string;
|
|
49
|
+
entityId: string;
|
|
50
|
+
}
|
|
51
|
+
export interface MmGetEntityResponse {
|
|
52
|
+
entity: MmEntity | undefined;
|
|
34
53
|
}
|
|
@@ -13,17 +13,23 @@ export declare class AiMatchMakingClient {
|
|
|
13
13
|
/**
|
|
14
14
|
* Retrieves an existing matchmaker by its ID.
|
|
15
15
|
*/
|
|
16
|
-
getMatchMaker(matchMakerId: string): MatchMaker
|
|
16
|
+
getMatchMaker(matchMakerId: string): Promise<MatchMaker | undefined>;
|
|
17
17
|
listMatchMakers(): Promise<Array<MmMatchMaker>>;
|
|
18
18
|
}
|
|
19
19
|
/**
|
|
20
20
|
* Represents a matchmaker. You can insert entities into the matchmaker and find matches for them.
|
|
21
21
|
*/
|
|
22
22
|
export declare class MatchMaker {
|
|
23
|
-
|
|
23
|
+
private readonly matchMaker;
|
|
24
24
|
private readonly rpcManager;
|
|
25
|
+
readonly id: string;
|
|
25
26
|
/** Adds a new entity to the matchmaker - replaces existing entity with the same ID if exists. */
|
|
26
27
|
insertEntity(entity: MmEntity): Promise<void>;
|
|
28
|
+
/**
|
|
29
|
+
* Adds a new entities to the matchmaker - replaces existing entities with the same ID if exists.
|
|
30
|
+
* This method is more efficient than calling insertEntity multiple times.
|
|
31
|
+
*/
|
|
32
|
+
insertManyEntities(entities: Array<MmEntity>): Promise<void>;
|
|
27
33
|
delete(): Promise<void>;
|
|
28
34
|
deleteEntity(entityId: string): Promise<void>;
|
|
29
35
|
/** Finds matches for the given entity id. */
|
|
@@ -35,4 +41,12 @@ export declare class MatchMaker {
|
|
|
35
41
|
* The results are ordered by the entity id.
|
|
36
42
|
*/
|
|
37
43
|
listEntities(categoryId: string, options?: MmListEntitiesOptions): Promise<Array<MmEntity>>;
|
|
44
|
+
/**
|
|
45
|
+
* Returns the entity with the given ID.
|
|
46
|
+
*/
|
|
47
|
+
getEntity(entityId: string): Promise<MmEntity | undefined>;
|
|
48
|
+
/**
|
|
49
|
+
* Returns an object with the matchmaker details.
|
|
50
|
+
*/
|
|
51
|
+
getMatchMakerDetails(): MmMatchMaker;
|
|
38
52
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.
|
|
1
|
+
export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.320";
|