Skip to main content
cross-chain Cross-chain bridge and multi-chain development expertise. Supports LayerZero, Chainlink CCIP, Wormhole, and Axelar for omnichain messaging, token bridging, and cross-chain state verification.
설치로 이동 Skills Marketplace 커뮤니티가 만든 AI 스킬을 발견하고 탐색하세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/a5c-ai/babysitter --skill cross-chain명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
Zip 다운로드 다운로드 중... Reference for querying the Atlas knowledge graph through its MCP tools — the SECONDARY enrichment/comparison layer that adds best-practice context to systems you have ALREADY scanned from your real sources (`az`, repos, dirs). Use when you need to look up nodes, edges, kinds, clusters, stats, or wiki pages in Atlas to compare against your real inventory. (atlas graph, query atlas, atlas mcp, search the graph, graph neighbors, atlas record, atlas kinds, enrichment layer)
Atlas turns your STATED NEED into a real systems atlas by SCANNING your actual sources (Azure via `az`, git repos, local dirs) and process/data mining them, THEN enriching against the Atlas knowledge graph. Use this skill when asked to inventory/map your real systems, scan your cloud + repos + directories, mine the real processes or data they contain, or collect their real constraints/gotchas. (atlas, scan my systems, inventory our azure account, map my repos, real systems atlas, process mining, data mining, collect nuances, system discovery)
assimilate-popular-workflows This skill should be used when the user asks to "find skills in the wild", "assimilate popular workflows", "discover SKILL.md files in repos", "research external skills", "find workflow patterns", "survey the skill landscape", "what skills exist out there", or wants to investigate public repositories for extractable processes, babysitter plugins, and reusable procedural insights. Searches GitHub for SKILL.md files, classifies repos by archetype, and maintains structured research under docs/reference-repos/.
name cross-chain description Cross-chain bridge and multi-chain development expertise. Supports LayerZero, Chainlink CCIP, Wormhole, and Axelar for omnichain messaging, token bridging, and cross-chain state verification. allowed-tools Read, Grep, Write, Bash, Edit, Glob, WebFetch graph {"domains":["domain:security"],"specializations":["specialization:cryptography-blockchain"],"skillAreas":["skill-area:cross-chain-interoperability","skill-area:smart-contract-development-testing","skill-area:smart-contract-security"],"roles":["role:backend-engineer","role:security-engineer"]}
Cross-Chain Development Skill
Expert cross-chain bridge development and multi-chain integration.
Capabilities
LayerZero : Omnichain messaging and OFT tokens
Chainlink CCIP : Cross-chain interoperability protocol
Bridge Verification : Implement verification logic
Finality Handling : Handle chain finality differences
Wormhole/Axelar : Alternative bridge protocols
Canonical Bridges : Token bridge implementations
State Verification : Cross-chain state proofs
LayerZero Integration
OFT Token (Omnichain Fungible Token)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
import { OFT } from "@layerzerolabs/lz-evm-oapp-v2/contracts/oft/OFT.sol";
contract MyOFT is OFT {
constructor(
string memory _name,
string memory _symbol,
address _lzEndpoint,
address _delegate
) OFT(_name, _symbol, _lzEndpoint, _delegate) {
_mint(msg.sender, 1000000 * 10 ** decimals());
}
}
OApp (Omnichain Application) import { OApp } from "@layerzerolabs/lz-evm-oapp-v2/contracts/oapp/OApp.sol";
import { Origin } from "@layerzerolabs/lz-evm-oapp-v2/contracts/oapp/interfaces/IOAppReceiver.sol";
contract CrossChainCounter is OApp {
uint256 public count;
constructor(address _endpoint, address _owner) OApp(_endpoint, _owner) {}
function increment(
uint32 _dstEid,
bytes calldata _options
) external payable {
bytes memory payload = abi.encode(count + 1);
_lzSend(
_dstEid,
payload,
_options,
MessagingFee(msg.value, 0),
payable(msg.sender)
);
count++;
}
function _lzReceive(
Origin calldata _origin,
bytes32 _guid,
bytes calldata _message,
address _executor,
bytes calldata _extraData
) internal override {
uint256 newCount = abi.decode(_message, (uint256));
count = newCount;
}
}
LayerZero Configuration
import { EndpointId } from "@layerzerolabs/lz-definitions" ;
const config = {
networks : {
ethereum : {
url : process.env .ETHEREUM_RPC ,
accounts : [process.env .PRIVATE_KEY ],
},
arbitrum : {
url : process.env .ARBITRUM_RPC ,
accounts : [process.env .PRIVATE_KEY ],
},
},
layerZero : {
ethereum : {
eid : EndpointId .ETHEREUM_V2_MAINNET ,
endpoint : "0x1a44076050125825900e736c501f859c50fE728c" ,
},
arbitrum : {
eid : EndpointId .ARBITRUM_V2_MAINNET ,
endpoint : "0x1a44076050125825900e736c501f859c50fE728c" ,
},
},
};
Chainlink CCIP
Token Transfer import {IRouterClient} from "@chainlink/contracts-ccip/src/v0.8/ccip/interfaces/IRouterClient.sol";
import {Client} from "@chainlink/contracts-ccip/src/v0.8/ccip/libraries/Client.sol";
import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
contract CCIPTokenTransfer {
IRouterClient public router;
address public linkToken;
constructor(address _router, address _link) {
router = IRouterClient(_router);
linkToken = _link;
}
function transferTokens(
uint64 destinationChainSelector,
address receiver,
address token,
uint256 amount
) external returns (bytes32 messageId) {
Client.EVMTokenAmount[] memory tokenAmounts = new Client.EVMTokenAmount[](1);
tokenAmounts[0] = Client.EVMTokenAmount({
token: token,
amount: amount
});
Client.EVM2AnyMessage memory message = Client.EVM2AnyMessage({
receiver: abi.encode(receiver),
data: "",
tokenAmounts: tokenAmounts,
extraArgs: "",
feeToken: linkToken
});
uint256 fee = router.getFee(destinationChainSelector, message);
IERC20(linkToken).approve(address(router), fee);
IERC20(token).approve(address(router), amount);
messageId = router.ccipSend(destinationChainSelector, message);
}
}
Cross-Chain Message import {CCIPReceiver} from "@chainlink/contracts-ccip/src/v0.8/ccip/applications/CCIPReceiver.sol";
import {Client} from "@chainlink/contracts-ccip/src/v0.8/ccip/libraries/Client.sol";
contract CCIPReceiver is CCIPReceiver {
event MessageReceived(bytes32 messageId, bytes data);
constructor(address router) CCIPReceiver(router) {}
function _ccipReceive(
Client.Any2EVMMessage memory message
) internal override {
emit MessageReceived(message.messageId, message.data);
// Process message
(string memory text) = abi.decode(message.data, (string));
// Handle the message...
}
}
Wormhole Integration
Token Bridge interface IWormholeTokenBridge {
function transferTokens(
address token,
uint256 amount,
uint16 recipientChain,
bytes32 recipient,
uint256 arbiterFee,
uint32 nonce
) external payable returns (uint64 sequence);
function completeTransfer(bytes memory encodedVm) external;
}
contract WormholeBridge {
IWormholeTokenBridge public bridge;
function bridgeTokens(
address token,
uint256 amount,
uint16 targetChain,
address recipient
) external payable {
IERC20(token).transferFrom(msg.sender, address(this), amount);
IERC20(token).approve(address(bridge), amount);
bytes32 recipientBytes = bytes32(uint256(uint160(recipient)));
bridge.transferTokens{value: msg.value}(
token,
amount,
targetChain,
recipientBytes,
0,
uint32(block.timestamp)
);
}
}
Bridge Security Patterns
Rate Limiting contract RateLimitedBridge {
uint256 public constant RATE_LIMIT = 1000000 * 1e18;
uint256 public constant RATE_PERIOD = 1 hours;
uint256 public currentPeriodStart;
uint256 public currentPeriodTransferred;
modifier rateLimited(uint256 amount) {
if (block.timestamp >= currentPeriodStart + RATE_PERIOD) {
currentPeriodStart = block.timestamp;
currentPeriodTransferred = 0;
}
require(
currentPeriodTransferred + amount <= RATE_LIMIT,
"Rate limit exceeded"
);
currentPeriodTransferred += amount;
_;
}
}
Circuit Breaker contract CircuitBreakerBridge {
bool public paused;
address public guardian;
uint256 public pauseThreshold;
modifier notPaused() {
require(!paused, "Bridge paused");
_;
}
function pause() external {
require(msg.sender == guardian, "Only guardian");
paused = true;
}
function unpause() external {
require(msg.sender == guardian, "Only guardian");
paused = false;
}
function emergencyWithdraw(
address token,
address to,
uint256 amount
) external {
require(msg.sender == guardian, "Only guardian");
require(paused, "Must be paused");
IERC20(token).transfer(to, amount);
}
}
Message Verification contract VerifiedBridge {
mapping(bytes32 => bool) public processedMessages;
mapping(uint256 => uint256) public chainConfirmations;
function processMessage(
bytes32 messageHash,
bytes[] calldata signatures,
uint256 sourceChain
) external {
require(!processedMessages[messageHash], "Already processed");
require(
verifySignatures(messageHash, signatures),
"Invalid signatures"
);
processedMessages[messageHash] = true;
// Process the message...
}
function verifySignatures(
bytes32 messageHash,
bytes[] calldata signatures
) internal view returns (bool) {
// Verify threshold signatures from validators
uint256 validSigs = 0;
for (uint i = 0; i < signatures.length; i++) {
address signer = recoverSigner(messageHash, signatures[i]);
if (isValidator(signer)) {
validSigs++;
}
}
return validSigs >= threshold;
}
}
Finality Handling
const CHAIN_FINALITY = {
ethereum : { blocks : 32 , time : 384 },
arbitrum : { blocks : 1 , time : 0 },
optimism : { blocks : 1 , time : 0 },
polygon : { blocks : 256 , time : 512 },
bsc : { blocks : 15 , time : 45 },
avalanche : { blocks : 1 , time : 2 },
};
async function waitForFinality (chainId : number , txHash : string ) {
const finality = CHAIN_FINALITY [chainId];
const receipt = await provider.getTransactionReceipt (txHash);
while (true ) {
const currentBlock = await provider.getBlockNumber ();
if (currentBlock - receipt.blockNumber >= finality.blocks ) {
return receipt;
}
await sleep (1000 );
}
}
Process Integration Process Purpose cross-chain-bridge.jsBridge development blockchain-node-setup.jsMulti-chain infra multi-signature-wallet.jsCross-chain multisig
Best Practices
Implement rate limiting on bridges
Use circuit breakers for emergencies
Handle finality differences per chain
Verify message authenticity thoroughly
Monitor bridge TVL and anomalies
Plan for chain reorganizations
See Also
skills/solidity-dev/SKILL.md - Contract development
agents/bridge-architect/AGENT.md - Bridge expert
LayerZero Docs
CCIP Docs