package com.yn.bftl.thirdparty.modules.secret.controller;

import com.yn.bftl.thirdparty.modules.secret.service.RandomKeyService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@Api(value = "AuthMemberController", tags = "加密随机因子")
@RestController
@RequestMapping("/random/secret")
public class RandomKeyController {

    @Resource
    private RandomKeyService randomKeyService;

    @ApiOperation(value = "获取一个随机因子")
    @RequestMapping(value = "/get", method = RequestMethod.GET)
    public String get() {
        return this.randomKeyService.getOneKey();
    }
}
