import { AdapterArgs } from '../../runtime/http'; import { ConfigInterface } from '../base-types'; import { HashFormat } from '../../runtime/crypto/types'; import { AuthQuery } from '../auth/oauth/types'; import { WebhookTypeValue } from '../webhooks/types'; import { ValidationInvalid, HmacValidationType, ValidationValid } from './types'; export type HMACSignator = 'admin' | 'appProxy'; export interface ValidateParams extends AdapterArgs { /** * The type of validation to perform, either 'flow' or 'webhook'. */ type: HmacValidationType; /** * The raw body of the request. */ rawBody: string; /** * The webhook type for header selection (optional, only for webhooks). */ webhookType?: WebhookTypeValue; } export declare function generateLocalHmac(config: ConfigInterface): (params: AuthQuery, signator?: HMACSignator) => Promise; export declare function validateHmac(config: ConfigInterface): (query: AuthQuery, { signator }?: { signator: HMACSignator; }) => Promise; export declare function validateHmacString(config: ConfigInterface, data: string, hmac: string, format: HashFormat): Promise; export declare function getCurrentTimeInSec(): number; export declare function validateHmacFromRequestFactory(config: ConfigInterface): ({ type, rawBody, webhookType, ...adapterArgs }: ValidateParams) => Promise; //# sourceMappingURL=hmac-validator.d.ts.map