Client
The class which is used to interact with the Wiki.js API.
Constructor
new Client({options});
Returns a Client.
| Parameter | Type | Description | Required |
|---|---|---|---|
| baseURL | String | Wiki.js API address, usually ends with /graphql | ✅ |
| token | String | Wiki.js API token | ✅ |
Properties
- <Client>.pages
Used to access methods related to Wiki.js pages.
Created upon login.
Null if accessed prior to a successful login.
Type: ?PageManager
Methods
- <Client>.login()
Used to verify provided Client options and connect to the Wiki.js API.
Upon successful verification method returns the title of the Wiki.js instance.
Returns: Promise<String>