# candor-js-lib

> JavaScript/TypeScript library created by Candor Services for interfacing with Project Mercury's API.

Latest version **1.0.0** (published 2023-09-14) · ISC license · 0 weekly downloads

## Install

```sh
npm install candor-js-lib
pnpm add candor-js-lib
yarn add candor-js-lib
bun add candor-js-lib
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2023-09-14 |
| First published | 2023-09-14 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 13.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | seailz |

## Links

- npm: https://www.npmjs.com/package/candor-js-lib
- npm.io page: https://npm.io/package/candor-js-lib

## Recent versions

- 1.0.0 (latest) — 2023-09-14

## README

# candor-js
JS/TS Library for Candor Services' Project Mercury API.

## Documentation
You can add the library to your project with:
```
npm install candor-mercury
```
You can then get started by intializing a new instance of the `Candor` clas using your public API key found at https://candorian.app/api-dashboard.

### Verifying a license
You can verify if a license is valid using this function:
```js
let valid = await candor.verifyLicense(LICENSE_KEY, PRODUCT_ID);
```

You'll want to grab your product ID from https://candorian.app/license-manager by creating a new product and then adding a license. The license key should be added by the client, using some sort of config (we recommend remote configs, see below!). Assign your license to your client using the tools in the dashboard.

### Retrieving a remote config
Remote configs allow clients to easily configure parts of their apps without having to mess with complicated or messy configuration files. You can use this function:
```js
let obj = await candor.getConfig(CONFIG_ID);
```
to retrieve the remote config as a JS object. You can create a remote config at https://candorian.app/config-manager.

## Need support?
If you need help with anything to do with this project, then please see the [project-mercury-support](https://canary.discord.com/channels/650773903236399134/1146431646418079744) channel in Discord under the FREELANCERS category.

---
_Source: https://npm.io/package/candor-js-lib · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
