DB::MONGO
Establish connection to MongoDB.
Syntax
resources:
<resource-id>:
type: DB::MONGO
props:
username: <username>
password: <password>
connectionString: "mongodb://localhost"
dbName: <database>
Properties
Property | Description | Type |
---|---|---|
<resource-id> | Unique identifier for the resource | string |
type | Type of the resource | string |
props | Properties specific to this resource. Refer to props section for more details. | object |
props
Property | Description | Type | Required |
---|---|---|---|
username | Username for Mongo | string | true |
password | Password for Mongo | string | true |
connectionString | Mongo connection | string | true |
dbName | Mongo DB name | string | true |
Example
resources:
mongodb:
type: DB::MONGO
props:
username: username
password: password
connectionString: "mongodb://localhost"
dbName: database