import { LicenseState } from '@n8n/backend-common';
import type { ICredentialsDb } from '@n8n/db';
import { CredentialsRepository, SecretsProviderConnectionRepository } from '@n8n/db';
import { Credentials } from 'n8n-core';
import type { ICredentialDataDecryptedObject, ICredentialsExpressionResolveValues, IHttpRequestOptions, INode, INodeCredentialsDetails, INodeProperties, IRequestOptionsSimplified, WorkflowExecuteMode, IHttpRequestHelper, IWorkflowExecuteAdditionalData, IExecuteData } from 'n8n-workflow';
import { ICredentialsHelper, Workflow } from 'n8n-workflow';
import { DynamicCredentialsProxy } from './credentials/dynamic-credentials-proxy';
import { CredentialTypes } from './credential-types';
import { CredentialsOverwrites } from './credentials-overwrites';
import { ExternalSecretsConfig } from './modules/external-secrets.ee/external-secrets.config';
import { AiGatewayService } from './services/ai-gateway.service';
export declare class CredentialsHelper extends ICredentialsHelper {
    private readonly credentialTypes;
    private readonly credentialsOverwrites;
    private readonly credentialsRepository;
    private readonly dynamicCredentialsProxy;
    private readonly secretsProviderConnectionRepository;
    private readonly licenseState;
    private readonly externalSecretsConfig;
    private readonly aiGatewayService;
    constructor(credentialTypes: CredentialTypes, credentialsOverwrites: CredentialsOverwrites, credentialsRepository: CredentialsRepository, dynamicCredentialsProxy: DynamicCredentialsProxy, secretsProviderConnectionRepository: SecretsProviderConnectionRepository, licenseState: LicenseState, externalSecretsConfig: ExternalSecretsConfig, aiGatewayService: AiGatewayService);
    authenticate(credentials: ICredentialDataDecryptedObject, typeName: string, incomingRequestOptions: IHttpRequestOptions | IRequestOptionsSimplified, workflow: Workflow, node: INode): Promise<IHttpRequestOptions>;
    preAuthentication(helpers: IHttpRequestHelper, credentials: ICredentialDataDecryptedObject, typeName: string, node: INode, credentialsExpired: boolean): Promise<ICredentialDataDecryptedObject | undefined>;
    private resolveValue;
    getParentTypes(typeName: string): string[];
    getCredentials(nodeCredential: INodeCredentialsDetails, type: string): Promise<Credentials>;
    private getCredentialsEntity;
    getCredentialsProperties(type: string): INodeProperties[];
    getDecrypted(additionalData: IWorkflowExecuteAdditionalData, nodeCredentials: INodeCredentialsDetails, type: string, mode: WorkflowExecuteMode, executeData?: IExecuteData, raw?: boolean, expressionResolveValues?: ICredentialsExpressionResolveValues): Promise<ICredentialDataDecryptedObject>;
    applyDefaultsAndOverwrites(additionalData: IWorkflowExecuteAdditionalData, decryptedDataOriginal: ICredentialDataDecryptedObject, type: string, mode: WorkflowExecuteMode, executeData?: IExecuteData, expressionResolveValues?: ICredentialsExpressionResolveValues): Promise<ICredentialDataDecryptedObject>;
    updateCredentials(nodeCredentials: INodeCredentialsDetails, type: string, data: ICredentialDataDecryptedObject): Promise<void>;
    updateCredentialsOauthTokenData(nodeCredentials: INodeCredentialsDetails, type: string, data: ICredentialDataDecryptedObject, additionalData: IWorkflowExecuteAdditionalData): Promise<void>;
}
export declare function createCredentialsFromCredentialsEntity(credential: ICredentialsDb, encrypt?: boolean): Credentials;
