import * as plugins from '../plugins.js'; import type * as authInterfaces from '../data/auth.js'; import type { IAcmeConfig } from '../data/acme-config.js'; // ============================================================================ // ACME Config Endpoints // ============================================================================ /** * Get the current ACME configuration. Returns null if no config has been * set yet (neither from DB nor seeded from the constructor). */ export interface IReq_GetAcmeConfig extends plugins.typedrequestInterfaces.implementsTR< plugins.typedrequestInterfaces.ITypedRequest, IReq_GetAcmeConfig > { method: 'getAcmeConfig'; request: { identity?: authInterfaces.IIdentity; apiToken?: string; }; response: { config: IAcmeConfig | null; }; } /** * Update the ACME configuration (upsert). All fields are required on first * create, optional on subsequent updates (partial update). * * NOTE: Most fields take effect on the next dcrouter restart — SmartAcme is * instantiated once at startup. `renewThresholdDays` applies immediately to * the next renewal check. */ export interface IReq_UpdateAcmeConfig extends plugins.typedrequestInterfaces.implementsTR< plugins.typedrequestInterfaces.ITypedRequest, IReq_UpdateAcmeConfig > { method: 'updateAcmeConfig'; request: { identity?: authInterfaces.IIdentity; apiToken?: string; accountEmail?: string; enabled?: boolean; useProduction?: boolean; autoRenew?: boolean; renewThresholdDays?: number; }; response: { success: boolean; config?: IAcmeConfig; message?: string; }; }