Magpie Protocol
  • Magpie Protocol
    • What is Magpie solving?
      • What is DeFi?
    • Magpies Key Features
      • Use Cases
    • FLY
      • xFLY & FLY33
  • 📶Supported Networks
  • Guides
    • 📖Glossary of DeFi Terms
    • 👜Connect Wallet
    • 🔄On-Chain Swap
    • 🔀Cross-Chain Swap
    • 🔂Swap configuration
    • 🥚Magpie Boosts
    • 📒Transaction History
    • 💲Portfolio
  • Media Kit
  • 👩‍💻Developers
    • Magpie Contracts
      • MagpieCCTPBridge
      • MagpieCelerBridgeV2
      • MagpieRouterV3
      • MagpieStargateBridgeV3
      • LibAsset
      • LibBridge
      • LibRouter
    • Smart Contracts Audit
    • Deployments
    • API Reference
      • On chain swap
      • Cross chain swap
      • Requesting and Using API Key
Powered by GitBook
On this page
  • DataTransferKey
  • DataTransferInProtocol
  • DataTransferInArgs
  • DataTransferOutArgs
  1. Developers
  2. Deprecated Magpie Contracts
  3. MagpieAggregator Diamond Proxy
  4. Data Transfer

LibCommon

It contains an enum and structs that are used to encapsulate and pass relevant information and parameters for data transfer operations. They store details such as the data transfer protocol, transfer key, payload, and data transfer type. The specific usage and implementation of these structs would depend on the context and requirements of the data transfer system or protocol being used.

DataTransferKey

enum DataTransferType {
    Wormhole,
    LayerZero
}

DataTransferInProtocol

struct DataTransferInProtocol {
    uint16 networkId;
    DataTransferType dataTransferType;
    bytes payload;
}
Field
Type
Description

This field is of type uint16 and represents the network ID of the data transfer protocol.

This field is of type DataTransferType (an enum) and represents the type of data transfer, either Wormhole or LayerZero.

This field is of type bytes and represents the payload of the data transfer.

DataTransferInArgs

struct DataTransferInArgs {
    DataTransferInProtocol protocol;
    TransferKey transferKey;
    bytes payload;
}
Field
Type
Description

This field is of type DataTransferInProtocol and represents the data transfer protocol details, including the network ID, data transfer type, and payload.

This field is of type TransferKey and represents a transfer key associated with the data transfer.

This field is of type bytes and represents the payload of the data transfer.

DataTransferOutArgs

struct DataTransferOutArgs {
    DataTransferType dataTransferType;
    bytes payload;
}
Field
Type
Description

This field is of type DataTransferType (an enum) and represents the type of data transfer, either Wormhole or LayerZero.

This field is of type bytes and represents the payload of the data transfer.

Last updated 1 year ago

👩‍💻
networkId
uint16
dataTransferType
DataTransferType
payload
bytes
protocol
DataTransferInProtocol
transferKey
TransferKey
payload
bytes
dataTransferType
DataTransferType
payload
bytes