2424"""
2525
2626class CNGnManager :
27- API_URL = "https://staging. api.wrapcbdc.com "
27+ API_URL = "https://api.cngn.co "
2828 API_CURRENT_VERSION = "v1"
2929
3030 def __init__ (self , api_key : str , private_key : str , encryption_key : str ):
@@ -91,8 +91,8 @@ def _handle_unexpected_error(self, error: Exception) -> Dict[str, Any]:
9191 def get_balance (self ) -> str :
9292 return self .__make_calls ("GET" , "/balance" )
9393
94- def get_transaction_history (self ) -> str :
95- return self .__make_calls ("GET" , "/transactions" )
94+ def get_transaction_history (self , page : int = 1 , limit : int = 10 ) -> str :
95+ return self .__make_calls ("GET" , f "/transactions?page { page } &limit= { limit } " )
9696
9797 def withdraw (self , data : dict ) -> str :
9898 return self .__make_calls ("POST" , "/withdraw" , data )
@@ -109,3 +109,6 @@ def update_external_accounts(self, data: dict) -> str:
109109 def get_banks (self ):
110110 return self .__make_calls ("GET" , "/banks" )
111111
112+ def swap_asset (self , data : dict ) -> str :
113+ return self .__make_calls ("POST" , "/swap" , data )
114+
0 commit comments