import type { UpsertResponse } from '../../../models/Data.js';
import type { DataRecord } from '../../../models/Sync.js';
import type { LogContext } from '@nangohq/logs';
/**
 * Upsert
 */
export declare function upsert(records: DataRecord[], nangoConnectionId: number, model: string, activityLogId: number, environment_id: number, softDelete: boolean | undefined, logCtx: LogContext): Promise<UpsertResponse>;
export declare function update(records: DataRecord[], nangoConnectionId: number, model: string, activityLogId: number, environment_id: number, logCtx: LogContext): Promise<UpsertResponse>;
export declare function removeDuplicateKey(response: DataRecord[], activityLogId: number, environment_id: number, model: string, logCtx: LogContext): Promise<DataRecord[]>;
/**
 * Compute Added Keys
 * @desc for any incoming payload use the provided unique to check against the rows
 * in the database and return the keys that are not in the database
 *
 */
export declare function getAddedKeys(response: DataRecord[], nangoConnectionId: number, model: string): Promise<string[]>;
/**
 * Get Updated Keys
 * @desc generate an array of the keys that exist in the database and also in
 * the incoming payload that will be used to update the database.
 * Compare using the data_hash key
 *
 */
export declare function getUpdatedKeys(response: DataRecord[], nangoConnectionId: number, model: string): Promise<string[]>;
export declare function getDeletedKeys(response: DataRecord[], nangoConnectionId: number, model: string): Promise<string[]>;
