@secondlayer/sdk 6.40.2 → 6.41.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.
- package/dist/index.d.ts +18 -1
- package/dist/index.js.map +3 -3
- package/dist/streams/index.js.map +2 -2
- package/dist/subgraphs/index.d.ts +18 -1
- package/dist/subgraphs/index.js.map +3 -3
- package/package.json +4 -4
package/dist/index.d.ts
CHANGED
|
@@ -1375,7 +1375,7 @@ type EventsWalkParams<T extends IndexEventType = IndexEventType> = Omit<EventsLi
|
|
|
1375
1375
|
type EventsConsumeParams<
|
|
1376
1376
|
T extends IndexEventType = IndexEventType,
|
|
1377
1377
|
TTx = never
|
|
1378
|
-
> = Omit<EventsListParams<T>, "cursor" | "fromCursor" | "limit"> & IndexConsumeOptions<IndexEventOf<T>, EventsEnvelope<T>, TTx>;
|
|
1378
|
+
> = Omit<EventsListParams<T>, "cursor" | "fromCursor" | "limit" | "fields"> & IndexConsumeOptions<IndexEventOf<T>, EventsEnvelope<T>, TTx>;
|
|
1379
1379
|
type IndexContractCall = {
|
|
1380
1380
|
cursor: string
|
|
1381
1381
|
block_height: number
|
|
@@ -2066,6 +2066,14 @@ interface NftTransfersResource {
|
|
|
2066
2066
|
}
|
|
2067
2067
|
/** `index.events` — callable shorthand for `.list()`; `eventType` is required. */
|
|
2068
2068
|
interface IndexEventsResource {
|
|
2069
|
+
/** Narrowing overload for the callable shorthand — same wire path as
|
|
2070
|
+
* `list`, so it must narrow identically. */
|
|
2071
|
+
<
|
|
2072
|
+
T extends IndexEventType,
|
|
2073
|
+
const F extends keyof IndexEventOf<T> & string
|
|
2074
|
+
>(params: EventsListParams<T> & {
|
|
2075
|
+
fields: readonly F[]
|
|
2076
|
+
}): Promise<EventsEnvelope<T, IndexEventFields<T, F>>>;
|
|
2069
2077
|
<T extends IndexEventType>(params: EventsListParams<T>): Promise<EventsEnvelope<T>>;
|
|
2070
2078
|
/** Narrowing overload: `fields` shrinks the returned row type to exactly
|
|
2071
2079
|
* the requested columns plus {@link IndexAlwaysFields}. `const F` means no
|
|
@@ -2077,6 +2085,15 @@ interface IndexEventsResource {
|
|
|
2077
2085
|
fields: readonly F[]
|
|
2078
2086
|
}): Promise<EventsEnvelope<T, IndexEventFields<T, F>>>;
|
|
2079
2087
|
list<T extends IndexEventType>(params: EventsListParams<T>): Promise<EventsEnvelope<T>>;
|
|
2088
|
+
/** Narrowing overload, matching `list`: `walk` forwards `fields` to the
|
|
2089
|
+
* wire, so without this the yielded rows are stripped while the type
|
|
2090
|
+
* still promises every column. */
|
|
2091
|
+
walk<
|
|
2092
|
+
T extends IndexEventType,
|
|
2093
|
+
const F extends keyof IndexEventOf<T> & string
|
|
2094
|
+
>(params: EventsWalkParams<T> & {
|
|
2095
|
+
fields: readonly F[]
|
|
2096
|
+
}): AsyncIterable<IndexEventFields<T, F>>;
|
|
2080
2097
|
walk<T extends IndexEventType>(params: EventsWalkParams<T>): AsyncIterable<IndexEventOf<T>>;
|
|
2081
2098
|
consume<
|
|
2082
2099
|
T extends IndexEventType,
|