# File lib/chef_zero/endpoints/rest_list_endpoint.rb, line 24 def post(request) contents = request.body key = get_key(contents) if key.nil? error(400, "Must specify '#{identity_key}' in JSON") else create_data(request, request.rest_path, key, contents) json_response(201, {'uri' => "#{build_uri(request.base_uri, request.rest_path + [key])}"}) end end