Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file.

## [Unreleased] - 9999-99-99
## [1.11.0] - 2025-07-29
### Added
- Added support for Exchange V2 proto queries and types
- Added support for ERC20 proto queries and types
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ clean-all:
$(call clean_repos)

clone-injective-indexer:
git clone https://github.com/InjectiveLabs/injective-indexer.git -b v1.16.20 --depth 1 --single-branch
git clone https://github.com/InjectiveLabs/injective-indexer.git -b v1.16.54 --depth 1 --single-branch

clone-all: clone-injective-indexer

Expand Down
2 changes: 1 addition & 1 deletion buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ inputs:
# branch: v0.51.x-inj
# subdir: proto
- git_repo: https://github.com/InjectiveLabs/injective-core
tag: v1.16.0-beta.3
tag: v1.16.0
subdir: proto
# - git_repo: https://github.com/InjectiveLabs/injective-core
# branch: master
Expand Down
1,118 changes: 584 additions & 534 deletions poetry.lock

Large diffs are not rendered by default.

98 changes: 51 additions & 47 deletions pyinjective/proto/exchange/injective_archiver_rpc_pb2.py

Large diffs are not rendered by default.

44 changes: 44 additions & 0 deletions pyinjective/proto/exchange/injective_archiver_rpc_pb2_grpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ def __init__(self, channel):
request_serializer=exchange_dot_injective__archiver__rpc__pb2.BalanceRequest.SerializeToString,
response_deserializer=exchange_dot_injective__archiver__rpc__pb2.BalanceResponse.FromString,
_registered_method=True)
self.AccountStats = channel.unary_unary(
'/injective_archiver_rpc.InjectiveArchiverRPC/AccountStats',
request_serializer=exchange_dot_injective__archiver__rpc__pb2.AccountStatsRequest.SerializeToString,
response_deserializer=exchange_dot_injective__archiver__rpc__pb2.AccountStatsResponse.FromString,
_registered_method=True)
self.Rpnl = channel.unary_unary(
'/injective_archiver_rpc.InjectiveArchiverRPC/Rpnl',
request_serializer=exchange_dot_injective__archiver__rpc__pb2.RpnlRequest.SerializeToString,
Expand Down Expand Up @@ -73,6 +78,13 @@ def Balance(self, request, context):
context.set_details('Method not implemented!')
raise NotImplementedError('Method not implemented!')

def AccountStats(self, request, context):
"""Provide all-time stats for a given account address.
"""
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
context.set_details('Method not implemented!')
raise NotImplementedError('Method not implemented!')

def Rpnl(self, request, context):
"""Provide historical realized profit and loss data for a given account address.
"""
Expand Down Expand Up @@ -137,6 +149,11 @@ def add_InjectiveArchiverRPCServicer_to_server(servicer, server):
request_deserializer=exchange_dot_injective__archiver__rpc__pb2.BalanceRequest.FromString,
response_serializer=exchange_dot_injective__archiver__rpc__pb2.BalanceResponse.SerializeToString,
),
'AccountStats': grpc.unary_unary_rpc_method_handler(
servicer.AccountStats,
request_deserializer=exchange_dot_injective__archiver__rpc__pb2.AccountStatsRequest.FromString,
response_serializer=exchange_dot_injective__archiver__rpc__pb2.AccountStatsResponse.SerializeToString,
),
'Rpnl': grpc.unary_unary_rpc_method_handler(
servicer.Rpnl,
request_deserializer=exchange_dot_injective__archiver__rpc__pb2.RpnlRequest.FromString,
Expand Down Expand Up @@ -216,6 +233,33 @@ def Balance(request,
metadata,
_registered_method=True)

@staticmethod
def AccountStats(request,
target,
options=(),
channel_credentials=None,
call_credentials=None,
insecure=False,
compression=None,
wait_for_ready=None,
timeout=None,
metadata=None):
return grpc.experimental.unary_unary(
request,
target,
'/injective_archiver_rpc.InjectiveArchiverRPC/AccountStats',
exchange_dot_injective__archiver__rpc__pb2.AccountStatsRequest.SerializeToString,
exchange_dot_injective__archiver__rpc__pb2.AccountStatsResponse.FromString,
options,
channel_credentials,
insecure,
call_credentials,
compression,
wait_for_ready,
timeout,
metadata,
_registered_method=True)

@staticmethod
def Rpnl(request,
target,
Expand Down
35 changes: 35 additions & 0 deletions pyinjective/proto/exchange/injective_megavault_rpc_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

81 changes: 81 additions & 0 deletions pyinjective/proto/exchange/injective_megavault_rpc_pb2_grpc.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
"""Client and server classes corresponding to protobuf-defined services."""
import grpc

from pyinjective.proto.exchange import injective_megavault_rpc_pb2 as exchange_dot_injective__megavault__rpc__pb2


class InjectiveMegavaultRPCStub(object):
"""InjectiveMegavaultRPC defined a gRPC service for Injective Megavault.
"""

def __init__(self, channel):
"""Constructor.

Args:
channel: A grpc.Channel.
"""
self.GetVault = channel.unary_unary(
'/injective_megavault_rpc.InjectiveMegavaultRPC/GetVault',
request_serializer=exchange_dot_injective__megavault__rpc__pb2.GetVaultRequest.SerializeToString,
response_deserializer=exchange_dot_injective__megavault__rpc__pb2.GetVaultResponse.FromString,
_registered_method=True)


class InjectiveMegavaultRPCServicer(object):
"""InjectiveMegavaultRPC defined a gRPC service for Injective Megavault.
"""

def GetVault(self, request, context):
"""Get the vault information
"""
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
context.set_details('Method not implemented!')
raise NotImplementedError('Method not implemented!')


def add_InjectiveMegavaultRPCServicer_to_server(servicer, server):
rpc_method_handlers = {
'GetVault': grpc.unary_unary_rpc_method_handler(
servicer.GetVault,
request_deserializer=exchange_dot_injective__megavault__rpc__pb2.GetVaultRequest.FromString,
response_serializer=exchange_dot_injective__megavault__rpc__pb2.GetVaultResponse.SerializeToString,
),
}
generic_handler = grpc.method_handlers_generic_handler(
'injective_megavault_rpc.InjectiveMegavaultRPC', rpc_method_handlers)
server.add_generic_rpc_handlers((generic_handler,))
server.add_registered_method_handlers('injective_megavault_rpc.InjectiveMegavaultRPC', rpc_method_handlers)


# This class is part of an EXPERIMENTAL API.
class InjectiveMegavaultRPC(object):
"""InjectiveMegavaultRPC defined a gRPC service for Injective Megavault.
"""

@staticmethod
def GetVault(request,
target,
options=(),
channel_credentials=None,
call_credentials=None,
insecure=False,
compression=None,
wait_for_ready=None,
timeout=None,
metadata=None):
return grpc.experimental.unary_unary(
request,
target,
'/injective_megavault_rpc.InjectiveMegavaultRPC/GetVault',
exchange_dot_injective__megavault__rpc__pb2.GetVaultRequest.SerializeToString,
exchange_dot_injective__megavault__rpc__pb2.GetVaultResponse.FromString,
options,
channel_credentials,
insecure,
call_credentials,
compression,
wait_for_ready,
timeout,
metadata,
_registered_method=True)
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "injective-py"
version = "1.11.0-rc6"
version = "1.11.0"
description = "Injective Python SDK, with Exchange API Client"
authors = ["Injective Labs <contact@injectivelabs.org>"]
license = "Apache-2.0"
Expand Down
Loading