Oauth 2.0 BaseCamp API禁止在使用承载令牌授权头的PUT和POST上使用

Oauth 2.0 BaseCamp API禁止在使用承载令牌授权头的PUT和POST上使用,oauth-2.0,omniauth,basecamp,Oauth 2.0,Omniauth,Basecamp,让请求正常工作 我正在使用omniauth basecamp和restclient: resource = RestClient::Resource.new( 'https://basecamp.com/27xxxxx/api/v1', headers: { user_agent: 'MyApp (me@example.com', authorization: "Bearer #{my_token}", content_type: "application/jso

让请求正常工作

我正在使用omniauth basecamp和restclient:

resource = RestClient::Resource.new(
  'https://basecamp.com/27xxxxx/api/v1',
  headers: {
    user_agent: 'MyApp (me@example.com',
    authorization: "Bearer #{my_token}",
    content_type: "application/json"
  }
)

resource['/projects/7213xxx/todos/129851xxx.json'].get # => 200 OK
resource['/projects/7213xxx/todos/129851xxx.json'].put(content: 'Hello!') # => 403 FORBIDDEN

问题是负载没有序列化为json,所以它是表单编码的

   payload = {content: 'Hello!!'}.to_json
   resource['/projects/7213xxx/todos/129851xxx.json'].put(payload) # => 200 OK
想知道响应是否应该是错误的请求而不是禁止的