While I have no issue making a GET request to basecamp, I keep getting an
error every time I make a POST request. The error is
*RestClient::UnsupportedMediaType:* 415 Unsupported Media Type. Does
anyone know why I might be getting this. Below is the method I'm calling
for the POST request.
def create_bc_project(name, description)
my_url = "https://basecamp.com/1942899/api/v1/projects.json"
my_user = "<my user name>"
my_password = "<my password>"
resource = RestClient::Request.new(
:method => :post,
:url => my_url,
:content_type => "application/json; charset=utf-8",
:user_agent => "MyApp",
:user => my_user,
:password => my_password,
:payload => { :name => name, :description => description }
).execute
end