import { Global, Module } from '@nestjs/common';
import { JwtModule } from '@nestjs/jwt';
import { PublicApiCryptoService } from '../crypto/public-api-crypto.service';
import { CryptoToolsController } from '../crypto/crypto-tools.controller';
import { EncryptedResponseInterceptor } from '../interceptors/encrypted-response.interceptor';
import { InternalCryptoKeyGuard } from '../guards/internal-crypto-key.guard';
import { PublicApiKeyGuard } from '../guards/public-api-key.guard';

@Global()
@Module({
  imports: [JwtModule.register({})],
  controllers: [CryptoToolsController],
  providers: [PublicApiCryptoService, PublicApiKeyGuard, InternalCryptoKeyGuard, EncryptedResponseInterceptor],
  exports: [PublicApiCryptoService, PublicApiKeyGuard, InternalCryptoKeyGuard, EncryptedResponseInterceptor],
})
export class PublicApiModule {}
