Method: Parse::API::Objects#update_object

Defined in:
lib/parse/api/objects.rb

#update_object(className, id, body = {}, headers: {}, **opts) ⇒ Parse::Response

Update an object in a collection.

Parameters:

  • className (String)

    the name of the Parse collection.

  • id (String)

    The objectId of the record in the collection.

  • body (Hash) (defaults to: {})

    The key value pairs to update.

  • opts (Hash)

    additional options to pass to the Client request.

  • headers (Hash) (defaults to: {})

    additional HTTP headers to send with the request.

Returns:



113
114
115
116
117
# File 'lib/parse/api/objects.rb', line 113

def update_object(className, id, body = {}, headers: {}, **opts)
  response = request :put, uri_path(className,id) , body: body, headers: headers, opts: opts
  response.parse_class = className if response.present?
  response
end