Using the UPDATE API, you can Update Public and Private bins.

Request Type
Request Headers
Header Value Required
Content-Type application/json Yes
secret-key <YOUR_SECRET_KEY> Optional
versioning false Optional

Content-Type needs to be set to application/json. The request will result in an error in-case of a missing Content-Type header.


secret-key is an optional header. It is required when you need to Update a Private record. You can find your secret-key on the API Keys page after signing-in.


versioning is an optional header. You need to pass versioning: false header to disable versioning while you are Updating a record. Note that you can disable versioning on Private records only.


Use versioning: false header to disable versioning if you are going to update the records frequently.


You cannot Disable Versioning on Public Records.

More on Versioning header

Updating a newly Created Bin, using versioning: false header will result in updating the base record only. No further versions will be created whatsoever.

Updating a Bin where the versions were created already, in this case, the last version of the bin will get updated. For example, a bin having 7 versions already, and then you start passing the versioning: false header, it will keep on updating the 7th version of the bin.

Basic Code Samples
curl --header "Content-Type: application/json" \
       --request PUT \
       --data '{"sample": "Hello World"}' \<BIN_ID>
let req = new XMLHttpRequest();

req.onreadystatechange = () => {
  if (req.readyState == XMLHttpRequest.DONE) {
};"PUT", "<BIN_ID>", true);
req.setRequestHeader("Content-Type", "application/json");
req.send('{"Sample": "Hello World"}');
import requests
url = '<BIN_ID>'
headers = {'Content-Type': 'application/json'}
data = {"Sample": "Hello World"}

req = requests.put(url, json=data, headers=headers)
require 'net/http'
require 'json'

uri = URI("<BIN_ID>")
res = Net::HTTP.start(, uri.port, use_ssl: true) do |http|
  req =
  req['Content-Type'] = 'application/json'

  req.body = {"Sample": "Hello World"}.to_json

puts res.body
Request Response

Success response will slightly differ if versioning is disabled.

    "Sample":"Hello World"
  "version": 1,
422, 404, 401
  "message": "<ERROR_MESSAGE>",
  "success": false
Status Code Error Message
422 Unprocessible Entity
Expected content type - application/json

Fix: You need to pass Content-Type: application/json in the headers.

422 Unprocessible Entity
JSON cannot be empty

Fix: You cannot store an empty JSON record, hence, you need to pass some data to store it.

422 Unprocessible Entity
Invalid Bin ID

Fix: You need to pass a valid Bin ID in-order to Update a bin.

404 Not Found
Bin not found

Fix: Check your Bin ID and pass a Valid Bin ID.

401 Unauthorized
Need to provide a secret-key to UPDATE private bins

Fix: While Updating a Private record, you need to pass secret-key header to update the Private record.

401 Unauthorized
Invalid secret key provided

Fix: Ensure you provide a valid secret-key while Updating a Private record.