Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update information architecture #15

Merged
merged 4 commits into from
May 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions docs/build/tutorial/remix-demo.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ After successfully compiling **`TestSender.sol`**, the next step is to deploy i
The most thrilling part of the process is invoking the **`send(uint256 toChainId, address toDapp, bytes calldata message, bytes calldata params)`** method on the TestSender contract, which will initiate the cross-chain message transmission. The parameters for this call are somewhat complex, so let's break them down for clarity:

1. value: `2000000000000000000`
- The cross-chain message fee. For the purpose of this demonstration, we'll employ a hardcoded cross-chain message fee that exceeds the normal rate to ensure reliability. In practical scenarios, the fee should be determined by the [msgport API](../../learn/api.md).
- The cross-chain message fee. For the purpose of this demonstration, we'll employ a hardcoded cross-chain message fee that exceeds the normal rate to ensure reliability. In practical scenarios, the fee should be determined by the [msgport API](../api.md).
2. toChainId: **`11155111`**
- The Sepolia chain ID.
3. toDapp: **`0xb115B479ef7cBAEae5a69Aae93ADb0287ADaA32c`**,
Expand All @@ -105,7 +105,7 @@ After setting up the required parameters, proceed to click the transact button t

## Check Message Status

A [msgport scan](../../learn/scan.md) available to monitor the status of cross-chain messages, offering the ability to index messages by either the transaction hash or the msghash. Typically, querying with the transaction hash is the most convenient approach.
A [msgport scan](../scan.md) available to monitor the status of cross-chain messages, offering the ability to index messages by either the transaction hash or the msghash. Typically, querying with the transaction hash is the most convenient approach.


![msgport-tutorial-remix-4](../../images/msgport-tutorial-remix-4.png)
Expand Down
6 changes: 3 additions & 3 deletions docs/learn/workflow.md → docs/build/workflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Within the diverse landscape of today's blockchain technology, each blockchain p

For dApp developers looking to incorporate these cross-chain messaging protocols into their applications, a solid grasp of the underlying mechanics is crucial. This knowledge becomes particularly important when encountering unexpected issues during development, which can often be resolved with an awareness of how these complex systems operate.

The purpose of this page is to provide you with a clear understanding of how the Msgport and [ORMP](./messaging-protocols/ormp.md) messaging protocols facilitate cross-chain interactions. By breaking down these protocols, we aim to demystify the process, making it more accessible for developers needing to integrate cross-chain functionality into their projects.
The purpose of this page is to provide you with a clear understanding of how the Msgport and [ORMP](../learn/messaging-protocols/ormp.md) messaging protocols facilitate cross-chain interactions. By breaking down these protocols, we aim to demystify the process, making it more accessible for developers needing to integrate cross-chain functionality into their projects.

## Verifying network support

Expand All @@ -19,10 +19,10 @@ On the other hand, if the network is not currently supported, your first course

### Find the Port Contract Address

After verifying that the Msgport aligns with your project's objectives, the subsequent step is to locate the port contract address. If you're unfamiliar with the concept of a port contract, you can learn more by visiting **[this link](./glossary.md#port)**. There are two methods to acquire the appropriate port address:
After verifying that the Msgport aligns with your project's objectives, the subsequent step is to locate the port contract address. If you're unfamiliar with the concept of a port contract, you can learn more by visiting **[this link](../learn/glossary.md#port)**. There are two methods to acquire the appropriate port address:

1. Check the [Supported Networks list](./networks.md) for the endpoint. The port addresses are standardized across all networks to enhance clarity and ease of use, and you can easily find this information there.
2. Use the  `get(uint256 chainId, string calldata name)` function to consult the [PortRegistry](./glossary.md#portregistry) contract. By supplying the chainId and the specific protocol name, you can retrieve the endpoint for the target network. The PortRegistry contract is a detailed ledger of all registered port contracts, providing a trustworthy reference point.
2. Use the  `get(uint256 chainId, string calldata name)` function to consult the [PortRegistry](../learn/glossary.md#portregistry) contract. By supplying the chainId and the specific protocol name, you can retrieve the endpoint for the target network. The PortRegistry contract is a detailed ledger of all registered port contracts, providing a trustworthy reference point.

### Build the receiver application in the target chain

Expand Down
6 changes: 3 additions & 3 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Overview
# What is Msgport

In the evolving landscape of blockchain technology, the need for interoperability and seamless communication between diverse blockchains has never been more critical. Msgport, stands at the forefront of this challenge, offering a robust solution for cross-chain messaging. With a focus on facilitating effortless asset and information transfer across blockchains, Msgport is revolutionizing the way applications communicate in web 3.0.

## Core Components and Innovations

The Msgport encompasses a collection of smart contracts that outline standardized interfaces for facilitating a cross-chain messaging protocol.

At the heart of this system is the core interface, [IMessagePort](./learn/interfaces.md#imessageport), which is designed with flexibility to support various implementations.
At the heart of this system is the core interface, [IMessagePort](./build/interfaces.md#imessageport), which is designed with flexibility to support various implementations.

![msgport-overview-1](./images/msgport-overview-1.png)

Expand All @@ -19,7 +19,7 @@ Highlighting Msgport's versatility are its flagship integrations:
These implementations underscore Msgport's commitment to fostering interoperability, ensuring that assets and information can navigate the complex landscape of blockchain technology smoothly.

## Integration and Understanding
For developers and applications eager to leverage the power of Msgport, the journey begins with the [Msgport Workflow Documentation](./learn/workflow.md) and a series of comprehensive [Tutorials](./build/tutorial/remix-demo.md). These resources are meticulously crafted to demystify the complexities of Msgport, offering a clear path to integration. From foundational knowledge to step-by-step guides, developers can expect a seamless onboarding experience, enabling them to harness the full potential of cross-chain messaging.
For developers and applications eager to leverage the power of Msgport, the journey begins with the [Msgport Workflow Documentation](./build/workflow.md) and a series of comprehensive [Tutorials](./build/tutorial/remix-demo.md). These resources are meticulously crafted to demystify the complexities of Msgport, offering a clear path to integration. From foundational knowledge to step-by-step guides, developers can expect a seamless onboarding experience, enabling them to harness the full potential of cross-chain messaging.

## Embracing the Future

Expand Down
2 changes: 1 addition & 1 deletion docs/learn/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Which networks are currently supported by the Msgport?

To find out which networks are currently compatible with the Msgport, you can view the list of supported networks **[here](./networks.md)**. The Msgport core team is actively working to expand this list and connect additional networks. Keep an eye on updates to stay informed about new integrations.
To find out which networks are currently compatible with the Msgport, you can view the list of supported networks **[here](../build/networks.md)**. The Msgport core team is actively working to expand this list and connect additional networks. Keep an eye on updates to stay informed about new integrations.

## What are the network requirements to support Msgport?

Expand Down
4 changes: 2 additions & 2 deletions docs/learn/messaging-protocols/ormp.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Please be aware that within the channel, all messages are organized in an increm

### Message Sending Flow

1. The cross-chain application, built on the msgport interface **[IMessagePort](../interfaces.md#imessageport)**, invokes the **`send(from, toChainId, to, gasLimit, encoded_call)`** method of the ORMP. This method is a payable method, meaning it requires the payment of a specific fee to execute. The fee structure is further explained below.
1. The cross-chain application, built on the msgport interface **[IMessagePort](../../build/interfaces.md#imessageport)**, invokes the **`send(from, toChainId, to, gasLimit, encoded_call)`** method of the ORMP. This method is a payable method, meaning it requires the payment of a specific fee to execute. The fee structure is further explained below.
2. Upon receiving the message, the ORMP contracts store it in an Incremental Merkle Tree, emit the `MessageAccepted` event and return msgHash to the sender as the an identifier for that message.
3. The ORMP contracts then invoke the specified relayer and oracle that have been previously registered with the protocol, emitting the `OracleAssigned` and `RelayerAssigned` event to signal the start of their respective tasks.

Expand Down Expand Up @@ -76,7 +76,7 @@ If the validation is successful, the message is then sent to the corresponding u

## Cross-chain Fee

The fee for cross-chain messaging is paid in the native token of the source chain. The application can retrieve the cross-chain fee by calling the **`fee`** function in the **[IMessagePort](../interfaces.md#imessageport)** interface.
The fee for cross-chain messaging is paid in the native token of the source chain. The application can retrieve the cross-chain fee by calling the **`fee`** function in the **[IMessagePort](../../build/interfaces.md#imessageport)** interface.

$$
Fee = OracleFee + RelayingFee
Expand Down
1 change: 0 additions & 1 deletion docs/learn/troublesome.md

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
54 changes: 34 additions & 20 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ extra:
social:
- icon: fontawesome/brands/github
link: https://github.com/msgport
extra:
analytics:
provider: google
property: G-4FS95WZ91T
extra_css:
- resource/stylesheets/extra.css

Expand Down Expand Up @@ -119,31 +123,41 @@ plugins:
- git-revision-date-localized:
fallback_to_build_date: false
enable_creation_date: true

- redirects:
redirect_maps:
"learn/networks.md": 'build/networks.md'
"learn/interfaces.md": "build/interfaces.md"
"learn/workflow.md": "build/workflow.md"
"learn/api.md": "build/api.md"
"learn/scan.md": "build/scan.md"
"build/use-cases/overview.md": "learn/use-cases/overview.md"
"build/use-cases/order-xclearing.md": "learn/use-cases/order-xclearing.md"
"build/use-cases/xtoken.md": "learn/use-cases/xtoken.md"
"build/use-cases/xaccount.md": "learn/use-cases/xaccount.md"
"build/use-cases/xdao.md": "learn/use-cases/xdao.md"
nav:
- Learn Msgport:
- Overview: "index.md"
- Glossary: "learn/glossary.md"
- Interfaces: "learn/interfaces.md"
- Workflow: "learn/workflow.md"
- API Documentation: "learn/api.md"
- Message Scan: "learn/scan.md"
- Supported Networks: "learn/networks.md"
- Messaging Protocols:
- What is Msgport:
- What is Msgport: "index.md"
- Supported Protocols:
- Overview: "learn/messaging-protocols/overview.md"
- ORMP Protocol: "learn/messaging-protocols/ormp.md"
- XCMP Protocol: "learn/messaging-protocols/xcmp.md"
- LCMP Protocol: "learn/messaging-protocols/lcmp.md"
- FAQs: "learn/faq.md"
- Troubleshooting: "learn/troublesome.md"
- Build with Msgport:
- Use Cases:
- Overview: "build/use-cases/overview.md"
- Order Clearing: "build/use-cases/order-xclearing.md"
- XToken Management: "build/use-cases/xtoken.md"
- XAccount Operations: "build/use-cases/xaccount.md"
- XDAO Functions: "build/use-cases/xdao.md"
- Overview: "learn/use-cases/overview.md"
- Order Clearing: "learn/use-cases/order-xclearing.md"
- XToken Management: "learn/use-cases/xtoken.md"
- XAccount Operations: "learn/use-cases/xaccount.md"
- XDAO Functions: "learn/use-cases/xdao.md"
- Glossary: "learn/glossary.md"
- FAQ: "learn/faq.md"
- Developers:
- Supported Networks: "build/networks.md"
- Interfaces: "build/interfaces.md"
- Workflow: "build/workflow.md"
- API Documentation: "build/api.md"
- Message Scan: "build/scan.md"
- Tutorial:
- Hello Message Using Remix: "build/tutorial/remix-demo.md"
- Hello Message Using Script: "build/tutorial/script-demo.md"
- Send Cross-Chain Messages Using Remix: "build/tutorial/remix-demo.md"
- Send Cross-Chain Messages Using Script: "build/tutorial/script-demo.md"
- Community: "community/ringdao.md"
Loading
Loading