class AccountController {

    @Path("/confirm2fa")
    @POST
    @Produces(MediaType.TEXT_HTML)
    @Consumes(MediaType.APPLICATION_FORM_URLENCODED)
    @Operation(
        summary = "Confirm two factor authentication",
        description = "Confirm two factor authentication.",
        tags = {"accounts"},
        responses = {
            @ApiResponse(responseCode = "200", description = "Successful execution",
                content = @Content(mediaType = "text/html",
                    schema = @Schema(implementation = Account2FADTO.class)))
        })

    @PermitAll
    @Secured2FA
    public Response confirm2FA(
        @Parameter(description = "The passphrase") @FormParam("passphrase") String passphraseParam,
        @Parameter(description = "The secret phrase") @FormParam("secretPhrase") String secretPhraseParam,
        @Parameter(description = "The account ID.") @FormParam("account") String accountStr,
        @Parameter(description = "The 2FA code.", required = true) @FormParam("code2FA") @NotNull Integer code2FA,
        @Context org.jboss.resteasy.spi.HttpRequest request
    ) {
        ResponseBuilder response = ResponseBuilder.startTiming();
        TwoFactorAuthParameters params2FA = RestParametersParser.get2FARequestAttribute(request);

        account2FAHelper.confirm2FA(params2FA);
        Account2FADTO dto = faConverter.convert(params2FA);

        return response.bind(dto).build();
    }

    @Inject public  AccountController(Blockchain blockchain,
                             Account2FAHelper account2FAHelper,
                             AccountService accountService,
                             AccountPublicKeyService accountPublicKeyService,
                             AccountAssetService accountAssetService,
                             AccountCurrencyService accountCurrencyService,
                             AccountAssetConverter accountAssetConverter,
                             AccountCurrencyConverter accountCurrencyConverter,
                             AccountConverter converter,
                             BlockConverter blockConverter,
                             WalletKeysConverter walletKeysConverter,
                             Account2FADetailsConverter faDetailsConverter,
                             Account2FAConverter faConverter,
                             @AskOrderService OrderService<AskOrder, ColoredCoinsAskOrderPlacement> orderService,
                             FirstLastIndexParser indexParser,
                             AccountStatisticsService accountStatisticsService);

}