Gem: POST method needs "body" rather then "parameters" parameter

Open
#53 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
45/100
Issue type
Documentation
Clarity
Clearly specified
Activity status
Stale
Tech stack
ruby
Domain
documentation

Research direction

Start with the POST method signature shown in the issue and compare it with the gem documentation for POST requests. Update the documented parameter from "parameters" to "body", then verify that the example matches the method signature.

Written by the indexing model from the issue text.

Description

After being unsuccessful in doing a POST request as per the documentation I dug into the code in the current version of the gem on rubygems (unirest-1.0.8) and discovered that while the documentation states that the post method takes a "parameters" parameter with the POST body, the actual method is expecting a "body" parameter.

  def self.post(url, headers = {}, body = nil, &callback)
    return HttpClient.request(:post, url, headers, body, &callback)
  end
Dominant language
Ruby
Stars
364
Forks
76
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Kong/unirest-ruby

All issues in Kong/unirest-ruby

Similar issues

More Ruby issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.