8.2. PUT /db/_design/design-doc

MethodPUT /db/_design/design-doc
Request JSON of the design document
Response JSON status
Admin Privileges Requiredno

Upload the specified design document, design-doc, to the specified database. The design document should follow the definition of a design document, as summarised in the following table.

Table 8.2.  Design Document

FieldDescription
_id Design Document ID
_rev Design Document Revision
views View
        viewname View Definition
                map Map Function for View
                reduce (optional) Reduce Function for View

For more information on writing views, see ???.