added event collector
This commit is contained in:
@@ -48,6 +48,14 @@ export function createChannel(data: CreateChannelData) {
|
||||
return invoke<Channel>('create_channel', { data });
|
||||
}
|
||||
|
||||
export function createChat(data: CreateChatData) {
|
||||
return invoke<Chat>('create_chat', { data });
|
||||
}
|
||||
|
||||
export function getChats(data: GetChatData) {
|
||||
return invoke<Chat[]>('get_chats', { data });
|
||||
}
|
||||
|
||||
export type CreateNoteData = {
|
||||
event_id: string;
|
||||
pubkey: string;
|
||||
@@ -59,10 +67,7 @@ export type CreateNoteData = {
|
||||
created_at: number;
|
||||
account_id: number;
|
||||
};
|
||||
export type CreateChannelData = { event_id: string; content: string };
|
||||
export type CreatePlebData = { pleb_id: string; pubkey: string; kind: number; metadata: string; account_id: number };
|
||||
export type GetNoteByIdData = { event_id: string };
|
||||
export type Pleb = { id: number; plebId: string; pubkey: string; kind: number; metadata: string; accountId: number };
|
||||
export type Note = {
|
||||
id: number;
|
||||
eventId: string;
|
||||
@@ -75,10 +80,16 @@ export type Note = {
|
||||
createdAt: number;
|
||||
accountId: number;
|
||||
};
|
||||
export type CreateChatData = { pubkey: string; created_at: number; account_id: number };
|
||||
export type GetNoteByIdData = { event_id: string };
|
||||
export type Chat = { id: number; pubkey: string; createdAt: number; accountId: number };
|
||||
export type Account = { id: number; pubkey: string; privkey: string; active: boolean; metadata: string };
|
||||
export type Channel = { id: number; eventId: string; content: string };
|
||||
export type GetChatData = { account_id: number };
|
||||
export type CreateChannelData = { event_id: string; content: string; account_id: number };
|
||||
export type GetPlebPubkeyData = { pubkey: string };
|
||||
export type Channel = { id: number; eventId: string; content: string; accountId: number };
|
||||
export type GetPlebData = { account_id: number };
|
||||
export type CreateAccountData = { pubkey: string; privkey: string; metadata: string };
|
||||
export type GetLatestNoteData = { date: number };
|
||||
export type Pleb = { id: number; plebId: string; pubkey: string; kind: number; metadata: string; accountId: number };
|
||||
export type GetNoteData = { date: number; limit: number; offset: number };
|
||||
|
||||
Reference in New Issue
Block a user