This commit is contained in:
2026-08-28 17:31:02 +02:00
commit 2b30e8bd39
694 changed files with 49243 additions and 0 deletions
@@ -0,0 +1,30 @@
import { Body, Controller, Get, Post, UseGuards } from '@nestjs/common';
import { Throttle } from '@nestjs/throttler';
import { JwtGuard } from '../../../guards/JwtGuard';
import { throttleProfiles } from '../../../config/throttleProfiles';
import { MoneroWalletRevealSeedDto } from '../dto/MoneroWalletRevealSeedDto';
import { MoneroWalletWithdrawDto } from '../dto/MoneroWalletWithdrawDto';
import { MoneroWalletAdminService } from '../services/MoneroWalletAdminService';
@Controller('monero-wallet')
@UseGuards(JwtGuard)
export class MoneroWalletController {
constructor(private readonly walletAdminService: MoneroWalletAdminService) {}
@Get('/')
getStatus() {
return this.walletAdminService.getStatus();
}
@Post('/withdraw')
@Throttle(throttleProfiles.walletWithdraw)
withdraw(@Body() { destinationAddress, password }: MoneroWalletWithdrawDto) {
return this.walletAdminService.withdrawAll(destinationAddress, password);
}
@Post('/reveal-seed')
@Throttle(throttleProfiles.walletRevealSeed)
revealSeed(@Body() { password }: MoneroWalletRevealSeedDto) {
return this.walletAdminService.revealSeed(password);
}
}