import { GetByProductParams, Records, Storable, JacksonOptionWithRequiredLogger } from '../typings';
import type { SSOTrace, Trace } from './types';
declare class SSOTraces {
    tracesStore: Storable;
    opts: JacksonOptionWithRequiredLogger;
    constructor({ tracesStore, opts }: {
        tracesStore: any;
        opts: any;
    });
    saveTrace(payload: SSOTrace): Promise<string | undefined>;
    /**
     * @openapi
     * components:
     *   schemas:
     *     SSOTrace:
     *       type: object
     *       properties:
     *         traceId:
     *           type: string
     *           description: Trace ID
     *         error:
     *           type: string
     *           description: Error
     *         timestamp:
     *           type: string
     *           description: Timestamp
     *         context:
     *           type: object
     *           properties:
     *             tenant:
     *               type: string
     *               description: Tenant
     *             product:
     *               type: string
     *               description: Product
     *             clientID:
     *               type: string
     *               description: Connection client ID
     *             issuer:
     *               type: string
     *               description: Issuer
     *             relayState:
     *               type: string
     *               description: Relay state
     *             samlResponse:
     *               type: string
     *               description: SAML response
     *             isSAMLFederated:
     *               type: boolean
     *               description: Indicates if SAML is federated
     *             isOIDCFederated:
     *               type: boolean
     *               description: Indicates if OIDC is federated
     *             isIdPFlow:
     *               type: boolean
     *               description: Indicates if request is from IdP
     *
     */
    /**
     * @openapi
     * /api/v1/sso-traces:
     *   get:
     *     tags:
     *       - SSO Traces
     *     summary: Get trace by ID
     *     parameters:
     *       - name: id
     *         in: query
     *         description: Trace ID
     *         required: true
     *         schema:
     *           type: string
     *     responses:
     *       200:
     *         description: Success
     *         content:
     *           application/json:
     *             schema:
     *               $ref: "#/components/schemas/SSOTrace"
     */
    getByTraceId(traceId: string): Promise<Trace>;
    getAllTraces(pageOffset?: number, pageLimit?: number, pageToken?: string): Promise<Records<Trace>>;
    /** Cleans up stale traces older than 1 week */
    cleanUpStaleTraces(): Promise<void>;
    /**
     * @openapi
     * /api/v1/sso-traces/product:
     *   get:
     *     tags:
     *       - SSO Traces
     *     summary: Get all traces for a product
     *     parameters:
     *      - $ref: '#/components/parameters/product'
     *      - $ref: '#/components/parameters/pageOffset'
     *      - $ref: '#/components/parameters/pageLimit'
     *      - $ref: '#/components/parameters/pageToken'
     *     responses:
     *       '200':
     *         description: Success
     *         content:
     *           application/json:
     *              schema:
     *                type: object
     *                properties:
     *                  data:
     *                    type: array
     *                    items:
     *                      $ref: '#/components/schemas/SSOTrace'
     *                  pageToken:
     *                    type: string
     *                    description: token for pagination
     */
    getTracesByProduct(params: GetByProductParams): Promise<Records<any>>;
    deleteTracesByProduct(product: string): Promise<void>;
    countByProduct(product: string): Promise<number | undefined>;
}
export default SSOTraces;
