Skip to content

Latest commit

 

History

History
40 lines (29 loc) · 849 Bytes

README.md

File metadata and controls

40 lines (29 loc) · 849 Bytes

Doctrine CouchDB Client

Build Status

Simple API that wraps around CouchDBs HTTP API.

Features

  • Create, Delete Databases
  • Create, Update, Delete Documents
  • Bulk API for Creating/Updating Documents
  • Find Documents by ID
  • Generate UUIDs
  • Query _all_docs view
  • Query Changes Feed
  • Compaction Info and Triggering APIs
  • Replication API
  • Symfony Console Commands

Installation

With Composer:

{
    "require": {
        "doctrine/couchdb": "@dev"
    }
}

Usage

<?php
$client = \Doctrine\CouchDB\CouchDBClient::create();

array($id, $rev) = $client->postDocument(array('foo' => 'bar'));
$client->putDocument(array('foo' => 'baz'), $id, $rev);

$doc = $client->findDocument($id);