feat: api keys

This commit is contained in:
Ahmed Bouhuolia
2025-07-01 23:45:38 +02:00
parent 84cb7693c8
commit 9457b3cda1
7 changed files with 87 additions and 20 deletions

View File

@@ -1,4 +1,4 @@
import { Controller, Post, Param, Get } from '@nestjs/common';
import { Controller, Post, Param, Get, Put } from '@nestjs/common';
import { GenerateApiKey } from './commands/GenerateApiKey.service';
import { GetApiKeysService } from './queries/GetApiKeys.service';
@@ -14,7 +14,7 @@ export class AuthApiKeysController {
return this.generateApiKeyService.generate();
}
@Post(':id/revoke')
@Put(':id/revoke')
async revoke(@Param('id') id: number) {
return this.generateApiKeyService.revoke(id);
}