标签:lang https pre bundle rest target mfile tps 添加
github地址
https://github.com/rest-client/rest-client
gemfile里添加
gem ‘rest-client‘, ‘~> 2.0‘
执行
bundle install
代码里
# 要请求接口地址
# 上传文件的key名字
# file 文件的绝对路径
resp = RestClient.post url, :file => File.new(file, ‘rb‘)
标签:lang https pre bundle rest target mfile tps 添加
原文地址:https://www.cnblogs.com/haima/p/14773835.html