refactor: list and fetch
Signed-off-by: Sebastian Krupinski <krupinski01@gmail.com>
This commit is contained in:
+16
-16
@@ -29,16 +29,16 @@ export interface EntityInterface<T = MessageInterface> {
|
||||
export interface EntityModelInterface extends Omit<EntityInterface<MessageModelInterface>, '@type' | 'version'> {}
|
||||
|
||||
/**
|
||||
* Entity list
|
||||
* Entity list bulk
|
||||
*/
|
||||
export interface EntityListRequest {
|
||||
export interface EntityListBulkRequest {
|
||||
sources?: CollectionIdentifier[];
|
||||
filter?: ListFilter;
|
||||
sort?: ListSort;
|
||||
range?: ListRange;
|
||||
}
|
||||
|
||||
export interface EntityListResponse {
|
||||
export interface EntityListBulkResponse {
|
||||
[providerId: string]: {
|
||||
[serviceId: string]: {
|
||||
[collectionId: string]: {
|
||||
@@ -48,6 +48,18 @@ export interface EntityListResponse {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Entity list stream
|
||||
*/
|
||||
export interface EntityListStreamRequest {
|
||||
sources?: CollectionIdentifier[];
|
||||
filter?: ListFilter;
|
||||
sort?: ListSort;
|
||||
range?: ListRange;
|
||||
}
|
||||
|
||||
export interface EntityListStreamResponse extends EntityInterface<MessageInterface> {}
|
||||
|
||||
/**
|
||||
* Entity fetch
|
||||
*/
|
||||
@@ -178,16 +190,4 @@ export interface EntityTransmitRequest {
|
||||
export interface EntityTransmitResponse {
|
||||
id: string;
|
||||
status: 'queued' | 'sent';
|
||||
}
|
||||
|
||||
/**
|
||||
* Entity stream
|
||||
*/
|
||||
export interface EntityStreamRequest {
|
||||
sources?: CollectionIdentifier[];
|
||||
filter?: ListFilter;
|
||||
sort?: ListSort;
|
||||
range?: ListRange;
|
||||
}
|
||||
|
||||
export interface EntityStreamResponse extends EntityInterface<MessageInterface> {}
|
||||
}
|
||||
Reference in New Issue
Block a user