The following macros are not currently supported in the header:
  • style

PUT /companies/:id

Resource URL

Update a company object.

PUT /companies/:id
POST /companies/:id?_method=put

Parameters

Table of allowed parameters.

websitestringThe new company's website
phonestringThe new company's phone number.
faxstringThe new company's fax.
notesstringNotes to be stored against the new company.
forced_status_idunsigned integer

Changing a company status is subject to progressions, which when requires user interactions can be quite complex to achieve through a restful api. To work around this we do allow you to forcefully update an id, which bypasses all progressions. Please do not this argument if you want progressions to be respected in your changes.

Feature restricted

Currently this parameter is feature restricted and experimental. If you would like to use, please contact support and we can switch the feature on for you. Please reference this documentation and the feature "allow_forced_status_id".
_fieldspartial stringAllows you to specify optional fields and linked objects to include in the response.

Handling the response

Below is a table of available response fields and objects that are returned within the response object of the returned object. The optional fields and objects can be requested in the _fields parameter; see included examples. Underlined values are default.

idunsigned int
namestring
websitestring
standingstring
statusunsigned int or object
phonestring
faxstring
date_createdunsigned int
date_modifiedunsigned int
commentsstring
contactunsigned int or object

Sample Response

PUT /companies/4.json?phone=123456789&_fields=phone
{
   "response" : { 
		 "name" : "BobsHouse",
         "id" : "4",
		 "phone": "123456789"
    },
   "meta" : {
      "status" : "ok",
      "message" : "Everything executed as expected."
   }
}