Sending a post query sent via HTTParty

喜欢而已 提交于 2019-12-06 00:57:41

I reviewed the API, and the updates expect the JSON to be in the POST body, not the query string. Try :body instead of :query:

    def create(text)
        BufferApp.post('/updates/create.json', :body => {"text" => text, "profile_ids[]" => @id, "access_token" => @token})
    end
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!