@usequota/nextjs 0.3.0 → 0.3.1

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/dist/index.d.mts CHANGED
@@ -25,7 +25,7 @@ interface QuotaConfig {
25
25
  clientSecret: string;
26
26
  /**
27
27
  * Quota API base URL
28
- * @default 'https://api.usequota.app'
28
+ * @default 'https://api.usequota.ai'
29
29
  */
30
30
  baseUrl?: string;
31
31
  /**
@@ -136,7 +136,7 @@ interface QuotaProviderProps {
136
136
  clientId: string;
137
137
  /**
138
138
  * Quota API base URL
139
- * @default 'https://api.usequota.app'
139
+ * @default 'https://api.usequota.ai'
140
140
  */
141
141
  baseUrl?: string;
142
142
  /**
package/dist/index.d.ts CHANGED
@@ -25,7 +25,7 @@ interface QuotaConfig {
25
25
  clientSecret: string;
26
26
  /**
27
27
  * Quota API base URL
28
- * @default 'https://api.usequota.app'
28
+ * @default 'https://api.usequota.ai'
29
29
  */
30
30
  baseUrl?: string;
31
31
  /**
@@ -136,7 +136,7 @@ interface QuotaProviderProps {
136
136
  clientId: string;
137
137
  /**
138
138
  * Quota API base URL
139
- * @default 'https://api.usequota.app'
139
+ * @default 'https://api.usequota.ai'
140
140
  */
141
141
  baseUrl?: string;
142
142
  /**
package/dist/index.js CHANGED
@@ -45,7 +45,7 @@ module.exports = __toCommonJS(index_exports);
45
45
 
46
46
  // src/middleware.ts
47
47
  var import_server = require("next/server");
48
- var DEFAULT_BASE_URL = "https://api.usequota.app";
48
+ var DEFAULT_BASE_URL = "https://api.usequota.ai";
49
49
  var DEFAULT_CALLBACK_PATH = "/api/quota/callback";
50
50
  var DEFAULT_COOKIE_PREFIX = "quota";
51
51
  var DEFAULT_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
@@ -184,7 +184,7 @@ function createQuotaMiddleware(config) {
184
184
  var import_react = require("react");
185
185
  var import_jsx_runtime = require("react/jsx-runtime");
186
186
  var QuotaContext = (0, import_react.createContext)(null);
187
- var DEFAULT_BASE_URL2 = "https://api.usequota.app";
187
+ var DEFAULT_BASE_URL2 = "https://api.usequota.ai";
188
188
  var DEFAULT_CALLBACK_PATH2 = "/api/quota/callback";
189
189
  var DEFAULT_API_PATH = "/api/quota/me";
190
190
  function QuotaProvider({
package/dist/index.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  // src/middleware.ts
2
2
  import { NextResponse } from "next/server";
3
- var DEFAULT_BASE_URL = "https://api.usequota.app";
3
+ var DEFAULT_BASE_URL = "https://api.usequota.ai";
4
4
  var DEFAULT_CALLBACK_PATH = "/api/quota/callback";
5
5
  var DEFAULT_COOKIE_PREFIX = "quota";
6
6
  var DEFAULT_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
@@ -145,7 +145,7 @@ import {
145
145
  } from "react";
146
146
  import { jsx } from "react/jsx-runtime";
147
147
  var QuotaContext = createContext(null);
148
- var DEFAULT_BASE_URL2 = "https://api.usequota.app";
148
+ var DEFAULT_BASE_URL2 = "https://api.usequota.ai";
149
149
  var DEFAULT_CALLBACK_PATH2 = "/api/quota/callback";
150
150
  var DEFAULT_API_PATH = "/api/quota/me";
151
151
  function QuotaProvider({
package/dist/server.d.mts CHANGED
@@ -50,7 +50,7 @@ interface QuotaRouteHandlerConfig {
50
50
  clientSecret: string;
51
51
  /**
52
52
  * Quota API base URL
53
- * @default 'https://api.usequota.app'
53
+ * @default 'https://api.usequota.ai'
54
54
  */
55
55
  baseUrl?: string;
56
56
  /**
@@ -162,7 +162,7 @@ declare function createQuotaRouteHandlers(config: QuotaRouteHandlerConfig): Quot
162
162
  * // accessToken can be used to proxy AI requests through Quota
163
163
  * const client = new Anthropic({
164
164
  * authToken: accessToken,
165
- * baseURL: 'https://api.usequota.app',
165
+ * baseURL: 'https://api.usequota.ai',
166
166
  * });
167
167
  *
168
168
  * const result = await client.messages.create({ ... });
@@ -183,7 +183,7 @@ interface WithQuotaAuthConfig {
183
183
  clientSecret: string;
184
184
  /**
185
185
  * Quota API base URL
186
- * @default 'https://api.usequota.app'
186
+ * @default 'https://api.usequota.ai'
187
187
  */
188
188
  baseUrl?: string;
189
189
  /**
@@ -248,7 +248,7 @@ interface QuotaServerConfig {
248
248
  clientSecret: string;
249
249
  /**
250
250
  * Quota API base URL
251
- * @default 'https://api.usequota.app'
251
+ * @default 'https://api.usequota.ai'
252
252
  */
253
253
  baseUrl?: string;
254
254
  /**
package/dist/server.d.ts CHANGED
@@ -50,7 +50,7 @@ interface QuotaRouteHandlerConfig {
50
50
  clientSecret: string;
51
51
  /**
52
52
  * Quota API base URL
53
- * @default 'https://api.usequota.app'
53
+ * @default 'https://api.usequota.ai'
54
54
  */
55
55
  baseUrl?: string;
56
56
  /**
@@ -162,7 +162,7 @@ declare function createQuotaRouteHandlers(config: QuotaRouteHandlerConfig): Quot
162
162
  * // accessToken can be used to proxy AI requests through Quota
163
163
  * const client = new Anthropic({
164
164
  * authToken: accessToken,
165
- * baseURL: 'https://api.usequota.app',
165
+ * baseURL: 'https://api.usequota.ai',
166
166
  * });
167
167
  *
168
168
  * const result = await client.messages.create({ ... });
@@ -183,7 +183,7 @@ interface WithQuotaAuthConfig {
183
183
  clientSecret: string;
184
184
  /**
185
185
  * Quota API base URL
186
- * @default 'https://api.usequota.app'
186
+ * @default 'https://api.usequota.ai'
187
187
  */
188
188
  baseUrl?: string;
189
189
  /**
@@ -248,7 +248,7 @@ interface QuotaServerConfig {
248
248
  clientSecret: string;
249
249
  /**
250
250
  * Quota API base URL
251
- * @default 'https://api.usequota.app'
251
+ * @default 'https://api.usequota.ai'
252
252
  */
253
253
  baseUrl?: string;
254
254
  /**
package/dist/server.js CHANGED
@@ -95,7 +95,7 @@ async function refreshAndPersistTokens(opts) {
95
95
  }
96
96
 
97
97
  // src/route-handlers.ts
98
- var DEFAULT_BASE_URL = "https://api.usequota.app";
98
+ var DEFAULT_BASE_URL = "https://api.usequota.ai";
99
99
  var DEFAULT_COOKIE_PREFIX = "quota";
100
100
  var DEFAULT_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
101
101
  function createQuotaRouteHandlers(config) {
@@ -557,7 +557,7 @@ function createQuotaRouteHandlers(config) {
557
557
  // src/with-quota-auth.ts
558
558
  var import_headers2 = require("next/headers");
559
559
  var import_core4 = require("@usequota/core");
560
- var DEFAULT_BASE_URL2 = "https://api.usequota.app";
560
+ var DEFAULT_BASE_URL2 = "https://api.usequota.ai";
561
561
  var DEFAULT_COOKIE_PREFIX2 = "quota";
562
562
  var DEFAULT_COOKIE_MAX_AGE2 = 60 * 60 * 24 * 7;
563
563
  function withQuotaAuth(config, handler) {
@@ -754,7 +754,7 @@ function withQuotaAuth(config, handler) {
754
754
  // src/server.ts
755
755
  var import_headers3 = require("next/headers");
756
756
  var import_core11 = require("@usequota/core");
757
- var DEFAULT_BASE_URL3 = "https://api.usequota.app";
757
+ var DEFAULT_BASE_URL3 = "https://api.usequota.ai";
758
758
  var DEFAULT_COOKIE_PREFIX3 = "quota";
759
759
  var DEFAULT_STORAGE_MODE = "client";
760
760
  var DEFAULT_COOKIE_MAX_AGE3 = 60 * 60 * 24 * 7;
package/dist/server.mjs CHANGED
@@ -52,7 +52,7 @@ async function refreshAndPersistTokens(opts) {
52
52
  }
53
53
 
54
54
  // src/route-handlers.ts
55
- var DEFAULT_BASE_URL = "https://api.usequota.app";
55
+ var DEFAULT_BASE_URL = "https://api.usequota.ai";
56
56
  var DEFAULT_COOKIE_PREFIX = "quota";
57
57
  var DEFAULT_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
58
58
  function createQuotaRouteHandlers(config) {
@@ -520,7 +520,7 @@ import {
520
520
  QuotaRateLimitError,
521
521
  QuotaError
522
522
  } from "@usequota/core";
523
- var DEFAULT_BASE_URL2 = "https://api.usequota.app";
523
+ var DEFAULT_BASE_URL2 = "https://api.usequota.ai";
524
524
  var DEFAULT_COOKIE_PREFIX2 = "quota";
525
525
  var DEFAULT_COOKIE_MAX_AGE2 = 60 * 60 * 24 * 7;
526
526
  function withQuotaAuth(config, handler) {
@@ -717,7 +717,7 @@ function withQuotaAuth(config, handler) {
717
717
  // src/server.ts
718
718
  import { cookies as cookies3 } from "next/headers";
719
719
  import { QuotaNotConnectedError as QuotaNotConnectedError3 } from "@usequota/core";
720
- var DEFAULT_BASE_URL3 = "https://api.usequota.app";
720
+ var DEFAULT_BASE_URL3 = "https://api.usequota.ai";
721
721
  var DEFAULT_COOKIE_PREFIX3 = "quota";
722
722
  var DEFAULT_STORAGE_MODE = "client";
723
723
  var DEFAULT_COOKIE_MAX_AGE3 = 60 * 60 * 24 * 7;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@usequota/nextjs",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "Next.js SDK for Quota — AI credit billing middleware, hooks, and components",
5
5
  "license": "MIT",
6
6
  "repository": {