@@ -55,6 +55,7 @@ def uploadBlob(self, source: io.BufferedReader, filename: str, tag: str = ''):
55
55
def getBalance (self ):
56
56
"""
57
57
Retrieve the balance information of a user from the Lighthouse.
58
+
58
59
:param publicKey: str, The public key of the user.
59
60
:return: dict[str, any], A dictionary containing the data usage and data limit details.
60
61
"""
@@ -66,6 +67,7 @@ def getBalance(self):
66
67
def generateKey (self ):
67
68
"""
68
69
Generate a new IPNS key for the authenticated user.
70
+
69
71
:return: dict, The generated IPNS key information.
70
72
"""
71
73
try :
@@ -76,6 +78,7 @@ def generateKey(self):
76
78
def publishRecord (self , cid : str , keyName : str ):
77
79
"""
78
80
Publish an IPNS record for a given CID and key name.
81
+
79
82
:param cid: str, Content Identifier to publish
80
83
:param keyName: str, Name of the IPNS key to use
81
84
:return: dict, The published IPNS record information
@@ -88,7 +91,8 @@ def publishRecord(self, cid: str, keyName: str):
88
91
def getAllKeys (self ):
89
92
"""
90
93
Retrieves all IPNS records associated with the current token.
91
- return: list A list of IPNS records retrieved using the provided token.
94
+
95
+ :return: list A list of IPNS records retrieved using the provided token.
92
96
"""
93
97
94
98
try :
@@ -99,6 +103,7 @@ def getAllKeys(self):
99
103
def removeKey (self , keyName : str ):
100
104
"""
101
105
Remove IPNS record of the given keyName
106
+
102
107
:param keyName: str, Name of the IPNS key to use
103
108
:return: dict, A dict of removed IPNS record.
104
109
"""
@@ -112,6 +117,7 @@ def removeKey(self, keyName: str):
112
117
def createWallet (password : str ):
113
118
"""
114
119
Creates a new wallet using the provided password.
120
+
115
121
:param password: str, The password to secure the wallet.
116
122
:return: dict, The wallet encrypted with the passowrd
117
123
"""
@@ -180,8 +186,9 @@ def download(cid: str):
180
186
def getFileInfo (cid : str ):
181
187
"""
182
188
Retrieves information about a file using its CID (Content Identifier).
189
+
183
190
:param cid: str, Content Identifier for the data to be downloaded
184
- returns : dict, A dictionary containing file information.
191
+ :return : dict, A dictionary containing file information.
185
192
"""
186
193
187
194
try :
@@ -193,6 +200,7 @@ def getFileInfo(cid: str):
193
200
def getApiKey (publicKey : str , signedMessage : str ):
194
201
"""
195
202
Generates and returns an API key for the given public key and signed message.
203
+
196
204
:param publicKey: str, The public key associated with the user.
197
205
:param signedMessage: str, The message signed by the user's private key.
198
206
:return: dict, A dict with generated API key.
0 commit comments