import { Insertable, Kysely, Updateable } from 'kysely';
import { DB } from "../schema";
import { ApiKeyTable } from "../schema/tables/api-key.table";
export declare class ApiKeyRepository {
    private db;
    constructor(db: Kysely<DB>);
    create(dto: Insertable<ApiKeyTable>): Promise<{
        id: string;
        createdAt: Date;
        userId: string;
        name: string;
        updatedAt: Date;
        permissions: import("../enum").Permission[];
    }>;
    update(userId: string, id: string, dto: Updateable<ApiKeyTable>): Promise<{
        id: string;
        createdAt: Date;
        userId: string;
        name: string;
        updatedAt: Date;
        permissions: import("../enum").Permission[];
    }>;
    delete(userId: string, id: string): Promise<void>;
    getKey(hashedToken: Buffer): Promise<{
        id: string;
        permissions: import("../enum").Permission[];
        user: {
            id: string;
            email: string;
            name: string;
            isAdmin: boolean;
            quotaSizeInBytes: number | null;
            quotaUsageInBytes: number;
        } | null;
    } | undefined>;
    getById(userId: string, id: string): Promise<{
        id: string;
        createdAt: Date;
        userId: string;
        name: string;
        updatedAt: Date;
        permissions: import("../enum").Permission[];
    } | undefined>;
    getByUserId(userId: string): Promise<{
        id: string;
        createdAt: Date;
        userId: string;
        name: string;
        updatedAt: Date;
        permissions: import("../enum").Permission[];
    }[]>;
}
