"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.metadata=void 0;const query_1=require("@b/utils/query");exports.metadata={summary:"Deletes a specific API key",operationId:"deleteApiKey",tags:["Admin","API Keys"],logModule:"ADMIN_API",logTitle:"Delete API",parameters:(0,query_1.deleteRecordParams)("API Key"),responses:(0,query_1.deleteRecordResponses)("API Key"),permission:"delete.api.key",requiresAuth:!0};exports.default=async e=>{const{params:t,query:s,ctx:r}=e;null==r||r.step("Validating API key ID");null==r||r.step(`Deleting API key: ${t.id}`);const a=await(0,query_1.handleSingleDelete)({model:"apiKey",id:t.id,query:s});null==r||r.success();return a};