Skip to content
This repository has been archived by the owner on Jul 1, 2019. It is now read-only.

Commit

Permalink
Merge pull request #2 from mikhuang/master
Browse files Browse the repository at this point in the history
Added create_or_update_documents
  • Loading branch information
Nevon committed Jan 21, 2013
2 parents 54c1529 + fb678b5 commit 079bbe3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions swiftype.php
Expand Up @@ -91,6 +91,10 @@ public function update_documents($engine_id, $document_type_id, $documents = arr
return $this->put($this->documents_path($engine_id, $document_type_id).'/bulk_update', array(), array('documents' => $documents));
}

public function create_or_update_documents($engine_id, $document_type_id, $documents = array()) {
return $this->post($this->documents_path($engine_id, $document_type_id).'/bulk_create_or_update', array(), array('documents' => $documents));
}

public function destroy_document($engine_id, $document_type_id, $document_id) {
return $this->delete($this->document_path($engine_id, $document_type_id, $document_id));
}
Expand Down

0 comments on commit 079bbe3

Please sign in to comment.