Skip to content

allbridge-io/allbridge-proxy-contract-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Proxy contract for Allbridge Core bridge

This project contains reference implementation of smart contracts that act as a proxy for Allbridge Core bridge smart contracts across multiple blockchains.

Key features

  • Supports swaps and bridge of stable tokens by forwarding requests to Allbridge Core bridge contract which handles the operation.
  • These contracts share the same interface as Allbridge Core bridge contracts, which means they can be used with existing tools designed for Allbridge Core like Allbridge Core SDK.
  • Can retain a portion of transferred amount as protocol fee.

How to Deploy

Follow the deployment instructions for the relevant blockchain:

SDK Integration

To use Allbridge Core SDK with custom bridge proxy, replace field bridgeAddress in source token info object with the address of the deployed proxy-contract.

const chainDetailsMap = await sdk.chainDetailsMap();
const sourceToken = chainDetailsMap[ChainSymbol.SRB]
  .tokens
  .find((t) => t.symbol == "USDC");
sourceToken.bridgeAddress = proxyAddress;

Reference Allbridge SDK documentation to learn more about using SDK to swap and bridge stable tokens.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors