delete https://api.keeptruckin.com/v1/groups//users
Delete users (drivers) from a group
require 'uri'
require 'net/http'
require 'json'
url = URI('https://api.keeptruckin.com/v1/groups/<id>/users')
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request['Authorization'] = "Bearer <OAUTH_TOKEN>"
request['Content-Type'] = 'application/json'
params = {
:ids => [14]
}
request.body = params.to_json
response = http.request(request)
puts response.read_body