{"repo":"byteball/counterstake-sdk","free":true,"listed":false,"github":"https://github.com/byteball/counterstake-sdk","clone":"git clone https://github.com/byteball/counterstake-sdk.git","description":"Counterstake SDK for integrating cross-chain transactions in your dapps https://counterstake.org","language":"JavaScript","stars":11,"topics":["cross-chain","interoperability","cross-chain-bridge","cross-chain-swap","interchain","dapp","cryptocurrency","obyte","counterstake","defi"],"license":"MIT","category":"blockchain-web3","readme_excerpt":"Counterstake SDK This SDK enables you to integrate cross-chain transactions in your dapps. It uses Counterstake Bridge for cross-chain transfers and optionally Oswap.io for swaps. The SDK works both in browser and in server based apps (bots). Install or Quick start Here is how you would transfer 100 USDC from Ethereum and receive GBYTE on the Obyte side. Under the hood, USDC-on-Ethereum will be first transferred to Obyte through Counterstake Bridge, then the receiving AA will swap USDC-on-Obyte to GBYTE-on-Obyte using Oswap.io and have it sent to the recipient address . Browser: Node.js: Demos Browser (React): https://github.com/byteball/getmein, website: https://getmein.ooo Node.js: https://github.com/byteball/counterstake-demo-client API The SDK exports the following functions and objects: transferEVM2Obyte This is the main function of this SDK. It sends a cross-chain transfer from an EVM based chain (Ethereum, BSC, Polygon) to Obyte. If the destination coin on Obyte is not the bridged version of the original coin (such as USDC-on-Ethereum to USDC-on-Obyte), the function tries to find an Oswap pool that would convert the bridged coin to the destination coin (such as USDC-on-Obyte to GBYTE). In this case, the cross-chain transfer is sent not to the recipient but to a forwarder AA, and additional data is sent in the transfer that instructs the AA to swap the received coins to the destination coins and send them to the recipient. The function's only argument is an object with ","default_branch":null,"files":null,"tree":[],"storefront":"/r/byteball","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/byteball/counterstake-sdk/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}