@digitalocean/dots 1.13.0 → 1.14.0

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.
@@ -16,8 +16,8 @@ jobs:
16
16
  - name: Setup Node.js
17
17
  uses: actions/setup-node@v4
18
18
  with:
19
- node-version: "18"
20
- caache: "npm"
19
+ node-version: "20"
20
+ cache: "npm"
21
21
 
22
22
  - name: Install dependencies
23
23
  run: make dev-dependencies
@@ -26,12 +26,17 @@ jobs:
26
26
  run: make lint
27
27
 
28
28
  test:
29
- name: Test
29
+ name: Test (Node ${{ matrix.node-version }})
30
30
  runs-on: ubuntu-latest
31
31
 
32
32
  needs:
33
33
  - lint
34
-
34
+
35
+ strategy:
36
+ fail-fast: false
37
+ matrix:
38
+ node-version: ["20", "22"]
39
+
35
40
  steps:
36
41
  - name: Check out code
37
42
  uses: actions/checkout@v4
@@ -39,7 +44,7 @@ jobs:
39
44
  - name: Setup Node.js
40
45
  uses: actions/setup-node@v4
41
46
  with:
42
- node-version: "18"
47
+ node-version: ${{ matrix.node-version }}
43
48
  cache: "npm"
44
49
 
45
50
  - name: Install dependencies
@@ -15,7 +15,7 @@ jobs:
15
15
  - name: Setup Node.js
16
16
  uses: actions/setup-node@v4
17
17
  with:
18
- node-version: '18'
18
+ node-version: '20'
19
19
  registry-url: 'https://registry.npmjs.org'
20
20
 
21
21
  - name: Install dependencies
@@ -58,9 +58,9 @@ jobs:
58
58
  GH_TOKEN: ${{secrets.WORKFLOW_TOKEN}}
59
59
 
60
60
  - name: Install Node.js
61
- uses: actions/setup-node@v3
61
+ uses: actions/setup-node@v4
62
62
  with:
63
- node-version: 18
63
+ node-version: "20"
64
64
 
65
65
  - name: Install Dependencies
66
66
  run: npm install
package/CONTRIBUTING.md CHANGED
@@ -12,7 +12,7 @@ DoTs is a generated client. This section will walk you through generating the cl
12
12
 
13
13
  ### Prerequisites
14
14
 
15
- * NodeJs version: >= 18
15
+ * NodeJs version: >= 20.10
16
16
  * [npm](https://www.npmjs.com/): To manage TypeScript/JavaScript dependencies
17
17
  * [Kiota](https://github.com/microsoft/kiota): The tool that generates the client libraries for accessing RESTful web services.
18
18
 
@@ -68,7 +68,7 @@ DoTs is a generated client. This section will walk you through generating the cl
68
68
  We use `jest` to define and run the tests.
69
69
 
70
70
  **_Requirements_**
71
- - [NodeJS 18 or above](https://nodejs.org/en/)
71
+ - [NodeJS 20.10 or above](https://nodejs.org/en/)
72
72
  - [TypeScript 5 or above](https://www.typescriptlang.org/)
73
73
  - [Jest 30 or above](https://www.npmjs.com/package/jest)
74
74
  - A DigitalOcean account with an active subscription. Along with a DigitalOcean token with proper permissions to manage DigitalOcean resources (for integration testing).
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
  ## Getting Started
5
5
  #### Prerequisites
6
- - [NodeJS 18 or above](https://nodejs.org/en/)
6
+ - [NodeJS 20.10 or above](https://nodejs.org/en/)
7
7
  - [TypeScript 5 or above](https://www.typescriptlang.org/)
8
8
  - A DigitalOcean account with an active subscription. Along with a DigitalOcean token with proper permissions to manage DigitalOcean resources.
9
9
  - `"type": "module"` in your package.json (for ES module support)
@@ -12,7 +12,7 @@ DoTs is a generated client. This section will walk you through generating the cl
12
12
 
13
13
  ### Prerequisites
14
14
 
15
- * NodeJs version: >= 18
15
+ * NodeJs version: >= 20.10
16
16
  * [npm](https://www.npmjs.com/): To manage TypeScript/JavaScript dependencies
17
17
  * [Kiota](https://github.com/microsoft/kiota): The tool that generates the client libraries for accessing RESTful web services.
18
18
 
@@ -68,7 +68,7 @@ DoTs is a generated client. This section will walk you through generating the cl
68
68
  We use `jest` to define and run the tests.
69
69
 
70
70
  **_Requirements_**
71
- - [NodeJS 18 or above](https://nodejs.org/en/)
71
+ - [NodeJS 20.10 or above](https://nodejs.org/en/)
72
72
  - [TypeScript 5 or above](https://www.typescriptlang.org/)
73
73
  - [Jest 30 or above](https://www.npmjs.com/package/jest)
74
74
  - A DigitalOcean account with an active subscription. Along with a DigitalOcean token with proper permissions to manage DigitalOcean resources (for integration testing).
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@digitalocean/dots",
3
3
  "type": "module",
4
- "version": "1.13.0",
4
+ "version": "1.14.0",
5
5
  "description": "TypeScript client generator based on DigitalOcean's OpenAPI specification.",
6
6
  "main": "index.js",
7
7
  "scripts": {
@@ -20,6 +20,9 @@
20
20
  },
21
21
  "author": "DigitalOcean",
22
22
  "license": "Apache-2.0",
23
+ "engines": {
24
+ "node": ">=20.10.0"
25
+ },
23
26
  "keywords": [
24
27
  "digitalocean",
25
28
  "typescript",
@@ -1,5 +1,4 @@
1
- // @ts-expect-error: Importing JSON for dynamic version in User-Agent header
2
- import pkg from '../../package.json' assert { type: "json" };
1
+ import pkg from '../../package.json' with { type: "json" };
3
2
  /** Authenticate a request by using an API Key */
4
3
  export class DigitalOceanApiKeyAuthenticationProvider {
5
4
  /**
@@ -1,6 +1,5 @@
1
1
  import { AuthenticationProvider, RequestInformation } from "@microsoft/kiota-abstractions";
2
- // @ts-expect-error: Importing JSON for dynamic version in User-Agent header
3
- import pkg from '../../package.json' assert { type: "json" };
2
+ import pkg from '../../package.json' with { type: "json" };
4
3
 
5
4
  /** Authenticate a request by using an API Key */
6
5
  export class DigitalOceanApiKeyAuthenticationProvider implements AuthenticationProvider {
@@ -1,8 +1,7 @@
1
1
 
2
2
  import { DigitalOceanApiKeyAuthenticationProvider } from "../../src/dots/DigitalOceanApiKeyAuthenticationProvider.js";
3
3
  import { RequestInformation } from "@microsoft/kiota-abstractions";
4
- // @ts-expect-error: Importing JSON for dynamic version in test
5
- import pkg from '../../package.json' assert { type: "json" };
4
+ import pkg from '../../package.json' with { type: "json" };
6
5
 
7
6
  describe("DigitalOceanApiKeyAuthenticationProvider", () => {
8
7
  it("should add the User-Agent header to every request", async () => {