qcobjects-lib-cosmosdb
v0.0.18
Published
QCObjects Lib for work with Microsoft Cosmosdb Database.
Downloads
2
Maintainers
Readme
QCObjects Lib Cosmosdb
QCObjects Lib for work with Microsoft Cosmosdb Database.
Instructions
- Install this dependency in your project using npm
npm i --save qcobjects-lib-cosmosdb
- In your config.json file, create the following settings
{
"CosmosDB":{
"endpoint": "$ENV(COSMOSDB_ENDPOINT)",
"key": "$ENV(COSMOSDB_API_KEY)",
"database": "$ENV(COSMOSDB_DATABASE)",
"userAgentSuffix": "QCObjectsCosmosDBAPIClient",
"partitionKey": ["$ENV(COSMOSDB_PARTITION_KEY)"]
}
}
Above settings will bring the API Key values from the following environment variables:
COSMOSDB_ENDPOINT COSMOSDB_API_KEY COSMOSDB_DATABASE COSMOSDB_PARTITION_KEY
Learn more about Accessing Microsoft CosmosDb in the official Microsoft Documentation website
- Test the integration
npm test
- Start the QCObjects HTTP2 Server
qcobjects-server
If you haven't installed QCObjects before, learn more about Installing QCObjects here