File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -37,9 +37,9 @@ collection into the Documents database using MarkLogic's built-in REST server
3737at port 8000:
3838
3939``` javascript
40- var marklogic = require (' marklogic' );
40+ const marklogic = require (' marklogic' );
4141
42- var db = marklogic .createDatabaseClient ({
42+ const db = marklogic .createDatabaseClient ({
4343 host: ' localhost' ,
4444 port: ' 8000' ,
4545 database: ' Documents' ,
@@ -48,6 +48,14 @@ var db = marklogic.createDatabaseClient({
4848 authType: ' DIGEST'
4949});
5050
51+ // For MarkLogic Cloud
52+ const db = marklogic .createDatabaseClient ({
53+ apiKey: ' changeme' ,
54+ host: ' example.beta.marklogic.com' ,
55+ authType: ' cloud' ,
56+ basePath: ' /marklogic/test'
57+ });
58+
5159db .createCollection (
5260 ' /books' ,
5361 {author: ' Beryl Markham' , ... },
You can’t perform that action at this time.
0 commit comments