import { MutationObserver } from '@tanstack/query-core';
import { WeavyType } from '../client/weavy';
import { ConversationType, ConversationTypeGuid, ConversationMutationContextType } from '../types/conversations.types';
import { AccessTypes, AppRef, AppType } from '../types/app.types';
export type MutateDeliveredConversationVariables = {
    id: number;
};
export type MutateMarkConversationVariables = {
    id: number;
    markAsRead: boolean;
    messageId: number | null;
};
export type MutateStarConversationVariables = {
    id: number;
    star: boolean;
};
export type MutatePinConversationVariables = {
    id: number;
    pin: boolean;
};
export type MutateLeaveConversationVariables = {
    id: number;
    members: number[];
};
export type MutateUpdateMemberVariables = {
    id: number;
    userId: number;
    access: AccessTypes;
};
export type MutateAddMembersToConversationVariables = {
    id: number;
    members: number[];
};
export type MutateUpdateConversationVariables = {
    id: number;
    name?: string | null | undefined;
    blobId?: number | null | undefined;
    thumbnailUrl?: string | null | undefined;
};
export type MutateTrashConversationVariables = {
    id: number;
};
export type DeliveredConversationMutationType = MutationObserver<void, Error, MutateDeliveredConversationVariables, ConversationMutationContextType>;
export type MarkConversationMutationType = MutationObserver<void, Error, MutateMarkConversationVariables, ConversationMutationContextType>;
export type StarConversationMutationType = MutationObserver<void, Error, MutateStarConversationVariables, ConversationMutationContextType>;
export type PinConversationMutationType = MutationObserver<void, Error, MutatePinConversationVariables, ConversationMutationContextType>;
export type LeaveConversationMutationType = MutationObserver<void, Error, MutateLeaveConversationVariables, ConversationMutationContextType>;
export type UpdateMemberMutationType = MutationObserver<void, Error, MutateUpdateMemberVariables, ConversationMutationContextType>;
export type AddMembersToConversationMutationType = MutationObserver<void, Error, MutateAddMembersToConversationVariables, ConversationMutationContextType>;
export type UpdateConversationMutationType = MutationObserver<ConversationType, Error, MutateUpdateConversationVariables, ConversationMutationContextType>;
export type TrashConversationMutationType = MutationObserver<void, Error, MutateTrashConversationVariables, ConversationMutationContextType>;
export declare function getDeliveredConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id }: MutateDeliveredConversationVariables) => Promise<void>;
    onMutate: () => Promise<object>;
};
export declare function getMarkConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, markAsRead, messageId }: MutateMarkConversationVariables) => Promise<void>;
    onMutate: (variables: MutateMarkConversationVariables) => Promise<object>;
    onError: (error: Error, variables: MutateMarkConversationVariables) => void;
};
export declare function getStarConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, star }: MutateStarConversationVariables) => Promise<void>;
    onMutate: (variables: MutateStarConversationVariables) => Promise<object>;
    onError: (error: Error, variables: MutateStarConversationVariables) => void;
};
export declare function getPinConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, pin }: MutatePinConversationVariables) => Promise<void>;
    onMutate: (variables: MutatePinConversationVariables) => Promise<object>;
    onSettled: () => Promise<void>;
};
export declare function getLeaveConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, members }: MutateLeaveConversationVariables) => Promise<void>;
    onMutate: (variables: MutateLeaveConversationVariables) => Promise<object>;
};
export declare function getUpdateMemberMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, userId, access }: MutateUpdateMemberVariables) => Promise<void>;
    onMutate: (variables: MutateUpdateMemberVariables) => Promise<object>;
};
export declare function getAddMembersToConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, members }: MutateAddMembersToConversationVariables) => Promise<void>;
    onMutate: () => Promise<object>;
};
export declare function getUpdateConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id, name, blobId }: MutateUpdateConversationVariables) => Promise<any>;
    onMutate: (variables: MutateUpdateConversationVariables) => Promise<object>;
};
export declare function getTrashConversationMutationOptions(weavy: WeavyType): {
    mutationFn: ({ id }: MutateTrashConversationVariables) => Promise<void>;
    onMutate: (variables: MutateTrashConversationVariables) => Promise<object>;
};
export declare function getDeliveredConversationMutation(weavy: WeavyType): DeliveredConversationMutationType;
export declare function getMarkConversationMutation(weavy: WeavyType): MarkConversationMutationType;
export declare function getStarConversationMutation(weavy: WeavyType): StarConversationMutationType;
export declare function getPinConversationMutation(weavy: WeavyType): PinConversationMutationType;
export declare function getLeaveConversationMutation(weavy: WeavyType): LeaveConversationMutationType;
export declare function getUpdateMemberMutation(weavy: WeavyType): UpdateMemberMutationType;
export declare function getAddMembersToConversationMutation(weavy: WeavyType): AddMembersToConversationMutationType;
export declare function getUpdateConversationMutation(weavy: WeavyType): UpdateConversationMutationType;
export declare function getTrashConversationMutation(weavy: WeavyType): TrashConversationMutationType;
export declare function getConversationOptions(weavy: WeavyType, conversationId: number): import('@tanstack/query-core').QueryObserverOptions<ConversationType, Error, ConversationType, ConversationType, import('@tanstack/query-core').QueryKey, never>;
export declare function getConversation(weavy: WeavyType, conversationId: number): Promise<ConversationType>;
export declare function resolveConversation(weavy: WeavyType, conversation: AppRef | AppType | number, types?: ConversationTypeGuid[]): Promise<ConversationType | undefined>;
//# sourceMappingURL=conversation.d.ts.map