@0xinsider/sdk 0.14.0-bootstrap.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.
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH;;;GAGG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,aAAa;IACb,iBAAiB;IACjB,uBAAuB;IACvB,WAAW;IACX,WAAW;IACX,gBAAgB;IAChB,cAAc;IACd,wBAAwB;IACxB,gBAAgB;IAChB,sEAAsE;IACtE,oBAAoB;IACpB,yEAAyE;IACzE,mDAAmD;IACnD,iBAAiB;CACT,CAAC;AAIX;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG;IAC/B,gBAAgB;IAChB,kBAAkB;IAClB,mBAAmB;IACnB,oBAAoB;IACpB,oBAAoB;IACpB,sBAAsB;IACtB,gCAAgC;IAChC,6EAA6E;IAC7E,oEAAoE;IACpE,0EAA0E;IAC1E,mDAAmD;IACnD,yBAAyB;IACzB,8BAA8B;IAC9B,yEAAyE;IACzE,2DAA2D;IAC3D,sCAAsC;IACtC,wCAAwC;IACxC,4EAA4E;IAC5E,+CAA+C;IAC/C,iBAAiB;IACjB,6EAA6E;IAC7E,2EAA2E;IAC3E,kBAAkB;IAClB,qEAAqE;IACrE,qEAAqE;IACrE,sEAAsE;IACtE,uBAAuB;IACvB,4EAA4E;IAC5E,2EAA2E;IAC3E,yEAAyE;IACzE,wBAAwB;IACxB,sEAAsE;IACtE,yEAAyE;IACzE,uEAAuE;IACvE,sEAAsE;IACtE,eAAe;IACf,4EAA4E;IAC5E,8DAA8D;IAC9D,yBAAyB;IACzB,cAAc;IACd,cAAc;IACd,kEAAkE;IAClE,0EAA0E;IAC1E,wEAAwE;IACxE,qBAAqB;IACrB,wBAAwB;IACxB,mBAAmB;IACnB,o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,IAAI,iBAAiB,CAAC,MAAM,EAAE,IAAI,EAAE,QAAQ,CAAC,CAAC;IACzD,CAAC;AACH,CAAC;AAED,uEAAuE;AACvE,MAAM,UAAU,mBAAmB,CAAC,IAAa;IAC/C,IAAI,CAAC,IAAI,IAAI,OAAO,IAAI,KAAK,QAAQ;QAAE,OAAO,IAAI,CAAC;IACnD,IACE,QAAQ,IAAI,IAAI;QACf,IAA6B,CAAC,MAAM,KAAK,OAAO;QACjD,OAAO,IAAI,IAAI;QACf,cAAc,CAAE,IAA4B,CAAC,KAAK,CAAC,EACnD,CAAC;QACD,OAAQ,IAAgC,CAAC,KAAK,CAAC;IACjD,CAAC;IACD,IAAI,cAAc,CAAC,IAAI,CAAC,IAAI,OAAQ,IAAqB,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;QAC5E,OAAO,IAAoB,CAAC;IAC9B,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED,SAAS,mBAAmB,CAAC,IAAa;IACxC,IAAI,CAAC,IAAI,IAAI,OAAO,IAAI,KAAK,QAAQ;QAAE,OAAO,IAAI,CAAC;IACnD,IAAI,MAAM,IAAI,IAAI,EAAE,CAAC;QACnB,MAAM,IAAI,GAAI,IAA2B,CAAC,IAAI,CAAC;QAC/C,IAAI,IAAI,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;YACrC,OAAO,IAAoB,CAAC;QAC9B,CAAC;IACH,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED,SAAS,cAAc,CAAC,IAAa;IACnC,OAAO,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI,KAAK,IAAI,CAAC;AACnD,CAAC"}
@@ -0,0 +1,65 @@
1
+ /**
2
+ * @0xinsider/sdk - official TypeScript SDK for the 0xinsider API.
3
+ *
4
+ * Analytics for Polymarket sports and esports markets: wallet grades, large
5
+ * trades, profitable-wallet flows, market flow/candles, the live SSE feed, and
6
+ * webhooks. Drift-tested
7
+ * against the public OpenAPI contract (`web/public/api/v1/openapi.json`).
8
+ *
9
+ * @example
10
+ * import { OxinsiderApiClient, paginate, streamFeed, verifySignature } from "@0xinsider/sdk";
11
+ *
12
+ * const client = new OxinsiderApiClient({ apiKey: process.env.OXINSIDER_API_KEY });
13
+ * const board = await client.listLeaderboard({ strategy: "swing_trader", limit: 100 });
14
+ */
15
+ export { assessDataQuality } from "./data-quality.js";
16
+ export type { AssessDataQualityOptions, DataQualityAssessment, DataQualityFailure, } from "./data-quality.js";
17
+ export { API_CLIENT_OPERATIONS, BATCH_TRADER_EXPANSIONS, DEFAULT_BASE_URL, IDEMPOTENT_WRITE_OPERATIONS, MCP_METHODS, READ_ONLY_POST_OPERATIONS, CONVERGENT_WRITE_OPERATIONS, REDIRECT_OPERATIONS, UNSUPPORTED_OPERATIONS, retryEligibility, DEFAULT_MAX_RETRIES, DEFAULT_TIMEOUT_MS, SANDBOX_BASE_URL, assertTrustedBaseUrl, resolveApiUrl, composeSignals, GRADES, LEADERBOARD_STRATEGIES, OxinsiderApiClient, interpolatePath, isApiNotModifiedResponse, isListEnvelope, } from "./client.js";
18
+ export type { ApiClientMethod, ApiClientOperation, ApiClientOptions, ApiClientResponse, ApiEnvelope, ApiListEnvelope, ApiNotModifiedResponse, ApiOperationId, ApiQueryValue, ApiRedirectOperation, ApiRequestOptions, ApiUnsupportedOperation, AuthMode, BatchGetTradersOptions, BatchTraderExpand, CategorySkillStatus, CategorySkillStatusCounts, ClientMeta, ConvenienceOptions, EnvelopeOperationId, ExploreMarketsParams, Game, GamesListParams, Grade, IdempotentWriteOperationId, InsiderRadarListParams, JsonRpcOperationId, LargePositionsListParams, ListOperationId, ListParams, McpJsonRpcRequest, McpJsonRpcResponse, McpMethod, McpOptions, McpResult, OperationEnvelope, OperationItem, OperationMeta, OperationOptionsArgs, OperationRequestOptions, OperationRequiresOptions, OptionalInputOperationId, RuntimeOperationId, OperationResult, PositionsListParams, ResponseKind, RetryEligibility, SseOperationId, TextOperationId, TraderExportDownload, TraderExportDownloadIntegrity, TraderExportDownloadOptions, TraderExportDownloadTarget, SharpMoneyFlowsParams, PickQualifyingExpert, PreGameSidesParams, PreGameSideObservationsParams, PreGameSideObservationsResponse, SportsEdgeSignalsParams, SportsEdgeObservationBoardUnavailableScope, SportsEdgeObservationBoardUpcomingStatus, SportsEdgeObservationCohort, SportsEdgeObservationDirectionalStatus, SportsEdgeObservationOutcomeIndex, SportsEdgeObservationProviderSource, SportsEdgeObservationSport, SportsEdgeObservationTopGrade, SportsEdgeObservationsParams, SportsEdgeObservationsResponse, SuspiciousTradesListParams, TennisTour, LargeTradeHistoryParams, WhaleTradeHistoryParams, LeaderboardListParams, LeaderboardStrategy, TrendingWalletsParams, LargeTradeListParams, WhaleTradeListParams, } from "./client.js";
19
+ export { API_ERROR_CODES, API_ERROR_REASONS, AccountLockedError, BadRequestError, CursorExpiredError, ExportIntegrityError, ForbiddenError, IdempotencyInProgressError, InternalServerError, InvalidApiKeyError, InvalidResponseError, NotFoundError, OxinsiderApiError, PickNotReleasedError, RateLimitUnavailableError, RequestTimeoutError, ResponseBodyReadError, ServerTimeoutError, RateLimitedError, ReadModelWarmingError, DatabaseUnavailableError, RequestAccountingUnavailableError, FreshnessCeilingUnsatisfiedError, SandboxApiKeyError, ApiKeyInQueryError, SubscriptionRequiredError, TraderNotTrackedError, UnknownEndpointError, UnknownQueryParameterError, WebhookDeliveryInProgressError, errorFromResponse, extractApiErrorBody, } from "./errors.js";
20
+ export type { ApiErrorCode, ApiErrorMeta, ApiErrorTransportMetadata, ApiErrorReason, FreshnessFailure, } from "./errors.js";
21
+ export { CURSOR_HISTORY_LIMIT, PaginationError, collect, paginate, paginatePages, paginationResumePoint, } from "./pagination.js";
22
+ export type { OperationPaginateOptions, PaginateOptions, PaginationErrorReason, PaginationProgress, PaginationResumePoint, PaginationStop, } from "./pagination.js";
23
+ export { MAX_TIMER_DELAY_MS, RETRY_AFTER_CEILING_MS, parseRetryAfter, } from "./retry.js";
24
+ export { DEFAULT_MAX_HANDLER_RETRIES, DEFAULT_MAX_STREAM_FRAME_BYTES, DEFAULT_MAX_STREAM_RECONNECTS, DEFAULT_MAX_STREAM_RETRY_AFTER_MS, StreamHandlerFailedError, StreamProtocolError, StreamReconnectsExhaustedError, StreamRetryDeferredError, consumeStream, consumeStreamCheckpointed, decodeStreamFrame, isEventStreamMediaType, parseSseFrame, streamFeed, streamFeedResilient, } from "./stream.js";
25
+ export type { CheckpointedStreamHandlers, CheckpointedStreamOptions, FeedEnvelope, ParsedSseFrame, ResilientStreamOptions, ResyncMarker, StreamCheckpoint, StreamCheckpointReason, StreamEvent, StreamFilters, StreamHandlerFailure, StreamHandlerStage, StreamOptions, StreamProtocolErrorReason, } from "./stream.js";
26
+ export { SIGNATURE_HEADER, SIGNATURE_TOLERANCE_SECONDS, TIMESTAMP_HEADER, WEBHOOK_EVENT_TYPES, computeSignature, parseWebhookEvent, verifySignature, } from "./webhooks.js";
27
+ export type { InsiderRadarFlagRaisedData, InsiderRadarFlagRaisedEvent, ExportJobCancelledData, ExportJobCancelledEvent, ExportJobExpiredData, ExportJobExpiredEvent, ExportJobFailedData, ExportJobFailedEvent, ExportJobReadyData, ExportJobReadyEvent, LargePositionsUpdatedData, LargePositionsUpdatedEvent, LiveSportsScoreEntry, LiveSportsUpdatedData, LiveSportsUpdatedEvent, SharpMoneyFlowDetectedData, SharpMoneyFlowDetectedEvent, SmartMoneyFlowDetectedData, SmartMoneyFlowDetectedEvent, SuspiciousTradeFlaggedData, SuspiciousTradeFlaggedEvent, VerifySignatureInput, WalletGradeChangedData, WalletGradeChangedEvent, WebhookEvent, WebhookEventEnvelope, WhaleTradesInsertedData, WhaleTradesInsertedEvent, WhaleTraderSyncedData, WhaleTraderSyncedEvent, } from "./webhooks.js";
28
+ export { APP_COMMIT, APP_REPOSITORY, APP_SPEC_PATH, OPENAPI_SHA256, OPENAPI_SOURCE, OPENAPI_VERSION, OPERATION_COUNT, } from "./provenance.js";
29
+ export type { AgentRegistration, ApiDiscovery, ApiError, BatchMarketFlowItem, BatchRateLimitMeta, BatchResponseMeta, BatchTraderItem, Candle, ContentSearchResult, CounterpartyAnalysis, CounterpartyExecution, CounterpartyMakerPage, CounterpartyMatchBreakdown, CounterpartyParticipant, CreateWebhookRequest, EventReplayEvent, EventReplayFreshness, EventReplayMeta, EventReplaySource, ExploreEntry, ExploreFacetValue, ExploreFacets, ExploreGroup, ExploreMarket, ExploreStandalone, ExportCompleteness, ExportCounts, ExportSourceRange, ExportVolumeReconciliation, LargeExportPolicy, LargePosition, LeaderboardEntry, MarketCandles, MarketFlow, MarketSearchResult, MarketSnapshot, MarketSnapshotFreshness, MarketSnapshotTopOfBook, MarketSnapshotTrust, McpJsonRpcError, OutcomeCandles, PickHolder, PickOfTheDay, PickOfTheDayArchive, PickOfTheDayArchiveDay, PickOfTheDayArchiveEntry, PickOfTheDayCommitmentPayload, PickOfTheDayHitRate, PickOfTheDayLedger, PickOfTheDayLedgerEntry, PickOfTheDayLedgerOpenedEntry, PickOfTheDayLedgerSealedEntry, PickOfTheDayLedgerUncommittedEntry, PickOfTheDayUncommittedPayload, PickSportsContext, PickSportsTeam, PickTrust, PlatformCapabilities, PlatformCapabilityStatus, Platforms, Position, PositionTimelineEvent, PotdEntryAuthorization, ProofPendingPickSlot, ReportPayload, ReportReconciliation, ReportSnapshot, ReportSourceRange, ResponseMeta, ScheduledPickSlot, ScoreCell, ScoreFormat, SmartMoneyFlowMarket, SnapshotCompleteness, SnapshotState, PreGameSideFunnelReport, PreGameSideObservation, PreGameSideObservationTerminalReason, PreGameSide, PreGameSideCategorySkill, PreGameSideSportFunnelReport, SuspiciousTrade, Trader, TraderCategoryRecord, TraderCategoryRecords, TraderGradeAt, TraderContext, TraderEsportsGameRecord, TraderExportJob, TraderExportArtifactManifest, TraderExportCategoryWatermark, TraderExportGeneration, TraderExportPnlWatermark, TraderExportPositionWatermark, TraderExportSnapshot, TraderExportSourceWatermarks, TraderExportTradeWatermark, TraderPnl, TraderTrust, TrendingWallet, TrustCompleteness, TrustFreshness, TrustMetadata, TrustReconciliation, TrustSource, UpdateWebhookRequest, Usage, VerifyWebhookRequest, WebhookDelivery, WebhookEndpoint, WebhookEventDescriptor, WebhookRetryPolicy, WebhookStatus, WebhookVerification, LargeTrade, LargeTradeDetail, LargeTradeHistoryMeta, OperationBody, OperationData, OperationPath, OperationQuery, OperationResponse, } from "./schema.js";
30
+ /**
31
+ * @deprecated Use `SuspiciousTrade`. The OpenAPI component schema `RadarFlag`
32
+ * was renamed to `SuspiciousTrade` in #16301 and the generated types no longer
33
+ * spell it, so the name is kept here as an alias: an existing
34
+ * `import type { RadarFlag } from "@0xinsider/sdk"` keeps compiling and keeps
35
+ * describing the same payload. The deprecated
36
+ * `GET /api/v1/insider-radar/{id}` still returns it under
37
+ * `object: "radar_flag"`.
38
+ */
39
+ export type RadarFlag = import("./schema.js").SuspiciousTrade;
40
+ import type { LargeTrade, LargeTradeDetail, LargeTradeHistoryMeta } from "./schema.js";
41
+ import type { BatchMarketFlowItem, MarketFlow } from "./schema.js";
42
+ /** @deprecated Use {@link MarketFlow} (#16312). */
43
+ export type MarketIntel = MarketFlow;
44
+ /** @deprecated Use {@link BatchMarketFlowItem} (#16312). */
45
+ export type BatchMarketIntelItem = BatchMarketFlowItem;
46
+ /** @deprecated Use {@link LargeTrade} (#16304). */
47
+ export type WhaleTrade = LargeTrade;
48
+ /** @deprecated Use {@link LargeTradeDetail} (#16304). */
49
+ export type WhaleTradeDetail = LargeTradeDetail;
50
+ /** @deprecated Use {@link LargeTradeHistoryMeta} (#16304). */
51
+ export type WhaleTradeHistoryMeta = LargeTradeHistoryMeta;
52
+ import type { PreGameSide, PreGameSideCategorySkill, PreGameSideFunnelReport, PreGameSideObservation, PreGameSideObservationTerminalReason, PreGameSideSportFunnelReport } from "./schema.js";
53
+ /** @deprecated Use {@link PreGameSide} (#16310). */
54
+ export type SportsEdgeSignal = PreGameSide;
55
+ /** @deprecated Use {@link PreGameSideCategorySkill} (#16310). */
56
+ export type SportsEdgeSignalCategorySkill = PreGameSideCategorySkill;
57
+ /** @deprecated Use {@link PreGameSideObservation} (#16310). */
58
+ export type SportsEdgeObservation = PreGameSideObservation;
59
+ /** @deprecated Use {@link PreGameSideObservationTerminalReason} (#16310). */
60
+ export type SportsEdgeObservationTerminalReason = PreGameSideObservationTerminalReason;
61
+ /** @deprecated Use {@link PreGameSideFunnelReport} (#16310). */
62
+ export type SportsEdgeFunnelReport = PreGameSideFunnelReport;
63
+ /** @deprecated Use {@link PreGameSideSportFunnelReport} (#16310). */
64
+ export type SportsEdgeSportFunnelReport = PreGameSideSportFunnelReport;
65
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAGH,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,YAAY,EACV,wBAAwB,EACxB,qBAAqB,EACrB,kBAAkB,GACnB,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EACL,qBAAqB,EACrB,uBAAuB,EACvB,gBAAgB,EAChB,2BAA2B,EAC3B,WAAW,EACX,yBAAyB,EACzB,2BAA2B,EAC3B,mBAAmB,EACnB,sBAAsB,EACtB,gBAAgB,EAChB,mBAAmB,EACnB,kBAAkB,EAClB,gBAAgB,EAChB,oBAAoB,EACpB,aAAa,EACb,cAAc,EACd,MAAM,EACN,sBAAsB,EACtB,kBAAkB,EAClB,eAAe,EACf,wBAAwB,EACxB,cAAc,GACf,MAAM,aAAa,CAAC;AACrB,YAAY,EACV,eAAe,EACf,kBAAkB,EAClB,gBAAgB,EAChB,iBAAiB,EACjB,WAAW,EACX,eAAe,EACf,sBAAsB,EACtB,cAAc,EACd,aAAa,EACb,oBAAoB,EACpB,iBAAiB,EACjB,uBAAuB,EACvB,QAAQ,EACR,sBAAsB,EACtB,iBAAiB,EACjB,mBAAmB,EACnB,yBAAyB,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AAG,mBAAmB,CAAC;AACvD,mDAAmD;AACnD,MAAM,MAAM,UAAU,GAAG,UAAU,CAAC;AACpC,yDAAyD;AACzD,MAAM,MAAM,gBAAgB,GAAG,gBAAgB,CAAC;AAChD,8DAA8D;AAC9D,MAAM,MAAM,qBAAqB,GAAG,qBAAqB,CAAC;AAC1D,OAAO,KAAK,EACV,WAAW,EACX,wBAAwB,EACxB,uBAAuB,EACvB,sBAAsB,EACtB,oCAAoC,EACpC,4BAA4B,EAC7B,MAAM,aAAa,CAAC;AACrB,oDAAoD;AACpD,MAAM,MAAM,gBAAgB,GAAG,WAAW,CAAC;AAC3C,iEAAiE;AACjE,MAAM,MAAM,6BAA6B,GAAG,wBAAwB,CAAC;AACrE,+DAA+D;AAC/D,MAAM,MAAM,qBAAqB,GAAG,sBAAsB,CAAC;AAC3D,6EAA6E;AAC7E,MAAM,MAAM,mCAAmC,GAAG,oCAAoC,CAAC;AACvF,gEAAgE;AAChE,MAAM,MAAM,sBAAsB,GAAG,uBAAuB,CAAC;AAC7D,qEAAqE;AACrE,MAAM,MAAM,2BAA2B,GAAG,4BAA4B,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,33 @@
1
+ /**
2
+ * @0xinsider/sdk - official TypeScript SDK for the 0xinsider API.
3
+ *
4
+ * Analytics for Polymarket sports and esports markets: wallet grades, large
5
+ * trades, profitable-wallet flows, market flow/candles, the live SSE feed, and
6
+ * webhooks. Drift-tested
7
+ * against the public OpenAPI contract (`web/public/api/v1/openapi.json`).
8
+ *
9
+ * @example
10
+ * import { OxinsiderApiClient, paginate, streamFeed, verifySignature } from "@0xinsider/sdk";
11
+ *
12
+ * const client = new OxinsiderApiClient({ apiKey: process.env.OXINSIDER_API_KEY });
13
+ * const board = await client.listLeaderboard({ strategy: "swing_trader", limit: 100 });
14
+ */
15
+ // One default decision over a response's data_quality block (#16965)
16
+ export { assessDataQuality } from "./data-quality.js";
17
+ // Client + core request/response types
18
+ export { API_CLIENT_OPERATIONS, BATCH_TRADER_EXPANSIONS, DEFAULT_BASE_URL, IDEMPOTENT_WRITE_OPERATIONS, MCP_METHODS, READ_ONLY_POST_OPERATIONS, CONVERGENT_WRITE_OPERATIONS, REDIRECT_OPERATIONS, UNSUPPORTED_OPERATIONS, retryEligibility, DEFAULT_MAX_RETRIES, DEFAULT_TIMEOUT_MS, SANDBOX_BASE_URL, assertTrustedBaseUrl, resolveApiUrl, composeSignals, GRADES, LEADERBOARD_STRATEGIES, OxinsiderApiClient, interpolatePath, isApiNotModifiedResponse, isListEnvelope, } from "./client.js";
19
+ // Error hierarchy
20
+ export { API_ERROR_CODES, API_ERROR_REASONS, AccountLockedError, BadRequestError, CursorExpiredError, ExportIntegrityError, ForbiddenError, IdempotencyInProgressError, InternalServerError, InvalidApiKeyError, InvalidResponseError, NotFoundError, OxinsiderApiError, PickNotReleasedError, RateLimitUnavailableError, RequestTimeoutError, ResponseBodyReadError, ServerTimeoutError, RateLimitedError, ReadModelWarmingError, DatabaseUnavailableError, RequestAccountingUnavailableError, FreshnessCeilingUnsatisfiedError, SandboxApiKeyError, ApiKeyInQueryError, SubscriptionRequiredError, TraderNotTrackedError, UnknownEndpointError, UnknownQueryParameterError, WebhookDeliveryInProgressError, errorFromResponse, extractApiErrorBody, } from "./errors.js";
21
+ // Pagination
22
+ export { CURSOR_HISTORY_LIMIT, PaginationError, collect, paginate, paginatePages, paginationResumePoint, } from "./pagination.js";
23
+ // Retry-After parsing and bounded waits, shared by REST and SSE (#16249)
24
+ export { MAX_TIMER_DELAY_MS, RETRY_AFTER_CEILING_MS, parseRetryAfter, } from "./retry.js";
25
+ // SSE stream
26
+ export { DEFAULT_MAX_HANDLER_RETRIES, DEFAULT_MAX_STREAM_FRAME_BYTES, DEFAULT_MAX_STREAM_RECONNECTS, DEFAULT_MAX_STREAM_RETRY_AFTER_MS, StreamHandlerFailedError, StreamProtocolError, StreamReconnectsExhaustedError, StreamRetryDeferredError, consumeStream, consumeStreamCheckpointed, decodeStreamFrame, isEventStreamMediaType, parseSseFrame, streamFeed, streamFeedResilient, } from "./stream.js";
27
+ // Webhooks
28
+ export { SIGNATURE_HEADER, SIGNATURE_TOLERANCE_SECONDS, TIMESTAMP_HEADER, WEBHOOK_EVENT_TYPES, computeSignature, parseWebhookEvent, verifySignature, } from "./webhooks.js";
29
+ // Which OpenAPI document this release was generated from (scripts/generate.mjs).
30
+ // Compare OPENAPI_SHA256 with the SHA-256 of the live document to see whether a
31
+ // release is behind the API.
32
+ export { APP_COMMIT, APP_REPOSITORY, APP_SPEC_PATH, OPENAPI_SHA256, OPENAPI_SOURCE, OPENAPI_VERSION, OPERATION_COUNT, } from "./provenance.js";
33
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,qEAAqE;AACrE,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAOtD,uCAAuC;AACvC,OAAO,EACL,qBAAqB,EACrB,uBAAuB,EACvB,gBAAgB,EAChB,2BAA2B,EAC3B,WAAW,EACX,yBAAyB,EACzB,2BAA2B,EAC3B,mBAAmB,EACnB,sBAAsB,EACtB,gBAAgB,EAChB,mBAAmB,EACnB,kBAAkB,EAClB,gBAAgB,EAChB,oBAAoB,EACpB,aAAa,EACb,cAAc,EACd,MAAM,EACN,sBAAsB,EACtB,kBAAkB,EAClB,eAAe,EACf,wBAAwB,EACxB,cAAc,GACf,MAAM,aAAa,CAAC;AAkFrB,kBAAkB;AAClB,OAAO,EACL,eAAe,EACf,iBAAiB,EACjB,kBAAkB,EAClB,eAAe,EACf,kBAAkB,EAClB,oBAAoB,EACpB,cAAc,EACd,0BAA0B,EAC1B,mBAAmB,EACnB,kBAAkB,EAClB,oBAAoB,EACpB,aAAa,EACb,iBAAiB,EACjB,oBAAoB,EACpB,yBAAyB,EACzB,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,EAClB,gBAAgB,EAChB,qBAAqB,EACrB,wBAAwB,EACxB,iCAAiC,EACjC,gCAAgC,EAChC,kBAAkB,EAClB,kBAAkB,EAClB,yBAAyB,EACzB,qBAAqB,EACrB,oBAAoB,EACpB,0BAA0B,EAC1B,8BAA8B,EAC9B,iBAAiB,EACjB,mBAAmB,GACpB,MAAM,aAAa,CAAC;AASrB,aAAa;AACb,OAAO,EACL,oBAAoB,EACpB,eAAe,EACf,OAAO,EACP,QAAQ,EACR,aAAa,EACb,qBAAqB,GACtB,MAAM,iBAAiB,CAAC;AAUzB,yEAAyE;AACzE,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACtB,eAAe,GAChB,MAAM,YAAY,CAAC;AAEpB,aAAa;AACb,OAAO,EACL,2BAA2B,EAC3B,8BAA8B,EAC9B,6BAA6B,EAC7B,iCAAiC,EACjC,wBAAwB,EACxB,mBAAmB,EACnB,8BAA8B,EAC9B,wBAAwB,EACxB,aAAa,EACb,yBAAyB,EACzB,iBAAiB,EACjB,sBAAsB,EACtB,aAAa,EACb,UAAU,EACV,mBAAmB,GACpB,MAAM,aAAa,CAAC;AAkBrB,WAAW;AACX,OAAO,EACL,gBAAgB,EAChB,2BAA2B,EAC3B,gBAAgB,EAChB,mBAAmB,EACnB,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,GAChB,MAAM,eAAe,CAAC;AAkCvB,iFAAiF;AACjF,gFAAgF;AAChF,6BAA6B;AAC7B,OAAO,EACL,UAAU,EACV,cAAc,EACd,aAAa,EACb,cAAc,EACd,cAAc,EACd,eAAe,EACf,eAAe,GAChB,MAAM,iBAAiB,CAAC"}
@@ -0,0 +1,196 @@
1
+ /**
2
+ * Cursor pagination over the Stripe-style V1 list envelope.
3
+ *
4
+ * Every list endpoint returns `{ object: "list", data, has_more, next_cursor }`
5
+ * (`backend/src/api_v1/types.rs` `ApiList`: `has_more` is always a boolean,
6
+ * `next_cursor` is a string or omitted). `paginate()` yields each `data[]`
7
+ * item across pages, following `next_cursor` while `has_more` is true.
8
+ * `paginatePages()` yields whole pages when you need the envelope (e.g. to
9
+ * read `meta.cost` or `total`).
10
+ *
11
+ * The walker is a progress-checked consumer of that protocol (#16246):
12
+ *
13
+ * - A page is validated BEFORE it is yielded. `has_more: true` with no usable
14
+ * `next_cursor` is a `PaginationError` (`missing_cursor`); the backend's own
15
+ * cursor builders refuse to produce that page ("has_more is true for an
16
+ * empty page", `insider_radar.rs`), so a client seeing it is looking at a
17
+ * malformed response, not the end of the collection. Before #16246 the
18
+ * walk returned as if the collection were exhausted.
19
+ * - A `next_cursor` that repeats a cursor this walk already requested is a
20
+ * `PaginationError` (`repeated_cursor`), thrown before the duplicate
21
+ * request. The last `CURSOR_HISTORY_LIMIT` cursors are remembered; a cycle
22
+ * longer than that is not detected, which bounds memory on a long walk.
23
+ * - `maxPages` is validated before any request: a positive integer or
24
+ * `Infinity`; `0`, a negative, fractional or `NaN` value throws `RangeError`.
25
+ * - `has_more: false` ends the walk normally, whatever `next_cursor` says.
26
+ * - A `PaginationError` carries the offending `page`, so its data is not lost,
27
+ * and registers a resume point like any other failure.
28
+ *
29
+ * `options.progress`, when passed, is updated as the walk goes: how many
30
+ * pages were fetched, the last cursor requested, the `next_cursor` of the
31
+ * last page, and why the walk stopped, so a caller that stops at `maxPages`
32
+ * can tell "the collection has more" from "the collection is exhausted" and
33
+ * keep the continuation.
34
+ */
35
+ import type { ApiListEnvelope, ApiOperationId, ApiRequestOptions, ListOperationId, ListParams, OperationEnvelope, OperationItem, OperationOptionsArgs, OxinsiderApiClient, RuntimeOperationId } from "./client.js";
36
+ import type { OperationPath, OperationQuery } from "./schema.js";
37
+ /**
38
+ * How many requested cursors a walk remembers for the repeat check. A cycle
39
+ * longer than this is not detected; the bound keeps a long walk's memory
40
+ * flat instead of growing with every page.
41
+ */
42
+ export declare const CURSOR_HISTORY_LIMIT = 1024;
43
+ /** Why a walk ended; see `PaginationProgress.stoppedBy`. */
44
+ export type PaginationStop =
45
+ /** The server said `has_more: false`: the collection is exhausted. */
46
+ "exhausted"
47
+ /** The caller's `maxPages` was reached; `nextCursor` continues the walk. */
48
+ | "max_pages";
49
+ /**
50
+ * Live progress of a walk (#16246). Pass an object as `options.progress`
51
+ * and read it after the loop; it is updated before each page is yielded and
52
+ * when the walk ends. An early consumer return keeps the delivered-page
53
+ * count and continuation without inventing a terminal reason. On a throw,
54
+ * cursor and pagesFetched agree with `paginationResumePoint(error)`.
55
+ */
56
+ export interface PaginationProgress {
57
+ /** Pages fetched and yielded so far. */
58
+ pagesFetched?: number;
59
+ /** The current request cursor, including a failed attempt; undefined for the first page. */
60
+ cursor?: string;
61
+ /**
62
+ * The delivered page's `next_cursor`, or the retry cursor after a failure.
63
+ * While a request is pending this is undefined. After `stoppedBy: "max_pages"`
64
+ * this is the continuation: pass it as `query.cursor` to carry on.
65
+ * `null` or `undefined` once the collection is exhausted.
66
+ */
67
+ nextCursor?: string | null;
68
+ /** Set before delivering a page known to exhaust the list or reach maxPages. */
69
+ stoppedBy?: PaginationStop;
70
+ }
71
+ export interface PaginateOptions {
72
+ /** Path parameters for templated list paths (e.g. `{ id }` for deliveries). */
73
+ path?: ApiRequestOptions["path"];
74
+ /** Initial query params (filters, `limit`, an initial `cursor`, ...). */
75
+ query?: ListParams;
76
+ /** Reject query names the operation does not publish before the first request. */
77
+ strictQuery?: ApiRequestOptions["strictQuery"];
78
+ /** Forwarded to each request for cooperative cancellation. */
79
+ signal?: AbortSignal;
80
+ /** Per-request deadline, forwarded to each page; see `ApiRequestOptions.timeoutMs`. */
81
+ timeoutMs?: number | null;
82
+ /** Retries per page, forwarded to each request; see `ApiRequestOptions.maxRetries`. */
83
+ maxRetries?: number;
84
+ /** Extra headers on every page, such as a conditional read's `If-None-Match`. */
85
+ headers?: Record<string, string>;
86
+ /**
87
+ * Hard cap on pages fetched. A positive integer, or `Infinity` / omitted
88
+ * for no cap. Anything else (`0`, negative, fractional, `NaN`) throws a
89
+ * `RangeError` before any request. Reaching it is a caller choice, not
90
+ * exhaustion: `progress.stoppedBy` reads `"max_pages"` and
91
+ * `progress.nextCursor` holds the continuation.
92
+ */
93
+ maxPages?: number;
94
+ /** Updated as the walk goes; see `PaginationProgress`. */
95
+ progress?: PaginationProgress;
96
+ }
97
+ /**
98
+ * `PaginateOptions` bound to one list operation (#16136): `path` required
99
+ * exactly when the route has path parameters, `query` the documented query.
100
+ */
101
+ export type OperationPaginateOptions<K extends ListOperationId> = Omit<PaginateOptions, "path" | "query"> & (OperationPath[K] extends Record<string, never> ? {
102
+ path?: OperationPath[K];
103
+ } : {
104
+ path: OperationPath[K];
105
+ }) & {
106
+ query?: OperationQuery[K];
107
+ };
108
+ /** Where an interrupted walk can pick up again; see `paginationResumePoint`. */
109
+ export interface PaginationResumePoint {
110
+ /**
111
+ * The cursor of the page that failed. Pass it back as `query.cursor` to
112
+ * refetch that page and continue. `undefined` means the first page failed,
113
+ * so start the walk again without a cursor.
114
+ */
115
+ cursor: string | undefined;
116
+ /** Pages already yielded before the failure. */
117
+ pagesFetched: number;
118
+ }
119
+ /** What a page did that the list protocol does not allow. */
120
+ export type PaginationErrorReason =
121
+ /** `has_more: true` with no usable `next_cursor` (missing, `null` or empty). */
122
+ "missing_cursor"
123
+ /** `next_cursor` repeats a cursor this walk already requested: a cycle. */
124
+ | "repeated_cursor";
125
+ /**
126
+ * The server's list response broke the pagination protocol (#16246). The
127
+ * walk stops before yielding the page and before any further request.
128
+ *
129
+ * `page` is the response as received, so its `data` is still available to
130
+ * you; `cursor` is what that page was requested with (`undefined` for the
131
+ * first page) and `nextCursor` is what it offered next. `pagesFetched`
132
+ * counts the pages already yielded. `paginationResumePoint(error)` returns
133
+ * `{ cursor, pagesFetched }` for this error too. Retrying the same page later
134
+ * is reasonable for a transient server fault; a repeat on the same cursor
135
+ * means the route's cursor is broken and is worth reporting with
136
+ * `page.meta.request_id`.
137
+ */
138
+ export declare class PaginationError<T = unknown> extends Error {
139
+ readonly reason: PaginationErrorReason;
140
+ readonly operationId: ApiOperationId;
141
+ readonly cursor: string | undefined;
142
+ readonly nextCursor: string | null | undefined;
143
+ readonly pagesFetched: number;
144
+ readonly page: ApiListEnvelope<T>;
145
+ constructor(reason: PaginationErrorReason, operationId: ApiOperationId, page: ApiListEnvelope<T>, cursor: string | undefined, pagesFetched: number);
146
+ }
147
+ /**
148
+ * The resume point of an error thrown out of `paginatePages`, `paginate` or
149
+ * `collect`, or `undefined` for any other error (#14281).
150
+ *
151
+ * Each page request already retries a 429 or 5xx (`maxRetries`). When those
152
+ * retries are exhausted the ORIGINAL error is rethrown unchanged, so an
153
+ * `instanceof RateLimitedError` check keeps working, and this function recovers
154
+ * the cursor that the throw would otherwise have destroyed with the generator.
155
+ * A `PaginationError` (#16246) is registered the same way.
156
+ *
157
+ * @example
158
+ * try {
159
+ * for await (const trade of paginate(client, "listWhaleTrades", { query })) handle(trade);
160
+ * } catch (err) {
161
+ * const resume = paginationResumePoint(err);
162
+ * if (resume) later(() => paginate(client, "listWhaleTrades", { query: { ...query, cursor: resume.cursor } }));
163
+ * }
164
+ */
165
+ export declare function paginationResumePoint(error: unknown): PaginationResumePoint | undefined;
166
+ /**
167
+ * Async-iterate whole list pages, following `next_cursor` until exhausted.
168
+ * Yields the full envelope so callers can read `meta`/`total`/`has_more`.
169
+ * A failed page throws its original error; `paginationResumePoint(error)`
170
+ * returns the cursor to continue from. A page that breaks the protocol
171
+ * throws `PaginationError` before it is yielded (#16246).
172
+ */
173
+ export declare function paginatePages<K extends ListOperationId>(client: OxinsiderApiClient, operationId: K, ...options: OperationOptionsArgs<K, OperationPaginateOptions<K>>): AsyncGenerator<OperationEnvelope<K>, void, undefined>;
174
+ /** The untyped form: a runtime-chosen operation, or a caller-asserted `T`. */
175
+ export declare function paginatePages<T = unknown, I extends ApiOperationId = ApiOperationId>(client: OxinsiderApiClient, operationId: RuntimeOperationId<I>, options?: PaginateOptions): AsyncGenerator<ApiListEnvelope<T>, void, undefined>;
176
+ /**
177
+ * Async-iterate individual `data[]` items across all pages.
178
+ *
179
+ * @example
180
+ * for await (const trade of paginate(client, "listWhaleTrades", {
181
+ * query: { min_grade: "S", limit: 100 },
182
+ * })) {
183
+ * handle(trade); // typed as the route's whale trade (#16136)
184
+ * }
185
+ */
186
+ export declare function paginate<K extends ListOperationId>(client: OxinsiderApiClient, operationId: K, ...options: OperationOptionsArgs<K, OperationPaginateOptions<K>>): AsyncGenerator<OperationItem<K>, void, undefined>;
187
+ /** The untyped form: a runtime-chosen operation, or a caller-asserted `T`. */
188
+ export declare function paginate<T = unknown, I extends ApiOperationId = ApiOperationId>(client: OxinsiderApiClient, operationId: RuntimeOperationId<I>, options?: PaginateOptions): AsyncGenerator<T, void, undefined>;
189
+ /**
190
+ * Collect every item across all pages into one array. Convenience over
191
+ * `paginate()` for small result sets; prefer the iterator for large ones.
192
+ */
193
+ export declare function collect<K extends ListOperationId>(client: OxinsiderApiClient, operationId: K, ...options: OperationOptionsArgs<K, OperationPaginateOptions<K>>): Promise<OperationItem<K>[]>;
194
+ /** The untyped form: a runtime-chosen operation, or a caller-asserted `T`. */
195
+ export declare function collect<T = unknown, I extends ApiOperationId = ApiOperationId>(client: OxinsiderApiClient, operationId: RuntimeOperationId<I>, options?: PaginateOptions): Promise<T[]>;
196
+ //# sourceMappingURL=pagination.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.d.ts","sourceRoot":"","sources":["../src/pagination.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AAEH,OAAO,KAAK,EACV,eAAe,EACf,cAAc,EACd,iBAAiB,EACjB,eAAe,EACf,UAAU,EACV,iBAAiB,EACjB,aAAa,EACb,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EACnB,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAEjE;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,OAAQ,CAAC;AAE1C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AO,EAAE,CAAC,SAAS,cAAc,GAAG,cAAc,EAC5E,MAAM,EAAE,kBAAkB,EAC1B,WAAW,EAAE,kBAAkB,CAAC,CAAC,CAAC,EAClC,OAAO,CAAC,EAAE,eAAe,GACxB,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC"}
@@ -0,0 +1,208 @@
1
+ /**
2
+ * Cursor pagination over the Stripe-style V1 list envelope.
3
+ *
4
+ * Every list endpoint returns `{ object: "list", data, has_more, next_cursor }`
5
+ * (`backend/src/api_v1/types.rs` `ApiList`: `has_more` is always a boolean,
6
+ * `next_cursor` is a string or omitted). `paginate()` yields each `data[]`
7
+ * item across pages, following `next_cursor` while `has_more` is true.
8
+ * `paginatePages()` yields whole pages when you need the envelope (e.g. to
9
+ * read `meta.cost` or `total`).
10
+ *
11
+ * The walker is a progress-checked consumer of that protocol (#16246):
12
+ *
13
+ * - A page is validated BEFORE it is yielded. `has_more: true` with no usable
14
+ * `next_cursor` is a `PaginationError` (`missing_cursor`); the backend's own
15
+ * cursor builders refuse to produce that page ("has_more is true for an
16
+ * empty page", `insider_radar.rs`), so a client seeing it is looking at a
17
+ * malformed response, not the end of the collection. Before #16246 the
18
+ * walk returned as if the collection were exhausted.
19
+ * - A `next_cursor` that repeats a cursor this walk already requested is a
20
+ * `PaginationError` (`repeated_cursor`), thrown before the duplicate
21
+ * request. The last `CURSOR_HISTORY_LIMIT` cursors are remembered; a cycle
22
+ * longer than that is not detected, which bounds memory on a long walk.
23
+ * - `maxPages` is validated before any request: a positive integer or
24
+ * `Infinity`; `0`, a negative, fractional or `NaN` value throws `RangeError`.
25
+ * - `has_more: false` ends the walk normally, whatever `next_cursor` says.
26
+ * - A `PaginationError` carries the offending `page`, so its data is not lost,
27
+ * and registers a resume point like any other failure.
28
+ *
29
+ * `options.progress`, when passed, is updated as the walk goes: how many
30
+ * pages were fetched, the last cursor requested, the `next_cursor` of the
31
+ * last page, and why the walk stopped, so a caller that stops at `maxPages`
32
+ * can tell "the collection has more" from "the collection is exhausted" and
33
+ * keep the continuation.
34
+ */
35
+ /**
36
+ * How many requested cursors a walk remembers for the repeat check. A cycle
37
+ * longer than this is not detected; the bound keeps a long walk's memory
38
+ * flat instead of growing with every page.
39
+ */
40
+ export const CURSOR_HISTORY_LIMIT = 1_024;
41
+ /**
42
+ * The server's list response broke the pagination protocol (#16246). The
43
+ * walk stops before yielding the page and before any further request.
44
+ *
45
+ * `page` is the response as received, so its `data` is still available to
46
+ * you; `cursor` is what that page was requested with (`undefined` for the
47
+ * first page) and `nextCursor` is what it offered next. `pagesFetched`
48
+ * counts the pages already yielded. `paginationResumePoint(error)` returns
49
+ * `{ cursor, pagesFetched }` for this error too. Retrying the same page later
50
+ * is reasonable for a transient server fault; a repeat on the same cursor
51
+ * means the route's cursor is broken and is worth reporting with
52
+ * `page.meta.request_id`.
53
+ */
54
+ export class PaginationError extends Error {
55
+ reason;
56
+ operationId;
57
+ cursor;
58
+ nextCursor;
59
+ pagesFetched;
60
+ page;
61
+ constructor(reason, operationId, page, cursor, pagesFetched) {
62
+ const requestId = page.meta?.request_id;
63
+ super(reason === "missing_cursor"
64
+ ? `0xinsider API ${operationId} page ${String(pagesFetched + 1)} says has_more but carries no next_cursor${requestId ? ` (request ${requestId})` : ""}; the walk cannot continue safely`
65
+ : `0xinsider API ${operationId} page ${String(pagesFetched + 1)} offers next_cursor ${JSON.stringify(page.next_cursor)}, which this walk already requested${requestId ? ` (request ${requestId})` : ""}; stopping before the duplicate request`);
66
+ this.name = "PaginationError";
67
+ this.reason = reason;
68
+ this.operationId = operationId;
69
+ this.cursor = cursor;
70
+ this.nextCursor = page.next_cursor;
71
+ this.pagesFetched = pagesFetched;
72
+ this.page = page;
73
+ }
74
+ }
75
+ const resumePoints = new WeakMap();
76
+ /**
77
+ * The resume point of an error thrown out of `paginatePages`, `paginate` or
78
+ * `collect`, or `undefined` for any other error (#14281).
79
+ *
80
+ * Each page request already retries a 429 or 5xx (`maxRetries`). When those
81
+ * retries are exhausted the ORIGINAL error is rethrown unchanged, so an
82
+ * `instanceof RateLimitedError` check keeps working, and this function recovers
83
+ * the cursor that the throw would otherwise have destroyed with the generator.
84
+ * A `PaginationError` (#16246) is registered the same way.
85
+ *
86
+ * @example
87
+ * try {
88
+ * for await (const trade of paginate(client, "listWhaleTrades", { query })) handle(trade);
89
+ * } catch (err) {
90
+ * const resume = paginationResumePoint(err);
91
+ * if (resume) later(() => paginate(client, "listWhaleTrades", { query: { ...query, cursor: resume.cursor } }));
92
+ * }
93
+ */
94
+ export function paginationResumePoint(error) {
95
+ return typeof error === "object" && error !== null
96
+ ? resumePoints.get(error)
97
+ : undefined;
98
+ }
99
+ function assertMaxPages(value) {
100
+ if (value === undefined || value === Infinity)
101
+ return Infinity;
102
+ if (!Number.isInteger(value) || value < 1) {
103
+ throw new RangeError(`maxPages must be a positive integer or Infinity, got ${String(value)}`);
104
+ }
105
+ return value;
106
+ }
107
+ /** A `next_cursor` the walk can request: a non-empty string. */
108
+ function usableCursor(value) {
109
+ return typeof value === "string" && value !== "";
110
+ }
111
+ export async function* paginatePages(client, operationId, options = {}) {
112
+ const { path, query, strictQuery, signal, progress, timeoutMs, maxRetries, headers } = options;
113
+ let cursor = query?.cursor;
114
+ let pages = 0;
115
+ // Every cursor requested so far, newest last, capped at CURSOR_HISTORY_LIMIT.
116
+ const requested = new Set();
117
+ const requestedOrder = [];
118
+ const remember = (value) => {
119
+ if (requested.has(value))
120
+ return;
121
+ requested.add(value);
122
+ requestedOrder.push(value);
123
+ if (requestedOrder.length > CURSOR_HISTORY_LIMIT) {
124
+ const oldest = requestedOrder.shift();
125
+ if (oldest !== undefined)
126
+ requested.delete(oldest);
127
+ }
128
+ };
129
+ const record = (fields) => {
130
+ if (progress) {
131
+ Object.assign(progress, fields);
132
+ if (fields.stoppedBy === undefined)
133
+ delete progress.stoppedBy;
134
+ }
135
+ };
136
+ const fail = (error) => {
137
+ record({ pagesFetched: pages, cursor, nextCursor: cursor });
138
+ resumePoints.set(error, { cursor, pagesFetched: pages });
139
+ return error;
140
+ };
141
+ record({ pagesFetched: pages, cursor, nextCursor: undefined });
142
+ const maxPages = assertMaxPages(options.maxPages);
143
+ for (;;) {
144
+ record({ pagesFetched: pages, cursor, nextCursor: undefined });
145
+ if (signal?.aborted) {
146
+ throw fail(signal.reason instanceof Error
147
+ ? signal.reason
148
+ : new DOMException("The pagination was aborted", "AbortError"));
149
+ }
150
+ if (cursor !== undefined)
151
+ remember(cursor);
152
+ let page;
153
+ try {
154
+ page = await client.list(operationId, {
155
+ path,
156
+ query: { ...query, ...(cursor === undefined ? {} : { cursor }) },
157
+ strictQuery,
158
+ signal,
159
+ ...(timeoutMs === undefined ? {} : { timeoutMs }),
160
+ ...(maxRetries === undefined ? {} : { maxRetries }),
161
+ ...(headers === undefined ? {} : { headers }),
162
+ });
163
+ }
164
+ catch (error) {
165
+ if (typeof error === "object" && error !== null)
166
+ fail(error);
167
+ else
168
+ record({ pagesFetched: pages, cursor, nextCursor: cursor });
169
+ throw error;
170
+ }
171
+ const next = page.next_cursor;
172
+ if (page.has_more) {
173
+ if (!usableCursor(next)) {
174
+ throw fail(new PaginationError("missing_cursor", operationId, page, cursor, pages));
175
+ }
176
+ if (requested.has(next)) {
177
+ throw fail(new PaginationError("repeated_cursor", operationId, page, cursor, pages));
178
+ }
179
+ }
180
+ pages += 1;
181
+ const stoppedBy = !page.has_more
182
+ ? "exhausted"
183
+ : pages >= maxPages
184
+ ? "max_pages"
185
+ : undefined;
186
+ record({ pagesFetched: pages, cursor, nextCursor: next, stoppedBy });
187
+ yield page;
188
+ if (stoppedBy !== undefined)
189
+ return;
190
+ // `has_more` was true and `next` passed both checks above.
191
+ cursor = next;
192
+ }
193
+ }
194
+ export async function* paginate(client, operationId, options = {}) {
195
+ for await (const page of paginatePages(client, operationId, options)) {
196
+ for (const item of page.data) {
197
+ yield item;
198
+ }
199
+ }
200
+ }
201
+ export async function collect(client, operationId, options = {}) {
202
+ const items = [];
203
+ for await (const item of paginate(client, operationId, options)) {
204
+ items.push(item);
205
+ }
206
+ return items;
207
+ }
208
+ //# sourceMappingURL=pagination.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.js","sourceRoot":"","sources":["../src/pagination.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AAgBH;;;;GAIG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,KAAK,CAAC;AA0F1C;;;;;;;;;;;;GAYG;AACH,MAAM,OAAO,eAA6B,SAAQ,KAAK;IAC5C,MAAM,CAAwB;IAC9B,WAAW,CAAiB;IAC5B,MAAM,CAAqB;IAC3B,UAAU,CAA4B;IACtC,YAAY,CAAS;IACrB,IAAI,CAAqB;IAElC,YACE,MAA6B,EAC7B,WAA2B,EAC3B,IAAwB,EACxB,MAA0B,EAC1B,YAAoB;QAEpB,MAAM,SAAS,GAAG,IAAI,CAAC,IAAI,EAAE,UAAU,CAAC;QACxC,KAAK,CACH,MAAM,KAAK,gBAAgB;YACzB,CAAC,CAAC,iBAAiB,WAAW,SAAS,MAAM,CAAC,YAAY,GAAG,CAAC,CAAC,4CAA4C,SAAS,CAAC,CAAC,CAAC,aAAa,SAAS,GAAG,CAAC,CAAC,CAAC,EAAE,mCAAmC;YACxL,CAAC,CAAC,iBAAiB,WAAW,SAAS,MAAM,CAAC,YAAY,GAAG,CAAC,CAAC,uBAAuB,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,WAAW,CAAC,sCAAsC,SAAS,CAAC,CAAC,CAAC,aAAa,SAAS,GAAG,CAAC,CAAC,CAAC,EAAE,yCAAyC,CAClP,CAAC;QACF,IAAI,CAAC,IAAI,GAAG,iBAAiB,CAAC;QAC9B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QAC/B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,WA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,CAAC,KAAK,UAAU,OAAO,CAC3B,MAA0B,EAC1B,WAA2B,EAC3B,OAAO,GAAoB,EAAE;IAE7B,MAAM,KAAK,GAAc,EAAE,CAAC;IAC5B,IAAI,KAAK,EAAE,MAAM,IAAI,IAAI,QAAQ,CAAU,MAAM,EAAE,WAAW,EAAE,OAAO,CAAC,EAAE,CAAC;QACzE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACnB,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
@@ -0,0 +1,8 @@
1
+ export declare const OPENAPI_SOURCE = "0xinsider/0xinsider:web/public/api/v1/openapi.json";
2
+ export declare const OPENAPI_SHA256 = "99be30eda181b9464fb925a2f609a86bc96bb9253f6e264bd1d63380573fce64";
3
+ export declare const OPENAPI_VERSION = "1.0.0";
4
+ export declare const OPERATION_COUNT = 87;
5
+ export declare const APP_REPOSITORY = "0xinsider/0xinsider";
6
+ export declare const APP_SPEC_PATH = "web/public/api/v1/openapi.json";
7
+ export declare const APP_COMMIT: string | null;
8
+ //# sourceMappingURL=provenance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provenance.d.ts","sourceRoot":"","sources":["../src/provenance.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,cAAc,uDAAuD,CAAC;AACnF,eAAO,MAAM,cAAc,qEAAqE,CAAC;AACjG,eAAO,MAAM,eAAe,UAAU,CAAC;AACvC,eAAO,MAAM,eAAe,KAAK,CAAC;AAClC,eAAO,MAAM,cAAc,wBAAwB,CAAC;AACpD,eAAO,MAAM,aAAa,mCAAmC,CAAC;AAC9D,eAAO,MAAM,UAAU,EAAE,MAAM,GAAG,IAAiD,CAAC"}
@@ -0,0 +1,15 @@
1
+ // GENERATED by scripts/generate.mjs. Do not edit.
2
+ //
3
+ // Which OpenAPI document this release was generated from. OPENAPI_SHA256 is
4
+ // the SHA-256 of the document bytes as fetched; APP_COMMIT is the
5
+ // 0xinsider/0xinsider commit that last changed web/public/api/v1/openapi.json
6
+ // when it could be resolved, else null. Compare OPENAPI_SHA256 with the live
7
+ // document to see whether a release is behind the API.
8
+ export const OPENAPI_SOURCE = "0xinsider/0xinsider:web/public/api/v1/openapi.json";
9
+ export const OPENAPI_SHA256 = "99be30eda181b9464fb925a2f609a86bc96bb9253f6e264bd1d63380573fce64";
10
+ export const OPENAPI_VERSION = "1.0.0";
11
+ export const OPERATION_COUNT = 87;
12
+ export const APP_REPOSITORY = "0xinsider/0xinsider";
13
+ export const APP_SPEC_PATH = "web/public/api/v1/openapi.json";
14
+ export const APP_COMMIT = "0db0fe65d309cdb55ef8ddef28afaafe53f455c2";
15
+ //# sourceMappingURL=provenance.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"provenance.js","sourceRoot":"","sources":["../src/provenance.ts"],"names":[],"mappings":"AAAA,kDAAkD;AAClD,EAAE;AACF,4EAA4E;AAC5E,kEAAkE;AAClE,8EAA8E;AAC9E,6EAA6E;AAC7E,uDAAuD;AAEvD,MAAM,CAAC,MAAM,cAAc,GAAG,oDAAoD,CAAC;AACnF,MAAM,CAAC,MAAM,cAAc,GAAG,kEAAkE,CAAC;AACjG,MAAM,CAAC,MAAM,eAAe,GAAG,OAAO,CAAC;AACvC,MAAM,CAAC,MAAM,eAAe,GAAG,EAAE,CAAC;AAClC,MAAM,CAAC,MAAM,cAAc,GAAG,qBAAqB,CAAC;AACpD,MAAM,CAAC,MAAM,aAAa,GAAG,gCAAgC,CAAC;AAC9D,MAAM,CAAC,MAAM,UAAU,GAAkB,0CAA0C,CAAC"}