@injectivelabs/abacus-proto-ts
Advanced tools
Comparing version 1.13.0 to 1.13.1
@@ -13,2 +13,4 @@ import { grpc } from "@injectivelabs/grpc-web"; | ||
totalPoints: string; | ||
/** League assigned based on the rank among total participants. */ | ||
league: string; | ||
/** Latest computation timestamp of the rank and total points. */ | ||
@@ -23,4 +25,4 @@ updatedAt: string; | ||
} | ||
export interface PointsStatsDailyForAccountResponse { | ||
field: HistoricalPointsStatsRow[]; | ||
export interface HistoricalPointsStatsRowCollection { | ||
rows: HistoricalPointsStatsRow[]; | ||
} | ||
@@ -43,5 +45,2 @@ export interface HistoricalPointsStatsRow { | ||
} | ||
export interface PointsStatsWeeklyForAccountResponse { | ||
field: HistoricalPointsStatsRow[]; | ||
} | ||
export interface PointsCreateAbsoluteCorrectionRequest { | ||
@@ -55,4 +54,4 @@ /** Account address to set points for. */ | ||
/** | ||
* Target timestamp of the points correction effective date. Correction applied | ||
* after this timestamp. | ||
* Target UNIX timestamp in seconds, of the points correction effective date. | ||
* Correction applied after this timestamp. | ||
*/ | ||
@@ -70,3 +69,6 @@ effectiveFrom?: string | undefined; | ||
label?: string | undefined; | ||
/** Target timestamp of the points correction. Delta applied at this timestamp. */ | ||
/** | ||
* Target UNIX timestamp in seconds, of the points correction effective date. | ||
* Delta applied at this timestamp. | ||
*/ | ||
effectiveTimestamp?: string | undefined; | ||
@@ -108,9 +110,9 @@ } | ||
}; | ||
export declare const PointsStatsDailyForAccountResponse: { | ||
encode(message: PointsStatsDailyForAccountResponse, writer?: _m0.Writer): _m0.Writer; | ||
decode(input: _m0.Reader | Uint8Array, length?: number): PointsStatsDailyForAccountResponse; | ||
fromJSON(object: any): PointsStatsDailyForAccountResponse; | ||
toJSON(message: PointsStatsDailyForAccountResponse): unknown; | ||
create(base?: DeepPartial<PointsStatsDailyForAccountResponse>): PointsStatsDailyForAccountResponse; | ||
fromPartial(object: DeepPartial<PointsStatsDailyForAccountResponse>): PointsStatsDailyForAccountResponse; | ||
export declare const HistoricalPointsStatsRowCollection: { | ||
encode(message: HistoricalPointsStatsRowCollection, writer?: _m0.Writer): _m0.Writer; | ||
decode(input: _m0.Reader | Uint8Array, length?: number): HistoricalPointsStatsRowCollection; | ||
fromJSON(object: any): HistoricalPointsStatsRowCollection; | ||
toJSON(message: HistoricalPointsStatsRowCollection): unknown; | ||
create(base?: DeepPartial<HistoricalPointsStatsRowCollection>): HistoricalPointsStatsRowCollection; | ||
fromPartial(object: DeepPartial<HistoricalPointsStatsRowCollection>): HistoricalPointsStatsRowCollection; | ||
}; | ||
@@ -133,10 +135,2 @@ export declare const HistoricalPointsStatsRow: { | ||
}; | ||
export declare const PointsStatsWeeklyForAccountResponse: { | ||
encode(message: PointsStatsWeeklyForAccountResponse, writer?: _m0.Writer): _m0.Writer; | ||
decode(input: _m0.Reader | Uint8Array, length?: number): PointsStatsWeeklyForAccountResponse; | ||
fromJSON(object: any): PointsStatsWeeklyForAccountResponse; | ||
toJSON(message: PointsStatsWeeklyForAccountResponse): unknown; | ||
create(base?: DeepPartial<PointsStatsWeeklyForAccountResponse>): PointsStatsWeeklyForAccountResponse; | ||
fromPartial(object: DeepPartial<PointsStatsWeeklyForAccountResponse>): PointsStatsWeeklyForAccountResponse; | ||
}; | ||
export declare const PointsCreateAbsoluteCorrectionRequest: { | ||
@@ -195,5 +189,5 @@ encode(message: PointsCreateAbsoluteCorrectionRequest, writer?: _m0.Writer): _m0.Writer; | ||
/** Gets user's daily incurred points and volume by account address. */ | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsDailyForAccountResponse>; | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
/** Gets user's weekly incurred points and volume by account address. */ | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsWeeklyForAccountResponse>; | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
/** Creates an absolute points correction for an account address. */ | ||
@@ -213,4 +207,4 @@ PointsCreateAbsoluteCorrection(request: DeepPartial<PointsCreateAbsoluteCorrectionRequest>, metadata?: grpc.Metadata): Promise<PointsCreateAbsoluteCorrectionResponse>; | ||
PointsLatestForAccount(request: DeepPartial<PointsLatestForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsLatestForAccountResponse>; | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsDailyForAccountResponse>; | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsWeeklyForAccountResponse>; | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
PointsCreateAbsoluteCorrection(request: DeepPartial<PointsCreateAbsoluteCorrectionRequest>, metadata?: grpc.Metadata): Promise<PointsCreateAbsoluteCorrectionResponse>; | ||
@@ -217,0 +211,0 @@ PointsCreateRelativeCorrection(request: DeepPartial<PointsCreateRelativeCorrectionRequest>, metadata?: grpc.Metadata): Promise<PointsCreateRelativeCorrectionResponse>; |
@@ -6,3 +6,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.GrpcWebError = exports.GrpcWebImpl = exports.PointsSvcPointsCreateBanDesc = exports.PointsSvcPointsCreateRelativeCorrectionDesc = exports.PointsSvcPointsCreateAbsoluteCorrectionDesc = exports.PointsSvcPointsStatsWeeklyForAccountDesc = exports.PointsSvcPointsStatsDailyForAccountDesc = exports.PointsSvcPointsLatestForAccountDesc = exports.PointsSvcDesc = exports.PointsSvcClientImpl = exports.PointsCreateBanResponse = exports.PointsCreateBanRequest = exports.PointsCreateRelativeCorrectionResponse = exports.PointsCreateRelativeCorrectionRequest = exports.PointsCreateAbsoluteCorrectionResponse = exports.PointsCreateAbsoluteCorrectionRequest = exports.PointsStatsWeeklyForAccountResponse = exports.PointsStatsWeeklyForAccountRequest = exports.HistoricalPointsStatsRow = exports.PointsStatsDailyForAccountResponse = exports.PointsStatsDailyForAccountRequest = exports.PointsLatestForAccountResponse = exports.PointsLatestForAccountRequest = exports.protobufPackage = void 0; | ||
exports.GrpcWebError = exports.GrpcWebImpl = exports.PointsSvcPointsCreateBanDesc = exports.PointsSvcPointsCreateRelativeCorrectionDesc = exports.PointsSvcPointsCreateAbsoluteCorrectionDesc = exports.PointsSvcPointsStatsWeeklyForAccountDesc = exports.PointsSvcPointsStatsDailyForAccountDesc = exports.PointsSvcPointsLatestForAccountDesc = exports.PointsSvcDesc = exports.PointsSvcClientImpl = exports.PointsCreateBanResponse = exports.PointsCreateBanRequest = exports.PointsCreateRelativeCorrectionResponse = exports.PointsCreateRelativeCorrectionRequest = exports.PointsCreateAbsoluteCorrectionResponse = exports.PointsCreateAbsoluteCorrectionRequest = exports.PointsStatsWeeklyForAccountRequest = exports.HistoricalPointsStatsRow = exports.HistoricalPointsStatsRowCollection = exports.PointsStatsDailyForAccountRequest = exports.PointsLatestForAccountResponse = exports.PointsLatestForAccountRequest = exports.protobufPackage = void 0; | ||
/* eslint-disable */ | ||
@@ -60,3 +60,3 @@ const grpc_web_1 = require("@injectivelabs/grpc-web"); | ||
function createBasePointsLatestForAccountResponse() { | ||
return { rank: "0", totalPoints: "0", updatedAt: "" }; | ||
return { rank: "0", totalPoints: "0", league: "", updatedAt: "" }; | ||
} | ||
@@ -71,4 +71,7 @@ exports.PointsLatestForAccountResponse = { | ||
} | ||
if (message.league !== "") { | ||
writer.uint32(26).string(message.league); | ||
} | ||
if (message.updatedAt !== "") { | ||
writer.uint32(26).string(message.updatedAt); | ||
writer.uint32(34).string(message.updatedAt); | ||
} | ||
@@ -91,2 +94,5 @@ return writer; | ||
case 3: | ||
message.league = reader.string(); | ||
break; | ||
case 4: | ||
message.updatedAt = reader.string(); | ||
@@ -105,2 +111,3 @@ break; | ||
totalPoints: isSet(object.totalPoints) ? String(object.totalPoints) : "0", | ||
league: isSet(object.league) ? String(object.league) : "", | ||
updatedAt: isSet(object.updatedAt) ? String(object.updatedAt) : "", | ||
@@ -113,2 +120,3 @@ }; | ||
message.totalPoints !== undefined && (obj.totalPoints = message.totalPoints); | ||
message.league !== undefined && (obj.league = message.league); | ||
message.updatedAt !== undefined && (obj.updatedAt = message.updatedAt); | ||
@@ -121,7 +129,8 @@ return obj; | ||
fromPartial(object) { | ||
var _a, _b, _c; | ||
var _a, _b, _c, _d; | ||
const message = createBasePointsLatestForAccountResponse(); | ||
message.rank = (_a = object.rank) !== null && _a !== void 0 ? _a : "0"; | ||
message.totalPoints = (_b = object.totalPoints) !== null && _b !== void 0 ? _b : "0"; | ||
message.updatedAt = (_c = object.updatedAt) !== null && _c !== void 0 ? _c : ""; | ||
message.league = (_c = object.league) !== null && _c !== void 0 ? _c : ""; | ||
message.updatedAt = (_d = object.updatedAt) !== null && _d !== void 0 ? _d : ""; | ||
return message; | ||
@@ -186,8 +195,8 @@ }, | ||
}; | ||
function createBasePointsStatsDailyForAccountResponse() { | ||
return { field: [] }; | ||
function createBaseHistoricalPointsStatsRowCollection() { | ||
return { rows: [] }; | ||
} | ||
exports.PointsStatsDailyForAccountResponse = { | ||
exports.HistoricalPointsStatsRowCollection = { | ||
encode(message, writer = minimal_js_1.default.Writer.create()) { | ||
for (const v of message.field) { | ||
for (const v of message.rows) { | ||
exports.HistoricalPointsStatsRow.encode(v, writer.uint32(10).fork()).ldelim(); | ||
@@ -200,3 +209,3 @@ } | ||
let end = length === undefined ? reader.len : reader.pos + length; | ||
const message = createBasePointsStatsDailyForAccountResponse(); | ||
const message = createBaseHistoricalPointsStatsRowCollection(); | ||
while (reader.pos < end) { | ||
@@ -206,3 +215,3 @@ const tag = reader.uint32(); | ||
case 1: | ||
message.field.push(exports.HistoricalPointsStatsRow.decode(reader, reader.uint32())); | ||
message.rows.push(exports.HistoricalPointsStatsRow.decode(reader, reader.uint32())); | ||
break; | ||
@@ -218,3 +227,3 @@ default: | ||
return { | ||
field: Array.isArray(object === null || object === void 0 ? void 0 : object.field) ? object.field.map((e) => exports.HistoricalPointsStatsRow.fromJSON(e)) : [], | ||
rows: Array.isArray(object === null || object === void 0 ? void 0 : object.rows) ? object.rows.map((e) => exports.HistoricalPointsStatsRow.fromJSON(e)) : [], | ||
}; | ||
@@ -224,7 +233,7 @@ }, | ||
const obj = {}; | ||
if (message.field) { | ||
obj.field = message.field.map((e) => e ? exports.HistoricalPointsStatsRow.toJSON(e) : undefined); | ||
if (message.rows) { | ||
obj.rows = message.rows.map((e) => e ? exports.HistoricalPointsStatsRow.toJSON(e) : undefined); | ||
} | ||
else { | ||
obj.field = []; | ||
obj.rows = []; | ||
} | ||
@@ -234,8 +243,8 @@ return obj; | ||
create(base) { | ||
return exports.PointsStatsDailyForAccountResponse.fromPartial(base !== null && base !== void 0 ? base : {}); | ||
return exports.HistoricalPointsStatsRowCollection.fromPartial(base !== null && base !== void 0 ? base : {}); | ||
}, | ||
fromPartial(object) { | ||
var _a; | ||
const message = createBasePointsStatsDailyForAccountResponse(); | ||
message.field = ((_a = object.field) === null || _a === void 0 ? void 0 : _a.map((e) => exports.HistoricalPointsStatsRow.fromPartial(e))) || []; | ||
const message = createBaseHistoricalPointsStatsRowCollection(); | ||
message.rows = ((_a = object.rows) === null || _a === void 0 ? void 0 : _a.map((e) => exports.HistoricalPointsStatsRow.fromPartial(e))) || []; | ||
return message; | ||
@@ -374,54 +383,2 @@ }, | ||
}; | ||
function createBasePointsStatsWeeklyForAccountResponse() { | ||
return { field: [] }; | ||
} | ||
exports.PointsStatsWeeklyForAccountResponse = { | ||
encode(message, writer = minimal_js_1.default.Writer.create()) { | ||
for (const v of message.field) { | ||
exports.HistoricalPointsStatsRow.encode(v, writer.uint32(10).fork()).ldelim(); | ||
} | ||
return writer; | ||
}, | ||
decode(input, length) { | ||
const reader = input instanceof minimal_js_1.default.Reader ? input : new minimal_js_1.default.Reader(input); | ||
let end = length === undefined ? reader.len : reader.pos + length; | ||
const message = createBasePointsStatsWeeklyForAccountResponse(); | ||
while (reader.pos < end) { | ||
const tag = reader.uint32(); | ||
switch (tag >>> 3) { | ||
case 1: | ||
message.field.push(exports.HistoricalPointsStatsRow.decode(reader, reader.uint32())); | ||
break; | ||
default: | ||
reader.skipType(tag & 7); | ||
break; | ||
} | ||
} | ||
return message; | ||
}, | ||
fromJSON(object) { | ||
return { | ||
field: Array.isArray(object === null || object === void 0 ? void 0 : object.field) ? object.field.map((e) => exports.HistoricalPointsStatsRow.fromJSON(e)) : [], | ||
}; | ||
}, | ||
toJSON(message) { | ||
const obj = {}; | ||
if (message.field) { | ||
obj.field = message.field.map((e) => e ? exports.HistoricalPointsStatsRow.toJSON(e) : undefined); | ||
} | ||
else { | ||
obj.field = []; | ||
} | ||
return obj; | ||
}, | ||
create(base) { | ||
return exports.PointsStatsWeeklyForAccountResponse.fromPartial(base !== null && base !== void 0 ? base : {}); | ||
}, | ||
fromPartial(object) { | ||
var _a; | ||
const message = createBasePointsStatsWeeklyForAccountResponse(); | ||
message.field = ((_a = object.field) === null || _a === void 0 ? void 0 : _a.map((e) => exports.HistoricalPointsStatsRow.fromPartial(e))) || []; | ||
return message; | ||
}, | ||
}; | ||
function createBasePointsCreateAbsoluteCorrectionRequest() { | ||
@@ -442,3 +399,3 @@ return { accountAddress: "", points: "0", label: undefined, effectiveFrom: undefined }; | ||
if (message.effectiveFrom !== undefined) { | ||
writer.uint32(34).string(message.effectiveFrom); | ||
writer.uint32(32).uint64(message.effectiveFrom); | ||
} | ||
@@ -464,3 +421,3 @@ return writer; | ||
case 4: | ||
message.effectiveFrom = reader.string(); | ||
message.effectiveFrom = longToString(reader.uint64()); | ||
break; | ||
@@ -554,3 +511,3 @@ default: | ||
if (message.effectiveTimestamp !== undefined) { | ||
writer.uint32(34).string(message.effectiveTimestamp); | ||
writer.uint32(32).uint64(message.effectiveTimestamp); | ||
} | ||
@@ -576,3 +533,3 @@ return writer; | ||
case 4: | ||
message.effectiveTimestamp = reader.string(); | ||
message.effectiveTimestamp = longToString(reader.uint64()); | ||
break; | ||
@@ -805,3 +762,3 @@ default: | ||
deserializeBinary(data) { | ||
const value = exports.PointsStatsDailyForAccountResponse.decode(data); | ||
const value = exports.HistoricalPointsStatsRowCollection.decode(data); | ||
return Object.assign(Object.assign({}, value), { toObject() { | ||
@@ -825,3 +782,3 @@ return value; | ||
deserializeBinary(data) { | ||
const value = exports.PointsStatsWeeklyForAccountResponse.decode(data); | ||
const value = exports.HistoricalPointsStatsRowCollection.decode(data); | ||
return Object.assign(Object.assign({}, value), { toObject() { | ||
@@ -828,0 +785,0 @@ return value; |
@@ -13,2 +13,4 @@ import { grpc } from "@injectivelabs/grpc-web"; | ||
totalPoints: string; | ||
/** League assigned based on the rank among total participants. */ | ||
league: string; | ||
/** Latest computation timestamp of the rank and total points. */ | ||
@@ -23,4 +25,4 @@ updatedAt: string; | ||
} | ||
export interface PointsStatsDailyForAccountResponse { | ||
field: HistoricalPointsStatsRow[]; | ||
export interface HistoricalPointsStatsRowCollection { | ||
rows: HistoricalPointsStatsRow[]; | ||
} | ||
@@ -43,5 +45,2 @@ export interface HistoricalPointsStatsRow { | ||
} | ||
export interface PointsStatsWeeklyForAccountResponse { | ||
field: HistoricalPointsStatsRow[]; | ||
} | ||
export interface PointsCreateAbsoluteCorrectionRequest { | ||
@@ -55,4 +54,4 @@ /** Account address to set points for. */ | ||
/** | ||
* Target timestamp of the points correction effective date. Correction applied | ||
* after this timestamp. | ||
* Target UNIX timestamp in seconds, of the points correction effective date. | ||
* Correction applied after this timestamp. | ||
*/ | ||
@@ -70,3 +69,6 @@ effectiveFrom?: string | undefined; | ||
label?: string | undefined; | ||
/** Target timestamp of the points correction. Delta applied at this timestamp. */ | ||
/** | ||
* Target UNIX timestamp in seconds, of the points correction effective date. | ||
* Delta applied at this timestamp. | ||
*/ | ||
effectiveTimestamp?: string | undefined; | ||
@@ -108,9 +110,9 @@ } | ||
}; | ||
export declare const PointsStatsDailyForAccountResponse: { | ||
encode(message: PointsStatsDailyForAccountResponse, writer?: _m0.Writer): _m0.Writer; | ||
decode(input: _m0.Reader | Uint8Array, length?: number): PointsStatsDailyForAccountResponse; | ||
fromJSON(object: any): PointsStatsDailyForAccountResponse; | ||
toJSON(message: PointsStatsDailyForAccountResponse): unknown; | ||
create(base?: DeepPartial<PointsStatsDailyForAccountResponse>): PointsStatsDailyForAccountResponse; | ||
fromPartial(object: DeepPartial<PointsStatsDailyForAccountResponse>): PointsStatsDailyForAccountResponse; | ||
export declare const HistoricalPointsStatsRowCollection: { | ||
encode(message: HistoricalPointsStatsRowCollection, writer?: _m0.Writer): _m0.Writer; | ||
decode(input: _m0.Reader | Uint8Array, length?: number): HistoricalPointsStatsRowCollection; | ||
fromJSON(object: any): HistoricalPointsStatsRowCollection; | ||
toJSON(message: HistoricalPointsStatsRowCollection): unknown; | ||
create(base?: DeepPartial<HistoricalPointsStatsRowCollection>): HistoricalPointsStatsRowCollection; | ||
fromPartial(object: DeepPartial<HistoricalPointsStatsRowCollection>): HistoricalPointsStatsRowCollection; | ||
}; | ||
@@ -133,10 +135,2 @@ export declare const HistoricalPointsStatsRow: { | ||
}; | ||
export declare const PointsStatsWeeklyForAccountResponse: { | ||
encode(message: PointsStatsWeeklyForAccountResponse, writer?: _m0.Writer): _m0.Writer; | ||
decode(input: _m0.Reader | Uint8Array, length?: number): PointsStatsWeeklyForAccountResponse; | ||
fromJSON(object: any): PointsStatsWeeklyForAccountResponse; | ||
toJSON(message: PointsStatsWeeklyForAccountResponse): unknown; | ||
create(base?: DeepPartial<PointsStatsWeeklyForAccountResponse>): PointsStatsWeeklyForAccountResponse; | ||
fromPartial(object: DeepPartial<PointsStatsWeeklyForAccountResponse>): PointsStatsWeeklyForAccountResponse; | ||
}; | ||
export declare const PointsCreateAbsoluteCorrectionRequest: { | ||
@@ -195,5 +189,5 @@ encode(message: PointsCreateAbsoluteCorrectionRequest, writer?: _m0.Writer): _m0.Writer; | ||
/** Gets user's daily incurred points and volume by account address. */ | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsDailyForAccountResponse>; | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
/** Gets user's weekly incurred points and volume by account address. */ | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsWeeklyForAccountResponse>; | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
/** Creates an absolute points correction for an account address. */ | ||
@@ -213,4 +207,4 @@ PointsCreateAbsoluteCorrection(request: DeepPartial<PointsCreateAbsoluteCorrectionRequest>, metadata?: grpc.Metadata): Promise<PointsCreateAbsoluteCorrectionResponse>; | ||
PointsLatestForAccount(request: DeepPartial<PointsLatestForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsLatestForAccountResponse>; | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsDailyForAccountResponse>; | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<PointsStatsWeeklyForAccountResponse>; | ||
PointsStatsDailyForAccount(request: DeepPartial<PointsStatsDailyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
PointsStatsWeeklyForAccount(request: DeepPartial<PointsStatsWeeklyForAccountRequest>, metadata?: grpc.Metadata): Promise<HistoricalPointsStatsRowCollection>; | ||
PointsCreateAbsoluteCorrection(request: DeepPartial<PointsCreateAbsoluteCorrectionRequest>, metadata?: grpc.Metadata): Promise<PointsCreateAbsoluteCorrectionResponse>; | ||
@@ -217,0 +211,0 @@ PointsCreateRelativeCorrection(request: DeepPartial<PointsCreateRelativeCorrectionRequest>, metadata?: grpc.Metadata): Promise<PointsCreateRelativeCorrectionResponse>; |
@@ -52,3 +52,3 @@ /* eslint-disable */ | ||
function createBasePointsLatestForAccountResponse() { | ||
return { rank: "0", totalPoints: "0", updatedAt: "" }; | ||
return { rank: "0", totalPoints: "0", league: "", updatedAt: "" }; | ||
} | ||
@@ -63,4 +63,7 @@ export const PointsLatestForAccountResponse = { | ||
} | ||
if (message.league !== "") { | ||
writer.uint32(26).string(message.league); | ||
} | ||
if (message.updatedAt !== "") { | ||
writer.uint32(26).string(message.updatedAt); | ||
writer.uint32(34).string(message.updatedAt); | ||
} | ||
@@ -83,2 +86,5 @@ return writer; | ||
case 3: | ||
message.league = reader.string(); | ||
break; | ||
case 4: | ||
message.updatedAt = reader.string(); | ||
@@ -97,2 +103,3 @@ break; | ||
totalPoints: isSet(object.totalPoints) ? String(object.totalPoints) : "0", | ||
league: isSet(object.league) ? String(object.league) : "", | ||
updatedAt: isSet(object.updatedAt) ? String(object.updatedAt) : "", | ||
@@ -105,2 +112,3 @@ }; | ||
message.totalPoints !== undefined && (obj.totalPoints = message.totalPoints); | ||
message.league !== undefined && (obj.league = message.league); | ||
message.updatedAt !== undefined && (obj.updatedAt = message.updatedAt); | ||
@@ -116,2 +124,3 @@ return obj; | ||
message.totalPoints = object.totalPoints ?? "0"; | ||
message.league = object.league ?? ""; | ||
message.updatedAt = object.updatedAt ?? ""; | ||
@@ -176,8 +185,8 @@ return message; | ||
}; | ||
function createBasePointsStatsDailyForAccountResponse() { | ||
return { field: [] }; | ||
function createBaseHistoricalPointsStatsRowCollection() { | ||
return { rows: [] }; | ||
} | ||
export const PointsStatsDailyForAccountResponse = { | ||
export const HistoricalPointsStatsRowCollection = { | ||
encode(message, writer = _m0.Writer.create()) { | ||
for (const v of message.field) { | ||
for (const v of message.rows) { | ||
HistoricalPointsStatsRow.encode(v, writer.uint32(10).fork()).ldelim(); | ||
@@ -190,3 +199,3 @@ } | ||
let end = length === undefined ? reader.len : reader.pos + length; | ||
const message = createBasePointsStatsDailyForAccountResponse(); | ||
const message = createBaseHistoricalPointsStatsRowCollection(); | ||
while (reader.pos < end) { | ||
@@ -196,3 +205,3 @@ const tag = reader.uint32(); | ||
case 1: | ||
message.field.push(HistoricalPointsStatsRow.decode(reader, reader.uint32())); | ||
message.rows.push(HistoricalPointsStatsRow.decode(reader, reader.uint32())); | ||
break; | ||
@@ -208,3 +217,3 @@ default: | ||
return { | ||
field: Array.isArray(object?.field) ? object.field.map((e) => HistoricalPointsStatsRow.fromJSON(e)) : [], | ||
rows: Array.isArray(object?.rows) ? object.rows.map((e) => HistoricalPointsStatsRow.fromJSON(e)) : [], | ||
}; | ||
@@ -214,7 +223,7 @@ }, | ||
const obj = {}; | ||
if (message.field) { | ||
obj.field = message.field.map((e) => e ? HistoricalPointsStatsRow.toJSON(e) : undefined); | ||
if (message.rows) { | ||
obj.rows = message.rows.map((e) => e ? HistoricalPointsStatsRow.toJSON(e) : undefined); | ||
} | ||
else { | ||
obj.field = []; | ||
obj.rows = []; | ||
} | ||
@@ -224,7 +233,7 @@ return obj; | ||
create(base) { | ||
return PointsStatsDailyForAccountResponse.fromPartial(base ?? {}); | ||
return HistoricalPointsStatsRowCollection.fromPartial(base ?? {}); | ||
}, | ||
fromPartial(object) { | ||
const message = createBasePointsStatsDailyForAccountResponse(); | ||
message.field = object.field?.map((e) => HistoricalPointsStatsRow.fromPartial(e)) || []; | ||
const message = createBaseHistoricalPointsStatsRowCollection(); | ||
message.rows = object.rows?.map((e) => HistoricalPointsStatsRow.fromPartial(e)) || []; | ||
return message; | ||
@@ -361,53 +370,2 @@ }, | ||
}; | ||
function createBasePointsStatsWeeklyForAccountResponse() { | ||
return { field: [] }; | ||
} | ||
export const PointsStatsWeeklyForAccountResponse = { | ||
encode(message, writer = _m0.Writer.create()) { | ||
for (const v of message.field) { | ||
HistoricalPointsStatsRow.encode(v, writer.uint32(10).fork()).ldelim(); | ||
} | ||
return writer; | ||
}, | ||
decode(input, length) { | ||
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input); | ||
let end = length === undefined ? reader.len : reader.pos + length; | ||
const message = createBasePointsStatsWeeklyForAccountResponse(); | ||
while (reader.pos < end) { | ||
const tag = reader.uint32(); | ||
switch (tag >>> 3) { | ||
case 1: | ||
message.field.push(HistoricalPointsStatsRow.decode(reader, reader.uint32())); | ||
break; | ||
default: | ||
reader.skipType(tag & 7); | ||
break; | ||
} | ||
} | ||
return message; | ||
}, | ||
fromJSON(object) { | ||
return { | ||
field: Array.isArray(object?.field) ? object.field.map((e) => HistoricalPointsStatsRow.fromJSON(e)) : [], | ||
}; | ||
}, | ||
toJSON(message) { | ||
const obj = {}; | ||
if (message.field) { | ||
obj.field = message.field.map((e) => e ? HistoricalPointsStatsRow.toJSON(e) : undefined); | ||
} | ||
else { | ||
obj.field = []; | ||
} | ||
return obj; | ||
}, | ||
create(base) { | ||
return PointsStatsWeeklyForAccountResponse.fromPartial(base ?? {}); | ||
}, | ||
fromPartial(object) { | ||
const message = createBasePointsStatsWeeklyForAccountResponse(); | ||
message.field = object.field?.map((e) => HistoricalPointsStatsRow.fromPartial(e)) || []; | ||
return message; | ||
}, | ||
}; | ||
function createBasePointsCreateAbsoluteCorrectionRequest() { | ||
@@ -428,3 +386,3 @@ return { accountAddress: "", points: "0", label: undefined, effectiveFrom: undefined }; | ||
if (message.effectiveFrom !== undefined) { | ||
writer.uint32(34).string(message.effectiveFrom); | ||
writer.uint32(32).uint64(message.effectiveFrom); | ||
} | ||
@@ -450,3 +408,3 @@ return writer; | ||
case 4: | ||
message.effectiveFrom = reader.string(); | ||
message.effectiveFrom = longToString(reader.uint64()); | ||
break; | ||
@@ -539,3 +497,3 @@ default: | ||
if (message.effectiveTimestamp !== undefined) { | ||
writer.uint32(34).string(message.effectiveTimestamp); | ||
writer.uint32(32).uint64(message.effectiveTimestamp); | ||
} | ||
@@ -561,3 +519,3 @@ return writer; | ||
case 4: | ||
message.effectiveTimestamp = reader.string(); | ||
message.effectiveTimestamp = longToString(reader.uint64()); | ||
break; | ||
@@ -791,3 +749,3 @@ default: | ||
deserializeBinary(data) { | ||
const value = PointsStatsDailyForAccountResponse.decode(data); | ||
const value = HistoricalPointsStatsRowCollection.decode(data); | ||
return { | ||
@@ -814,3 +772,3 @@ ...value, | ||
deserializeBinary(data) { | ||
const value = PointsStatsWeeklyForAccountResponse.decode(data); | ||
const value = HistoricalPointsStatsRowCollection.decode(data); | ||
return { | ||
@@ -817,0 +775,0 @@ ...value, |
{ | ||
"name": "@injectivelabs/abacus-proto-ts", | ||
"version": "1.13.0", | ||
"version": "1.13.1", | ||
"description": "Injective Abacus API client with generated gRPC bindings.", | ||
@@ -5,0 +5,0 @@ "sideEffects": "false", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
471364
11153