├── .gitignore ├── .source ├── index.ts └── source.config.mjs ├── .vscode ├── settings.json └── spellright.dict ├── LICENSE ├── README.md ├── content └── docs │ ├── api │ ├── index.mdx │ ├── meta.json │ ├── node │ │ ├── encode_submission.mdx │ │ ├── estimate_gas_price.mdx │ │ ├── get_account.mdx │ │ ├── get_account_module.mdx │ │ ├── get_account_modules.mdx │ │ ├── get_account_resource.mdx │ │ ├── get_account_resources.mdx │ │ ├── get_account_transactions.mdx │ │ ├── get_block_by_height.mdx │ │ ├── get_block_by_version.mdx │ │ ├── get_events_by_creation_number.mdx │ │ ├── get_events_by_event_handle.mdx │ │ ├── get_ledger_info.mdx │ │ ├── get_raw_table_item.mdx │ │ ├── get_table_item.mdx │ │ ├── get_transaction_by_hash.mdx │ │ ├── get_transaction_by_version.mdx │ │ ├── get_transactions.mdx │ │ ├── healthy.mdx │ │ ├── meta.json │ │ ├── simulate_transaction.mdx │ │ ├── spec.mdx │ │ ├── submit_batch_transactions.mdx │ │ ├── submit_transaction.mdx │ │ ├── view.mdx │ │ └── wait_transaction_by_hash.mdx │ ├── spec.yaml │ └── spec_fixed.yaml │ ├── devs │ ├── contractLibrary │ │ └── meta.json │ ├── faq.mdx │ ├── firstMoveContract.mdx │ ├── fullnode.mdx │ ├── index.mdx │ ├── indexing.mdx │ ├── interactonchain │ │ ├── meta.json │ │ ├── pythonSDK.mdx │ │ ├── rustSDK.mdx │ │ ├── tsSdk.mdx │ │ └── wallet-adapter │ │ │ ├── aptos_wallet_standard.mdx │ │ │ ├── connect_wallet.mdx │ │ │ ├── meta.json │ │ │ └── useWallet │ │ │ ├── ConnectWallet.mdx │ │ │ ├── meta.json │ │ │ ├── signAndSubmitTx.mdx │ │ │ └── signMessage.mdx │ ├── meta.json │ ├── move2.mdx │ ├── movementcli.mdx │ ├── networkEndpoints.mdx │ ├── oracles.mdx │ ├── templates.mdx │ └── tutorials │ │ ├── build.mdx │ │ ├── deploy.mdx │ │ ├── imgs │ │ ├── localapp.png │ │ ├── localupdated.png │ │ ├── scaffoldeth.png │ │ ├── structure.webp │ │ ├── suiapp.png │ │ └── suifinal.png │ │ ├── meta.json │ │ ├── move_slayers.mdx │ │ ├── stablecoin.mdx │ │ └── uniswap_v2_example.mdx │ └── general │ ├── index.mdx │ ├── l1 │ ├── architecture.mdx │ ├── index.mdx │ ├── meta.json │ ├── move-language.md │ ├── node-level-architecture.mdx │ ├── nodes │ │ ├── index.mdx │ │ ├── meta.json │ │ ├── public-fullnode.mdx │ │ ├── validator-fullnode.mdx │ │ ├── validator-node.mdx │ │ └── validator-node │ │ │ ├── validator-fullnode.mdx.bak │ │ │ └── validator.mdx.bak │ ├── protocol-specification.mdx │ └── what-is-movement-l1.mdx │ ├── meta.json │ ├── networks │ ├── devnet.mdx │ ├── index.mdx │ ├── mainnet.mdx │ ├── meta.json │ └── testnet.mdx │ ├── nodes │ ├── full-node │ │ ├── index.mdx │ │ ├── meta.json │ │ └── run │ │ │ ├── deploy │ │ │ ├── docker.mdx │ │ │ ├── index.mdx │ │ │ ├── meta.json │ │ │ └── source.mdx │ │ │ ├── index.mdx │ │ │ ├── meta.json │ │ │ └── verify.mdx │ ├── index.mdx │ └── meta.json │ ├── sidechain │ ├── architecture.mdx │ ├── images │ │ ├── architecture.png │ │ ├── architecture_movement.png │ │ ├── move_chain.png │ │ ├── move_stack.png │ │ └── mvmt_network.png │ ├── index.mdx │ ├── meta.json │ ├── node-level-architecture.mdx │ ├── what-is-movement-sidechain.mdx │ └── whitepaper.mdx │ └── usingmovement │ ├── bridge.mdx │ ├── community-support.mdx │ ├── connect_to_movement.mdx │ ├── imgs │ ├── addethos.png │ ├── addmetamask.png │ ├── image1.png │ ├── image10.png │ ├── image11.png │ ├── image12.png │ ├── image13.png │ ├── image14.png │ ├── image15.png │ ├── image16.png │ ├── image17.png │ ├── image18.png │ ├── image19.png │ ├── image2.png │ ├── image20.png │ ├── image21.png │ ├── image22.png │ ├── image23.png │ ├── image24.png │ ├── image25.png │ ├── image26.png │ ├── image3.png │ ├── image4.png │ ├── image5.png │ ├── image6.png │ ├── image7.png │ ├── image8.png │ ├── image9.png │ ├── okx1.png │ ├── okx2.png │ ├── okx3.png │ ├── okx4.png │ ├── okx5.png │ ├── okx6.png │ ├── okx7.png │ └── petra_add.png │ └── meta.json ├── docs ├── devs │ └── indexing.md └── general │ └── intro.mdx ├── lib └── cn.ts ├── next-env.d.ts ├── next.config.mjs ├── package-lock.json ├── package.json ├── postcss.config.mjs ├── public ├── api-spec.yaml ├── favicon.ico ├── icon-yellow.svg ├── img │ ├── movementlabs-social-card.png │ └── subpage-bg.jpg └── spec.yaml ├── scripts └── generate-docs.mjs ├── source.config.ts ├── src ├── app │ ├── (home) │ │ ├── layout.tsx │ │ └── page.tsx │ ├── api │ │ ├── [[...slug]] │ │ │ └── page.tsx │ │ ├── layout.tsx │ │ ├── search │ │ │ └── route.ts │ │ └── spec │ │ │ └── route.ts │ ├── devs │ │ ├── [[...slug]] │ │ │ └── page.tsx │ │ └── layout.tsx │ ├── general │ │ ├── [[...slug]] │ │ │ └── page.tsx │ │ └── layout.tsx │ ├── global.css │ ├── layout.config.tsx │ ├── layout.tsx │ ├── llms-full.txt │ │ └── route.ts │ ├── llms.mdx │ │ └── [[...slug]] │ │ │ └── route.ts │ └── not-found.tsx ├── components │ ├── CustomAPIPage.tsx │ ├── MovementCard.tsx │ ├── MovementIcon.tsx │ └── ai │ │ └── page-actions.tsx ├── lib │ ├── get-llm-text.ts │ └── source.ts └── mdx-components.tsx ├── tailwind.config.js ├── tsconfig.json └── yarn.lock /.gitignore: -------------------------------------------------------------------------------- 1 | # Dependencies 2 | /node_modules 3 | 4 | # Production 5 | /build 6 | 7 | # Generated files 8 | .docusaurus 9 | .cache-loader 10 | 11 | # Misc 12 | .DS_Store 13 | .env.local 14 | .env.development.local 15 | .env.test.local 16 | .env.production.local 17 | .env 18 | 19 | npm-debug.log* 20 | yarn-debug.log* 21 | yarn-error.log* 22 | .next -------------------------------------------------------------------------------- /.source/source.config.mjs: -------------------------------------------------------------------------------- 1 | // source.config.ts 2 | import { 3 | defineConfig, 4 | defineDocs, 5 | frontmatterSchema, 6 | metaSchema 7 | } from "fumadocs-mdx/config"; 8 | var docs = defineDocs({ 9 | docs: { 10 | schema: frontmatterSchema 11 | }, 12 | meta: { 13 | schema: metaSchema 14 | } 15 | }); 16 | var source_config_default = defineConfig({ 17 | mdxOptions: { 18 | // MDX options 19 | } 20 | }); 21 | export { 22 | source_config_default as default, 23 | docs 24 | }; 25 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spellright.userDictionary": "${workspaceFolder}/.vscode/spellright.dict" 3 | } -------------------------------------------------------------------------------- /.vscode/spellright.dict: -------------------------------------------------------------------------------- 1 | 2 | AptosBFT 3 | bytecode 4 | Devnet 5 | Fullnode 6 | Fullnodes 7 | Jolteon 8 | Mainnet 9 | Merkle 10 | sidechain 11 | sidechains 12 | Testnet 13 | trilemma -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Movement Docs 2 | 3 | This is a Next.js application generated with 4 | [Create Fumadocs](https://github.com/fuma-nama/fumadocs). 5 | 6 | Run development server: 7 | 8 | ```bash 9 | npm run dev 10 | # or 11 | pnpm dev 12 | # or 13 | yarn dev 14 | ``` 15 | 16 | Open http://localhost:3000 with your browser to see the result. 17 | 18 | ## Explore 19 | 20 | In the project, you can see: 21 | 22 | - `lib/source.ts`: Code for content source adapter, [`loader()`](https://fumadocs.dev/docs/headless/source-api) provides the interface to access your content. 23 | - `app/layout.config.tsx`: Shared options for layouts, optional but preferred to keep. 24 | 25 | | Route | Description | 26 | | ------------------------- | ------------------------------------------------------ | 27 | | `app/(home)` | The route group for your landing page and other pages. | 28 | | `app/devs` | The documentation layout and pages for developers. | 29 | | `app/general` | The documentation layout and pages for general users. | 30 | | `app/api/search/route.ts` | The Route Handler for search. | 31 | 32 | ### Content Structure 33 | 34 | The content is organized into two main sections: 35 | 36 | - `content/devs/` - Developer documentation (accessible at `/devs`) 37 | - `content/general/` - General user documentation (accessible at `/general`) 38 | 39 | ### Fumadocs MDX 40 | 41 | A `source.config.ts` config file has been included, you can customise different options like frontmatter schema. 42 | 43 | Read the [Introduction](https://fumadocs.dev/docs/mdx) for further details. 44 | 45 | ## Learn More 46 | 47 | To learn more about Next.js and Fumadocs, take a look at the following 48 | resources: 49 | 50 | - [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js 51 | features and API. 52 | - [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial. 53 | - [Fumadocs](https://fumadocs.vercel.app) - learn about Fumadocs 54 | -------------------------------------------------------------------------------- /content/docs/api/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: API Documentation 3 | description: Complete API reference for Movement Network 4 | --- 5 | 6 | # Movement Labs Node API 7 | 8 | The Movement Labs Full Node Node API is a RESTful API for client applications to interact with the Movement blockchain. Use this section of the documentation to review all requests that can be made to the full node. 9 | 10 | ## Contact 11 | 12 | **Movement Labs:** 13 | 14 | URL: https://github.com/movementlabsxyz/movement 15 | 16 | ## License 17 | 18 | Apache 2.0 -------------------------------------------------------------------------------- /content/docs/api/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "API", 3 | "pages": ["index", "node"], 4 | "root": true, 5 | "defaultOpen": true 6 | } -------------------------------------------------------------------------------- /content/docs/api/node/encode_submission.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Encode submission 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /transactions/encode_submission 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | This endpoint accepts an EncodeSubmissionRequest, which internally is 13 | a 14 | 15 | UserTransactionRequestInner (and optionally secondary signers) encoded 16 | 17 | as JSON, validates the request format, and then returns that request 18 | 19 | encoded in BCS. The client can then use this to create a transaction 20 | 21 | signature to be used in a SubmitTransactionRequest, which it then 22 | 23 | passes to the /transactions POST endpoint. 24 | 25 | 26 | To be clear, this endpoint makes it possible to submit transaction 27 | 28 | requests to the API from languages that do not have library support 29 | for 30 | 31 | BCS. If you are using an SDK that has BCS support, such as the 32 | official 33 | 34 | Rust, TypeScript, or Python SDKs, you do not need to use this 35 | endpoint. 36 | 37 | 38 | To sign a message using the response from this endpoint: 39 | 40 | - Decode the hex encoded string in the response to bytes. 41 | 42 | - Sign the bytes to create the signature. 43 | 44 | - Use that as the signature field in something like Ed25519Signature, 45 | which you then use to build a TransactionSignature. 46 | --- 47 | 48 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 49 | 50 | This endpoint accepts an EncodeSubmissionRequest, which internally is a 51 | UserTransactionRequestInner (and optionally secondary signers) encoded 52 | as JSON, validates the request format, and then returns that request 53 | encoded in BCS. The client can then use this to create a transaction 54 | signature to be used in a SubmitTransactionRequest, which it then 55 | passes to the /transactions POST endpoint. 56 | 57 | To be clear, this endpoint makes it possible to submit transaction 58 | requests to the API from languages that do not have library support for 59 | BCS. If you are using an SDK that has BCS support, such as the official 60 | Rust, TypeScript, or Python SDKs, you do not need to use this endpoint. 61 | 62 | To sign a message using the response from this endpoint: 63 | - Decode the hex encoded string in the response to bytes. 64 | - Sign the bytes to create the signature. 65 | - Use that as the signature field in something like Ed25519Signature, which you then use to build a TransactionSignature. 66 | 67 | -------------------------------------------------------------------------------- /content/docs/api/node/estimate_gas_price.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Estimate gas price 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /estimate_gas_price 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Gives an estimate of the gas unit price required to get a transaction 13 | on chain in a 14 | 15 | reasonable amount of time. The gas unit price is the amount that each 16 | transaction commits to 17 | 18 | pay for each unit of gas consumed in executing the transaction. The 19 | estimate is based on 20 | 21 | recent history: it gives the minimum gas that would have been required 22 | to get into recent 23 | 24 | blocks, for blocks that were full. (When blocks are not full, the 25 | estimate will match the 26 | 27 | minimum gas unit price.) 28 | 29 | 30 | The estimation is given in three values: de-prioritized (low), 31 | regular, and prioritized 32 | 33 | (aggressive). Using a more aggressive value increases the likelihood 34 | that the transaction 35 | 36 | will make it into the next block; more aggressive values are computed 37 | with a larger history 38 | 39 | and higher percentile statistics. More details are in AIP-34. 40 | --- 41 | 42 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 43 | 44 | Gives an estimate of the gas unit price required to get a transaction on chain in a 45 | reasonable amount of time. The gas unit price is the amount that each transaction commits to 46 | pay for each unit of gas consumed in executing the transaction. The estimate is based on 47 | recent history: it gives the minimum gas that would have been required to get into recent 48 | blocks, for blocks that were full. (When blocks are not full, the estimate will match the 49 | minimum gas unit price.) 50 | 51 | The estimation is given in three values: de-prioritized (low), regular, and prioritized 52 | (aggressive). Using a more aggressive value increases the likelihood that the transaction 53 | will make it into the next block; more aggressive values are computed with a larger history 54 | and higher percentile statistics. More details are in AIP-34. 55 | 56 | -------------------------------------------------------------------------------- /content/docs/api/node/get_account.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get account 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Return the authentication key and the sequence number for an account 13 | 14 | address. Optionally, a ledger version can be specified. If the ledger 15 | 16 | version is not specified in the request, the latest ledger version is 17 | used. 18 | --- 19 | 20 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 21 | 22 | Return the authentication key and the sequence number for an account 23 | address. Optionally, a ledger version can be specified. If the ledger 24 | version is not specified in the request, the latest ledger version is used. 25 | 26 | -------------------------------------------------------------------------------- /content/docs/api/node/get_account_module.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get account module 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/module/{module_name} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Retrieves an individual module from a given account and at a specific 13 | ledger version. If the 14 | 15 | ledger version is not specified in the request, the latest ledger 16 | version is used. 17 | 18 | 19 | The Aptos nodes prune account state history, via a configurable time 20 | window. 21 | 22 | If the requested ledger version has been pruned, the server responds 23 | with a 410. 24 | --- 25 | 26 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 27 | 28 | Retrieves an individual module from a given account and at a specific ledger version. If the 29 | ledger version is not specified in the request, the latest ledger version is used. 30 | 31 | The Aptos nodes prune account state history, via a configurable time window. 32 | If the requested ledger version has been pruned, the server responds with a 410. 33 | 34 | -------------------------------------------------------------------------------- /content/docs/api/node/get_account_modules.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get account modules 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/modules 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Retrieves all account modules' bytecode for a given account at a 13 | specific ledger version. 14 | 15 | If the ledger version is not specified in the request, the latest 16 | ledger version is used. 17 | 18 | 19 | The Aptos nodes prune account state history, via a configurable time 20 | window. 21 | 22 | If the requested ledger version has been pruned, the server responds 23 | with a 410. 24 | --- 25 | 26 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 27 | 28 | Retrieves all account modules' bytecode for a given account at a specific ledger version. 29 | If the ledger version is not specified in the request, the latest ledger version is used. 30 | 31 | The Aptos nodes prune account state history, via a configurable time window. 32 | If the requested ledger version has been pruned, the server responds with a 410. 33 | 34 | -------------------------------------------------------------------------------- /content/docs/api/node/get_account_resource.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get account resource 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/resource/{resource_type} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Retrieves an individual resource from a given account and at a 13 | specific ledger version. If the 14 | 15 | ledger version is not specified in the request, the latest ledger 16 | version is used. 17 | 18 | 19 | The Aptos nodes prune account state history, via a configurable time 20 | window. 21 | 22 | If the requested ledger version has been pruned, the server responds 23 | with a 410. 24 | --- 25 | 26 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 27 | 28 | Retrieves an individual resource from a given account and at a specific ledger version. If the 29 | ledger version is not specified in the request, the latest ledger version is used. 30 | 31 | The Aptos nodes prune account state history, via a configurable time window. 32 | If the requested ledger version has been pruned, the server responds with a 410. 33 | 34 | -------------------------------------------------------------------------------- /content/docs/api/node/get_account_resources.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get account resources 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/resources 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Retrieves all account resources for a given account and a specific 13 | ledger version. If the 14 | 15 | ledger version is not specified in the request, the latest ledger 16 | version is used. 17 | 18 | 19 | The Aptos nodes prune account state history, via a configurable time 20 | window. 21 | 22 | If the requested ledger version has been pruned, the server responds 23 | with a 410. 24 | --- 25 | 26 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 27 | 28 | Retrieves all account resources for a given account and a specific ledger version. If the 29 | ledger version is not specified in the request, the latest ledger version is used. 30 | 31 | The Aptos nodes prune account state history, via a configurable time window. 32 | If the requested ledger version has been pruned, the server responds with a 410. 33 | 34 | -------------------------------------------------------------------------------- /content/docs/api/node/get_account_transactions.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get account transactions 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/transactions 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Retrieves on-chain committed transactions from an account. If the 13 | start 14 | 15 | version is too far in the past, a 410 will be returned. 16 | 17 | 18 | If no start version is given, it will start at version 0. 19 | 20 | 21 | To retrieve a pending transaction, use /transactions/by_hash. 22 | --- 23 | 24 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 25 | 26 | Retrieves on-chain committed transactions from an account. If the start 27 | version is too far in the past, a 410 will be returned. 28 | 29 | If no start version is given, it will start at version 0. 30 | 31 | To retrieve a pending transaction, use /transactions/by_hash. 32 | 33 | -------------------------------------------------------------------------------- /content/docs/api/node/get_block_by_height.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get blocks by height 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /blocks/by_height/{block_height} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | This endpoint allows you to get the transactions in a block 13 | 14 | and the corresponding block information. 15 | 16 | 17 | Transactions are limited by max default transactions size. If not all 18 | transactions 19 | 20 | are present, the user will need to query for the rest of the 21 | transactions via the 22 | 23 | get transactions API. 24 | 25 | 26 | If the block is pruned, it will return a 410 27 | --- 28 | 29 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 30 | 31 | This endpoint allows you to get the transactions in a block 32 | and the corresponding block information. 33 | 34 | Transactions are limited by max default transactions size. If not all transactions 35 | are present, the user will need to query for the rest of the transactions via the 36 | get transactions API. 37 | 38 | If the block is pruned, it will return a 410 39 | 40 | -------------------------------------------------------------------------------- /content/docs/api/node/get_block_by_version.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get blocks by version 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /blocks/by_version/{version} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | This endpoint allows you to get the transactions in a block 13 | 14 | and the corresponding block information given a version in the block. 15 | 16 | 17 | Transactions are limited by max default transactions size. If not all 18 | transactions 19 | 20 | are present, the user will need to query for the rest of the 21 | transactions via the 22 | 23 | get transactions API. 24 | 25 | 26 | If the block has been pruned, it will return a 410 27 | --- 28 | 29 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 30 | 31 | This endpoint allows you to get the transactions in a block 32 | and the corresponding block information given a version in the block. 33 | 34 | Transactions are limited by max default transactions size. If not all transactions 35 | are present, the user will need to query for the rest of the transactions via the 36 | get transactions API. 37 | 38 | If the block has been pruned, it will return a 410 39 | 40 | -------------------------------------------------------------------------------- /content/docs/api/node/get_events_by_creation_number.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get events by creation number 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/events/{creation_number} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: |- 12 | Event types are globally identifiable by an account `address` and 13 | monotonically increasing `creation_number`, one per event type emitted 14 | to the given account. This API returns events corresponding to that 15 | that event type. 16 | --- 17 | 18 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 19 | 20 | Event types are globally identifiable by an account `address` and 21 | monotonically increasing `creation_number`, one per event type emitted 22 | to the given account. This API returns events corresponding to that 23 | that event type. 24 | 25 | -------------------------------------------------------------------------------- /content/docs/api/node/get_events_by_event_handle.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get events by event handle 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /accounts/{address}/events/{event_handle}/{field_name} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | This API uses the given account `address`, `eventHandle`, and 13 | `fieldName` 14 | 15 | to build a key that can globally identify an event types. It then uses 16 | this 17 | 18 | key to return events emitted to the given account matching that event 19 | type. 20 | --- 21 | 22 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 23 | 24 | This API uses the given account `address`, `eventHandle`, and `fieldName` 25 | to build a key that can globally identify an event types. It then uses this 26 | key to return events emitted to the given account matching that event type. 27 | 28 | -------------------------------------------------------------------------------- /content/docs/api/node/get_ledger_info.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get ledger info 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: / 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: |- 12 | Get the latest ledger information, including data such as chain ID, 13 | role type, ledger versions, epoch, etc. 14 | --- 15 | 16 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 17 | 18 | Get the latest ledger information, including data such as chain ID, 19 | role type, ledger versions, epoch, etc. 20 | 21 | -------------------------------------------------------------------------------- /content/docs/api/node/get_raw_table_item.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get raw table item 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /tables/{table_handle}/raw_item 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Get a table item at a specific ledger version from the table 13 | identified by {table_handle} 14 | 15 | in the path and the "key" (RawTableItemRequest) provided in the 16 | request body. 17 | 18 | 19 | The `get_raw_table_item` requires only a serialized key comparing to 20 | the full move type information 21 | 22 | comparing to the `get_table_item` api, and can only return the query 23 | in the bcs format. 24 | 25 | 26 | The Aptos nodes prune account state history, via a configurable time 27 | window. 28 | 29 | If the requested ledger version has been pruned, the server responds 30 | with a 410. 31 | --- 32 | 33 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 34 | 35 | Get a table item at a specific ledger version from the table identified by {table_handle} 36 | in the path and the "key" (RawTableItemRequest) provided in the request body. 37 | 38 | The `get_raw_table_item` requires only a serialized key comparing to the full move type information 39 | comparing to the `get_table_item` api, and can only return the query in the bcs format. 40 | 41 | The Aptos nodes prune account state history, via a configurable time window. 42 | If the requested ledger version has been pruned, the server responds with a 410. 43 | 44 | -------------------------------------------------------------------------------- /content/docs/api/node/get_table_item.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get table item 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /tables/{table_handle}/item 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Get a table item at a specific ledger version from the table 13 | identified by {table_handle} 14 | 15 | in the path and the "key" (TableItemRequest) provided in the request 16 | body. 17 | 18 | 19 | This is a POST endpoint because the "key" for requesting a specific 20 | 21 | table item (TableItemRequest) could be quite complex, as each of its 22 | 23 | fields could themselves be composed of other structs. This makes it 24 | 25 | impractical to express using query params, meaning GET isn't an 26 | option. 27 | 28 | 29 | The Aptos nodes prune account state history, via a configurable time 30 | window. 31 | 32 | If the requested ledger version has been pruned, the server responds 33 | with a 410. 34 | --- 35 | 36 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 37 | 38 | Get a table item at a specific ledger version from the table identified by {table_handle} 39 | in the path and the "key" (TableItemRequest) provided in the request body. 40 | 41 | This is a POST endpoint because the "key" for requesting a specific 42 | table item (TableItemRequest) could be quite complex, as each of its 43 | fields could themselves be composed of other structs. This makes it 44 | impractical to express using query params, meaning GET isn't an option. 45 | 46 | The Aptos nodes prune account state history, via a configurable time window. 47 | If the requested ledger version has been pruned, the server responds with a 410. 48 | 49 | -------------------------------------------------------------------------------- /content/docs/api/node/get_transaction_by_hash.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get transaction by hash 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /transactions/by_hash/{txn_hash} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Look up a transaction by its hash. This is the same hash that is 13 | returned 14 | 15 | by the API when submitting a transaction (see PendingTransaction). 16 | 17 | 18 | When given a transaction hash, the server first looks for the 19 | transaction 20 | 21 | in storage (on-chain, committed). If no on-chain transaction is found, 22 | it 23 | 24 | looks the transaction up by hash in the mempool (pending, not yet 25 | committed). 26 | 27 | 28 | To create a transaction hash by yourself, do the following: 29 | 30 | 1. Hash message bytes: "RawTransaction" bytes + BCS bytes of 31 | [Transaction](https://aptos-labs.github.io/aptos-core/aptos_types/transaction/enum.Transaction.html). 32 | 33 | 2. Apply hash algorithm `SHA3-256` to the hash message bytes. 34 | 35 | 3. Hex-encode the hash bytes with `0x` prefix. 36 | --- 37 | 38 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 39 | 40 | Look up a transaction by its hash. This is the same hash that is returned 41 | by the API when submitting a transaction (see PendingTransaction). 42 | 43 | When given a transaction hash, the server first looks for the transaction 44 | in storage (on-chain, committed). If no on-chain transaction is found, it 45 | looks the transaction up by hash in the mempool (pending, not yet committed). 46 | 47 | To create a transaction hash by yourself, do the following: 48 | 1. Hash message bytes: "RawTransaction" bytes + BCS bytes of [Transaction](https://aptos-labs.github.io/aptos-core/aptos_types/transaction/enum.Transaction.html). 49 | 2. Apply hash algorithm `SHA3-256` to the hash message bytes. 50 | 3. Hex-encode the hash bytes with `0x` prefix. 51 | 52 | -------------------------------------------------------------------------------- /content/docs/api/node/get_transaction_by_version.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get transaction by version 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /transactions/by_version/{txn_version} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: |- 12 | Retrieves a transaction by a given version. If the version has been 13 | pruned, a 410 will be returned. 14 | --- 15 | 16 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 17 | 18 | Retrieves a transaction by a given version. If the version has been 19 | pruned, a 410 will be returned. 20 | 21 | -------------------------------------------------------------------------------- /content/docs/api/node/get_transactions.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Get transactions 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /transactions 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Retrieve on-chain committed transactions. The page size and start 13 | ledger version 14 | 15 | can be provided to get a specific sequence of transactions. 16 | 17 | 18 | If the version has been pruned, then a 410 will be returned. 19 | 20 | 21 | To retrieve a pending transaction, use /transactions/by_hash. 22 | --- 23 | 24 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 25 | 26 | Retrieve on-chain committed transactions. The page size and start ledger version 27 | can be provided to get a specific sequence of transactions. 28 | 29 | If the version has been pruned, then a 410 will be returned. 30 | 31 | To retrieve a pending transaction, use /transactions/by_hash. 32 | 33 | -------------------------------------------------------------------------------- /content/docs/api/node/healthy.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Check basic node health 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /-/healthy 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | By default this endpoint just checks that it can get the latest ledger 13 | 14 | info and then returns 200. 15 | 16 | 17 | If the duration_secs param is provided, this endpoint will return a 18 | 19 | 200 if the following condition is true: 20 | 21 | 22 | `server_latest_ledger_info_timestamp >= server_current_time_timestamp 23 | - duration_secs` 24 | --- 25 | 26 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 27 | 28 | By default this endpoint just checks that it can get the latest ledger 29 | info and then returns 200. 30 | 31 | If the duration_secs param is provided, this endpoint will return a 32 | 200 if the following condition is true: 33 | 34 | `server_latest_ledger_info_timestamp >= server_current_time_timestamp - duration_secs` 35 | 36 | -------------------------------------------------------------------------------- /content/docs/api/node/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Node API", 3 | "pages": [ 4 | "get_account", 5 | "get_account_resources", 6 | "get_account_modules", 7 | "get_account_resource", 8 | "get_account_module", 9 | "get_account_transactions", 10 | "get_block_by_height", 11 | "get_block_by_version", 12 | "get_events_by_creation_number", 13 | "get_events_by_event_handle", 14 | "spec", 15 | "healthy", 16 | "get_ledger_info", 17 | "get_table_item", 18 | "get_raw_table_item", 19 | "get_transactions", 20 | "submit_transaction", 21 | "get_transaction_by_hash", 22 | "wait_transaction_by_hash", 23 | "get_transaction_by_version", 24 | "submit_batch_transactions", 25 | "simulate_transaction", 26 | "encode_submission", 27 | "estimate_gas_price", 28 | "view" 29 | ], 30 | "defaultOpen": true 31 | } -------------------------------------------------------------------------------- /content/docs/api/node/simulate_transaction.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Simulate transaction 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /transactions/simulate 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | The output of the transaction will have the exact transaction outputs 13 | and events that running 14 | 15 | an actual signed transaction would have. However, it will not have 16 | the associated state 17 | 18 | hashes, as they are not updated in storage. This can be used to 19 | estimate the maximum gas 20 | 21 | units for a submitted transaction. 22 | 23 | 24 | To use this, you must: 25 | 26 | - Create a SignedTransaction with a zero-padded signature. 27 | 28 | - Submit a SubmitTransactionRequest containing a 29 | UserTransactionRequest containing that signature. 30 | 31 | 32 | To use this endpoint with BCS, you must submit a SignedTransaction 33 | 34 | encoded as BCS. See SignedTransaction in types/src/transaction/mod.rs. 35 | --- 36 | 37 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 38 | 39 | The output of the transaction will have the exact transaction outputs and events that running 40 | an actual signed transaction would have. However, it will not have the associated state 41 | hashes, as they are not updated in storage. This can be used to estimate the maximum gas 42 | units for a submitted transaction. 43 | 44 | To use this, you must: 45 | - Create a SignedTransaction with a zero-padded signature. 46 | - Submit a SubmitTransactionRequest containing a UserTransactionRequest containing that signature. 47 | 48 | To use this endpoint with BCS, you must submit a SignedTransaction 49 | encoded as BCS. See SignedTransaction in types/src/transaction/mod.rs. 50 | 51 | -------------------------------------------------------------------------------- /content/docs/api/node/spec.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Show OpenAPI explorer 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /spec 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: |- 12 | Provides a UI that you can use to explore the API. You can also 13 | retrieve the API directly at `/spec.yaml` and `/spec.json`. 14 | --- 15 | 16 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 17 | 18 | Provides a UI that you can use to explore the API. You can also 19 | retrieve the API directly at `/spec.yaml` and `/spec.json`. 20 | 21 | -------------------------------------------------------------------------------- /content/docs/api/node/submit_batch_transactions.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Submit batch transactions 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /transactions/batch 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | This allows you to submit multiple transactions. The response has 13 | three outcomes: 14 | 15 | 16 | 1. All transactions succeed, and it will return a 202 17 | 18 | 2. Some transactions succeed, and it will return the failed 19 | transactions and a 206 20 | 21 | 3. No transactions succeed, and it will also return the failed 22 | transactions and a 206 23 | 24 | 25 | To submit a transaction as JSON, you must submit a 26 | SubmitTransactionRequest. 27 | 28 | To build this request, do the following: 29 | 30 | 31 | 1. Encode the transaction as BCS. If you are using a language that has 32 | 33 | native BCS support, make sure to use that library. If not, you may 34 | take 35 | 36 | advantage of /transactions/encode_submission. When using this 37 | 38 | endpoint, make sure you trust the node you're talking to, as it is 39 | 40 | possible they could manipulate your request. 41 | 42 | 2. Sign the encoded transaction and use it to create a 43 | TransactionSignature. 44 | 45 | 3. Submit the request. Make sure to use the "application/json" 46 | Content-Type. 47 | 48 | 49 | To submit a transaction as BCS, you must submit a SignedTransaction 50 | 51 | encoded as BCS. See SignedTransaction in types/src/transaction/mod.rs. 52 | 53 | Make sure to use the `application/x.aptos.signed_transaction+bcs` 54 | Content-Type. 55 | --- 56 | 57 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 58 | 59 | This allows you to submit multiple transactions. The response has three outcomes: 60 | 61 | 1. All transactions succeed, and it will return a 202 62 | 2. Some transactions succeed, and it will return the failed transactions and a 206 63 | 3. No transactions succeed, and it will also return the failed transactions and a 206 64 | 65 | To submit a transaction as JSON, you must submit a SubmitTransactionRequest. 66 | To build this request, do the following: 67 | 68 | 1. Encode the transaction as BCS. If you are using a language that has 69 | native BCS support, make sure to use that library. If not, you may take 70 | advantage of /transactions/encode_submission. When using this 71 | endpoint, make sure you trust the node you're talking to, as it is 72 | possible they could manipulate your request. 73 | 2. Sign the encoded transaction and use it to create a TransactionSignature. 74 | 3. Submit the request. Make sure to use the "application/json" Content-Type. 75 | 76 | To submit a transaction as BCS, you must submit a SignedTransaction 77 | encoded as BCS. See SignedTransaction in types/src/transaction/mod.rs. 78 | Make sure to use the `application/x.aptos.signed_transaction+bcs` Content-Type. 79 | 80 | -------------------------------------------------------------------------------- /content/docs/api/node/submit_transaction.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Submit transaction 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /transactions 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | This endpoint accepts transaction submissions in two formats. 13 | 14 | 15 | To submit a transaction as JSON, you must submit a 16 | SubmitTransactionRequest. 17 | 18 | To build this request, do the following: 19 | 20 | 21 | 1. Encode the transaction as BCS. If you are using a language that has 22 | 23 | native BCS support, make sure of that library. If not, you may take 24 | 25 | advantage of /transactions/encode_submission. When using this 26 | 27 | endpoint, make sure you trust the node you're talking to, as it is 28 | 29 | possible they could manipulate your request. 30 | 31 | 2. Sign the encoded transaction and use it to create a 32 | TransactionSignature. 33 | 34 | 3. Submit the request. Make sure to use the "application/json" 35 | Content-Type. 36 | 37 | 38 | To submit a transaction as BCS, you must submit a SignedTransaction 39 | 40 | encoded as BCS. See SignedTransaction in types/src/transaction/mod.rs. 41 | 42 | Make sure to use the `application/x.aptos.signed_transaction+bcs` 43 | Content-Type. 44 | --- 45 | 46 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 47 | 48 | This endpoint accepts transaction submissions in two formats. 49 | 50 | To submit a transaction as JSON, you must submit a SubmitTransactionRequest. 51 | To build this request, do the following: 52 | 53 | 1. Encode the transaction as BCS. If you are using a language that has 54 | native BCS support, make sure of that library. If not, you may take 55 | advantage of /transactions/encode_submission. When using this 56 | endpoint, make sure you trust the node you're talking to, as it is 57 | possible they could manipulate your request. 58 | 2. Sign the encoded transaction and use it to create a TransactionSignature. 59 | 3. Submit the request. Make sure to use the "application/json" Content-Type. 60 | 61 | To submit a transaction as BCS, you must submit a SignedTransaction 62 | encoded as BCS. See SignedTransaction in types/src/transaction/mod.rs. 63 | Make sure to use the `application/x.aptos.signed_transaction+bcs` Content-Type. 64 | 65 | -------------------------------------------------------------------------------- /content/docs/api/node/view.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Execute view function of a module 3 | full: true 4 | _openapi: 5 | method: POST 6 | route: /view 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Execute the Move function with the given parameters and return its 13 | execution result. 14 | 15 | 16 | The Aptos nodes prune account state history, via a configurable time 17 | window. 18 | 19 | If the requested ledger version has been pruned, the server responds 20 | with a 410. 21 | --- 22 | 23 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 24 | 25 | Execute the Move function with the given parameters and return its execution result. 26 | 27 | The Aptos nodes prune account state history, via a configurable time window. 28 | If the requested ledger version has been pruned, the server responds with a 410. 29 | 30 | -------------------------------------------------------------------------------- /content/docs/api/node/wait_transaction_by_hash.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Wait for transaction by hash 3 | full: true 4 | _openapi: 5 | method: GET 6 | route: /transactions/wait_by_hash/{txn_hash} 7 | toc: [] 8 | structuredData: 9 | headings: [] 10 | contents: 11 | - content: >- 12 | Same as /transactions/by_hash, but will wait for a pending transaction 13 | to be committed. To be used as a long 14 | 15 | poll optimization by clients, to reduce latency caused by polling. The 16 | "long" poll is generally a second or 17 | 18 | less but dictated by the server; the client must deal with the result 19 | as if the request was a normal 20 | 21 | /transactions/by_hash request, e.g., by retrying if the transaction is 22 | pending. 23 | --- 24 | 25 | {/* This file was generated by Fumadocs. Do not edit this file directly. Any changes should be made by running the generation command again. */} 26 | 27 | Same as /transactions/by_hash, but will wait for a pending transaction to be committed. To be used as a long 28 | poll optimization by clients, to reduce latency caused by polling. The "long" poll is generally a second or 29 | less but dictated by the server; the client must deal with the result as if the request was a normal 30 | /transactions/by_hash request, e.g., by retrying if the transaction is pending. 31 | 32 | -------------------------------------------------------------------------------- /content/docs/devs/contractLibrary/meta.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/contractLibrary/meta.json -------------------------------------------------------------------------------- /content/docs/devs/faq.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: FAQ 3 | description: Frequently asked questions about working with Movement as a developer 4 | --- 5 | 6 | # FAQ 7 | 8 | Frequently asked questions about working with Movement as a developer. 9 | 10 | ## What is Movement Labs? 11 | 12 | Movement Labs makes the Move programming language accessible across the entire modular blockchain ecosystem. By bringing the Move Virtual Machine to Ethereum through its innovative Move Layer 2, Movement Labs is creating a secure, scalable, developer-friendly blockchain infrastructure combining the best aspects of modular and monolithic architectures. 13 | 14 | ## Is Mainnet/Testnet/Devnet live? 15 | 16 | Currently we are live on testnet and the latest information on networks can be found [here](/devs/networkEndpoints). 17 | 18 | 19 | ## How do I get started building? 20 | 21 | Our [getting started](/devs/getstarted) guide will help you through finding exactly what you need in order to start building on Movement. 22 | 23 | ## How can I get help? 24 | 25 | Make sure to join our [Discord](https://discord.gg/movementlabsxyz) and get yourself a developer role. You can ask any questions you have in dev-chat where someone in the community or our Developer Relations team will be able to answer your questions. 26 | 27 | ## What are the hardware requirements for running a node? 28 | 29 | For running a Movement follower node, we recommend: 30 | - CPU: 16 cores 31 | - RAM: 64GB 32 | - Storage: 4TB NVMe SSD 33 | - Network: 2.5Gbps 34 | 35 | However, minimum requirements are 8 cores, 32GB RAM, and 2TB storage. 36 | 37 | ## What programming languages are supported on Movement? 38 | 39 | Movement supports multiple programming languages: 40 | - Move language for native Move development 41 | - Solidity for EVM compatibility 42 | - Any language that can compile to EVM bytecode 43 | 44 | ## How does Movement ensure security? 45 | 46 | Movement implements multiple security measures: 47 | - Secure Move VM implementation 48 | - Regular security audits 49 | - Battle-tested EVM compatibility layer 50 | - Strong consensus mechanism 51 | - Robust validator network 52 | 53 | ## What tools are available for developers? 54 | 55 | Movement provides a comprehensive suite of developer tools: 56 | - Movement CLI 57 | - SDK support for multiple languages 58 | - Development frameworks 59 | - Testing environments 60 | - Block explorers 61 | - Documentation and tutorials 62 | -------------------------------------------------------------------------------- /content/docs/devs/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Developer Documentation 3 | description: Complete guide for developers building on Movement 4 | --- 5 | 6 | import MovementIcon from '@/components/MovementIcon'; 7 | 8 | 9 | 10 | } href="/devs/firstMoveContract" title="Your First Move"> 11 | Build your first Move Module 12 | 13 | } href="/devs/movementcli" title="Movement CLI"> 14 | Install and use the Movement CLI 15 | 16 | } href="/devs/interactonchain/tsSdk" title="Interact with your Move Modules"> 17 | Start building apps on the Movement Network 18 | 19 | } href="/devs/networkEndpoints" title="Network Endpoints"> 20 | All the endpoints you need to get started 21 | 22 | } href="https://faucet.movementnetwork.xyz/" title="Faucet"> 23 | Get Testnet tokens 24 | 25 | } href="https://explorer.movementnetwork.xyz/" title="Explorer"> 26 | Our Block Explorer 27 | 28 | -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Interact on Chain", 3 | "pages": ["tsSdk", "rustSDK", "pythonSDK", "wallet-adapter"], 4 | "root": false, 5 | "defaultOpen": true 6 | } -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/pythonSDK.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Python SDK 3 | description: Learn how to interact with Movement using the Aptos Python SDK. 4 | --- 5 | 6 | Aptos provides a lightly maintained official Python SDK. It is available on [PyPi](https://pypi.org/project/aptos-sdk/) with the source code in the [aptos-python-sdk GitHub repository](https://github.com/aptos-labs/aptos-python-sdk). Much of the functionality of the Python SDK mirrors the Typescript SDK. The primary purpose of the Python SDK is to help Python developers to quickly become familiar with Aptos and as an accompaniment to Aptos tutorials. 7 | 8 | ## Installation 9 | 10 | ### Install with pip 11 | 12 | ```bash 13 | pip3 install aptos-sdk 14 | ``` 15 | 16 | ### Install from source code 17 | 18 | ```bash 19 | git clone https://github.com/aptos-labs/aptos-python-sdk 20 | pip3 install . --user 21 | ``` 22 | 23 | ### Install by embedding 24 | 25 | ```bash 26 | cd /path/to/python/project 27 | cp -r /path/to/aptos-python-sdk aptos-sdk 28 | ``` 29 | 30 | ## Usage 31 | 32 | ```python 33 | from aptos_sdk import AptosClient 34 | 35 | client = AptosClient("https://testnet.bardock.movementnetwork.xyz/v1") 36 | ``` -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/rustSDK.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Rust SDK 3 | description: Learn how to interact with Movement using the Aptos Rust SDK. 4 | --- 5 | 6 | 7 | Aptos provides an official lightly supported Rust SDK in the Aptos-core GitHub repository. To use the Rust SDK, add the following dependency and patches on the git repo directly in your Cargo.toml, like this: 8 | 9 | ```toml 10 | [dependencies] 11 | aptos-sdk = { git = "https://github.com/aptos-labs/aptos-core", branch = "devnet" } 12 | 13 | [patch.crates-io] 14 | merlin = { git = "https://github.com/aptos-labs/merlin" } 15 | x25519-dalek = { git = "https://github.com/aptos-labs/x25519-dalek", branch = "zeroize_v1" } 16 | ``` 17 | 18 | You must also create a `.cargo/config.toml` file with this content: 19 | 20 | ```toml 21 | [build] 22 | rustflags = ["--cfg", "tokio_unstable"] 23 | ``` 24 | 25 | ## Usage 26 | 27 | Full example availables [here](https://github.com/aptos-labs/aptos-core/blob/main/sdk/examples/transfer-coin.rs). 28 | 29 | Network endpoints should be replaced with the appropriate [Movement endpoints](/devs/networkEndpoints). -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/tsSdk.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: TypeScript SDK 3 | description: Learn how to interact with Movement using the Aptos TypeScript SDK. 4 | --- 5 | 6 | # Aptos TypeScript SDK 7 | 8 | On the Movement Network, you are building with Aptos Move; this allows you to leverage the Aptos TypeScript SDK to interact with the chain. 9 | 10 | The guide below will walk you through the process of setting up the SDK and interacting with the chain. If you would like to reference specific functions on the SDK refer to the [reference documentation](https://aptos-labs.github.io/aptos-ts-sdk/) for the version of the SDK you are using. 11 | 12 | ## Installation 13 | 14 | ```bash tab="npm" 15 | npm install @aptos-labs/ts-sdk 16 | ``` 17 | 18 | ```bash tab="pnpm" 19 | pnpm add @aptos-labs/ts-sdk 20 | ``` 21 | 22 | ```bash tab="yarn" 23 | yarn add @aptos-labs/ts-sdk 24 | ``` 25 | 26 | ```bash tab="bun" 27 | bun add @aptos-labs/ts-sdk 28 | ``` 29 | 30 | ## Imports 31 | 32 | To get started with the SDK, import the necessary components: 33 | 34 | ```javascript 35 | const { Account, Aptos, AptosConfig, Network, Ed25519PrivateKey } = require("@aptos-labs/ts-sdk"); 36 | ``` 37 | 38 | ## Configuration 39 | 40 | Configure the SDK to connect to the Movement Bardock Testnet (Please refer to [Network Endpoints](/devs/networkEndpoints) for more endpoints): 41 | 42 | ```javascript 43 | const config = new AptosConfig({ 44 | network: Network.CUSTOM, 45 | fullnode: 'https://testnet.bardock.movementnetwork.xyz/v1', 46 | faucet: 'https://faucet.testnet.bardock.movementnetwork.xyz/', 47 | }); 48 | 49 | // Initialize the Aptos client 50 | const aptos = new Aptos(config); 51 | ``` 52 | 53 | ## Interacting with the Chain 54 | 55 | ### Account Setup 56 | 57 | ```javascript 58 | // Create an account from a private key 59 | const privateKey = new Ed25519PrivateKey("YOUR_PRIVATE_KEY") 60 | const account = Account.fromPrivateKey({ privateKey }) 61 | ``` 62 | 63 | ### Reading Data 64 | 65 | ```javascript 66 | // Example of reading data using view function 67 | const viewPayload = { 68 | function: "0x1::message::get_message", 69 | functionArguments: [accountAddress] 70 | }; 71 | 72 | const result = await aptos.view({ payload: viewPayload }); 73 | ``` 74 | 75 | ### Sending Transactions 76 | 77 | ```javascript 78 | // Build the transaction 79 | const transaction = await aptos.transaction.build.simple({ 80 | sender: accountAddress, 81 | data: { 82 | function: "0x1::message::set_message", 83 | functionArguments: ["Hello Movement!"] 84 | }, 85 | }); 86 | 87 | // Sign the transaction 88 | const signature = aptos.transaction.sign({ 89 | signer: account, 90 | transaction 91 | }); 92 | 93 | // Submit the transaction 94 | const committedTxn = await aptos.transaction.submit.simple({ 95 | transaction, 96 | senderAuthenticator: signature, 97 | }); 98 | 99 | // Wait for transaction completion 100 | const response = await aptos.waitForTransaction({ 101 | transactionHash: committedTxn.hash 102 | }); 103 | ``` 104 | 105 | 106 | 107 | Remember to replace `YOUR_PRIVATE_KEY` with your actual private key and never share or commit private keys to version control. 108 | 109 | 110 | 111 | ## Example Code 112 | 113 | The Code below is based on the [Your First Move Contract tutorial](/devs/firstmove). 114 | 115 | ```javascript 116 | const { Account, Aptos, AptosConfig, Network, Ed25519PrivateKey } = require("@aptos-labs/ts-sdk"); 117 | 118 | // Define the custom network configuration 119 | const config = new AptosConfig({ 120 | network: Network.CUSTOM, 121 | fullnode: 'https://testnet.bardock.movementnetwork.xyz/v1', 122 | faucet: 'https://faucet.testnet.bardock.movementnetwork.xyz/', 123 | }); 124 | 125 | // Define the module address and functions 126 | const MODULE_ADDRESS = ""; 127 | const SET_MESSAGE_FUNCTION = `${MODULE_ADDRESS}::message::set_message`; 128 | const GET_MESSAGE_FUNCTION = `${MODULE_ADDRESS}::message::get_message`; 129 | 130 | const PRIVATE_KEY = "YOUR_PRIVATE_KEY"; // Replace with your private key 131 | const MESSAGE = "gmove"; 132 | 133 | const setMessage = async () => { 134 | // Setup the client 135 | const aptos = new Aptos(config); 136 | 137 | // Create an account from the provided private key 138 | console.log("creating") 139 | const privateKey = new Ed25519PrivateKey(PRIVATE_KEY) 140 | const account = Account.fromPrivateKey({ privateKey }) 141 | const accountAddress = account.accountAddress 142 | 143 | console.log(`address: ${account.accountAddress}`) 144 | 145 | console.log(`Using account: ${accountAddress}`); 146 | 147 | // Build the transaction payload 148 | const payload = { 149 | function: SET_MESSAGE_FUNCTION, 150 | type_arguments: [], 151 | arguments: [MESSAGE], 152 | }; 153 | 154 | console.log("\n=== Reading Message ===\n"); 155 | const viewPayload = { 156 | function: GET_MESSAGE_FUNCTION, 157 | functionArguments: [accountAddress] 158 | } 159 | try { 160 | const message = await aptos.view({ payload: viewPayload }); 161 | console.log("Message:", message); 162 | } catch (error) { 163 | console.error("Error reading message:", error); 164 | } 165 | 166 | // Submit the transaction 167 | console.log("\n=== Submitting Transaction ===\n"); 168 | const transaction = await aptos.transaction.build.simple({ 169 | sender: accountAddress, 170 | data: { 171 | function: SET_MESSAGE_FUNCTION, 172 | functionArguments: [MESSAGE] 173 | }, 174 | }); 175 | 176 | // Sign the transaction 177 | const signature = aptos.transaction.sign({ signer: account, transaction }); 178 | 179 | // Submit the transaction to chain 180 | const committedTxn = await aptos.transaction.submit.simple({ 181 | transaction, 182 | senderAuthenticator: signature, 183 | }); 184 | 185 | console.log(`Submitted transaction: ${committedTxn.hash}`); 186 | const response = await aptos.waitForTransaction({ transactionHash: committedTxn.hash }); 187 | console.log({ response }) 188 | // Read the message after it has been set 189 | console.log("\n=== Reading Message ===\n"); 190 | 191 | const newMessage = await aptos.view({ payload: viewPayload }); 192 | 193 | console.log("Message:", newMessage); 194 | }; 195 | 196 | setMessage().catch((err) => { 197 | console.error("Error setting message:", err); 198 | }); 199 | ``` 200 | -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/wallet-adapter/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Wallet Adapter", 3 | "pages": ["connect_wallet", "useWallet", "aptos_wallet_standard"], 4 | "root": false, 5 | "defaultOpen": false 6 | } -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/wallet-adapter/useWallet/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Use Wallet", 3 | "pages": ["ConnectWallet", "signAndSubmitTx", "signMessage"], 4 | "root": false, 5 | "defaultOpen": false 6 | } -------------------------------------------------------------------------------- /content/docs/devs/interactonchain/wallet-adapter/useWallet/signAndSubmitTx.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Sign & Submit 3 | description: Implements a transaction signing and submission functionality 4 | --- 5 | 6 | ## Overview 7 | This React component implements a transaction signing and submission functionality for the Aptos blockchain. It provides a simple button interface that allows users to sign and submit transactions using their connected Aptos wallet. 8 | 9 | ## Dependencies 10 | ```typescript 11 | import React from 'react'; 12 | import { useWallet } from '@aptos-labs/wallet-adapter-react'; 13 | import { Aptos, AptosConfig, Network } from '@aptos-labs/ts-sdk'; 14 | ``` 15 | - `@aptos-labs/wallet-adapter-react`: Provides wallet connection functionality 16 | - `@aptos-labs/ts-sdk`: Aptos blockchain SDK for interaction with the network 17 | 18 | ## Configuration 19 | ```typescript 20 | const config = new AptosConfig({ 21 | network: Network.TESTNET, 22 | fullnode: 'https://testnet.bardock.movementnetwork.xyz/v1', 23 | faucet: 'https://faucet.testnet.bardock.movementnetwork.xyz/' 24 | }) 25 | const aptos = new Aptos(config); 26 | ``` 27 | - Creates a new Aptos configuration instance 28 | - Connects to the Aptos mainnet network 29 | - Initializes the Aptos client with the configuration 30 | 31 | ## Component Breakdown 32 | 33 | ### 1️⃣ Hook Usage 34 | ```typescript 35 | const { account, signAndSubmitTransaction } = useWallet(); 36 | ``` 37 | - Uses the `useWallet` hook to get: 38 | - `account`: Current connected wallet account 39 | - `signAndSubmitTransaction`: Function to sign and submit transactions 40 | 41 | ### 2️⃣ Transaction Handler 42 | ```typescript 43 | const onSignAndSubmitTransaction = async () => { 44 | ``` 45 | This function handles: 46 | 1. Account verification 47 | 2. Transaction creation and submission 48 | 3. Transaction confirmation 49 | 50 | #### Transaction Structure 51 | ```typescript 52 | { 53 | sender: account.address, 54 | data: { 55 | function: "::::", 56 | functionArguments: [account.address, 1], 57 | } 58 | } 59 | ``` 60 | - `sender`: The address of the transaction sender 61 | - `function`: Calls the Aptos account transfer function 62 | - `functionArguments`: Array containing: 63 | - Recipient address (in this case, sending to self) 64 | - Amount to transfer (1 unit) 65 | 66 | ### 3️⃣ Transaction Confirmation 67 | ```typescript 68 | await aptos.waitForTransaction({ transactionHash: response.hash }); 69 | ``` 70 | - Waits for transaction confirmation on the blockchain 71 | - Includes error handling for failed transactions 72 | 73 | ### 4️⃣ UI Component 74 | ```typescript 75 | return ( 76 | 79 | ); 80 | ``` 81 | - Renders a simple button 82 | - Triggers the transaction process when clicked 83 | 84 | ## Usage Example 85 | ```typescript 86 | import SignAndSubmit from './components/signAndSubmitTx'; 87 | 88 | function App() { 89 | return ( 90 |
91 | 92 |
93 | ); 94 | } 95 | ``` 96 | 97 | ## Important Notes 98 | 1. This component requires a connected Aptos wallet to function 99 | 2. It's configured to work with Mainnet (production network) 100 | 3. The current implementation sends 1 unit to the same address (self-transfer) 101 | 4. Error handling is implemented for transaction confirmation 102 | 5. The component should be used within a wallet provider context 103 | 104 | ## Fullcode 105 | ```typescript title="src/components/signAndSubmitTx.tsx" 106 | import React from 'react'; 107 | import { useWallet } from '@aptos-labs/wallet-adapter-react'; 108 | import { Aptos, AptosConfig, Network } from '@aptos-labs/ts-sdk'; 109 | 110 | const config = new AptosConfig({ network: Network.MAINNET }); 111 | const aptos = new Aptos(config); 112 | 113 | const SignAndSubmit = () => { 114 | const { account, signAndSubmitTransaction } = useWallet(); 115 | 116 | const onSignAndSubmitTransaction = async () => { 117 | if(account == null) { 118 | throw new Error("Unable to find account to sign transaction") 119 | } 120 | const response = await signAndSubmitTransaction({ 121 | sender: account.address, 122 | data: { 123 | function: "0x1::aptos_account::transfer", 124 | functionArguments: [account.address, 1], 125 | }, 126 | }); 127 | // if you want to wait for transaction 128 | try { 129 | await aptos.waitForTransaction({ transactionHash: response.hash }); 130 | } catch (error) { 131 | console.error(error); 132 | } 133 | }; 134 | 135 | return ( 136 | 139 | ); 140 | }; 141 | 142 | export default SignAndSubmit; 143 | ``` 144 | -------------------------------------------------------------------------------- /content/docs/devs/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Build", 3 | "pages": ["index", 4 | "firstMoveContract", 5 | "movementcli", 6 | "networkEndpoints", 7 | "interactonchain", 8 | "templates", 9 | "indexing", 10 | "oracles", 11 | "fullnode", 12 | "tutorials", 13 | "move2", 14 | "faq"], 15 | "root": true, 16 | "defaultOpen": true 17 | } -------------------------------------------------------------------------------- /content/docs/devs/movementcli.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Movement CLI 3 | description: Install and use the Movement CLI 4 | --- 5 | 6 | Movement CLI supports Aptos Move natively. Here are the instructions to install and use `movement` CLI. 7 | 8 | ## Prerequisites 9 | 10 | ### Install Rust and Cargo 11 | Having Rust and Cargo is a prerequisite to installing the `movement` CLI. 12 | The easiest way to get Cargo is to install the current stable release of [Rust](https://www.rust-lang.org/) by using [`rustup`](https://rustup.rs/). Installing Rust using rustup will also install `cargo`. 13 | 14 | On Linux and macOS systems, this is done as follows: 15 | 16 | ```bash 17 | curl https://sh.rustup.rs -sSf | sh 18 | ``` 19 | 20 | ## Quick Install Movement Precompiled Binaries 21 | 22 | ```bash tab="MacOS ARM" 23 | curl -LO https://github.com/movementlabsxyz/homebrew-movement-cli/releases/download/bypass-homebrew/movement-macos-arm64.tar.gz 24 | tar -xzf movement-macos-arm64.tar.gz 25 | chmod +x macos-arm64/movement 26 | sudo mv macos-arm64/movement /usr/local/bin/movement 27 | ``` 28 | 29 | ```bash tab="MacOS Intel" 30 | curl -LO https://github.com/movementlabsxyz/homebrew-movement-cli/releases/download/bypass-homebrew/movement-macos-x86_64.tar.gz 31 | tar -xzf movement-macos-x86_64.tar.gz 32 | chmod +x macos-x86_64/movement 33 | sudo mv macos-x86_64/movement /usr/local/bin/movement 34 | ``` 35 | 36 | ```bash tab="Windows" 37 | $Version = "3.5.0" 38 | $ZipUrl = "https://github.com/aptos-labs/aptos-core/releases/download/aptos-cli-v$Version/aptos-cli-$Version-Windows-x86_64.zip" 39 | $InstallDir = "$env:USERPROFILE\.aptoscli\bin" 40 | $ZipPath = "$env:TEMP\aptos-cli.zip" 41 | 42 | Invoke-WebRequest -Uri $ZipUrl -OutFile $ZipPath 43 | New-Item -ItemType Directory -Force -Path $InstallDir | Out-Null 44 | Expand-Archive -Path $ZipPath -DestinationPath $InstallDir -Force 45 | 46 | # Set PATH 47 | $CurrentPath = [System.Environment]::GetEnvironmentVariable("Path", "User") 48 | if ($CurrentPath -notlike "*$InstallDir*") { 49 | setx PATH "$CurrentPath;$InstallDir" 50 | Write-Host "`n✅ PATH updated. Please restart your terminal before running 'aptos'." 51 | } else { 52 | Write-Host "`n✅ PATH already configured." 53 | } 54 | ``` 55 | 56 | ## Install Movement CLI Manually 57 | 58 | 59 | 60 | When developing on Movement, it is recommended to use the `movement` CLI. 61 | 62 | 63 | 64 | ### Binary Install 65 | ``` 66 | git clone https://github.com/movementlabsxyz/aptos-core/ && cd aptos-core 67 | ``` 68 | ``` 69 | cargo build -p movement 70 | ``` 71 | 72 | Copy `movement` into your `bin` or add it to your `PATH` depending on your system config. 73 | 74 | For example, to copy `movement` to `bin` on Mac or Linux: 75 | 76 | ``` 77 | sudo cp target/debug/movement /usr/local/bin/ 78 | ``` 79 | 80 | 81 | ## Use Movement CLI 82 | 83 | Movement CLI commands are analogous to those of Aptos CLI. Simply replace `aptos` with `movement`. 84 | 85 | So `aptos move build` becomes `movement move build`. 86 | 87 | For help within the CLI tool: 88 | 89 | ``` 90 | movement --help 91 | ``` 92 | 93 | or 94 | 95 | ``` 96 | movement --help 97 | ``` 98 | 99 | Developers who would like to contribute or read the source code, please see [the Movement CLI crate](https://github.com/movementlabsxyz/aptos-core/tree/movement/crates/aptos). 100 | -------------------------------------------------------------------------------- /content/docs/devs/networkEndpoints.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Network Endpoints 3 | description: Public endpoints for the Movement Network 4 | --- 5 | 6 | 7 | 8 | 9 | 10 | This page contains public endpoints that may at times be subject to rate limits. 11 | 12 | All partners listed below have paid private nodes as well for scaling your applications. 13 | 14 | 15 | 16 | ### Network Status 17 | 18 | **View the network status and uptime performance of Movement Network here: https://status.movementnetwork.xyz/** 19 | 20 | 21 | ## Movement Mainnet 22 | 23 | 24 | **Chain ID: 126** 25 | 26 | | Service | URL | 27 | |------------------|------------------------------------------------------------------------| 28 | | RPC (Primary) | https://full.mainnet.movementinfra.xyz/v1 | 29 | | Bridge | https://bridge.movementnetwork.xyz/ | 30 | | Explorer | https://explorer.movementnetwork.xyz/?network=mainnet | 31 | | Indexer Explorer | [Explorer](https://cloud.hasura.io/public/graphiql?endpoint=https%3A%2F%2Findexer.mainnet.movementnetwork.xyz%2Fv1%2Fgraphql) | 32 | | Indexer Endpoint | https://indexer.mainnet.movementnetwork.xyz/v1/graphql | 33 | 34 | 35 | ### Partner Endpoints 36 | 37 | The following public endpoints are provided by Movement's ecosystem infrastructure providers. All of the partners below also have paid private nodes. To learn more about setting up a private node for your project, see their website below. 38 | 39 | | Name | RPC Endpoint | 40 | |------------------|---------------------------------------------------------------------------------| 41 | | [Sentio](https://app.sentio.xyz/) | https://rpc.sentio.xyz/movement/v1 | 42 | | [Hello Moon (API Key Required)](https://www.hellomoon.io/) | https://movement.hellomoon.io/v1 | 43 | | [BlockPi](https://blockpi.io/) | https://movement.blockpi.network/rpc/v1/public/v1 | 44 | | [Lava Network](https://www.lavanet.xyz/) | https://movement.lava.build/ | 45 | | [Ankr](https://www.ankr.com/) | https://rpc.ankr.com/http/movement_mainnet/v1 | 46 | 47 | #### Partner Indexers 48 | 49 | | Name | Indexer Endpoint | 50 | | ----- | ----------------| 51 | | [Sentio](https://app.sentio.xyz/) | https://rpc.sentio.xyz/movement-indexer/v1/graphql | 52 | 53 | 54 | #### Custom Solutions 55 | 56 | | Name | Documentation | 57 | |------------------|------------------------------------------------------------------------| 58 | | [Pangea](https://pangea.foundation/) | https://docs.pangea.foundation/chain-data/movement/movement.html | 59 | 60 | 61 | 62 | ## Movement Testnet 63 | **Chain ID: 250** 64 | 65 | | Service | URL | 66 | |------------------|------------------------------------------------------------------------| 67 | | RPC | https://testnet.movementnetwork.xyz/v1 | 68 | | Faucet endpoint | https://faucet.testnet.movementnetwork.xyz/ | 69 | | Faucet UI | https://faucet.movementnetwork.xyz/ | 70 | | Explorer | https://explorer.movementnetwork.xyz/?network=bardock+testnet  | 71 | | Indexer Explorer | [Explorer](https://cloud.hasura.io/public/graphiql?endpoint=https%3A%2F%2Findexer.testnet.movementnetwork.xyz%2Fv1%2Fgraphql) | 72 | | Indexer Endpoint | https://hasura.testnet.movementnetwork.xyz/v1/graphql | 73 | 74 | 75 | ## Network Properties 76 | 77 | | | Testnet | Devnet | 78 | | --- | --- | --- | 79 | | Validators | Movement Labs operated validators | Movement Labs operated validators. | 80 | | Full Nodes | Permissionless + Movement Labs operated nodes | Movement Labs operated nodes | 81 | | Data Durability | Data wipes will be announced ahead of time. | Data can be wiped as part of the regular software updates. | 82 | | Announcement Channel | [Discord](https://discord.com/channels/1101576619493167217/1259638014184001668)| [Discord](https://discord.com/channels/1101576619493167217/1259638353607917589) | 83 | | Network Uptime | Constant uptime. | Expect down time happens. | 84 | -------------------------------------------------------------------------------- /content/docs/devs/oracles.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Oracles 3 | description: Oracles for the Movement Network 4 | --- 5 | 6 | This document explains how to use real-time data from [Pyth Network](https://www.pyth.network/) in modules on the Movement Bardock testnet. 7 | 8 | ## Configuring the Move.toml file 9 | 10 | Add the Pyth Contract to your project dependencies in the Move.toml file like so: 11 | 12 | ``` 13 | [dependencies] 14 | Pyth = { git = "https://github.com/pyth-network/pyth-crosschain.git", subdir = "target_chains/aptos/contracts", rev = "main" } 15 | ``` 16 | 17 | The named addresses of `pyth`, `wormhole`, and `deployer` must be defined at compile time. These addresses are used to interact with the Pyth contract on Movement. 18 | 19 | The Pyth smart contracts are deployed on the Movement Network on the following addresses: 20 | 21 | | Name | Address | 22 | |----------|--------------------------------------------------------------------| 23 | | pyth | 0x9357e76fe965c9956a76181ee49f66d51b7f9c3800182a944ed96be86301e49f | 24 | | wormhole | 0x9236893d6444b208b7e0b3e8d4be4ace90b6d17817ab7d1584e46a33ef5c50c9 | 25 | | deployer | 0xa3ad2d9c8114b9a4fe97d45b7a9d3c731148d936b0f5dd396fc20a53a11a70da | 26 | 27 | 28 | ## Example Code 29 | 30 | The code snippet below provides an example module fetching the BTC/USD price from Pyth price feeds: 31 | 32 | ```rust 33 | module example::example { 34 | use pyth::pyth; 35 | use pyth::price::Price; 36 | use pyth::price_identifier; 37 | use aptos_framework::coin; 38 | 39 | // Add the pyth_price_update argument to any method on your contract that needs to read the Pyth price. 40 | // See https://docs.pyth.network/price-feeds/fetch-price-updates for more information on how to fetch the pyth_price_update. 41 | public fun get_btc_usd_price(user: &signer, pyth_price_update: vector>): Price { 42 | 43 | // First update the Pyth price feeds 44 | let coins = coin::withdraw(user, pyth::get_update_fee(&pyth_price_update)); 45 | pyth::update_price_feeds(pyth_price_update, coins); 46 | 47 | // Read the current price from a price feed. 48 | // Each price feed (e.g., BTC/USD) is identified by a price feed ID. 49 | // The complete list of feed IDs is available at https://pyth.network/developers/price-feed-ids 50 | // Note: Aptos uses the Pyth price feed ID without the `0x` prefix. 51 | let btc_price_identifier = x"e62df6c8b4a85fe1a67db44dc12de5db330f7ac66b72dc658afedf0f4a415b43"; 52 | let btc_usd_price_id = price_identifier::from_byte_vec(btc_price_identifier); 53 | pyth::get_price(btc_usd_price_id) 54 | } 55 | } 56 | ``` 57 | 58 | The code snippet above does the following: 59 | 60 | 1. Call `pyth::get_update_fee` to get the fee required to update the Pyth price feeds. 61 | 2. Call `pyth::update_price_feeds` and pass pyth_price_update to update the Pyth price feeds. 62 | 3. Call `pyth::get_price to read` the current price, providing the price feed ID you wish to read. 63 | 64 | 65 | ## API Reference 66 | 67 | The [Aptos API reference](https://docs.pyth.network/price-feeds/api-reference/aptos) (Which is also compatible with Movement) lets you interactively explore the complete API of the Pyth contract. 68 | 69 | 70 | ## Example Applications 71 | 72 | [Minimal on-chain contract](https://github.com/pyth-network/pyth-examples/blob/main/price_feeds/aptos/fetch_btc_price/sources/example.move), which updates and returns the BTC/USD price from Pyth price feeds. 73 | 74 | [Mint NFT](https://github.com/pyth-network/pyth-examples/tree/main/price_feeds/aptos/mint_nft), which uses Pyth price feeds to mint an NFT. -------------------------------------------------------------------------------- /content/docs/devs/templates.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Templates and Other Docs 3 | description: Templates and Documentations for Wallet SDKs 4 | --- 5 | import MovementIcon from '@/components/MovementIcon'; 6 | 7 | Below you can find a list of templates and documentations for Wallet SDKs from many of our partnered wallets. In some cases you will have full templates for you to start from that can auto detect any Aptos Wallets, in other cases you will have documentation for you to implement their specific SDK into your dApp. 8 | 9 | 10 | 11 | } href="https://www.okx.com/web3/build/docs/sdks/app-connect-aptos" title="OKX Connect"> 12 | OKX Connect Documentation 13 | 14 | } href="https://movement-web3-template.nightly.app/" title="Nightly Connect"> 15 | Starter Template for Nightly Connect 16 | 17 | } href="https://kit.razorwallet.xyz/docs/getting-started" title="Razor Kit"> 18 | Razor Kit Documentation 19 | 20 | -------------------------------------------------------------------------------- /content/docs/devs/tutorials/deploy.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Deploy 3 | description: Deploy your Move module to the Movement Network 4 | --- 5 | 6 | 🚀 If you already have a Move module written, you can deploy it to the Movement Network using the Movement CLI or Aptos CLI. 7 | 8 | For a full guide on how to install the CLI and get your development environment setup, please see our [First Move Module](/devs/firstMoveContract) guide. 9 | 10 | ## Check Config 11 | 12 | Ensure your `config.yaml` is configured to the correct network for the profile you are using. This can be found in the `.movement` directory at the root of your project. 13 | 14 | ``` 15 | --- 16 | profiles: 17 | default: 18 | network: Custom 19 | private_key: "0xYOUR_PRIVATE_KEY" 20 | public_key: "0xYOUR_PRIVATE_KEY" 21 | account: "account_address" 22 | rest_url: "https://testnet.bardock.movementnetwork.xyz/v1" 23 | faucet_url: "https://faucet.testnet.bardock.movementnetwork.xyz/" 24 | ``` 25 | 26 | 27 | ## Add Address to Move.Toml 28 | 29 | To make compiling, testing, and of course deploying your Move module easier, you can add your address to the `move.toml` file at the root of your Move project. 30 | 31 | ``` 32 | [addresses] 33 | default = "YOUR_ADDRESS" 34 | ``` 35 | 36 | ## Deploy to Movement Network 37 | 38 | Run the following command to deploy your Move module to the Movement Network: 39 | 40 | ``` 41 | movement move publish 42 | ``` 43 | 44 | You'll be prompted to confirm the transaction and spend a small amount of testnet tokens: 45 | 46 | ``` 47 | Do you want to submit this transaction? [Y/n] 48 | ``` 49 | 50 | Type `Y` and press **Enter**. 51 | 52 | > **Ensure you have sufficient testnet tokens from the faucet before proceeding.** -------------------------------------------------------------------------------- /content/docs/devs/tutorials/imgs/localapp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/tutorials/imgs/localapp.png -------------------------------------------------------------------------------- /content/docs/devs/tutorials/imgs/localupdated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/tutorials/imgs/localupdated.png -------------------------------------------------------------------------------- /content/docs/devs/tutorials/imgs/scaffoldeth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/tutorials/imgs/scaffoldeth.png -------------------------------------------------------------------------------- /content/docs/devs/tutorials/imgs/structure.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/tutorials/imgs/structure.webp -------------------------------------------------------------------------------- /content/docs/devs/tutorials/imgs/suiapp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/tutorials/imgs/suiapp.png -------------------------------------------------------------------------------- /content/docs/devs/tutorials/imgs/suifinal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/devs/tutorials/imgs/suifinal.png -------------------------------------------------------------------------------- /content/docs/devs/tutorials/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Tutorials", 3 | "pages": [ 4 | "build", 5 | "deploy", 6 | "move_slayers", 7 | "uniswap_v2_example", 8 | "stablecoin" 9 | ], 10 | "root": false, 11 | "defaultOpen": false 12 | } -------------------------------------------------------------------------------- /content/docs/general/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Getting Started 3 | description: Welcome to the Movement! This documentation will help you understand the Movement ecosystem and how to interact with it. 4 | --- 5 | 6 | import MovementIcon from '@/components/MovementIcon'; 7 | 8 | 9 | 10 | } href="/general/l1/move-language" title="Why Move?"> 11 | High level overview of the Move Language 12 | 13 | } href="/general/networks/mainnet" title="Architecture"> 14 | How the Movement Network functions 15 | 16 | } href="/devs" title="Developers"> 17 | Start building apps on the Movement Network 18 | 19 | } href="/devs/firstMoveContract" title="Move Contracts"> 20 | Build your first Move Module 21 | 22 | } href="https://faucet.movementnetwork.xyz/" title="Faucet"> 23 | Get Testnet tokens 24 | 25 | } href="https://explorer.movementnetwork.xyz/" title="Explorer"> 26 | Our Block Explorer 27 | 28 | 29 | -------------------------------------------------------------------------------- /content/docs/general/l1/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: movement-l1 3 | title: Overview 4 | description: "Movement L1 - A native Move blockchain with high throughput and fast finality" 5 | --- 6 | 7 | import React from 'react'; 8 | 9 | Movement L1 is a native Move blockchain that provides high-throughput execution through the MoveVM. 10 | 11 | ## Documentation 12 | 13 | - **[What is Movement L1](/general/l1/what-is-movement-l1)** - Learn about Movement L1 components and capabilities 14 | - **[Move Language](/general/l1/move-language)** - High level overview of the Move Language 15 | - **[High-Level Architecture](/general/l1/architecture)** - Detailed architecture of the Movement L1 16 | - **[Node-Level Architecture](/general/l1/node-level-architecture)** - Detailed node-level architecture and components 17 | - **[Node Operations](/general/l1/nodes)** - Information about running Movement L1 nodes 18 | - **[Movement L1 Protocol Specification](/general/l1/protocol-specification)** - Protocol specification for Movement L1 19 | 20 | ## Networks 21 | 22 | Movement L1 currently operates: 23 | - **[Testnet](/general/networks/testnet)** - Production-ready testing environment 24 | - **[Devnet](/general/networks/devnet)** - Development and feature testing network 25 | 26 | ## Protocol Specification 27 | 28 | For further information about Movement L1, please refer to our [Movement L1 Protocol Specification](/general/l1/whitepaper). 29 | -------------------------------------------------------------------------------- /content/docs/general/l1/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Movement L1", 3 | "pages": [ 4 | "index", 5 | "what-is-movement-l1", 6 | "move-language", 7 | "architecture", 8 | "node-level-architecture", 9 | "nodes", 10 | "protocol-specification" 11 | ] 12 | } 13 | -------------------------------------------------------------------------------- /content/docs/general/l1/move-language.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Move Language 3 | description: A high level overview of the Move programming language 4 | --- 5 | 6 | Move is a safe and secure programming language designed by Facebook for smart contracts that emphasize ownership and safety. Assets in Move are represented as resources. Owing to Move's strong ownership model and explicit resource abilities, Move simplifies the development of safe smart contracts for common blockchain tasks such as transferring ownership of assets, minting, and destroying. 7 | 8 | The chart below compares common non-Move runtimes against Aptos and Sui Move runtimes, underscoring the different models and benefits of Move. 9 | 10 | | | Aptos / Move | Solana / SeaLevel | EVM | Sui / Move | 11 | |------------------------|--------------------------------------------------|-----------------------------------------------------|-----------------------------------------------|------------------------------------------| 12 | | **Data storage** | Stored at a global address or within the owner's account | Stored within the owner's account associated with a program | Stored within the account associated with a smart contract | Stored at a global address | 13 | | **Parallelization** | Capable of inferring parallelization at runtime within Aptos | Requires specifying all data accessed | Currently serial, nothing in production | Requires specifying all data accessed | 14 | | **Transaction safety** | Sequence number | Transaction uniqueness | Nonces, similar to sequence numbers | Transaction uniqueness | 15 | | **Type safety** | Module structs and generics | Program structs | Contract types | Module structs and generics | 16 | | **Function calling** | Static dispatch | Static dispatch | Dynamic dispatch | Static dispatch | 17 | | **Authenticated Storage** | Yes | No | Yes | No | 18 | | **Object accessibility** | Guaranteed to be globally accessible | Not applicable | Not applicable | Can be hidden | 19 | 20 | 21 | -------------------------------------------------------------------------------- /content/docs/general/l1/nodes/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: nodes 3 | sidebar_position: 6 4 | title: Overview 5 | description: "Comprehensive guide to Movement Mainnet node types and operations" 6 | --- 7 | 8 | import React from 'react'; 9 | 10 | The Movement Mainnet consists of three main node types: 11 | 12 | - **Validator Nodes** 13 | - **Validator Fullnodes (VFNs)** 14 | - **Public Fullnodes (PFNs)** 15 | 16 | To participate in consensus, you are required to run a validator node and stake the minimum amount of MOVE tokens. VFNs and PFNs are not required to participate in consensus, but they are essential for distributing blockchain data and enabling ecosystem services such as indexing, querying, and RESTful API services. 17 | VFNs can only be run by validator operators, while PFNs can be run by anyone. All node types are currently in development and will be available soon. 18 | 19 | 20 | Thus, the Movement network uses a multi-tier architecture: 21 | 22 | ``` 23 | ┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐ 24 | │ Validator │◄──►│ Validator │◄──►│ Validator │ 25 | │ Node │ │ Node │ │ Node │ 26 | └─────────┬───────┘ └─────────┬───────┘ └─────────┬───────┘ 27 | │ │ │ 28 | ▼ ▼ ▼ 29 | ┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐ 30 | │ Validator │ │ Validator │ │ Validator │ 31 | │ Fullnode │ │ Fullnode │ │ Fullnode │ 32 | └─────────┬───────┘ └─────────┬───────┘ └─────────┬───────┘ 33 | │ │ │ 34 | └──────────┬───────────┴───────────┬──────────┘ 35 | │ │ 36 | ┌─────────────────┐ ┌─────────────────┐ 37 | │ Public │ │ Public │ 38 | │ Fullnode │ │ Fullnode │ 39 | └─────────────────┘ └─────────────────┘ 40 | ``` 41 | 42 | ## Node Types Overview 43 | 44 | ### Validator Nodes 45 | 46 | [View Validator Node Documentation →](/general/l1/nodes/validator-node) 47 | 48 | - **Purpose**: Participate in consensus protocol and validate transactions 49 | - **Requirements**: Must stake minimum MOVE tokens 50 | - **Rewards**: Earn staking rewards for successful validation 51 | - **Status**: 🚧 Coming Soon 52 | - **Requirements**: See System Requirements (Coming Soon) 53 | 54 | ### Validator Fullnodes (VFNs) 55 | 56 | [View VFN Documentation →](/general/l1/nodes/validator-fullnode) 57 | 58 | - **Purpose**: Serve as secure entry/exit points for validator operations 59 | - **Requirements**: Can only be operated by validator operators 60 | - **Benefits**: Improved reliability and secure data access for validators 61 | - **Status**: 🚧 Coming Soon 62 | - **Requirements**: See System Requirements (Coming Soon) 63 | 64 | ### Public Fullnodes (PFNs) 65 | 66 | [View PFN Documentation →](/general/l1/nodes/public-fullnode) 67 | 68 | - **Purpose**: Replicate blockchain state and provide public access 69 | - **Requirements**: No staking required, open to anyone 70 | - **Benefits**: Increase network decentralization and data availability 71 | - **Use Cases**: RPC services, indexing, dApps, and ecosystem tools 72 | - **Status**: 🚧 Coming Soon 73 | - **Requirements**: See System Requirements (Currently Supported) 74 | 75 | ## Validator Node Types Comparison 76 | 77 | To participate in the Movement consensus protocol, you will need to deploy and run a **validator node**. Additionally, it will be **highly recommended** to run a **validator fullnode (VFN)** to provide secure and reliable access to blockchain data. 78 | 79 | Comprehensive deployment guides will be available when validators launch on Movement. 80 | 81 | ### Node Types Comparison 82 | 83 | | Feature | Validator Node | Validator Fullnode (VFN) | 84 | |---------|----------------|---------------------------| 85 | | **Purpose** | Consensus participation | Data distribution & security | 86 | | **Required** | ✅ Yes (for consensus) | 📋 Highly recommended | 87 | | **Staking** | ✅ Required | ❌ No staking needed | 88 | | **Public Access** | ❌ Private network only | ✅ Public API access | 89 | | **API Services** | ❌ Disabled for security | ✅ Full REST/WebSocket APIs | 90 | | **Hardware** | High (consensus critical) | Moderate (data serving) | 91 | | **Uptime** | Critical (affects rewards) | Important (affects users) | 92 | 93 | ### Architecture Overview 94 | 95 | The recommended validator setup uses a two-tier architecture: 96 | 97 | ``` 98 | Internet ←→ VFN ←→ Validator Node 99 | ↑ ↑ 100 | (Public APIs) (Private Network) 101 | (Data Access) (Consensus Only) 102 | ``` 103 | 104 | ## Quick Links 105 | 106 | ### System Requirements 107 | Essential information for planning and deploying Movement nodes. 108 | 109 | - **Complete System Requirements** (Coming Soon) - Comprehensive hardware and software requirements for all node types 110 | - **Cloud Provider Recommendations** (Coming Soon) - AWS, GCP, and Azure instance recommendations 111 | - **Storage Requirements** (Coming Soon) - Storage types, capacity planning, and performance considerations 112 | - **Network Requirements** (Coming Soon) - Bandwidth, latency, and port configuration 113 | 114 | ### Validation & Staking (Coming Soon) 115 | Comprehensive guides for validation, staking, and governance will be available when Movement validators launch. 116 | 117 | ### Node Operations (Coming Soon) 118 | Step-by-step deployment and operational guides will be available when nodes launch. 119 | 120 | ### Development Tools (Coming Soon) 121 | Developer tools and local development environments will be available soon. 122 | 123 | ## Getting Started 124 | 125 | All Movement node types are currently in development and will be available soon. Detailed deployment guides and operational procedures will be published when the nodes are ready for mainnet launch. 126 | 127 | Stay tuned for updates on node availability and deployment instructions. 128 | 129 | 130 | 131 | ## Additional Resources 132 | 133 | - For community resources, support channels, and ways to get involved, see [Community and Support](/general/usingmovement/community-support). 134 | -------------------------------------------------------------------------------- /content/docs/general/l1/nodes/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Node types and setup", 3 | "pages": [ 4 | "index", 5 | "validator-node", 6 | "validator-fullnode", 7 | "public-fullnode" 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /content/docs/general/l1/nodes/public-fullnode.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: public-fullnode 3 | title: Public Fullnode (PFN) 4 | description: "Complete guide to running Movement public fullnodes (PFNs)" 5 | --- 6 | 7 | Public fullnodes (PFNs) will allow you to synchronize the state of the Movement blockchain and stay up-to-date. PFNs will replicate the entire state of the blockchain by syncing from VFNs and other PFNs. PFNs will be available for anyone to run and will serve as crucial infrastructure for the Movement ecosystem. 8 | 9 | PFNs will enable various use cases including: 10 | 11 | - **RPC Services**: Provide JSON-RPC endpoints for dApps and wallets 12 | - **Indexing**: Index blockchain data for analytics and APIs 13 | - **Development**: Local testing and development environments 14 | - **Backup**: Maintain redundant copies of blockchain state 15 | - **Analytics**: Historical data analysis and research 16 | 17 | ## Network Connection 18 | 19 | **Default connection to mainnet**: If you follow the default setup in this document, then your PFN will be connected to the Movement mainnet. To connect to a different Movement network, such as testnet, make sure you have the correct configuration files and genesis data. 20 | 21 | You can find the genesis and waypoint files for all Movement networks in the **[Movement Networks repository](https://github.com/movementlabsxyz/movement-networks)**. 22 | 23 | ## Overview 24 | 25 | When PFNs become available, running a PFN will involve: 26 | 27 | 1. **Requirements Check** - Ensure your system meets hardware and software specifications 28 | 2. **Deployment Method Selection** - Choose Docker, source build, or cloud deployment 29 | 3. **Node Configuration** - Set up configuration files and network parameters 30 | 4. **Deploy and Sync** - Start the node and sync with the network 31 | 5. **Service Configuration** - Set up optional services like APIs and indexing 32 | 33 | Detailed deployment guides will be published when PFNs are ready for launch. 34 | 35 | ## PFN Types and Use Cases 36 | 37 | #### Standard PFN 38 | - **Purpose**: Basic blockchain synchronization and data access 39 | - **Resources**: Moderate hardware requirements 40 | - **Services**: Basic RPC endpoints 41 | 42 | #### API PFN 43 | - **Purpose**: High-performance API services for dApps 44 | - **Resources**: Higher compute and memory for request handling 45 | - **Services**: Full REST API, WebSocket, custom endpoints 46 | 47 | #### Indexer PFN 48 | - **Purpose**: Specialized indexing and analytics 49 | - **Resources**: High storage and compute for data processing 50 | - **Services**: Custom indexing, analytics APIs, database integration 51 | 52 | #### Archive PFN 53 | - **Purpose**: Long-term historical data preservation 54 | - **Resources**: Very high storage requirements 55 | - **Services**: Complete historical access, research APIs 56 | 57 | ## System Requirements 58 | 59 | Detailed requirements will be provided when PFNs launch. 60 | 61 | ## Deployment Guides 62 | 63 | When PFNs become available, comprehensive guides will be provided for various deployment methods. 64 | -------------------------------------------------------------------------------- /content/docs/general/l1/nodes/validator-fullnode.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: validator-fullnode 3 | title: Validator Fullnode (VFN) 4 | description: "Complete guide to running Movement validator fullnodes" 5 | --- 6 | 7 | Running a validator fullnode is not supported on the Movement Network at this time. 8 | 9 | ## System Requirements 10 | 11 | When validator fullnodes become available, they will serve as secure data access layers for validators. For detailed specifications and planning information, see System Requirements (Coming Soon). 12 | 13 | ## What VFNs Will Provide 14 | 15 | When available, validator fullnodes will offer: 16 | - **Security Layer**: Acts as a buffer between validators and public networks 17 | - **API Services**: Provides REST API and WebSocket endpoints 18 | - **Load Balancing**: Reduces load on validator nodes 19 | - **Data Distribution**: Serves blockchain data to ecosystem applications 20 | -------------------------------------------------------------------------------- /content/docs/general/l1/nodes/validator-node.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: validator 3 | title: Validator Node (VN) 4 | description: "Complete guide to running Movement validator nodes" 5 | --- 6 | 7 | Running a validator node is not supported on the Movement Network at this time. 8 | 9 | ## System Requirements 10 | 11 | When validator nodes become available, they will have specific hardware and software requirements. For detailed specifications and planning information, see System Requirements (Coming Soon). 12 | 13 | ## Get Notified 14 | 15 | To be notified when validator functionality becomes available: 16 | - **[Join the validator waitlist](https://forms.movementnetwork.xyz/validator-interest)** - Get early access notifications 17 | - **[Subscribe to updates](https://movementnetwork.xyz/newsletter)** - Receive launch announcements 18 | - **[Follow on Discord](https://discord.gg/movementlabsxyz)** - Join the validator community 19 | - **[Monitor GitHub](https://github.com/movementlabsxyz/movement)** - Track development progress -------------------------------------------------------------------------------- /content/docs/general/l1/what-is-movement-l1.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: what-is-movement-l1 3 | title: What is Movement L1 4 | description: "Learn about Movement L1 components and capabilities" 5 | --- 6 | 7 | Movement L1 is a native Layer 1 blockchain built specifically for the Move programming language and virtual machine. Unlike sidechains or Layer 2 solutions, Movement L1 operates as an independent blockchain with its own consensus mechanism and validator set. 8 | 9 | ## Core Components 10 | 11 | #### Native Move Virtual Machine (MoveVM) 12 | Movement L1 runs the Move Virtual Machine natively, providing _**direct Move execution**_ where smart contracts execute without translation or adaptation layers. The platform offers full support for Move's _**resource-oriented programming model**_ with _**optimized performance**_ through direct bytecode execution for maximum efficiency. Built-in _**type safety**_ provides compile-time guarantees for asset safety and program correctness. 13 | 14 | #### Consensus and Validation 15 | Movement L1 employs a _**proof-of-stake consensus**_ mechanism for energy-efficient validation with native staking. A _**decentralized validator network**_ secures the network, while _**fast finality**_ ensures sub-second transaction finality for optimal user experience. The system features _**Byzantine fault tolerance**_, providing robust consensus resistant to malicious actors. 16 | 17 | #### Native Token Economics 18 | The _**MOVE token**_ serves as the native token for transaction fees, staking, and governance. _**Efficient gas metering**_ provides resource pricing for computational operations, while _**staking rewards**_ incentivize validators and delegators to earn rewards for network security. _**Token holders**_ participate in protocol governance, ensuring decentralized decision-making. 19 | 20 | ## Key Advantages 21 | 22 | #### Developer Experience 23 | Movement L1 provides a purpose-built _**Move language**_ designed specifically for digital assets and DeFi applications. Developers benefit from _**comprehensive development tools and libraries**_, along with _**built-in testing and simulation capabilities**_. _**Extensive guides and API references**_ ensure developers have the resources they need to build effectively. 24 | 25 | #### Performance and Scalability 26 | The platform delivers _**high throughput**_ with thousands of transactions per second capability, combined with _**low latency**_ through fast block times and transaction confirmation. _**Efficient storage**_ is achieved through optimized state management and data structures, while _**parallel execution**_ enables concurrent transaction processing where possible. 27 | 28 | #### Security and Reliability 29 | Movement L1 leverages Move's built-in _**formal verification**_ capabilities to ensure program correctness. _**Resource safety**_ prevents common smart contract vulnerabilities, while the platform is built on _**battle-tested**_ blockchain architectures. An _**audit trail**_ maintains transaction history and state transitions for full transparency. 30 | 31 | ## Use Cases 32 | 33 | #### DeFi Applications 34 | Movement L1 excels at supporting DeFi applications including efficient _**decentralized exchanges**_ through automated market makers (AMMs), _**secure borrowing and lending platforms**_, _**complex yield generation strategies**_, and the creation and management of _**synthetic assets and derivatives**_. 35 | 36 | #### NFTs and Digital Assets 37 | The platform enables direct creation and trading of _**non-fungible tokens**_ through NFT marketplaces, supports _**gaming assets**_ including in-game items and character progression systems, facilitates _**digital collectibles**_ like unique digital art and memorabilia, and enables _**asset tokenization**_ for real-world asset (RWA) representation on-chain. 38 | 39 | #### Enterprise Applications 40 | Movement L1 supports enterprise use cases such as _**transparent supply chain tracking**_ for goods and materials, _**secure digital identity verification and management**_ systems, _**efficient cross-border and micropayment**_ solutions, and _**regulatory-friendly blockchain compliance**_ tools. 41 | 42 | ## Comparison with Sidechain 43 | 44 | | Feature | Movement L1 | Sidechain | 45 | |---------|-------------|-------------------| 46 | | **Security Model** | Native validators | Operator and L1-secured | 47 | | **Consensus** | BFT with PoS | Operator + Anchoring | 48 | | **Execution** | native* MoveVM | native or adapted MoveVM | 49 | | **Finality** | Native finality | anchoring- / bridge-dependent | 50 | | **Governance** | Native governance | dependent on L1 | 51 | 52 | _* the L1 defines the meaning of native_ 53 | 54 | ## Getting Started 55 | 56 | #### For Developers 57 | 1. **[Learn Move](/devs/firstMoveContract)**: Familiarize yourself with the Move programming language 58 | 2. **[Set up Tools](/devs/movementcli)**: Install Movement CLI and development environment 59 | 3. **[Deploy on Testnet](/devs/networkEndpoints)**: Test your applications on Movement L1 testnet 60 | 4. **[Build Applications](/devs/tutorials/build)**: Create DeFi, NFT, or enterprise applications 61 | 62 | #### For Users 63 | 1. **[Get a Wallet](/general/usingmovement/connect_to_movement)**: Use Move-compatible wallets for L1 interaction 64 | 2. **Acquire MOVE**: Obtain native tokens for transaction fees 65 | 3. **[Explore DApps](https://explorer.movementnetwork.xyz/)**: Discover applications built on Movement L1 66 | 4. **Participate**: Engage with governance and network activities 67 | -------------------------------------------------------------------------------- /content/docs/general/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Learn", 3 | "pages": [ 4 | "index", 5 | "networks", 6 | "l1", 7 | "sidechain", 8 | "nodes", 9 | "usingmovement", 10 | "[Faucet](https://faucet.movementnetwork.xyz/)", 11 | "[Explorer](https://explorer.movementnetwork.xyz/)" 12 | ], 13 | "root": true, 14 | "defaultOpen": true 15 | } -------------------------------------------------------------------------------- /content/docs/general/networks/devnet.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: devnet 3 | title: L1 (Devnet) 4 | description: "Movement L1 Development Network" 5 | --- 6 | 7 | import React from 'react'; 8 | 9 | Movement Devnet is a native L1 blockchain network that serves as the development environment for testing the latest protocol features and upgrades. Unlike the current mainnet sidechain, devnet operates as a full L1 blockchain with native Move execution. 10 | 11 | #### Devnet vs Testnet 12 | 13 | **Devnet** is for experimental development with rapid updates and frequent resets, while **testnet** provides a stable, production-like environment with persistent data for pre-production testing. 14 | 15 | ## Key Features 16 | 17 | The devnet is development-focused with the following features: 18 | 19 | - **Latest Features**: Access to cutting-edge protocol features before they reach other networks 20 | - **Rapid Updates**: Weekly updates with new functionality and improvements 21 | - **Experimental APIs**: Early access to new APIs and developer tools 22 | - **Reset Capability**: Network resets for major upgrades and testing 23 | 24 | ## Network Properties 25 | 26 | | Property | Value | 27 | |----------|-------| 28 | | **Network Type** | Native L1 Blockchain | 29 | | **Consensus** | BFT Consensus | 30 | | **Block Time** | ~1 second (Target) | 31 | | **Finality** | ~1 second (Details TBD) | 32 | | **Validators** | Managed by Movement Labs | 33 | | **Data Retention** | Reset on major updates | 34 | | **Faucet** | Available via API | 35 | 36 | 37 | ## Use Cases 38 | 39 | #### Protocol Development 40 | 41 | Protocol development involves testing _**new consensus mechanisms**_, validating _**protocol upgrades**_, experimenting with _**new transaction types**_, and conducting _**performance testing and optimization**_. 42 | 43 | #### Application Development 44 | 45 | Application development includes building and testing _**Move applications**_, performing _**integration testing**_ with L1 features, conducting _**performance benchmarking**_, and preparing for _**migration from sidechain**_. 46 | 47 | #### Tooling and Infrastructure 48 | 49 | Tooling and infrastructure development covers testing _**new developer tools**_, validating _**indexing and analytics services**_, conducting _**infrastructure stress testing**_, and developing _**API and SDK**_ capabilities. 50 | 51 | 52 | -------------------------------------------------------------------------------- /content/docs/general/networks/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: networks 3 | sidebar_position: 4 4 | title: Overview 5 | description: "Overview of all Movement networks" 6 | --- 7 | 8 | import React from 'react'; 9 | 10 | Movement provides several networks with different architectures for development and production needs: 11 | 12 | ### L1 Networks 13 | 1. **[L1 (Testnet)](/general/networks/testnet)** — A native L1 testing environment that provides developers with a safe space to build and test applications using the full Move execution environment before deploying to production networks. 14 | 2. **[L1 (Devnet)](/general/networks/devnet)** — A native L1 development network for testing the latest protocol features and upgrades, providing early access to new functionality in the Movement ecosystem. It may reset frequently. 15 | 16 | ### Sidechain Networks 17 | 3. **[Sidechain (Mainnet)](/general/networks/mainnet)** — Currently operating as a sidechain serving production traffic with real economic value. This network will eventually migrate to become the flagship L1 network. 18 | 19 | 20 | ## Timeline and Roadmap 21 | 22 | _**Phase 1**_ (Current: Devnet) 23 | focuses on _**core L1 infrastructure development**_ and integrating _**developer tools**_. 24 | 25 | _**Phase 2**_ (Testnet Migration) 26 | involves _**testnet transitions**_ to L1 architecture, creating a _**production-like testing environment**_. Extended testing and validation period with community. 27 | 28 | _**Phase 3**_ (Mainnet Migration) 29 | covers _**mainnet transitions**_ from sidechain to L1, achieving _**full decentralization**_, and launching the _**production L1 network**_. A complete native blockchain ecosystem is achieved. 30 | 31 | 32 | {/* ### Network Properties 33 | 34 | | Network | Chain ID | Genesis | Faucet | Governance | Update Schedule | Data Persistence | 35 | |---------|------------|---------|---------|------------|-----------------|------------------| 36 | | **Sidechain (Mainnet)** | 126 | Info Coming Soon | N/A | Transitioning to L1 | Monthly, varies | Permanent | 37 | | **L1 (Testnet)** | 250 | Info Coming Soon | Coming Soon | Managed by Movement Labs | Monthly, varies | Resets as Needed, but avoided | 38 | | **L1 (Devnet)** | 27 | Info Coming Soon | Coming Soon | Managed by Movement Labs | As updated | Resets as Needed | */} 39 | 40 | All Network URLS are availble [here](/devs/networkEndpoints). 41 | 42 | 43 | ## Additional Resources 44 | 45 | - For community resources, support channels, and ways to get involved, see [Community and Support](/general/usingmovement/community-support). 46 | - **[Node Operations](/general/l1/nodes)** - Information about running Movement nodes 47 | - **[Explorer](https://explorer.movementnetwork.xyz/)** - Browse network activity and transactions 48 | -------------------------------------------------------------------------------- /content/docs/general/networks/mainnet.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: mainnet 3 | title: Mainnet 4 | description: "Movement Mainnet" 5 | --- 6 | 7 | import React from 'react'; 8 | 9 | Movement Mainnet is the flagship blockchain in the Movement ecosystem, designed to be a high-performance, secure, and scalable blockchain platform. Until the migration it is operated as a sidechain. 10 | 11 | 12 | **Coming Soon**: Movement L1 Mainnet documentation is currently under development. This section will be updated with detailed technical specifications, network parameters, and developer resources. To get started building on the current Mainnet, see our developer documentation [here](/devs). You can continue using these resources even after the migration to L1. 13 | 14 | 15 | ## Documentation 16 | 17 | - **[Learn more about the current architecture (Sidechain)](/general/sidechain)** 18 | - **[Learn more about the future architecture (L1)](/general/l1)** 19 | -------------------------------------------------------------------------------- /content/docs/general/networks/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Networks", 3 | "pages": [ 4 | "index", 5 | "mainnet", 6 | "testnet", 7 | "devnet" 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /content/docs/general/networks/testnet.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: testnet 3 | title: L1 (Testnet) 4 | description: "Movement L1 Testnet" 5 | --- 6 | 7 | import React from 'react'; 8 | 9 | Movement Testnet is a native L1 blockchain network that provides a production-like testing environment for developers to build and test applications before deploying to the production networks. Unlike the current mainnet [sidechain](/general/sidechain), testnet operates as a full [L1 blockchain](/general/l1). 10 | 11 | ## Key Features 12 | 13 | Testnet represents the stable testing version of Movement's L1 architecture: 14 | 15 | - **Stable Environment**: Persistent network with reliable uptime 16 | - **Production-Ready Conditions**: Production-like network conditions, consensus and performance 17 | - **Community Validators**: Decentralized validator set for realistic testing 18 | - **Persistent Data**: Long-term data retention for continuous development 19 | - **Stable APIs**: Production-ready interfaces for application development 20 | 21 | 22 | ## Network Properties 23 | 24 | | Property | Value | 25 | |----------|-------| 26 | | **Network Type** | Native L1 Blockchain | 27 | | **Consensus** | BFT Consensus | 28 | | **Block Time** | ~1 second | 29 | | **Finality** | ~1 second (Details TBA) | 30 | | **Validators** | Community + Movement Labs | 31 | | **Data Retention** | Permanent | 32 | | **Faucet** | [Get testnet tokens](https://faucet.movementnetwork.xyz/) | 33 | 34 | 35 | Migration preparation involves _**sidechain to L1**_ testing to ensure applications are compatible with L1 architecture, _**tool validation**_ to ensure development tools work with L1, _**workflow testing**_ to validate deployment and operational workflows, and _**training**_ to familiarize teams with L1 operations. 36 | 37 | 38 | 39 | ## Use Cases 40 | 41 | #### Application Development 42 | 43 | Testnet enables comprehensive application development through _**pre-production testing**_ in production-like conditions, _**integration testing**_ to validate integrations with realistic network behavior, _**performance testing**_ to benchmark application performance on L1, and _**user acceptance testing**_ for end-to-end testing with real user flows. 44 | 45 | #### Infrastructure Testing 46 | 47 | Infrastructure testing includes _**validator setup**_ for testing validator node configurations, _**API services**_ validation for RPC and indexing services, _**monitoring**_ implementation for infrastructure monitoring and alerting, and _**scaling**_ tests to validate infrastructure performance under load. 48 | 49 | ## Getting Started 50 | 51 | #### Prerequisites 52 | 53 | - [Movement CLI tools](/devs/movementcli) installed 54 | - Understanding of [Move language](/general/l1/move-language) 55 | - Testnet MOVE tokens from [faucet](https://faucet.movementnetwork.xyz/) 56 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Overview" 3 | description: "Deploy and operate your own public fullnode (PFN) to synchronize with the Movement blockchain and stay up-to-date with the latest state." 4 | sidebar: 5 | label: "Overview" 6 | --- 7 | 8 | You can run your own public fullnode (PFN) to synchronize the state of the Movement blockchain and stay 9 | up-to-date. PFNs replicate the entire state of the blockchain by syncing from other Movement VFNs and PFNs. PFNs 10 | can be run by anyone. This section explains how to deploy a PFN and connect to a Movement network. You can learn 11 | more about the different types of nodes in the [Movement L1](/general/l1/nodes) section. 12 | 13 | **Default connection to testnet** 14 | If you follow the default setup in this document, then your PFN will be connected to the Movement testnet. To connect 15 | to a different Movement network, such as devnet or testnet, make sure you have the correct docker image tag, or source 16 | code branch if you build the binary directly. 17 | 18 | You can find the genesis and waypoint files for all the networks, here ➜ https://github.com/movementlabsxyz/movement-networks. 19 | 20 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Full Node", 3 | "pages": [ 4 | "index", 5 | "run" 6 | ] 7 | } 8 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/deploy/docker.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Using Docker" 3 | description: "Deploy a public fullnode (PFN) using Docker containers with automated configuration download and container setup for x86-64 systems." 4 | sidebar: 5 | label: "Docker" 6 | --- 7 | 8 | This section describes how to configure and run your PFN using Docker. You can either use pre-built Docker images or build your own from source. 9 | 10 | 11 | **Supported only on x86-64 CPUs**
12 | Running aptos-core via Docker is currently only supported on x86-64 CPUs. If you have an Apple M1/M2 (ARM64) Mac, use 13 | the aptos-core source code approach (above). If M1/M2 support is important to you, comment on this 14 | issue: https://github.com/aptos-labs/aptos-core/issues/1412 15 |
16 | 17 | If you prefer to use the official pre-built images, follow these steps: 18 | 19 | 1. First, install [Docker](https://docs.docker.com/get-docker/). 20 | 2. Next, run the following script to prepare your local configuration and data directory for mainnet. This will 21 | download the `fullnode.yaml` configuration file, the `genesis.blob` and `waypoint.txt` files for your PFN, and 22 | create a `data` directory to store the blockchain database: 23 | 24 | ```shellscript filename="Terminal" 25 | mkdir testnet && cd testnet 26 | mkdir data && \ 27 | curl -O https://raw.githubusercontent.com/movementlabsxyz/aptos-core/movement/docker/compose/aptos-node/fullnode.yaml && \ 28 | curl -O https://raw.githubusercontent.com/movementlabsxyz/movement-networks/main/testnet/waypoint.txt && \ 29 | curl -O https://raw.githubusercontent.com/movementlabsxyz/movement-networks/main/testnet/genesis.blob 30 | curl -O https://raw.githubusercontent.com/movementlabsxyz/movement-networks/main/testnet/genesis_waypoint.txt 31 | ``` 32 | 33 | 34 | **Don't want to connect to testnet?**
35 | To connect to other networks (e.g., `devnet` and `mainnet`), you can find the genesis and waypoint here ➜ https://github.com/movementlabsxyz/movement-networks. 36 | Be sure to download the `genesis.blob` and `waypoint.txt` for those networks, instead of using the genesis 37 | and waypoint pointed to by the `curl` commands above. 38 |
39 | 40 | 3. Next, update the `fullnode.yaml` configuration file that you downloaded above with the following content. 41 | This will ensure that this configuration is for a PFN and not for another node type (e.g., validator or VFN): 42 | 43 | ```yaml filename="fullnode.yaml" 44 | base: 45 | role: "full_node" 46 | data_dir: "/opt/aptos/data" 47 | waypoint: 48 | from_file: "/opt/aptos/waypoint.txt" 49 | 50 | execution: 51 | genesis_file_location: "/opt/aptos/genesis.blob" 52 | genesis_waypoint: 53 | from_file: "/opt/aptos/genesis_waypoint.txt" 54 | 55 | storage: 56 | rocksdb_configs: 57 | enable_storage_sharding: false 58 | 59 | full_node_networks: 60 | - network_id: "public" 61 | discovery_method: "none" 62 | listen_address: "/ip4/0.0.0.0/tcp/6182" 63 | seeds: 64 | 9967EBF40AC8C2CCB38709488952DA1826176584EA3067B63B1695362ECB3D1F: 65 | addresses: 66 | - "/dns/testnet.movementnetwork.xyz/tcp/6182/noise-ik/9967EBF40AC8C2CCB38709488952DA1826176584EA3067B63B1695362ECB3D1F/handshake/0" 67 | role: "Upstream" 68 | 69 | api: 70 | enabled: true 71 | address: 0.0.0.0:8080 72 | 73 | state_sync: 74 | state_sync_driver: 75 | bootstrapping_mode: DownloadLatestStates 76 | continuous_syncing_mode: ApplyTransactionOutputs 77 | ``` 78 | 79 | 80 | **Don't want to allow inbound connections?**
81 | Override the following if you do not want other PFNs connecting to yours: `listen_address: "/ip4/127.0.0.1/tcp/6182"`. 82 |
83 | 84 | 4. Next, run the following `docker` command: 85 | 86 | ```shellscript filename="Terminal" 87 | docker run --pull=always \ 88 | --rm -p 8080:8080 \ 89 | -p 9101:9101 -p 6180:6180 \ 90 | -v $(pwd):/opt/aptos -v $(pwd)/data:/opt/aptos/data \ 91 | --workdir /opt/aptos \ 92 | --name=aptos-fullnode ghcr.io/movementlabsxyz/aptos-node:1f072d5 \ 93 | -f /opt/aptos/fullnode.yaml 94 | ``` 95 | 96 | 97 | **Sudo access**
98 | Note: you may need to prefix the docker command with `sudo` depending on your configuration. 99 |
100 | 101 | 102 | **Docker tags**
103 | The `latest` tag always refers to the latest official Docker image tag. You can find the latest hash for comparison at: 104 | https://github.com/movementlabsxyz/movement-networks/tree/main/testnet 105 |
106 | 107 | You have now successfully configured and started running a PFN in the Aptos mainnet. 108 | 109 | 110 | **Verify your PFN** 111 | If you want to verify that your PFN is running correctly, you can follow the instructions in the [Verify a PFN](/network/nodes/full-node/verify-pfn) guide. 112 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/deploy/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Deploy a PFN" 3 | description: "Step-by-step guides for deploying a public fullnode (PFN) on Movement networks using various deployment methods including source code, Docker, and cloud platforms coming soon." 4 | sidebar: 5 | label: "Overview" 6 | --- 7 | 8 | The following guides provide step-by-step instructions for deploying a PFN on the Movement networks. 9 | 10 | 11 | **Do I have to run a PFN?**
12 | If you do not wish to run a PFN, but still want to interact with the Movement blockchain, you can use the REST API 13 | provided by the Movement Labs' PFNs (see [Movement APIs](/api)). Note, however, that Movement Labs-provided PFNs have rate 14 | limits, which can impede your development. You can deploy your own PFN 15 | and synchronize with the Movement blockchain directly, or use a different node infrastructure provider. 16 |
17 | 18 | Select the guide for the deployment method you prefer: 19 | 20 | 21 | **Choose a network**
22 | These guides default to deploying a PFN in the Movement testnet network, but they can easily be used to do 23 | the same in other networks (e.g., devnet or mainnet network). To do so, check out the 24 | [movement-networks](https://github.com/movementlabsxyz/movement-networks) repo 25 | and use the `genesis.blob` and `waypoint.txt` node files for the respective networks: 26 | [mainnet](https://github.com/movementlabsxyz/movement-networks/blob/main/mainnet/README.md), 27 | [testnet](https://github.com/movementlabsxyz/movement-networks/blob/main/testnet/README.md), 28 | and [devnet](https://github.com/movementlabsxyz/movement-networks/blob/main/devnet/README.md). 29 |
30 | 31 | - ### [Using Source Code](/general/nodes/full-node/run/deploy/source) 32 | - ### [Using Docker](/general/nodes/full-node/run/deploy/docker) -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/deploy/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Deploy a Full Node", 3 | "pages": [ 4 | "index", 5 | "source", 6 | "docker" 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/deploy/source.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Using Source Code" 3 | description: "Deploy a public fullnode (PFN) by building from aptos-core source code with complete configuration and setup instructions." 4 | sidebar: 5 | label: "Source Code" 6 | --- 7 | 8 | To deploy a PFN using the `aptos-core` source code maintained by movement labs 9 | Follow the steps below: 10 | 11 | 1. Clone the movement `aptos-core` repo : `git clone https://github.com/movementlabsxyz/aptos-core.git`. 12 | 13 | 1. Go in `aptos-core` directory: `cd aptos-core`. 14 | 15 | 2. Check out the `l1-mgiration` branch using `git checkout --track origin/l1-migration` 16 | 17 | 3. Next, download the `genesis.blob`, `waypoint.txt`, `genesis_waypoint.txt` files for the network your PFN will connect to: 18 | 19 | - Run this command to download the genesis blob (for testnet): 20 | ```shellscript filename="Terminal" 21 | curl -O https://raw.githubusercontent.com/movementlabsxyz/movement-networks/main/testnet/genesis.blob 22 | ``` 23 | 24 | - Run this command to download the waypoint file (for testnet): 25 | ```shellscript filename="Terminal" 26 | curl -O https://raw.githubusercontent.com/movementlabsxyz/movement-networks/main/testnet/waypoint.txt 27 | ``` 28 | 29 | - Run this command to download the genesis_waypoint file (for testnet): 30 | ```shellscript filename="Terminal" 31 | curl -O https://raw.githubusercontent.com/movementlabsxyz/movement-networks/main/testnet/genesis_waypoint.txt 32 | ``` 33 | 34 | **Don't want to connect to testnet?**
35 | To connect to other networks (e.g., `devnet` and `mainnet`), you can find the genesis, waypoint and genesis_waypoint here ➜ https://github.com/movementlabsxyz/movement-networks. 36 | Be sure to download the `genesis.blob`, `waypoint.txt` and `genesis_waypoint.txt` for those networks. 37 |
38 | 39 | 4. Next, run the command below to create a copy of the PFN configuration YAML template: 40 | ```shellscript filename="Terminal" 41 | cp config/src/config/test_data/public_full_node.yaml fullnode.yaml 42 | ``` 43 | 44 | 5. Finally, edit the `fullnode.yaml` configuration file to ensure that your PFN: (i) contains the files you just downloaded; and (ii) saves the synchronized blockchain data to the location of your 45 | choice (on your local machine). To do this: 46 | 47 | 1. Specify the correct path to the `genesis.blob` and `genesis_waypoint.txt` file you just downloaded by editing `execution.genesis_file_location` in the `fullnode.yaml` configuration. By default, it points to `genesis.blob` in the current working directory. 48 | ```yaml filename="fullnode.yaml" 49 | execution: 50 | genesis_file_location: ./genesis.blob # update to your path 51 | genesis_waypoint: 52 | from_file: ./genesis_waypoint.txt 53 | ``` 54 | 2. Specify the correct path to the `waypoint.txt` file you just downloaded by editing `base.waypoint.from_file` in the `fullnode.yaml` configuration. By default, it points to `waypoint.txt` in the current working directory. For example: 55 | ```yaml filename="fullnode.yaml" 56 | base: 57 | waypoint: 58 | from_file: "./waypoint.txt" 59 | 60 | 3. Specify the directory on your local machine that you want to store the blockchain database by editing the `base.data_dir` in the `fullnode.yaml` configuration. For example, you can create a directory `my-full-node/data` in your home directory and specify it as: 61 | ```yaml filename="fullnode.yaml" 62 | base: 63 | data_dir: "" 64 | ``` 65 | 4. Specify the upstream peer for your PFN. The upstream peer is the node from which your PFN will synchronize blockchain data. In this example, `9967EBF40AC8C2CCB38709488952DA1826176584EA3067B63B1695362ECB3D1F` is the upstream peer_id. You can also configure this to point to your own PFN if preferred. For example: 66 | ``` 67 | full_node_networks: 68 | - network_id: "public" 69 | discovery_method: "none" 70 | listen_address: "/ip4/0.0.0.0/tcp/6182" 71 | seeds: 72 | 9967EBF40AC8C2CCB38709488952DA1826176584EA3067B63B1695362ECB3D1F: 73 | addresses: 74 | - "/dns/testnet.movementnetwork.xyz/tcp/6182/noise-ik/9967EBF40AC8C2CCB38709488952DA1826176584EA3067B63B1695362ECB3D1F/handshake/0" 75 | role: "Upstream" 76 | ``` 77 | 78 | 6. Start your local public fullnode by running the below command: 79 | 80 | ```shellscript filename="Terminal" 81 | cargo run -p aptos-node --release -- -f ./fullnode.yaml 82 | ``` 83 | 84 | 85 | **Debugging?**
86 | The command above will build a release binary for `aptos-node` at: `aptos-core/target/release/aptos-node`. The release 87 | binaries tend to be substantially faster than debug binaries but lack debugging information useful for development. 88 | To build a debug binary, omit the `--release` flag from the command above. 89 |
90 | 91 | You have now successfully configured and started running a PFN in the Movement testnet. 92 | 93 | 94 | **Verify your PFN**
95 | If you want to verify that your PFN is running correctly, you can follow the instructions in the [Verify a PFN](/general/nodes/full-node/run/verify) guide. 96 |
97 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Requirements" 3 | description: "Hardware, network, storage, and port requirements for running a production-grade public fullnode (PFN) on the Movement blockchain." 4 | sidebar: 5 | label: "Requirements" 6 | --- 7 | 8 | To ensure that your public fullnode (PFN) operates smoothly, it should meet the requirements specified in this document. 9 | 10 | ## Hardware requirements 11 | 12 | 13 | **Minimum hardware requirements**
14 | Failing to meet the minimum hardware requirements mean that your PFN will experience degradation under 15 | load and general instability in production environments. It is not recommended to run a PFN without 16 | meeting the minimum hardware requirements. 17 |
18 | 19 | For running a production-grade PFN, we recommend that your hardware meet the same requirements as a 20 | validator or VFN. You can see the hardware requirements for these, here: [validator and VFN hardware requirements](/network/nodes/validator-node/node-requirements#hardware-requirements). 21 | 22 | 23 | **Testing PFNs**
24 | If you wish to run a PFN for development or testing only, lower hardware specs can be used. 25 | But, it should not be used in production. 26 |
27 | 28 | ## Network requirements and ports 29 | 30 | When you are running a PFN, you are required to open network ports on your nodes to allow other nodes (i.e., peers) 31 | to connect to you. There are different Movement network types, and each network type uses a different port. However, 32 | the only network type that a PFN uses is the public network, where PFNs to connect to other PFNs and VFNs. 33 | 34 | Your PFN can be configured so that the public network operates using a specific port on your node. You can configure 35 | the port settings using the node configuration YAML file. Here is an [example 36 | configuration file](https://github.com/movementlabsxyz/aptos-core/blob/movement/config/src/config/test_data/public_full_node.yaml#L16) for a PFN 37 | that configures the public network to use port `6180`. 38 | 39 | ### Port settings 40 | 41 | The recommendations described below assume the default port settings used by PFNs. If you have 42 | changed the default port settings in your configuration file, then you should adjust the recommendations accordingly. 43 | 44 | 45 | **Exposing ports**
46 | Unless explicitly required, we recommend that you do not expose any other ports while operating a PFN. This is because 47 | exposing additional ports can increase the attack surface of your node and make it more vulnerable to adversaries. 48 |
49 | 50 | #### Running a PFN: 51 | 52 | Assuming default ports are used, the following should be configured for PFNs: 53 | 54 | - Open the following TCP ports: 55 | - `6182` – **Public network**: Open this port publicly to enable other PFNs to connect to your PFN. 56 | - Close the following TCP ports: 57 | - `9101` – **Inspection service**: Close this port to prevent unauthorized metric inspection. 58 | - `9102` – **Admin service**: Close this port to prevent unauthorized admin service interaction. 59 | - `80/8080` - **REST API**: Close this port to prevent unauthorized REST API access. 60 | 61 | 62 | **Exposing services**
63 | The inspection service port (`9101`), admin service port (`9102`) and the REST API port (`80` or `8080`) 64 | are likely useful for your internal network, e.g., application development and debugging. However, the inspection service 65 | port and the admin service port should never be exposed publicly as they can be easily abused. Similarly, if you choose 66 | to expose the REST API endpoint publicly, you should deploy an additional authentication or rate-limiting mechanism to 67 | prevent abuse. 68 |
69 | 70 | ## Storage requirements 71 | 72 | The amount of data stored by Movement PFNs depends on the ledger history (length) of the blockchain and the number of 73 | on-chain states (e.g., accounts and resources). Both the ledger history and the number of 74 | on-chain states depend on several additional factors, including the age of the blockchain, the average transaction 75 | rate over time, and the configuration of the ledger database pruner. At the time of writing, we estimate 76 | that testnet and mainnet PFNs require several 100's of GB of storage. 77 | 78 | Note that because archival nodes store the entire history of the blockchain, the database size on archival nodes 79 | will continue to grow unbounded. As a result, we cannot provide a recommendation for archival node storage sizes. 80 | 81 | 82 | **Devnet blockchain storage**
83 | The Movement devnet is currently reset as needed. If you are deploying a devnet PFN, this means that the storage 84 | can be reset (i.e., wiped). See the [#devnet-announcements](https://discord.com/channels/1101576619493167217/1259638353607917589) channel on the [Movement Discord](http://discord.gg/movementlabsxyz). 85 |
-------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Run a Full Node", 3 | "pages": [ 4 | "index", 5 | "deploy", 6 | "verify" 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /content/docs/general/nodes/full-node/run/verify.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Verify a PFN" 3 | description: "Monitor and verify your public fullnode (PFN) operation by checking synchronization status, network connections, and storage metrics." 4 | sidebar: 5 | label: "Verify PFN" 6 | --- 7 | 8 | After deploying your PFN, you can verify that it is operating correctly by checking several of the PFN's metrics. 9 | This document describes the common types of checks that you might wish to perform. 10 | 11 | 12 | You can learn more about Aptos metrics in the [Node Inspection Service](/network/nodes/measure/node-inspection-service) documents. 13 | 14 | 15 | ### Verify synchronization 16 | 17 | During the initial synchronization of your PFN, there may be a lot of data to transfer. You can monitor state sync progress 18 | by querying the metrics port to see what version your node is currently synced to. Run the following example 19 | command to see the currently synced version of your node: 20 | 21 | ```shellscript filename="Terminal" 22 | curl 127.0.0.1:9101/metrics 2> /dev/null | grep "aptos_state_sync_version{.*\"synced\"}" | awk '{print $2}' 23 | ``` 24 | 25 | The command will output the current synced version of your node. For example: 26 | 27 | ```shellscript filename="Terminal" 28 | 71000 29 | ``` 30 | 31 | Compare the synced version returned by this command (e.g., `71000`) with the highest version shown on the 32 | [Movement explorer page](https://explorer.movementnetwork.xyz/?network=bardock+testnet). If your node is catching up to the highest 33 | version, it is synchronizing correctly. It is fine if the explorer page differs by a few versions, as the explorer 34 | nodes may sync with some variance. 35 | 36 | 37 | **Using fast sync?**
38 | If your node is fast syncing, the command may show `0` until it has finally caught up. To verify that the node is 39 | fast syncing, run the following command: 40 | 41 | ```shellscript filename="Terminal" 42 | curl 127.0.0.1:9101/metrics 2> /dev/null | grep "aptos_state_sync_version{.*\"synced_states\"}" | awk '{print $2}' 43 | ``` 44 | 45 | This should show an increasing number of synced states. It may take several hours for your node to fast sync to the 46 | latest version. Eventually, once fast syncing is complete, the `aptos_state_sync_version{.*"synced"}` command will 47 | return the current synced version of your node. 48 | 49 |
50 | 51 | ### (Optional) Verify outbound network connections 52 | 53 | If you wish, you can also check the outbound network connections for your PFN. The number of outbound network 54 | connections should be more than `0` for healthy PFNs. Run the following command: 55 | 56 | ```shellscript filename="Terminal" 57 | curl 127.0.0.1:9101/metrics 2> /dev/null | grep "aptos_connections{direction=\"outbound\"" 58 | ``` 59 | 60 | The above command will output the number of outbound network connections for your node. For example: 61 | 62 | ```shellscript filename="Terminal" 63 | curl 127.0.0.1:9101/metrics 2> /dev/null | grep "aptos_connections{direction=\"outbound\"" 64 | aptos_connections{direction="outbound",network_id="Public",peer_id="aabd651f",role_type="full_node"} 3 65 | ``` 66 | 67 | If the number of outbound connections returned is `0`, then it means your node cannot connect to the Movement blockchain. If this happens to you, follow these steps to resolve the issue: 68 | 69 | 1. Update your node to the latest release. 70 | 2. Remove any `seed` peers you may have added to your configuration file. The seeds may be preventing you from 71 | connecting to the network. 72 | 73 | ### (Optional) Examine Docker ledger size 74 | 75 | If you are running your PFN using Docker, you can monitor the size of the blockchain ledger by entering the Docker 76 | container and checking the size. This will allow you to see how much storage the blockchain ledger is currently consuming. 77 | 78 | - First, run `docker container ls` on your terminal and copy the NAME field output. This will be a string similar to `public_full_node_fullnode_1`. 79 | - Next, run these commands to check the storage size consumed by the ledger, using the NAME field you copied over in place of `public_full_node_fullnode_1`: 80 | 81 | ```shellscript filename="Terminal" 82 | # Obtain the container ID: 83 | id=$(docker container ls | grep public_full_node_fullnode_1 | grep -oE "^[0-9a-zA-Z]+") 84 | 85 | # Enter the container: 86 | docker exec -it $id /bin/bash 87 | 88 | # Observe the volume (ledger) size: 89 | du -cs -BM /opt/aptos/data 90 | ``` 91 | 92 | [rest_spec]: https://github.com/movementlabsxyz/aptos-core/tree/main/api 93 | 94 | [devnet_genesis]: https://devnet.movementnetwork.com/genesis.blob 95 | 96 | [devnet_waypoint]: https://devnet.movementnetwork.com/waypoint.txt 97 | 98 | [movementlabsxyz/aptos-core]: https://github.com/movementlabsxyz/aptos-core.git 99 | -------------------------------------------------------------------------------- /content/docs/general/nodes/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Movement Network Nodes" 3 | description: "Learn about validator nodes, validator fullnodes, and public fullnodes that power the Movement network" 4 | sidebar: 5 | label: "Nodes Overview" 6 | --- 7 | 8 | The Movement network consists of three node types: validator nodes, validator fullnodes (VFNs), and public fullnodes (PFNs). To 9 | participate in consensus, you are required to run a validator node and stake the minimum amount of coins. VFNs and PFNs 10 | are not required to participate in consensus, but they are necessary to distribute blockchain data and enable ecosystem services, 11 | e.g., indexing, querying, and RESTful API services (see [Movement APIs](/api)). VFNs can only be run by validator operators, 12 | while PFNs can be run by anyone. You can learn more about the different types of nodes in the [L1 Architecture](/general/l1/architecture) section. 13 | 14 | -------------------------------------------------------------------------------- /content/docs/general/nodes/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Nodes", 3 | "pages": [ 4 | "index", 5 | "full-node" 6 | ] 7 | } 8 | -------------------------------------------------------------------------------- /content/docs/general/sidechain/architecture.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Sidechain Architecture 3 | description: Detailed architecture of the Movement Sidechain 4 | --- 5 | 6 | Movement Sidechain is built on a modular architecture that combines MoveVM execution with L1 security. This section covers the detailed architecture components and how they work together. 7 | 8 | ![architecture_movement.png](./images/architecture_movement.png) 9 | 10 | 11 | Integration with Celestia is currently in progress and will be coming soon. 12 | 13 | 14 | ## Data Availability 15 | 16 | The DA service is used to store transaction data and make it available to the network. The service is accessed via [DA light nodes](./node-level-architecture#da-light-node). The DA service is currently responsible for the following actions: 17 | 18 | - Forming transaction batches 19 | - Signing the transaction batches 20 | - Ordering the transactions batches 21 | - Using the ordered transaction protoBlocks 22 | - Construct a protoBlock stream 23 | 24 | ## Sequencing 25 | 26 | In order to protect the DA layer from spam, only certain [sequencer nodes](./node-level-architecture#sequencer-node) receive authorization to sequence transactions into ordered transaction batches. These sequencer nodes provide basic sequencing for transactions ingressed from the users. The sequencer node sends the transaction batch digest to the DA service using the [DA light node](./node-level-architecture#da-light-node). Initially, there will be a leader node that is responsible for sequencing transactions. Sequenced transactions then result in construction of protoBlocks, where each protoBlock may contain several transaction batches. 27 | 28 | The protoBlock is the final ordering step of transactions. Next stop: execution. 29 | 30 | ## Execution 31 | 32 | A node receives protoBlocks via the [DA light node](./node-level-architecture#da-light-node) and executes the transactions in the protoBlocks. The node then creates Movement blocks from the protoBlocks, which contain additional information such as the new state root after applying the transactions. 33 | 34 | ## Fees 35 | 36 | Transaction fees are paid in the token of the Movement Network. They are used to pay for the data availability, sequencing, execution, and settlement services: 37 | 38 | ``` 39 | fee = data_availability_fee + sequencing_fee + execution_fee + settlement_fee 40 | ``` 41 | 42 | For more information on fees, see [this MIP](https://github.com/movementlabsxyz/MIP/tree/gas-fee-calculation/MIP/mip-19). 43 | -------------------------------------------------------------------------------- /content/docs/general/sidechain/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/sidechain/images/architecture.png -------------------------------------------------------------------------------- /content/docs/general/sidechain/images/architecture_movement.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/sidechain/images/architecture_movement.png -------------------------------------------------------------------------------- /content/docs/general/sidechain/images/move_chain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/sidechain/images/move_chain.png -------------------------------------------------------------------------------- /content/docs/general/sidechain/images/move_stack.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/sidechain/images/move_stack.png -------------------------------------------------------------------------------- /content/docs/general/sidechain/images/mvmt_network.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/sidechain/images/mvmt_network.png -------------------------------------------------------------------------------- /content/docs/general/sidechain/index.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: sidechain 3 | sidebar_position: 3 4 | title: Overview 5 | description: "Movement Sidechain - A Move-based sidechain secured by the L1" 6 | --- 7 | 8 | import React from 'react'; 9 | 10 | Movement Sidechain is a Move-based sidechain secured by an L1, providing high-throughput execution through the MoveVM. 11 | 12 | ## Documentation 13 | 14 | - **[What is Movement Sidechain](/general/sidechain/what-is-movement-sidechain)** - Learn about Movement Sidechain components and capabilities 15 | - **[High-Level Architecture](/general/sidechain/architecture)** - Detailed architecture of the Movement Sidechain 16 | - **[Node-Level Architecture](/general/sidechain/node-level-architecture)** - Detailed node-level architecture and components 17 | - **[Movement Sidechain Whitepaper](/general/sidechain/whitepaper)** - Whitepaper for Movement Sidechain 18 | 19 | ## Networks 20 | 21 | Movement Sidechain currently operates: 22 | - **[Mainnet](/general/networks/mainnet)** - Production sidechain network 23 | 24 | ## Whitepaper 25 | 26 | For further information about Movement Sidechain, please refer to our [Movement Sidechain Whitepaper](/general/sidechain/whitepaper). 27 | -------------------------------------------------------------------------------- /content/docs/general/sidechain/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Movement Sidechain", 3 | "pages": ["index", "what-is-movement-sidechain", "architecture", "node-level-architecture", "whitepaper"], 4 | "link": { 5 | "type": "generated-index", 6 | "description": "Learn about Movement Sidechain - a Move-based sidechain secured by the L1" 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /content/docs/general/sidechain/node-level-architecture.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Node-Level Architecture 3 | description: Architecture of the nodes in the Movement Sidechain 4 | --- 5 | 6 | Nodes have some basic functionalities in common, such as: 7 | 8 | - Runs executions of blocks sequenced by the Data Availability (DA) service, 9 | receiving them through the DA light node. The sequenced blocks provided by the DA are called protoBlocks. 10 | - Provides views on the optimistic and settled (finalized) states via 11 | Aptos REST API endpoints. 12 | - Creates deterministic state transitions from the protoBlocks, and from which Movement blocks are created. 13 | 14 | ## Node Types 15 | 16 | ### Sequencer node 17 | 18 | A sequencer node ingresses transactions into a local mempool and forms batches from the transactions in the mempool and forwards them to the [DA light node](#da-light-node) 19 | 20 | ### Validator node 21 | 22 | A validator node is a node that is part of the trusted validator set, which settles blocks via the [Fast-Finality-Settlement](./architecture#settlement). 23 | 24 | ### Follower Node 25 | 26 | The follower node is a node type introduced for RPC providers. A follower node performs basic operations but does neither sequence nor settle. As such, it does not need access to a private key from the trusted validator set. Follower Nodes help the Movement Network to scale by providing increased transaction ingress capacity and horizontal scaling for queries over chain state. Learn to run and deploy a follower node [here](https://github.com/movementlabsxyz/movement/tree/main/docs/movement-node/run/manual/follower-node). 27 | 28 | ### Archival node 29 | 30 | An archival node is a read-only follower-type node that synchronizes with the DA network and provides a view on the chain state. 31 | 32 | ## DA light node 33 | 34 | The DA light node is a standalone service, that differs from the above node types. It performs these categories of operations: 35 | 36 | 1. Write: the light node forwards signed transaction-batches, which are submitted by authorized nodes, to the data availability layer. 37 | 2. Read: the light node reads the data from the data availability layer and verifies them against its verification parameters, currently by verifying a trusted signature. 38 | 3. Read: the light node reads the ordered transaction batches with the data from the DA layer constructs protoBlocks. 39 | 40 | The DA light node provides access to these operation via a gRPC API. 41 | -------------------------------------------------------------------------------- /content/docs/general/sidechain/whitepaper.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Sidechain Whitepaper 3 | description: Whitepaper for Movement Sidechain 4 | --- 5 | 6 | The Movement Sidechain whitepaper provides information about the architecture, security model, and implementation of the proposed Move-based sidechain secured by an L1. 7 | 8 | 9 | [Download the Movement Sidechain Whitepaper (PDF)](https://www.movementnetwork.xyz/whitepaper/movement-whitepaper_en.pdf) 10 | -------------------------------------------------------------------------------- /content/docs/general/usingmovement/bridge.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Bridge 3 | description: Bridge funds between the Movement Network and other chains. 4 | --- 5 | 6 | 7 | ## Canonical Bridging via Layer Zero 8 | 9 | The Movement Network Bridge, powered by [LayerZero](https://www.layerzero.network/), is a bridge that allows users to bridge tokens between the Movement Network and other chains, initially supporting transfers from Ethereum to Movement Network. 10 | 11 | Note: The Movement Network Bridge is currently in beta and only supports transfers from Ethereum to Movement Network for Move. Other assets can be bridged in both directions. 12 | 13 | Learn more about Layer Zero OFT(Omnichain Fungible Tokens) and how this is implemented using Aptos Move [here](https://docs.layerzero.network/v2/developers/aptos-move/contract-modules/oft). 14 | 15 | Note: OFTs do not currently support the Coin standard and as such all OFTs are minted as Fungible Asset Standard. 16 | 17 | ## Bridge Interface 18 | 19 | The Bridge Interface is a web application that allows users to bridge tokens between the Movement Network and other chains. 20 | 21 | To start bridging, navigate to the [Bridge Interface](https://bridge.movementnetwork.xyz/) and connect your wallet. 22 | 23 | ## Asset Transfer 24 | 25 | We are launching with support for the following assets: 26 | 27 | - Move Token 28 | - Daily Bridge Limit: 29 | - 75M tokens can be bridged to Movement on Day 1 30 | - 25m tokens can be bridged to Movement per day thereafter 31 | - No withdrawals from Movement back to Ethereum for Move Token at launch 32 | - USDC/USDT/ETH 33 | - 3 Day waiting period for withdrawals when briding from Movement to Ethereum 34 | - Other Assets 35 | - 3 Day waiting period for withdrawals when briding from Movement to Ethereum 36 | 37 | ## Mainnet Addresses 38 | 39 | The mainnet Bridge currently allows for bridging between Ethereum Mainnet and Movement Mainnet. 40 | 41 | 42 | 43 | Note that the Move Token listed below is not an OFT but is an FA token that is used to pay for gas on the Movement Network. On the Movement Network both Coin and FA move can be used to initialize accounts and pay for gas. 44 | 45 | 46 | 47 | 48 | 49 | ### Adaptor Addresses on Ethereum Mainnet 50 | 51 | | Adaptor | Address | 52 | |---------|---------| 53 | | MOVE OFT Adapter | `0xf1df43a3053cd18e477233b59a25fc483c2cbe0f` | 54 | | USDC OFT Adapter | `0xc209a627a7B0a19F16A963D9f7281667A2d9eFf2` | 55 | | USDT OFT Adapter | `0x5e87D7e75B272fb7150B4d1a05afb6Bd71474950` | 56 | | WETH OFT Adapter | `0x06E01cB086fea9C644a2C105A9F20cfC21A526e8` | 57 | | WBTC OFT Adapter | `0xa55688C280E725704CFe8Ea30eD33fE5B91cE6a4` | 58 | 59 | ### Ethereum Token Addresses 60 | 61 | | Token | Address | 62 | |-------|---------| 63 | | MOVE | `0x3073f7aAA4DB83f95e9FFf17424F71D4751a3073` | 64 | | USDC | `0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48` | 65 | | USDT | `0xdac17f958d2ee523a2206206994597c13d831ec7` | 66 | | WETH | `0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2` | 67 | | WBTC | `0x2260fac5e5542a773aa44fbcfedf7c193bc2c599` | 68 | 69 | 70 | ### Movement OFT Contract Addresses 71 | 72 | | Token | Address | 73 | |-------|---------| 74 | | MOVE | `0x7e4fd97ef92302eea9b10f74be1d96fb1f1511cf7ed28867b0144ca89c6ebc3c` | 75 | | USDC.e | `0x4d2969d384e440db9f1a51391cfc261d1ec08ee1bdf7b9711a6c05d485a4110a` | 76 | | USDT.e | `0x38cdb3f0afabee56a3393793940d28214cba1f5781e13d5db18fa7079f60ab55` | 77 | | WETH.e | `0x3dfe1ac4574c7dbbe6f1c5ba862de88fc3e7d3cf8eba95ef1abf32b582889e6d` | 78 | | WBTC.e | `0xbdf86868a32dbae96f2cd50ab05b4be43b92e84e793a4fc01b5b460cc38fdc14` | 79 | 80 | ### Movement MOVE Escrow Address: 81 | 82 | `0x42afc6935b692cd286e3087a4464ec516a60dd21c9e355e1b8b0088376501372` 83 | 84 | ### Movement OFT / FA Addresses 85 | 86 | | Token | Address | 87 | |-------|---------| 88 | | MOVE | `0xa` | 89 | | USDC.e | `0x83121c9f9b0527d1f056e21a950d6bf3b9e9e2e8353d0e95ccea726713cbea39` | 90 | | USDT.e | `0x447721a30109c662dde9c73a0c2c9c9c459fb5e5a9c92f03c50fa69737f5d08d` | 91 | | WETH.e | `0x908828f4fb0213d4034c3ded1630bbd904e8a3a6bf3c63270887f0b06653a376` | 92 | | WBTC.e | `0xb06f29f24dde9c6daeec1f930f14a441a8d6c0fbea590725e88b340af3e1939c` | 93 | 94 | 95 | ## Testnet Addresses 96 | 97 | The testnet Bridge currently allows for bridging between Binance Smart Chain Testnet and Movement Bardock Testnet. 98 | 99 | 100 | ### Mock Token Addresses on BSC Testnet 101 | 102 | | Token | Address | 103 | |-------|---------| 104 | | tUsdc | `0x3D40fF7Ff9D5B01Cb5413e7E5C18Aa104A6506a5` | 105 | | tUsdt | `0xC1c94Dde81053612aC602ba39b6AfBd3CfE6a8Bc` | 106 | | tWeth | `0x50e288885258bC62da02d7Bd1e37d5c7B27F814F` | 107 | 108 | ### Bardock OFT Addresses 109 | 110 | | Token | Address | 111 | |-------|---------| 112 | | USDC.e | `0x33987308d6698c3def1f155c8ea394360e9756b0a22e64fb20834327f04a1e42` | 113 | | USDT.e | `0x9cda672762a6f88e4b608428dd063e03aaf6712f0a427923dd0f1416afa1c075` | 114 | | WETH.e | `0x2fa1f2914aa17d239410cb81ab46dd8fa9230272c58bc84e9e8b971eded79ca5` | 115 | -------------------------------------------------------------------------------- /content/docs/general/usingmovement/community-support.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: community-support 3 | title: Community and Support 4 | description: "Get involved with the Movement community and find support resources" 5 | --- 6 | 7 | import React from 'react'; 8 | 9 | ## Get Involved 10 | 11 | - **Validator Program**: Participate in testnet validation 12 | - **Developer Feedback**: Report issues and suggestions 13 | - **Community Testing**: Join coordinated testing efforts 14 | - **Documentation**: Contribute to documentation improvements 15 | 16 | ## Support Channels 17 | 18 | - **[Discord Community](https://discord.gg/movementlabsxyz)** - Real-time support and discussion 19 | - **[Developer Forum](https://forum.movementnetwork.xyz)** - Technical discussions and Q&A 20 | - **[GitHub Issues](https://github.com/movementlabsxyz/movement)** - Bug reports and feature requests 21 | - **Office Hours** - Regular developer support sessions 22 | 23 | ## Stay Updated 24 | 25 | - **[Newsletter](https://movementnetwork.xyz/newsletter)** - Development updates and announcements 26 | - **[Twitter](https://twitter.com/movementlabsxyz)** - Latest news and developments 27 | - **[GitHub](https://github.com/movementlabsxyz/movement)** - Technical updates and releases 28 | -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/addethos.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/addethos.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/addmetamask.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/addmetamask.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image1.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image10.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image11.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image12.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image13.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image14.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image15.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image16.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image17.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image17.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image18.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image18.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image19.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image19.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image2.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image20.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image21.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image21.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image22.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image23.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image23.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image24.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image24.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image25.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image25.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image26.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image26.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image3.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image4.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image5.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image6.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image7.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image8.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/image9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/image9.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx1.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx2.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx3.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx4.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx5.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx6.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/okx7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/okx7.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/imgs/petra_add.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/content/docs/general/usingmovement/imgs/petra_add.png -------------------------------------------------------------------------------- /content/docs/general/usingmovement/meta.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Using Movement", 3 | "pages": ["connect_to_movement", "bridge", "community-support"], 4 | "defaultOpen": true 5 | } -------------------------------------------------------------------------------- /docs/general/intro.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | id: intro 3 | sidebar_position: 1 4 | title: Getting Started 5 | slug: / 6 | description: "Movement Network Documentation" 7 | --- 8 | 9 | import Link from '@docusaurus/Link'; 10 | import React from 'react'; 11 | import CustomDocCardList from '@site/src/components/CustomDocCardList'; 12 | 13 | # Getting Started 14 | 15 | Welcome to Movement! This documentation will help you understand the Movement ecosystem and how to interact with it. 16 | 17 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /lib/cn.ts: -------------------------------------------------------------------------------- 1 | export { twMerge as cn } from 'tailwind-merge'; 2 | -------------------------------------------------------------------------------- /next-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | 4 | // NOTE: This file should not be edited 5 | // see https://nextjs.org/docs/app/api-reference/config/typescript for more information. 6 | -------------------------------------------------------------------------------- /next.config.mjs: -------------------------------------------------------------------------------- 1 | import { createMDX } from 'fumadocs-mdx/next'; 2 | 3 | const withMDX = createMDX(); 4 | 5 | /** @type {import('next').NextConfig} */ 6 | const config = { 7 | reactStrictMode: true, 8 | }; 9 | 10 | export default withMDX(config); 11 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "new-docs", 3 | "version": "0.0.0", 4 | "private": true, 5 | "scripts": { 6 | "build": "next build", 7 | "dev": "next dev --turbo", 8 | "start": "next start", 9 | "postinstall": "fumadocs-mdx" 10 | }, 11 | "dependencies": { 12 | "fumadocs-core": "15.6.1", 13 | "fumadocs-mdx": "11.6.10", 14 | "fumadocs-openapi": "^9.1.8", 15 | "fumadocs-ui": "15.6.1", 16 | "lucide-react": "^0.525.0", 17 | "next": "15.3.4", 18 | "react": "^19.1.0", 19 | "react-dom": "^19.1.0", 20 | "remark": "^15.0.1", 21 | "remark-gfm": "^4.0.1", 22 | "remark-mdx": "^3.1.0", 23 | "shiki": "^3.9.2" 24 | }, 25 | "devDependencies": { 26 | "@tailwindcss/postcss": "^4.1.11", 27 | "@types/mdx": "^2.0.13", 28 | "@types/node": "24.0.7", 29 | "@types/react": "^19.1.8", 30 | "@types/react-dom": "^19.1.6", 31 | "eslint": "^8", 32 | "eslint-config-next": "15.3.4", 33 | "postcss": "^8.5.6", 34 | "tailwindcss": "^4.1.11", 35 | "typescript": "^5.8.3" 36 | }, 37 | "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e" 38 | } 39 | -------------------------------------------------------------------------------- /postcss.config.mjs: -------------------------------------------------------------------------------- 1 | export default { 2 | plugins: { 3 | '@tailwindcss/postcss': {}, 4 | }, 5 | }; 6 | -------------------------------------------------------------------------------- /public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/public/favicon.ico -------------------------------------------------------------------------------- /public/icon-yellow.svg: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /public/img/movementlabs-social-card.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/public/img/movementlabs-social-card.png -------------------------------------------------------------------------------- /public/img/subpage-bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/movementlabsxyz/movement-docs/45801c348854b80ca205483e90225f384a1eb777/public/img/subpage-bg.jpg -------------------------------------------------------------------------------- /scripts/generate-docs.mjs: -------------------------------------------------------------------------------- 1 | import { generateFiles } from 'fumadocs-openapi'; 2 | 3 | void generateFiles({ 4 | // the OpenAPI schema, you can also give it an external URL. 5 | input: ['https://docs.movementnetwork.xyz/spec.yaml'], 6 | output: './content/docs/api/node', 7 | // we recommend to enable it 8 | // make sure your endpoint description doesn't break MDX syntax. 9 | includeDescription: true, 10 | }); -------------------------------------------------------------------------------- /source.config.ts: -------------------------------------------------------------------------------- 1 | import { 2 | defineConfig, 3 | defineDocs, 4 | frontmatterSchema, 5 | metaSchema, 6 | } from 'fumadocs-mdx/config'; 7 | 8 | // You can customise Zod schemas for frontmatter and `meta.json` here 9 | // see https://fumadocs.vercel.app/docs/mdx/collections#define-docs 10 | export const docs = defineDocs({ 11 | docs: { 12 | schema: frontmatterSchema, 13 | }, 14 | meta: { 15 | schema: metaSchema, 16 | }, 17 | }); 18 | 19 | export default defineConfig({ 20 | mdxOptions: { 21 | // MDX options 22 | }, 23 | }); 24 | -------------------------------------------------------------------------------- /src/app/(home)/layout.tsx: -------------------------------------------------------------------------------- 1 | import type { ReactNode } from 'react'; 2 | import { HomeLayout } from 'fumadocs-ui/layouts/home'; 3 | import { baseOptions } from '@/app/layout.config'; 4 | 5 | export default function Layout({ children }: { children: ReactNode }) { 6 | return {children}; 7 | } 8 | -------------------------------------------------------------------------------- /src/app/(home)/page.tsx: -------------------------------------------------------------------------------- 1 | import { redirect } from 'next/navigation'; 2 | 3 | export default function Home() { 4 | redirect('/general'); 5 | } 6 | -------------------------------------------------------------------------------- /src/app/api/[[...slug]]/page.tsx: -------------------------------------------------------------------------------- 1 | import { apiSource } from '@/lib/source'; 2 | import { 3 | DocsPage, 4 | DocsBody, 5 | DocsDescription, 6 | DocsTitle, 7 | } from 'fumadocs-ui/page'; 8 | import { notFound } from 'next/navigation'; 9 | import { createRelativeLink } from 'fumadocs-ui/mdx'; 10 | import { getMDXComponents } from '@/mdx-components'; 11 | import { LLMCopyButton, ViewOptions } from '@/components/ai/page-actions'; 12 | 13 | export default async function Page(props: { 14 | params: Promise<{ slug?: string[] }>; 15 | }) { 16 | const params = await props.params; 17 | 18 | // Handle index page (no slug) and sub-pages 19 | // Based on available pages, we need to use ['api'] for the main api page 20 | const slug = params.slug ? ['api', ...params.slug] : ['api']; 21 | 22 | const page = apiSource.getPage(slug); 23 | if (!page) notFound(); 24 | 25 | const MDXContent = page.data.body; 26 | 27 | // Check if this is the main API index page 28 | const isMainPage = params.slug === undefined || params.slug.length === 0; 29 | 30 | return ( 31 | 32 | {page.data.title} 33 | {page.data.description} 34 | {!isMainPage && ( 35 |
36 | 37 | 41 |
42 | )} 43 | 44 | 50 | 51 |
52 | ); 53 | } 54 | 55 | export async function generateStaticParams() { 56 | return apiSource.generateParams(); 57 | } 58 | 59 | export async function generateMetadata(props: { 60 | params: Promise<{ slug?: string[] }>; 61 | }) { 62 | const params = await props.params; 63 | const slug = params.slug ? ['api', ...params.slug] : ['api']; 64 | const page = apiSource.getPage(slug); 65 | if (!page) notFound(); 66 | 67 | return { 68 | title: page.data.title, 69 | description: page.data.description, 70 | openGraph: { 71 | title: page.data.title, 72 | description: page.data.description, 73 | url: `https://docs.movementnetwork.xyz/api${slug.length > 1 ? '/' + slug.slice(1).join('/') : ''}`, 74 | siteName: 'Movement Docs', 75 | images: [ 76 | { 77 | url: '/img/movementlabs-social-card.png', 78 | width: 1200, 79 | height: 630, 80 | alt: 'Movement Labs Documentation', 81 | }, 82 | ], 83 | locale: 'en_US', 84 | type: 'website', 85 | }, 86 | twitter: { 87 | card: 'summary_large_image', 88 | title: page.data.title, 89 | description: page.data.description, 90 | images: ['/img/movementlabs-social-card.png'], 91 | }, 92 | }; 93 | } -------------------------------------------------------------------------------- /src/app/api/layout.tsx: -------------------------------------------------------------------------------- 1 | import { DocsLayout } from 'fumadocs-ui/layouts/docs'; 2 | import type { ReactNode } from 'react'; 3 | import { baseOptions } from '@/app/layout.config'; 4 | import { apiSource } from '@/lib/source'; 5 | 6 | const sidebarTabs = [ 7 | { 8 | title: 'Build', 9 | description: 'Developer Documentation', 10 | url: '/devs', 11 | }, 12 | { 13 | title: 'Learn', 14 | description: 'General Documentation', 15 | url: '/general', 16 | }, 17 | { 18 | title: 'API', 19 | description: 'API Documentation', 20 | url: '/api', 21 | }, 22 | ]; 23 | 24 | function rewriteUrls(node: any, base: string): any { 25 | const newNode = { ...node }; 26 | if (newNode.url) { 27 | // Check if this is an external URL (starts with http:// or https://) 28 | if (newNode.url.startsWith('http://') || newNode.url.startsWith('https://')) { 29 | // Keep external URLs as-is 30 | return newNode; 31 | } 32 | 33 | const parts = newNode.url.split('/'); 34 | const filtered = parts.filter((p: string) => Boolean(p) && p !== 'api'); 35 | newNode.url = [base, ...filtered].join('/'); 36 | if (!newNode.url.startsWith('/')) newNode.url = '/' + newNode.url; 37 | } 38 | if (newNode.children) { 39 | newNode.children = newNode.children.map((child: any) => rewriteUrls(child, base)); 40 | } 41 | if (newNode.index) { 42 | newNode.index = rewriteUrls(newNode.index, base); 43 | } 44 | return newNode; 45 | } 46 | 47 | const filterTree = (tree: any) => { 48 | if (!tree?.children) return tree; 49 | const apiNode = tree.children.find((child: any) => child.name === 'API'); 50 | const filtered = { 51 | ...tree, 52 | children: apiNode ? [rewriteUrls(apiNode, '/api')] : [], 53 | }; 54 | console.log('Filtered sidebar tree for /api:', JSON.stringify(filtered, null, 2)); 55 | return filtered; 56 | }; 57 | 58 | export default function Layout({ children }: { children: ReactNode }) { 59 | return ( 60 |
61 | 68 | {children} 69 | 70 |
71 | ); 72 | } -------------------------------------------------------------------------------- /src/app/api/search/route.ts: -------------------------------------------------------------------------------- 1 | import { devsSource, generalSource, apiSource } from '@/lib/source'; 2 | import { createFromSource } from 'fumadocs-core/search/server'; 3 | import { loader } from 'fumadocs-core/source'; 4 | import { docs } from '@/.source'; 5 | import { NextRequest } from 'next/server'; 6 | 7 | // Create a combined source for search that includes all sections 8 | const combinedSource = loader({ 9 | baseUrl: '', // No base URL since we'll handle routing manually 10 | source: docs.toFumadocsSource(), 11 | }); 12 | 13 | // Create the base search handler 14 | const baseSearchHandler = createFromSource(combinedSource, { 15 | // https://docs.orama.com/open-source/supported-languages 16 | language: 'english', 17 | }); 18 | 19 | // Custom search result processor to handle URL rewriting 20 | function processSearchResults(results: any[]) { 21 | return results.map(result => { 22 | // Get the original URL from the result 23 | const originalUrl = result.url || ''; 24 | 25 | // Determine the correct base URL based on the path 26 | if (originalUrl.startsWith('devs/')) { 27 | // Remove 'devs/' prefix and add '/devs' base 28 | const pathWithoutDevs = originalUrl.replace('devs/', ''); 29 | result.url = `/devs/${pathWithoutDevs}`; 30 | } else if (originalUrl.startsWith('general/')) { 31 | // Remove 'general/' prefix and add '/general' base 32 | const pathWithoutGeneral = originalUrl.replace('general/', ''); 33 | result.url = `/general/${pathWithoutGeneral}`; 34 | } else if (originalUrl.startsWith('api/')) { 35 | // Remove 'api/' prefix and add '/api' base 36 | const pathWithoutApi = originalUrl.replace('api/', ''); 37 | result.url = `/api/${pathWithoutApi}`; 38 | } else { 39 | // If no section prefix, assume it's a devs page 40 | result.url = `/devs/${originalUrl}`; 41 | } 42 | 43 | return result; 44 | }); 45 | } 46 | 47 | export async function GET(request: NextRequest) { 48 | // Call the base search handler 49 | const response = await baseSearchHandler.GET(request); 50 | 51 | // Get the search results from the response 52 | const data = await response.json(); 53 | 54 | // Process the search results to fix URLs 55 | if (data.results) { 56 | data.results = processSearchResults(data.results); 57 | } 58 | 59 | // Return the modified response 60 | return new Response(JSON.stringify(data), { 61 | status: response.status, 62 | headers: response.headers, 63 | }); 64 | } 65 | -------------------------------------------------------------------------------- /src/app/api/spec/route.ts: -------------------------------------------------------------------------------- 1 | import { NextResponse } from 'next/server'; 2 | import { readFileSync } from 'fs'; 3 | import { join } from 'path'; 4 | 5 | export async function GET() { 6 | try { 7 | const specPath = join(process.cwd(), 'public', 'spec.yaml'); 8 | const specContent = readFileSync(specPath, 'utf-8'); 9 | 10 | return new NextResponse(specContent, { 11 | headers: { 12 | 'Content-Type': 'application/yaml', 13 | 'Cache-Control': 'public, max-age=3600', 14 | }, 15 | }); 16 | } catch (error) { 17 | console.error('Error reading spec file:', error); 18 | return new NextResponse('Spec file not found', { status: 404 }); 19 | } 20 | } -------------------------------------------------------------------------------- /src/app/devs/[[...slug]]/page.tsx: -------------------------------------------------------------------------------- 1 | import { devsSource } from '@/lib/source'; 2 | import { 3 | DocsPage, 4 | DocsBody, 5 | DocsDescription, 6 | DocsTitle, 7 | } from 'fumadocs-ui/page'; 8 | import { notFound } from 'next/navigation'; 9 | import { createRelativeLink } from 'fumadocs-ui/mdx'; 10 | import { getMDXComponents } from '@/mdx-components'; 11 | import { LLMCopyButton, ViewOptions } from '@/components/ai/page-actions'; 12 | 13 | export default async function Page(props: { 14 | params: Promise<{ slug?: string[] }>; 15 | }) { 16 | const params = await props.params; 17 | 18 | // Handle index page (no slug) and sub-pages 19 | // Based on available pages, we need to use ['devs'] for the main devs page 20 | const slug = params.slug ? ['devs', ...params.slug] : ['devs']; 21 | 22 | // Debug: Let's see what pages are available 23 | console.log('Devs slug:', slug); 24 | console.log('Available pages:', devsSource.generateParams()); 25 | 26 | const page = devsSource.getPage(slug); 27 | if (!page) { 28 | console.log('Page not found for slug:', slug); 29 | notFound(); 30 | } 31 | 32 | const MDXContent = page.data.body; 33 | 34 | // Check if this is the main devs index page 35 | const isMainPage = params.slug === undefined || params.slug.length === 0; 36 | 37 | return ( 38 | 39 | {page.data.title} 40 | {page.data.description} 41 | {!isMainPage && ( 42 |
43 | 44 | 48 |
49 | )} 50 | 51 | 57 | 58 |
59 | ); 60 | } 61 | 62 | export async function generateStaticParams() { 63 | return devsSource.generateParams(); 64 | } 65 | 66 | export async function generateMetadata(props: { 67 | params: Promise<{ slug?: string[] }>; 68 | }) { 69 | const params = await props.params; 70 | const slug = params.slug ? ['devs', ...params.slug] : ['devs']; 71 | const page = devsSource.getPage(slug); 72 | if (!page) notFound(); 73 | 74 | return { 75 | title: page.data.title, 76 | description: page.data.description, 77 | openGraph: { 78 | title: page.data.title, 79 | description: page.data.description, 80 | url: `https://docs.movementnetwork.xyz/devs${slug.length > 1 ? '/' + slug.slice(1).join('/') : ''}`, 81 | siteName: 'Movement Docs', 82 | images: [ 83 | { 84 | url: '/img/movementlabs-social-card.png', 85 | width: 1200, 86 | height: 630, 87 | alt: 'Movement Labs Documentation', 88 | }, 89 | ], 90 | locale: 'en_US', 91 | type: 'website', 92 | }, 93 | twitter: { 94 | card: 'summary_large_image', 95 | title: page.data.title, 96 | description: page.data.description, 97 | images: ['/img/movementlabs-social-card.png'], 98 | }, 99 | }; 100 | } -------------------------------------------------------------------------------- /src/app/devs/layout.tsx: -------------------------------------------------------------------------------- 1 | import { DocsLayout } from 'fumadocs-ui/layouts/docs'; 2 | import type { ReactNode } from 'react'; 3 | import { baseOptions } from '@/app/layout.config'; 4 | import { devsSource } from '@/lib/source'; 5 | 6 | const sidebarTabs = [ 7 | { 8 | title: 'Build', 9 | description: 'Developer Documentation', 10 | url: '/devs', 11 | }, 12 | { 13 | title: 'Learn', 14 | description: 'General Documentation', 15 | url: '/general', 16 | }, 17 | { 18 | title: 'API', 19 | description: 'API Documentation', 20 | url: '/api', 21 | }, 22 | ]; 23 | 24 | function rewriteUrls(node: any, base: string): any { 25 | const newNode = { ...node }; 26 | if (newNode.url) { 27 | // Check if this is an external URL (starts with http:// or https://) 28 | if (newNode.url.startsWith('http://') || newNode.url.startsWith('https://')) { 29 | // Keep external URLs as-is 30 | return newNode; 31 | } 32 | 33 | const parts = newNode.url.split('/'); 34 | const filtered = parts.filter((p: string) => Boolean(p) && p !== 'devs' && p !== 'general'); 35 | newNode.url = [base, ...filtered].join('/'); 36 | if (!newNode.url.startsWith('/')) newNode.url = '/' + newNode.url; 37 | } 38 | if (newNode.children) { 39 | newNode.children = newNode.children.map((child: any) => rewriteUrls(child, base)); 40 | } 41 | if (newNode.index) { 42 | newNode.index = rewriteUrls(newNode.index, base); 43 | } 44 | return newNode; 45 | } 46 | 47 | const filterTree = (tree: any) => { 48 | if (!tree?.children) return tree; 49 | const buildNode = tree.children.find((child: any) => child.name === 'Build'); 50 | const filtered = { 51 | ...tree, 52 | children: buildNode ? [rewriteUrls(buildNode, '/devs')] : [], 53 | }; 54 | console.log('Filtered sidebar tree for /devs:', JSON.stringify(filtered, null, 2)); 55 | return filtered; 56 | }; 57 | 58 | export default function Layout({ children }: { children: ReactNode }) { 59 | return ( 60 |
61 | 68 | {children} 69 | 70 |
71 | ); 72 | } -------------------------------------------------------------------------------- /src/app/general/[[...slug]]/page.tsx: -------------------------------------------------------------------------------- 1 | import { generalSource } from '@/lib/source'; 2 | import { 3 | DocsPage, 4 | DocsBody, 5 | DocsDescription, 6 | DocsTitle, 7 | } from 'fumadocs-ui/page'; 8 | import { notFound } from 'next/navigation'; 9 | import { createRelativeLink } from 'fumadocs-ui/mdx'; 10 | import { getMDXComponents } from '@/mdx-components'; 11 | import { LLMCopyButton, ViewOptions } from '@/components/ai/page-actions'; 12 | 13 | export default async function Page(props: { 14 | params: Promise<{ slug?: string[] }>; 15 | }) { 16 | const params = await props.params; 17 | 18 | // Handle index page (no slug) and sub-pages 19 | // Based on available pages, we need to use ['general'] for the main general page 20 | const slug = params.slug ? ['general', ...params.slug] : ['general']; 21 | 22 | const page = generalSource.getPage(slug); 23 | if (!page) notFound(); 24 | 25 | const MDXContent = page.data.body; 26 | 27 | // Check if this is the main general index page 28 | const isMainPage = params.slug === undefined || params.slug.length === 0; 29 | 30 | return ( 31 | 32 | {page.data.title} 33 | {page.data.description} 34 | {!isMainPage && ( 35 |
36 | 37 | 41 |
42 | )} 43 | 44 | 50 | 51 |
52 | ); 53 | } 54 | 55 | export async function generateStaticParams() { 56 | return generalSource.generateParams(); 57 | } 58 | 59 | export async function generateMetadata(props: { 60 | params: Promise<{ slug?: string[] }>; 61 | }) { 62 | const params = await props.params; 63 | const slug = params.slug ? ['general', ...params.slug] : ['general']; 64 | const page = generalSource.getPage(slug); 65 | if (!page) notFound(); 66 | 67 | return { 68 | title: page.data.title, 69 | description: page.data.description, 70 | openGraph: { 71 | title: page.data.title, 72 | description: page.data.description, 73 | url: `https://docs.movementnetwork.xyz/general${slug.length > 1 ? '/' + slug.slice(1).join('/') : ''}`, 74 | siteName: 'Movement Docs', 75 | images: [ 76 | { 77 | url: '/img/movementlabs-social-card.png', 78 | width: 1200, 79 | height: 630, 80 | alt: 'Movement Labs Documentation', 81 | }, 82 | ], 83 | locale: 'en_US', 84 | type: 'website', 85 | }, 86 | twitter: { 87 | card: 'summary_large_image', 88 | title: page.data.title, 89 | description: page.data.description, 90 | images: ['/img/movementlabs-social-card.png'], 91 | }, 92 | }; 93 | } -------------------------------------------------------------------------------- /src/app/general/layout.tsx: -------------------------------------------------------------------------------- 1 | import { DocsLayout } from 'fumadocs-ui/layouts/docs'; 2 | import type { ReactNode } from 'react'; 3 | import { baseOptions } from '@/app/layout.config'; 4 | import { generalSource } from '@/lib/source'; 5 | 6 | const sidebarTabs = [ 7 | { 8 | title: 'Build', 9 | description: 'Developer Documentation', 10 | url: '/devs', 11 | }, 12 | { 13 | title: 'Learn', 14 | description: 'General Documentation', 15 | url: '/general', 16 | }, 17 | { 18 | title: 'API', 19 | description: 'API Documentation', 20 | url: '/api', 21 | }, 22 | ]; 23 | 24 | function rewriteUrls(node: any, base: string): any { 25 | const newNode = { ...node }; 26 | if (newNode.url) { 27 | // Check if this is an external URL (starts with http:// or https://) 28 | if (newNode.url.startsWith('http://') || newNode.url.startsWith('https://')) { 29 | // Keep external URLs as-is 30 | return newNode; 31 | } 32 | 33 | const parts = newNode.url.split('/'); 34 | // Remove any empty strings and the section name (case-insensitive) 35 | const filtered = parts.filter((p: string) => Boolean(p) && p.toLowerCase() !== 'general' && p.toLowerCase() !== 'learn'); 36 | newNode.url = [base, ...filtered].join('/'); 37 | if (!newNode.url.startsWith('/')) newNode.url = '/' + newNode.url; 38 | } 39 | if (newNode.children) { 40 | newNode.children = newNode.children.map((child: any) => rewriteUrls(child, base)); 41 | } 42 | if (newNode.index) { 43 | newNode.index = rewriteUrls(newNode.index, base); 44 | } 45 | return newNode; 46 | } 47 | 48 | export default function Layout({ children }: { children: ReactNode }) { 49 | return ( 50 |
51 | 58 | {children} 59 | 60 |
61 | ); 62 | } -------------------------------------------------------------------------------- /src/app/global.css: -------------------------------------------------------------------------------- 1 | @import 'tailwindcss'; 2 | @import 'fumadocs-ui/css/neutral.css'; 3 | @import 'fumadocs-ui/css/preset.css'; 4 | 5 | /* Theme Configuration */ 6 | :root { 7 | /* Custom Colors */ 8 | --color-primary-50: #fefce8; 9 | --color-primary-100: #fef9c3; 10 | --color-primary-200: #fef08a; 11 | --color-primary-300: #fde047; 12 | --color-primary-400: #facc15; 13 | --color-primary-500: #eab308; 14 | --color-primary-600: #ca8a04; 15 | --color-primary-700: #a16207; 16 | --color-primary-800: #854d0e; 17 | --color-primary-900: #713f12; 18 | 19 | --color-secondary-50: #f8fafc; 20 | --color-secondary-100: #f1f5f9; 21 | --color-secondary-200: #e2e8f0; 22 | --color-secondary-300: #cbd5e1; 23 | --color-secondary-400: #94a3b8; 24 | --color-secondary-500: #64748b; 25 | --color-secondary-600: #475569; 26 | --color-secondary-700: #334155; 27 | --color-secondary-800: #1e293b; 28 | --color-secondary-900: #0f172a; 29 | 30 | /* Movement Brand Colors */ 31 | --color-movement-yellow: #FFDA34; 32 | --color-movement-black: #111111; 33 | 34 | /* Custom Spacing */ 35 | --spacing-18: 4.5rem; 36 | --spacing-88: 22rem; 37 | 38 | /* Custom Border Radius */ 39 | --radius-xl: 0.75rem; 40 | --radius-2xl: 1rem; 41 | } 42 | 43 | /* Movement Card Styles - Updated to match provided design */ 44 | .cardContainer { 45 | --ifm-link-color: #FFFFFF; 46 | --ifm-link-hover-color: #000000; 47 | --ifm-link-hover-decoration: none; 48 | box-shadow: 0 1.5px 3px 0 rgb(0 0 0 / 15%); 49 | border: 1px solid var(--ifm-color-emphasis-200, #ffe666); 50 | transition: all 0.2s ease; 51 | transition-property: border, box-shadow, background; 52 | margin: 0; 53 | width: 100%; 54 | background: #111; 55 | border-radius: 16px; 56 | display: flex; 57 | align-items: center; 58 | gap: 1.5rem; 59 | padding: 2rem; 60 | } 61 | .cardContainer:hover { 62 | background: #FFDA34; 63 | border-color: #FFDA34; 64 | } 65 | .movementIcon { 66 | color: #FFDA34; 67 | width: 48px; 68 | height: 48px; 69 | flex-shrink: 0; 70 | transition: color 0.2s ease; 71 | } 72 | .cardContainer:hover .movementIcon { 73 | color: #000000; 74 | } 75 | .cardTitle { 76 | color: #FFFFFF; 77 | font-size: 1.5rem; 78 | font-weight: 700; 79 | margin-bottom: 0.5rem; 80 | transition: color 0.2s ease; 81 | } 82 | .cardDescription { 83 | color: #FFFFFF; 84 | opacity: 0.8; 85 | font-size: 1.1rem; 86 | transition: color 0.2s ease; 87 | } 88 | .cardContainer:hover .cardTitle, 89 | .cardContainer:hover .cardDescription { 90 | color: #000000; 91 | opacity: 1; 92 | } 93 | .cardsContainer { 94 | display: grid; 95 | grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 96 | gap: 1rem; 97 | padding: 0; 98 | margin: 2rem 0; 99 | } 100 | 101 | /* Movement Card Styling */ 102 | .movement-card { 103 | background: var(--color-movement-black); 104 | color: white; 105 | border-top: 1px solid var(--color-movement-yellow); 106 | border-left: 1px solid; 107 | border-right: 1px solid; 108 | border-bottom: none; 109 | border-image: linear-gradient(to bottom, var(--color-movement-yellow), transparent 90%) 1 100%; 110 | border-image-slice: 1; 111 | border-image-width: 2; 112 | border-image-outset: 0; 113 | border-image-repeat: stretch; 114 | border-radius: 12px; 115 | transition: background 0.3s, color 0.3s; 116 | } 117 | 118 | .movement-card:hover { 119 | background: var(--color-movement-yellow); 120 | color: var(--color-movement-black); 121 | border: none; 122 | border-image: none; 123 | } 124 | 125 | .movement-card .movement-icon { 126 | color: var(--color-movement-yellow) !important; 127 | transition: color 0.3s ease !important; 128 | } 129 | 130 | .movement-card:hover .movement-icon { 131 | color: var(--color-movement-black) !important; 132 | } 133 | 134 | .docs-bg::before { 135 | content: ''; 136 | position: absolute; 137 | top: 0; 138 | left: 0; 139 | right: 0; 140 | height: 300px; 141 | background-image: url('/img/subpage-bg.jpg'); 142 | background-size: cover; 143 | background-position: center; 144 | background-repeat: no-repeat; 145 | opacity: 0.45; 146 | z-index: -1; 147 | pointer-events: none; 148 | width: 100vw; 149 | } 150 | 151 | html:not(.dark) .docs-bg::before { 152 | display: none; 153 | } 154 | 155 | html:not(.dark) .movement-card { 156 | background: #fff; 157 | color: #111; 158 | border-top: 2px solid var(--color-movement-yellow); 159 | border-left: 1px solid #f6e9b6; 160 | border-right: 1px solid #f6e9b6; 161 | border-bottom: none; 162 | border-image: none; 163 | border-radius: 12px; 164 | box-shadow: 0 2px 8px 0 rgba(0,0,0,0.06); 165 | transition: background 0.3s, color 0.3s, box-shadow 0.3s; 166 | } 167 | 168 | html:not(.dark) .movement-card .text-gray-300 { 169 | color: #444 !important; 170 | opacity: 1 !important; 171 | } 172 | 173 | html:not(.dark) .movement-card .text-2xl { 174 | color: #111 !important; 175 | font-weight: 700 !important; 176 | } 177 | 178 | html:not(.dark) .movement-card:hover { 179 | background: var(--color-movement-yellow); 180 | color: #111; 181 | border: none; 182 | border-image: none; 183 | } 184 | 185 | html:not(.dark) .movement-card .movement-icon { 186 | color: var(--color-movement-yellow) !important; 187 | } 188 | 189 | html:not(.dark) .movement-card:hover .movement-icon { 190 | color: #111 !important; 191 | } 192 | 193 | /* Hide color mode/theme toggle button */ 194 | /* [data-theme-toggle], .theme-toggle, .color-mode-toggle { 195 | display: none !important; 196 | } */ 197 | 198 | -------------------------------------------------------------------------------- /src/app/layout.config.tsx: -------------------------------------------------------------------------------- 1 | import type { BaseLayoutProps } from 'fumadocs-ui/layouts/shared'; 2 | import Image from 'next/image'; 3 | import { Github, MessageCircle } from 'lucide-react'; 4 | 5 | /** 6 | * Shared layout configurations 7 | * 8 | * you can customise layouts individually from: 9 | * Home Layout: app/(home)/layout.tsx 10 | * Docs Layout: app/docs/layout.tsx 11 | */ 12 | export const baseOptions: BaseLayoutProps = { 13 | nav: { 14 | title: ( 15 | <> 16 | Movement Labs Logo 23 | Movement Docs 24 | 25 | ), 26 | }, 27 | links: [ 28 | { 29 | type: 'icon', 30 | label: 'GitHub Repository', 31 | icon: , 32 | text: 'GitHub', 33 | url: 'https://github.com/movementlabsxyz/movement-docs', 34 | }, 35 | { 36 | type: 'icon', 37 | label: 'Community Forum', 38 | icon: , 39 | text: 'Forum', 40 | url: 'https://forums.movementnetwork.xyz/', 41 | }, 42 | ], 43 | // see https://fumadocs.dev/docs/ui/navigation/links 44 | }; 45 | -------------------------------------------------------------------------------- /src/app/layout.tsx: -------------------------------------------------------------------------------- 1 | import '@/app/global.css'; 2 | import { RootProvider } from 'fumadocs-ui/provider'; 3 | import { Inter } from 'next/font/google'; 4 | import type { ReactNode } from 'react'; 5 | import type { Metadata } from 'next'; 6 | 7 | const inter = Inter({ 8 | subsets: ['latin'], 9 | }); 10 | 11 | export const metadata: Metadata = { 12 | title: { 13 | default: 'Movement Docs', 14 | template: '%s | Movement Docs', 15 | }, 16 | description: 'Start Building on the Movement Network', 17 | icons: { 18 | icon: [ 19 | { url: '/favicon.ico', sizes: 'any' }, 20 | { url: '/icon-yellow.svg', type: 'image/svg+xml' }, 21 | ], 22 | shortcut: '/favicon.ico', 23 | apple: '/favicon.ico', 24 | }, 25 | openGraph: { 26 | title: 'Movement Docs', 27 | description: 'Start Building on the Movement Network', 28 | url: 'https://docs.movementnetwork.xyz', 29 | siteName: 'Movement Docs', 30 | images: [ 31 | { 32 | url: '/img/movementlabs-social-card.png', 33 | width: 1200, 34 | height: 630, 35 | alt: 'Movement Labs Documentation', 36 | }, 37 | ], 38 | locale: 'en_US', 39 | type: 'website', 40 | }, 41 | twitter: { 42 | card: 'summary_large_image', 43 | title: 'Movement Docs', 44 | description: 'Documentation for Movement Labs - Building the future of blockchain interoperability', 45 | images: ['/img/movementlabs-social-card.png'], 46 | }, 47 | robots: { 48 | index: true, 49 | follow: true, 50 | }, 51 | }; 52 | 53 | export default function Layout({ children }: { children: ReactNode }) { 54 | return ( 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | {children} 63 | 64 | 65 | ); 66 | } 67 | -------------------------------------------------------------------------------- /src/app/llms-full.txt/route.ts: -------------------------------------------------------------------------------- 1 | import { devsSource, generalSource, apiSource } from '@/lib/source'; 2 | import { getLLMText } from '@/lib/get-llm-text'; 3 | 4 | // cached forever 5 | export const revalidate = false; 6 | 7 | export async function GET() { 8 | try { 9 | // Get pages from all sources 10 | const devsPages = devsSource.getPages(); 11 | const generalPages = generalSource.getPages(); 12 | const apiPages = apiSource.getPages(); 13 | 14 | const allPages = [...devsPages, ...generalPages, ...apiPages]; 15 | console.log('Found pages:', allPages.length); 16 | 17 | if (allPages.length === 0) { 18 | return new Response('No pages found', { 19 | headers: { 20 | 'Content-Type': 'text/plain; charset=utf-8', 21 | }, 22 | }); 23 | } 24 | 25 | const scan = allPages.map(getLLMText); 26 | const scanned = await Promise.all(scan); 27 | 28 | return new Response(scanned.join('\n\n'), { 29 | headers: { 30 | 'Content-Type': 'text/plain; charset=utf-8', 31 | }, 32 | }); 33 | } catch (error) { 34 | console.error('Error generating LLM text:', error); 35 | const errorMessage = error instanceof Error ? error.message : 'Unknown error'; 36 | return new Response(`Error generating documentation: ${errorMessage}`, { status: 500 }); 37 | } 38 | } -------------------------------------------------------------------------------- /src/app/llms.mdx/[[...slug]]/route.ts: -------------------------------------------------------------------------------- 1 | import { type NextRequest, NextResponse } from 'next/server'; 2 | import { getLLMText } from '@/lib/get-llm-text'; 3 | import { devsSource, generalSource, apiSource } from '@/lib/source'; 4 | import { notFound } from 'next/navigation'; 5 | 6 | export const revalidate = false; 7 | 8 | export async function GET( 9 | _req: NextRequest, 10 | { params }: { params: Promise<{ slug?: string[] }> }, 11 | ) { 12 | const { slug } = await params; 13 | 14 | // Try to find the page in each source 15 | let page = null; 16 | 17 | if (slug && slug.length > 0) { 18 | // Try devs source first 19 | if (slug[0] === 'devs') { 20 | page = devsSource.getPage(slug); 21 | } 22 | // Try general source 23 | else if (slug[0] === 'general') { 24 | page = generalSource.getPage(slug); 25 | } 26 | // Try API source 27 | else if (slug[0] === 'api') { 28 | page = apiSource.getPage(slug); 29 | } 30 | } 31 | 32 | if (!page) notFound(); 33 | 34 | return new NextResponse(await getLLMText(page), { 35 | headers: { 36 | 'Content-Type': 'text/plain; charset=utf-8', 37 | }, 38 | }); 39 | } 40 | 41 | export function generateStaticParams() { 42 | const devsParams = devsSource.generateParams(); 43 | const generalParams = generalSource.generateParams(); 44 | const apiParams = apiSource.generateParams(); 45 | 46 | return [...devsParams, ...generalParams, ...apiParams]; 47 | } -------------------------------------------------------------------------------- /src/app/not-found.tsx: -------------------------------------------------------------------------------- 1 | import Link from 'next/link' 2 | import { HomeLayout } from 'fumadocs-ui/layouts/home' 3 | import { baseOptions } from '@/app/layout.config' 4 | 5 | export default function NotFound() { 6 | return ( 7 | 8 |
9 |
10 | {/* 404 Number */} 11 |
12 |

13 | 404 14 |

15 |
16 | 17 | {/* Main Content */} 18 |
19 |
20 |

21 | Page Not Found 22 |

23 |

24 | Sorry, the page you're looking for seems to have been moved or deleted. Use the search bar to find what you're looking for or navigate using the links below. 25 |

26 |
27 | 28 | {/* Action Buttons */} 29 |
30 | 34 | Go Home 35 | 36 | 37 | 41 | Developer Docs 42 | 43 |
44 | 45 | {/* Quick Navigation */} 46 |
47 |

Quick Navigation

48 |
49 |
50 | 54 |
55 | 🚀 56 |
57 |

Build

58 | 59 | 60 | 64 |
65 | ℹ️ 66 |
67 |

Learn

68 | 69 |
70 |
71 |
72 | 73 | {/* Help Text */} 74 |
75 |

76 | Can't find what you're looking for? Check out our{' '} 77 | 78 | FAQ 79 | 80 | {' '}or{' '} 81 | 87 | community forum 88 | 89 |

90 |
91 |
92 |
93 |
94 |
95 | ) 96 | } 97 | -------------------------------------------------------------------------------- /src/components/CustomAPIPage.tsx: -------------------------------------------------------------------------------- 1 | import { APIPage } from 'fumadocs-openapi/ui'; 2 | 3 | interface CustomAPIPageProps { 4 | document: string; 5 | operations: any[]; 6 | webhooks?: any[]; 7 | hasHead?: boolean; 8 | } 9 | 10 | export function CustomAPIPage(props: CustomAPIPageProps) { 11 | // Just pass through the props - let the generated files handle the path 12 | return ; 13 | } -------------------------------------------------------------------------------- /src/components/MovementCard.tsx: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { Card } from 'fumadocs-ui/components/card'; 3 | 4 | interface MovementCardProps { 5 | icon?: React.ReactNode; 6 | title: React.ReactNode; 7 | children?: React.ReactNode; 8 | href?: string; 9 | [key: string]: any; 10 | } 11 | 12 | export function MovementCard({ icon, title, children, ...props }: MovementCardProps) { 13 | return ( 14 | 19 |
20 |
21 | {icon} 22 |
23 |
24 |
{children}
25 |
26 |
27 |
28 | ); 29 | } -------------------------------------------------------------------------------- /src/components/MovementIcon.tsx: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | 3 | export default function MovementIcon() { 4 | return ( 5 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | ); 24 | } 25 | -------------------------------------------------------------------------------- /src/lib/get-llm-text.ts: -------------------------------------------------------------------------------- 1 | import { remark } from 'remark'; 2 | import remarkGfm from 'remark-gfm'; 3 | import remarkMdx from 'remark-mdx'; 4 | import { remarkInclude } from 'fumadocs-mdx/config'; 5 | import { docs } from '@/.source'; 6 | import type { Page } from 'fumadocs-core/source'; 7 | 8 | const processor = remark() 9 | .use(remarkMdx) 10 | // needed for Fumadocs MDX 11 | .use(remarkInclude) 12 | .use(remarkGfm); 13 | 14 | export async function getLLMText(page: any) { 15 | try { 16 | // For now, just return the basic page info without processing MDX 17 | return `# ${page.data.title} 18 | URL: ${page.url} 19 | 20 | ${page.data.description} 21 | 22 | [Content available at: ${page.url}]`; 23 | } catch (error) { 24 | console.error('Error processing page:', page.url, error); 25 | return `# ${page.data.title} 26 | URL: ${page.url} 27 | 28 | ${page.data.description} 29 | 30 | [Error processing content]`; 31 | } 32 | } -------------------------------------------------------------------------------- /src/lib/source.ts: -------------------------------------------------------------------------------- 1 | import { docs } from '@/.source'; 2 | import { loader } from 'fumadocs-core/source'; 3 | import { createOpenAPI, attachFile } from 'fumadocs-openapi/server'; 4 | 5 | // See https://fumadocs.vercel.app/docs/headless/source-api for more info 6 | const baseSource = docs.toFumadocsSource(); 7 | 8 | export const devsSource = loader({ 9 | // it assigns a URL to your pages 10 | baseUrl: '/devs', 11 | source: baseSource, 12 | }); 13 | 14 | export const generalSource = loader({ 15 | // it assigns a URL to your pages 16 | baseUrl: '/general', 17 | source: baseSource, 18 | }); 19 | 20 | export const apiSource = loader({ 21 | // it assigns a URL to your pages 22 | baseUrl: '/api', 23 | source: baseSource, 24 | pageTree: { 25 | // adds a badge to each page item in page tree 26 | attachFile, 27 | }, 28 | }); 29 | 30 | export const openapi = createOpenAPI(); 31 | -------------------------------------------------------------------------------- /src/mdx-components.tsx: -------------------------------------------------------------------------------- 1 | import defaultMdxComponents from 'fumadocs-ui/mdx'; 2 | import type { MDXComponents } from 'mdx/types'; 3 | import { MovementCard } from '@/components/MovementCard'; 4 | import { CustomAPIPage } from '@/components/CustomAPIPage'; 5 | 6 | // use this function to get MDX components, you will need it for rendering MDX 7 | export function getMDXComponents(components?: MDXComponents): MDXComponents { 8 | return { 9 | ...defaultMdxComponents, 10 | MovementCard, 11 | APIPage: CustomAPIPage, 12 | ...components, 13 | }; 14 | } 15 | -------------------------------------------------------------------------------- /tailwind.config.js: -------------------------------------------------------------------------------- 1 | /** @type {import('tailwindcss').Config} */ 2 | export default { 3 | content: [ 4 | './src/**/*.{js,ts,jsx,tsx,mdx}', 5 | './content/**/*.{md,mdx}', 6 | ], 7 | theme: { 8 | extend: { 9 | colors: { 10 | // Custom colors 11 | primary: { 12 | 50: '#fefce8', 13 | 100: '#fef9c3', 14 | 200: '#fef08a', 15 | 300: '#fde047', 16 | 400: '#facc15', 17 | 500: '#eab308', 18 | 600: '#ca8a04', 19 | 700: '#a16207', 20 | 800: '#854d0e', 21 | 900: '#713f12', 22 | }, 23 | secondary: { 24 | 50: '#f8fafc', 25 | 100: '#f1f5f9', 26 | 200: '#e2e8f0', 27 | 300: '#cbd5e1', 28 | 400: '#94a3b8', 29 | 500: '#64748b', 30 | 600: '#475569', 31 | 700: '#334155', 32 | 800: '#1e293b', 33 | 900: '#0f172a', 34 | }, 35 | // Movement brand colors 36 | movement: { 37 | yellow: 'var(--color-movement-yellow)', 38 | black: 'var(--color-movement-black)', 39 | }, 40 | }, 41 | fontFamily: { 42 | sans: ['Inter', 'system-ui', 'sans-serif'], 43 | mono: ['JetBrains Mono', 'monospace'], 44 | }, 45 | spacing: { 46 | '18': '4.5rem', 47 | '88': '22rem', 48 | }, 49 | borderRadius: { 50 | 'xl': '0.75rem', 51 | '2xl': '1rem', 52 | }, 53 | }, 54 | }, 55 | plugins: [], 56 | } -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "target": "ESNext", 5 | "lib": [ 6 | "dom", 7 | "dom.iterable", 8 | "esnext" 9 | ], 10 | "allowJs": true, 11 | "skipLibCheck": true, 12 | "strict": true, 13 | "forceConsistentCasingInFileNames": true, 14 | "noEmit": true, 15 | "esModuleInterop": true, 16 | "module": "esnext", 17 | "moduleResolution": "bundler", 18 | "resolveJsonModule": true, 19 | "isolatedModules": true, 20 | "jsx": "preserve", 21 | "incremental": true, 22 | "paths": { 23 | "@/.source": [ 24 | "./.source/index.ts" 25 | ], 26 | "@/*": [ 27 | "./src/*" 28 | ] 29 | }, 30 | "plugins": [ 31 | { 32 | "name": "next" 33 | } 34 | ] 35 | }, 36 | "include": [ 37 | "next-env.d.ts", 38 | "**/*.ts", 39 | "**/*.tsx", 40 | ".next/types/**/*.ts" 41 | ], 42 | "exclude": [ 43 | "node_modules" 44 | ] 45 | } --------------------------------------------------------------------------------