Пример #1
0
        public ApiResponse GetQiniuToken()
        {
            const uint expire         = 60 * 60 * 24 * 30;
            DateTime   expirationDate = DateTime.Now.AddDays(30);
            string     token          = QiniuUtil.GetUpToken(expire);
            // WriteLog(token);
            var model = new QiniuToken
            {
                Token          = token,
                ExpirationTime = DateTimeConverter.ConvertDateTimeToDouble(expirationDate)
            };

            return(new ApiResponse(Metas.SUCCESS, model));
        }