Skip to content

doc: missed WOQLClient key parameter description from «Connect to docker with js-client» tutorial #13

@alexander-mart

Description

@alexander-mart

Is your feature request related to a problem? Please describe.

Missed instructions about what is a key from WOQLClient() parameters and how to get or generate it.

Quote from tutorial: Connect with the JavaScript Client

Whether you are connecting to a local docker, a local server, or a server that you've set up somewhere, you can use the following to log in to TerminusDB.

Code fragment from tutorial

const client = new TerminusClient.WOQLClient(SERVER_URL,{user:"admin",key:"myKey"})

Doc source:

"value": "Ensure you have installed the JavaScript Client. See here for [installation instructions](/docs/install-terminusdb-js-client/)\n\n## Connecting with the JavaScript Client\n\nDepending on whether you are connecting to an instance you have set up yourself, or whether you are using TerminusCMS in the cloud, there are two different methods of connection.\n\nIn both cases, you should load the TerminusDB client in your script with the following:\n\n```javascript\nconst TerminusClient = require(\"@terminusdb/terminusdb-client\");\n```\n\n## TerminusCMS\n\nThe TerminusCMS endpoint has the form https://cloud.terminusdb.com/TEAM/ where TEAM is the name of the team you are using in TerminusCMS for the data products you want to access.\n\nIn order to connect to this team, you will need to [get your API key](/docs/how-to-connect-terminuscms/) after selecting the team you want to use.\n\nTo create a client use the following code within your script, ensuring to use your credentials.\n\n```javascript\nconst client = new TerminusClient.WOQLClient('https://cloud.terminusdb.com/Team',\n {user:\"[email protected]\", organization:'Team'})\n​\nclient.setApiKey(MY_ACCESS_TOKEN)\n```\n\n## Connecting to a TerminusDB installation\n\nWhether you are connecting to a local docker, a local server, or a server that you've set up somewhere, you can use the following to log in to TerminusDB.\n\n```javascript\nconst client = new TerminusClient.WOQLClient(SERVER_URL,{user:\"admin\",key:\"myKey\"})\n\nasync function getSchema() {\n client.db(\"DB_NAME\")\n const schema = await client.getSchema()\n}\n```\n\n> Try out the [Getting Started with the TerminusDB JavaScript Client](https://github.com/terminusdb/terminusdb-tutorials/blob/main/getting_started/javascript-client/lesson_1.md) five-part tutorial to get to grips with it."

Describe the solution you'd like

Describe alternatives you've considered

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions