@byte_fluffy/nexra-sdk 0.1.0-alpha.35 → 0.1.0-alpha.37

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.ts CHANGED
@@ -5,8 +5,8 @@ import { C as CursorPage, J as JsonValue } from './json-Cz0MkWQn.js';
5
5
  export { a as JsonObject, b as JsonPrimitive } from './json-Cz0MkWQn.js';
6
6
  import { N as NexraError, P as PublicErrorFields } from './errors-DZlSwyv8.js';
7
7
  export { A as ApiErrorPayload, a as PublicError, b as PublicErrorContext } from './errors-DZlSwyv8.js';
8
- import { V as Voice, C as CreateVoiceRequest, a as VoiceCreation, A as AssetsClient, T as TasksClient, R as RunTaskOptions, b as RunResult, c as TaskResult } from './voices-bcGBcfH-.js';
9
- export { d as CreateTaskOptions, e as CreateTaskRequest, f as RequestDetails, g as TASK_STATUSES, h as TaskCost, i as TaskError, j as TaskEvent, k as TaskEventType, l as TaskListParams, m as TaskPage, n as TaskProgress, o as TaskReceipt, p as TaskStatus, q as TaskTiming, r as TaskUsage, s as TaskWebhookConfig, t as TerminalTaskStatus, u as VerifyWebhookOptions, W as WaitTaskOptions, v as WatchTaskOptions, w as isTerminalTaskStatus, x as verifyWebhook } from './voices-bcGBcfH-.js';
8
+ import { V as Voice, C as CreateVoiceRequest, a as VoiceCreation, A as AssetsClient, T as TasksClient, R as RunTaskOptions, b as RunResult, c as TaskResult } from './voices-CFRCuodH.js';
9
+ export { d as CreateTaskOptions, e as CreateTaskRequest, f as RequestDetails, g as TASK_STATUSES, h as TaskCost, i as TaskError, j as TaskEvent, k as TaskEventType, l as TaskListParams, m as TaskPage, n as TaskProgress, o as TaskReceipt, p as TaskStatus, q as TaskTiming, r as TaskUsage, s as TaskWebhookConfig, t as TerminalTaskStatus, u as VerifyWebhookOptions, W as WaitTaskOptions, v as WatchTaskOptions, w as isTerminalTaskStatus, x as verifyWebhook } from './voices-CFRCuodH.js';
10
10
  import { CatalogClient } from './catalog.js';
11
11
  export { formatModelDisplayName, getModelSpec, listModelSpecs } from './catalog.js';
12
12
  export { ceilDecimal, multiplyDecimal } from './decimal.js';
package/dist/index.js CHANGED
@@ -20,13 +20,13 @@ import {
20
20
  projectMediaGeometry,
21
21
  queryString,
22
22
  sleep
23
- } from "./chunk-HVCSMBOG.js";
23
+ } from "./chunk-ENL3IGRX.js";
24
24
  import {
25
25
  MEDIA_KINDS,
26
26
  TASK_STATUSES,
27
27
  createTaskRequest,
28
28
  isTerminalTaskStatus
29
- } from "./chunk-R4BEO26Q.js";
29
+ } from "./chunk-AAGTZN2G.js";
30
30
 
31
31
  // src/assets.ts
32
32
  var AssetsClient = class {
package/dist/language.js CHANGED
@@ -6,12 +6,12 @@ import {
6
6
  jsonBody,
7
7
  parseServerSentEvents,
8
8
  resolveNexraLanguageReasoning
9
- } from "./chunk-HVCSMBOG.js";
9
+ } from "./chunk-ENL3IGRX.js";
10
10
  import {
11
11
  isPublicErrorCode,
12
12
  publicErrorMessage,
13
13
  resolvePublicErrorLocale
14
- } from "./chunk-R4BEO26Q.js";
14
+ } from "./chunk-AAGTZN2G.js";
15
15
 
16
16
  // src/language/index.ts
17
17
  import { createAnthropic } from "@ai-sdk/anthropic";
package/dist/media.js CHANGED
@@ -10,7 +10,7 @@ import {
10
10
  nexraMediaInputSchema,
11
11
  nexraMediaInputSchemaForMode,
12
12
  nexraMediaOperationForMode
13
- } from "./chunk-R4BEO26Q.js";
13
+ } from "./chunk-AAGTZN2G.js";
14
14
  export {
15
15
  NEXRA_GENERATION_OPERATIONS,
16
16
  NEXRA_MEDIA_API_VERSION,
package/dist/types.d.ts CHANGED
@@ -2,4 +2,4 @@ export { A as AssetImportRequest, a as AssetInput, b as AssetReference, c as Ass
2
2
  export { C as CreateNexraDisplayQuoteBatchRequest, d as CreateNexraQuoteRequest, F as FetchLike, e as MediaGeometryField, f as MediaGeometryProjection, g as ModelCapabilitySummary, h as ModelDateVersion, i as ModelEndpointSummary, j as ModelModality, c as ModelResourceList, k as ModelResourceOption, b as ModelSchema, M as ModelSearchParams, l as NexraBillingCurrency, m as NexraCatalogRevision, N as NexraClientOptions, n as NexraDisplayQuoteBatch, o as NexraDisplayQuoteBatchEntry, p as NexraModelOperation, q as NexraModelSpec, r as NexraModelSpecFilter, s as NexraQuote, t as NexraSalePrice, u as NexraSalePriceList, v as NexraSettlement, a as TaskModel, T as TaskModelSummary, U as UnifiedMediaGeometry } from './media-geometry-DAVFGry1.js';
3
3
  export { C as CursorPage, a as JsonObject, b as JsonPrimitive, J as JsonValue } from './json-Cz0MkWQn.js';
4
4
  export { A as ApiErrorPayload, N as NexraError, a as PublicError, b as PublicErrorContext, P as PublicErrorFields } from './errors-DZlSwyv8.js';
5
- export { d as CreateTaskOptions, e as CreateTaskRequest, C as CreateVoiceRequest, f as RequestDetails, b as RunResult, R as RunTaskOptions, c as Task, h as TaskCost, i as TaskError, j as TaskEvent, k as TaskEventType, l as TaskListParams, m as TaskPage, n as TaskProgress, o as TaskReceipt, c as TaskResult, p as TaskStatus, q as TaskTiming, r as TaskUsage, s as TaskWebhookConfig, t as TerminalTaskStatus, u as VerifyWebhookOptions, V as Voice, a as VoiceCreation, W as WaitTaskOptions, v as WatchTaskOptions } from './voices-bcGBcfH-.js';
5
+ export { d as CreateTaskOptions, e as CreateTaskRequest, C as CreateVoiceRequest, f as RequestDetails, b as RunResult, R as RunTaskOptions, c as Task, h as TaskCost, i as TaskError, j as TaskEvent, k as TaskEventType, l as TaskListParams, m as TaskPage, n as TaskProgress, o as TaskReceipt, c as TaskResult, p as TaskStatus, q as TaskTiming, r as TaskUsage, s as TaskWebhookConfig, t as TerminalTaskStatus, u as VerifyWebhookOptions, V as Voice, a as VoiceCreation, W as WaitTaskOptions, v as WatchTaskOptions } from './voices-CFRCuodH.js';
@@ -62,6 +62,16 @@ declare function verifyWebhook(request: Request, secret: string, options?: Verif
62
62
 
63
63
  type TaskPage<TOutput = JsonValue> = CursorPage<TaskResult<TOutput>>;
64
64
 
65
+ declare const REQUEST_HISTORY_MODALITIES: readonly ["image", "video", "audio", "language"];
66
+ declare const REQUEST_HISTORY_KINDS: readonly ["task", "api"];
67
+ declare const REQUEST_HISTORY_DISPLAY_STATUSES: readonly ["succeeded", "failed", "delivery_failed", "running"];
68
+ type RequestHistoryFilters = Readonly<{
69
+ query?: string;
70
+ modality?: typeof REQUEST_HISTORY_MODALITIES[number];
71
+ kind?: typeof REQUEST_HISTORY_KINDS[number];
72
+ displayStatus?: typeof REQUEST_HISTORY_DISPLAY_STATUSES[number];
73
+ }>;
74
+
65
75
  declare const TASK_STATUSES: readonly ["queued", "running", "succeeded", "failed", "cancelling", "cancelled"];
66
76
  type TaskStatus = (typeof TASK_STATUSES)[number];
67
77
  type TerminalTaskStatus = "succeeded" | "failed" | "cancelled";
@@ -83,6 +93,7 @@ interface TaskCost {
83
93
  amount: string;
84
94
  currency: string;
85
95
  }
96
+ type TaskBillingReason = "request_failed" | "request_cancelled" | "billing_usage_unavailable" | "billing_usage_invalid" | "billing_usage_incomplete" | "billing_evidence_invalid" | "billing_evidence_incomplete" | "billing_hold_unavailable" | "billing_price_unavailable" | "billing_pricing_unavailable";
86
97
  interface TaskQueueSnapshot {
87
98
  phase: "waiting_capacity" | "waiting_channel" | "dispatch_pending";
88
99
  since: string;
@@ -154,6 +165,8 @@ interface Task<TOutput = JsonValue> extends PublicErrorFields {
154
165
  cost?: TaskCost;
155
166
  /** Customer billing state; absent on older servers. */
156
167
  billingStatus?: "pending" | "succeeded" | "failed" | "refunded" | "unavailable";
168
+ /** Safe read-only cause; execution failures release authorization rather than failing settlement. */
169
+ billingReason?: TaskBillingReason;
157
170
  /** Final customer sale settlement. Provider procurement cost is never exposed here. */
158
171
  settlement?: NexraSettlement;
159
172
  /**
@@ -207,10 +220,13 @@ interface RequestDetails extends PublicErrorFields {
207
220
  timing?: TaskTiming;
208
221
  cost?: TaskCost;
209
222
  billingStatus?: Task["billingStatus"];
223
+ billingReason?: Task["billingReason"];
210
224
  settlement?: NexraSettlement;
211
225
  metadata?: JsonObject;
212
226
  /** Caller-asserted origin extracted from metadata.callerUrl; diagnostics display only. */
213
227
  callerUrl?: string | null;
228
+ /** Client address recorded at the trusted HTTP ingress; absent on historical requests. */
229
+ clientIp?: string | null;
214
230
  /** Caller-asserted end-user identifier extracted from metadata.endUserId; diagnostics display only. */
215
231
  endUserId?: string | null;
216
232
  /** Name of the API key that authenticated this request; diagnostics display only. */
@@ -269,11 +285,12 @@ type CreateTaskControls = Readonly<{
269
285
  * is deliberately not an envelope. Persistent Task records still retain their
270
286
  * own `input` snapshot after the HTTP boundary separates control fields. */
271
287
  type CreateTaskRequest<TInput extends JsonObject = JsonObject> = TInput & CreateTaskControls;
272
- interface TaskListParams {
288
+ interface TaskListParams extends RequestHistoryFilters {
273
289
  status?: TaskStatus;
274
290
  model?: string;
275
291
  limit?: number;
276
292
  cursor?: string;
293
+ orphanOnly?: boolean;
277
294
  }
278
295
  interface RunResult<TOutput = JsonValue> {
279
296
  taskId: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@byte_fluffy/nexra-sdk",
3
- "version": "0.1.0-alpha.35",
3
+ "version": "0.1.0-alpha.37",
4
4
  "type": "module",
5
5
  "types": "./dist/index.d.ts",
6
6
  "sideEffects": false,