openai-api-mock 0.2.2 → 0.3.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.
Files changed (2) hide show
  1. package/index.d.ts +2 -2
  2. package/package.json +3 -2
package/index.d.ts CHANGED
@@ -52,7 +52,7 @@ export interface MockControl {
52
52
  */
53
53
  createResponseTemplate: (
54
54
  templateType: string,
55
- overrides?: Record<string, any>
55
+ overrides?: Record<string, any>,
56
56
  ) => Record<string, any>;
57
57
  /**
58
58
  * Adds a custom endpoint mock
@@ -63,7 +63,7 @@ export interface MockControl {
63
63
  addCustomEndpoint: (
64
64
  method: string,
65
65
  path: string,
66
- handler: (uri: string, body: any) => [number, any] | Promise<[number, any]>
66
+ handler: (uri: string, body: any) => [number, any] | Promise<[number, any]>,
67
67
  ) => void;
68
68
  }
69
69
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openai-api-mock",
3
- "version": "0.2.2",
3
+ "version": "0.3.0",
4
4
  "description": "A Node.js module for mocking OpenAI-compatible API responses in a development environment with consistency mechanisms for deterministic testing",
5
5
  "repository": {
6
6
  "type": "git",
@@ -43,6 +43,7 @@
43
43
  "module": "./dist/index.js",
44
44
  "exports": {
45
45
  ".": {
46
+ "types": "./index.d.ts",
46
47
  "require": "./dist/index.cjs",
47
48
  "import": "./dist/index.js"
48
49
  }
@@ -58,7 +59,7 @@
58
59
  "devDependencies": {
59
60
  "jest": "^30.0.0",
60
61
  "node-fetch": "^3.3.2",
61
- "openai": "^4.52.4",
62
+ "openai": "^5.0.0",
62
63
  "prettier": "^3.0.0",
63
64
  "vite": "^7.0.0"
64
65
  },