add_document

The function add_document(document, collection_name) uploads a single document to a collection.

Input

  • document – Represents the document to upload. The structure of each document must conform to the database schema configuration file. It must be of type dictionary.

  • collection_name – Specifies the name of the Collection into which to load the document.

Example

hyperspace_client.add_document(document, collection_name)

Response

The following response should be received –

{'status': 'OK', 'code': 200, 'message': 'Document was successfully added'}

Last updated