@wise-old-man/utils 2.0.6 → 2.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +29 -0
  2. package/package.json +16 -5
package/README.md ADDED
@@ -0,0 +1,29 @@
1
+ # Wise Old Man - Web Client
2
+
3
+ A JavaScript/TypeScript client that interfaces and consumes the [Wise Old Man API](https://wiseoldman.net), an API that tracks and measures players' progress in Old School Runescape.
4
+
5
+ API Documentation: https://docs.wiseoldman.net
6
+
7
+ ### Installation
8
+
9
+ `npm i @wise-old-man/utils`
10
+
11
+ ### Usage
12
+
13
+ ```javascript
14
+ const { WOMClient, CompetitionStatus, MetricProps } = require('@wise-old-man/utils');
15
+
16
+ const client = new WOMClient();
17
+
18
+ // Example API request
19
+ const competitions = await client.competitions.searchCompetitions(
20
+ { title: 'the', status: CompetitionStatus.ONGOING },
21
+ { limit: 5 }
22
+ );
23
+
24
+ // Example utils
25
+ competitions.forEach(c => {
26
+ // Example: "Skill Of The Week", "Mining", false
27
+ console.log(c.name, MetricProps[c.metric].name, MetricProps[c.metric].isMembers);
28
+ });
29
+ ```
package/package.json CHANGED
@@ -1,7 +1,21 @@
1
1
  {
2
2
  "name": "@wise-old-man/utils",
3
- "version": "2.0.6",
4
- "description": "",
3
+ "version": "2.0.7",
4
+ "description": "A JavaScript/TypeScript client that interfaces and consumes the Wise Old Man API, an API that tracks and measures players' progress in Old School Runescape.",
5
+ "keywords": [
6
+ "wiseoldman",
7
+ "wom",
8
+ "osrs",
9
+ "runescape",
10
+ "oldschool",
11
+ "api"
12
+ ],
13
+ "author": "Psikoi",
14
+ "license": "ISC",
15
+ "repository": {
16
+ "type": "git",
17
+ "url": "https://github.com/wise-old-man/wise-old-man.git"
18
+ },
5
19
  "main": "dist/index.js",
6
20
  "types": "dist/index.d.ts",
7
21
  "files": [
@@ -13,9 +27,6 @@
13
27
  "prebuild": "cd ../server && npm run prisma:generate",
14
28
  "build": "rm -rf ./dist && npx rollup -c && node prisma-transform.js && tsc dist/index.d.ts"
15
29
  },
16
- "keywords": [],
17
- "author": "",
18
- "license": "ISC",
19
30
  "devDependencies": {
20
31
  "@rollup/plugin-typescript": "^8.3.4",
21
32
  "@typescript-eslint/eslint-plugin": "^5.40.1",