@openrouter/sdk 1.5.79 → 1.5.80
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.
- package/esm/funcs/analyticsGetAnalyticsMeta.d.ts +1 -1
- package/esm/funcs/analyticsGetAnalyticsMeta.js +1 -1
- package/esm/funcs/analyticsQueryAnalytics.d.ts +1 -1
- package/esm/funcs/analyticsQueryAnalytics.js +1 -1
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/sdk/analytics.d.ts +2 -2
- package/esm/sdk/analytics.js +2 -2
- package/jsr.json +1 -1
- package/package.json +7 -7
|
@@ -12,7 +12,7 @@ import { Result } from "../types/fp.js";
|
|
|
12
12
|
* Get available analytics metrics and dimensions
|
|
13
13
|
*
|
|
14
14
|
* @remarks
|
|
15
|
-
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
15
|
+
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. Workspace-scoped management keys are accepted. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
16
16
|
*/
|
|
17
17
|
export declare function analyticsGetAnalyticsMeta(client: OpenRouterCore, request?: operations.GetAnalyticsMetaRequest | undefined, options?: RequestOptions): APIPromise<Result<operations.GetAnalyticsMetaResponse, errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
18
18
|
//# sourceMappingURL=analyticsGetAnalyticsMeta.d.ts.map
|
|
@@ -16,7 +16,7 @@ import { APIPromise } from "../types/async.js";
|
|
|
16
16
|
* Get available analytics metrics and dimensions
|
|
17
17
|
*
|
|
18
18
|
* @remarks
|
|
19
|
-
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
19
|
+
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. Workspace-scoped management keys are accepted. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
20
20
|
*/
|
|
21
21
|
export function analyticsGetAnalyticsMeta(client, request, options) {
|
|
22
22
|
return new APIPromise($do(client, request, options));
|
|
@@ -12,7 +12,7 @@ import { Result } from "../types/fp.js";
|
|
|
12
12
|
* Query analytics data
|
|
13
13
|
*
|
|
14
14
|
* @remarks
|
|
15
|
-
* Execute an analytics query with specified metrics, dimensions, filters, and time range. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
15
|
+
* Execute an analytics query with specified metrics, dimensions, filters, and time range. A workspace-scoped management key needs `activity:view_all` on its own workspace and reads only that workspace: it is refused a `workspace` filter naming another workspace, it excludes legacy rows with no workspace (including for the default workspace), and possible-cache metrics such as `possible_cached_tokens` return 400. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
16
16
|
*/
|
|
17
17
|
export declare function analyticsQueryAnalytics(client: OpenRouterCore, request: operations.QueryAnalyticsRequest, options?: RequestOptions): APIPromise<Result<operations.QueryAnalyticsResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.RequestTimeoutResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
18
18
|
//# sourceMappingURL=analyticsQueryAnalytics.d.ts.map
|
|
@@ -16,7 +16,7 @@ import { APIPromise } from "../types/async.js";
|
|
|
16
16
|
* Query analytics data
|
|
17
17
|
*
|
|
18
18
|
* @remarks
|
|
19
|
-
* Execute an analytics query with specified metrics, dimensions, filters, and time range. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
19
|
+
* Execute an analytics query with specified metrics, dimensions, filters, and time range. A workspace-scoped management key needs `activity:view_all` on its own workspace and reads only that workspace: it is refused a `workspace` filter naming another workspace, it excludes legacy rows with no workspace (including for the default workspace), and possible-cache metrics such as `possible_cached_tokens` return 400. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
20
20
|
*/
|
|
21
21
|
export function analyticsQueryAnalytics(client, request, options) {
|
|
22
22
|
return new APIPromise($do(client, request, options));
|
package/esm/lib/config.d.ts
CHANGED
|
@@ -50,8 +50,8 @@ export declare function serverURLFromOptions(options: SDKOptions): URL | null;
|
|
|
50
50
|
export declare const SDK_METADATA: {
|
|
51
51
|
readonly language: "typescript";
|
|
52
52
|
readonly openapiDocVersion: "1.0.0";
|
|
53
|
-
readonly sdkVersion: "1.5.
|
|
53
|
+
readonly sdkVersion: "1.5.80";
|
|
54
54
|
readonly genVersion: "2.950.13";
|
|
55
|
-
readonly userAgent: "speakeasy-sdk/typescript 1.5.
|
|
55
|
+
readonly userAgent: "speakeasy-sdk/typescript 1.5.80 2.950.13 1.0.0 @openrouter/sdk";
|
|
56
56
|
};
|
|
57
57
|
//# sourceMappingURL=config.d.ts.map
|
package/esm/lib/config.js
CHANGED
|
@@ -29,8 +29,8 @@ export function serverURLFromOptions(options) {
|
|
|
29
29
|
export const SDK_METADATA = {
|
|
30
30
|
language: "typescript",
|
|
31
31
|
openapiDocVersion: "1.0.0",
|
|
32
|
-
sdkVersion: "1.5.
|
|
32
|
+
sdkVersion: "1.5.80",
|
|
33
33
|
genVersion: "2.950.13",
|
|
34
|
-
userAgent: "speakeasy-sdk/typescript 1.5.
|
|
34
|
+
userAgent: "speakeasy-sdk/typescript 1.5.80 2.950.13 1.0.0 @openrouter/sdk",
|
|
35
35
|
};
|
|
36
36
|
//# sourceMappingURL=config.js.map
|
package/esm/sdk/analytics.d.ts
CHANGED
|
@@ -13,14 +13,14 @@ export declare class Analytics extends ClientSDK {
|
|
|
13
13
|
* Get available analytics metrics and dimensions
|
|
14
14
|
*
|
|
15
15
|
* @remarks
|
|
16
|
-
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
16
|
+
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. Workspace-scoped management keys are accepted. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
17
17
|
*/
|
|
18
18
|
getAnalyticsMeta(request?: operations.GetAnalyticsMetaRequest | undefined, options?: RequestOptions): Promise<operations.GetAnalyticsMetaResponse>;
|
|
19
19
|
/**
|
|
20
20
|
* Query analytics data
|
|
21
21
|
*
|
|
22
22
|
* @remarks
|
|
23
|
-
* Execute an analytics query with specified metrics, dimensions, filters, and time range. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
23
|
+
* Execute an analytics query with specified metrics, dimensions, filters, and time range. A workspace-scoped management key needs `activity:view_all` on its own workspace and reads only that workspace: it is refused a `workspace` filter naming another workspace, it excludes legacy rows with no workspace (including for the default workspace), and possible-cache metrics such as `possible_cached_tokens` return 400. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
24
24
|
*/
|
|
25
25
|
queryAnalytics(request: operations.QueryAnalyticsRequest, options?: RequestOptions): Promise<operations.QueryAnalyticsResponse>;
|
|
26
26
|
}
|
package/esm/sdk/analytics.js
CHANGED
|
@@ -21,7 +21,7 @@ export class Analytics extends ClientSDK {
|
|
|
21
21
|
* Get available analytics metrics and dimensions
|
|
22
22
|
*
|
|
23
23
|
* @remarks
|
|
24
|
-
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
24
|
+
* Returns the available metrics, dimensions, filter operators, and granularities for the analytics query endpoint. Workspace-scoped management keys are accepted. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
25
25
|
*/
|
|
26
26
|
async getAnalyticsMeta(request, options) {
|
|
27
27
|
return unwrapAsync(analyticsGetAnalyticsMeta(this, request, options));
|
|
@@ -30,7 +30,7 @@ export class Analytics extends ClientSDK {
|
|
|
30
30
|
* Query analytics data
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Execute an analytics query with specified metrics, dimensions, filters, and time range. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
33
|
+
* Execute an analytics query with specified metrics, dimensions, filters, and time range. A workspace-scoped management key needs `activity:view_all` on its own workspace and reads only that workspace: it is refused a `workspace` filter naming another workspace, it excludes legacy rows with no workspace (including for the default workspace), and possible-cache metrics such as `possible_cached_tokens` return 400. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
34
34
|
*/
|
|
35
35
|
async queryAnalytics(request, options) {
|
|
36
36
|
return unwrapAsync(analyticsQueryAnalytics(this, request, options));
|
package/jsr.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openrouter/sdk",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.80",
|
|
4
4
|
"author": "OpenRouter",
|
|
5
5
|
"description": "The OpenRouter TypeScript SDK is a type-safe toolkit for building AI applications with access to 400+ language models through a unified API.",
|
|
6
6
|
"keywords": [
|
|
@@ -73,15 +73,15 @@
|
|
|
73
73
|
"lint": "eslint --cache --max-warnings=0 src",
|
|
74
74
|
"build": "tsc && node scripts/unbarrel-imports.js",
|
|
75
75
|
"prepublishOnly": "npm run build",
|
|
76
|
-
"
|
|
77
|
-
"postinstall": "node scripts/check-types.js || true",
|
|
78
|
-
"test:e2e": "vitest --run --project e2e",
|
|
76
|
+
"test": "vitest --run --project unit",
|
|
79
77
|
"test:watch": "vitest --watch --project unit",
|
|
78
|
+
"test:e2e": "vitest --run --project e2e",
|
|
79
|
+
"test:transit": "exit 0",
|
|
80
80
|
"typecheck": "tsc --noEmit",
|
|
81
81
|
"typecheck:transit": "exit 0",
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
"
|
|
82
|
+
"compile": "tsc && node scripts/unbarrel-imports.js",
|
|
83
|
+
"postinstall": "node scripts/check-types.js || true",
|
|
84
|
+
"prepare": "npm run build"
|
|
85
85
|
},
|
|
86
86
|
"peerDependencies": {
|
|
87
87
|
|