From a879eafa3b003ae7ef25ba8a6c940372a12a7b04 Mon Sep 17 00:00:00 2001 From: Tyler van der Hoeven Date: Wed, 10 Aug 2022 21:20:19 -0400 Subject: [PATCH 1/5] reorder the docs content as well as add basic /api route --- docs/anchoring-assets/_category_.json | 7 + .../_category_.json | 7 + .../enabling-cross-border-payments/index.mdx | 2 +- .../enabling-cross-border-payments/launch.mdx | 2 +- .../metadata.json | 4 - .../reference-implementations.mdx | 8 +- .../setting-up-production-server.mdx | 2 +- .../setting-up-test-server.mdx | 2 +- .../_category_.json | 7 + .../enabling-deposit-and-withdrawal/index.mdx | 2 +- .../launch.mdx | 2 +- .../metadata.json | 4 - .../reference-implementations.mdx | 8 +- .../setting-up-production-server.mdx | 2 +- .../setting-up-test-server.mdx | 4 +- docs/anchoring-assets/index.mdx | 2 +- docs/anchoring-assets/metadata.json | 4 - docs/building-apps/_category_.json | 7 + docs/building-apps/basic-wallet.mdx | 14 +- .../connect-to-anchors/_category_.json | 7 + .../deposit-anchored-assets.mdx | 2 +- .../connect-to-anchors/index.mdx | 2 +- .../connect-to-anchors/metadata.json | 4 - .../setup-for-anchored-assets.mdx | 2 +- .../withdraw-anchored-assets.mdx | 2 +- docs/building-apps/custom-assets.mdx | 2 +- docs/building-apps/first-deposit.mdx | 8 +- docs/building-apps/index.mdx | 2 +- docs/building-apps/key-management.mdx | 2 +- docs/building-apps/metadata.json | 4 - docs/building-apps/project-setup.mdx | 10 +- .../building-apps/setup-custodial-account.mdx | 2 +- docs/building-apps/xlm-payments.mdx | 2 +- docs/glossary/_category_.json | 7 + docs/glossary/accounts.mdx | 1 - docs/glossary/assets.mdx | 1 - docs/glossary/channels.mdx | 1 - docs/glossary/claimable-balance.mdx | 1 - docs/glossary/clawback.mdx | 3 +- docs/glossary/decentralized-exchange.mdx | 3 +- docs/glossary/federation.mdx | 1 - docs/glossary/fee-bumps.mdx | 1 - docs/glossary/fees.mdx | 1 - docs/glossary/inflation.mdx | 1 - docs/glossary/ledger.mdx | 1 - docs/glossary/liquidity-pool.mdx | 1 - docs/glossary/lumen-supply.mdx | 1 - docs/glossary/metadata.json | 5 - docs/glossary/minimum-balance.mdx | 1 - docs/glossary/miscellaneous-core-objects.mdx | 1 - docs/glossary/multisig.mdx | 1 - docs/glossary/muxed-accounts.mdx | 1 - docs/glossary/network-passphrase.mdx | 1 - docs/glossary/operations.mdx | 1 - docs/glossary/scp.mdx | 1 - docs/glossary/sponsored-reserves.mdx | 1 - docs/glossary/testnet.mdx | 1 - docs/glossary/transactions.mdx | 1 - docs/glossary/versioning.mdx | 1 - docs/glossary/xdr.mdx | 1 - docs/index.mdx | 2 +- docs/issuing-assets/_category_.json | 7 + docs/issuing-assets/anatomy-of-an-asset.mdx | 2 +- docs/issuing-assets/control-asset-access.mdx | 2 +- docs/issuing-assets/how-to-issue-an-asset.mdx | 2 +- docs/issuing-assets/index.mdx | 2 +- docs/issuing-assets/metadata.json | 4 - docs/issuing-assets/publishing-asset-info.mdx | 2 +- docs/metadata.json | 4 - docs/run-api-server/_category_.json | 7 + docs/run-api-server/configuring.mdx | 2 +- docs/run-api-server/index.mdx | 2 +- docs/run-api-server/ingestion.mdx | 2 +- docs/run-api-server/installing.mdx | 2 +- docs/run-api-server/metadata.json | 4 - docs/run-api-server/migrating.mdx | 2 +- docs/run-api-server/monitoring.mdx | 2 +- docs/run-api-server/prerequisites.mdx | 2 +- docs/run-api-server/remote-core.mdx | 2 +- docs/run-api-server/running.mdx | 2 +- docs/run-api-server/scaling.mdx | 12 +- docs/run-core-node/_category_.json | 7 + docs/run-core-node/commands.mdx | 2 +- docs/run-core-node/configuring.mdx | 2 +- docs/run-core-node/index.mdx | 2 +- docs/run-core-node/installation.mdx | 2 +- docs/run-core-node/metadata.json | 4 - docs/run-core-node/monitoring.mdx | 2 +- docs/run-core-node/network-upgrades.mdx | 2 +- docs/run-core-node/prerequisites.mdx | 2 +- .../publishing-history-archives.mdx | 2 +- docs/run-core-node/running-node.mdx | 2 +- docs/run-core-node/tier-1-orgs.mdx | 2 +- docs/software-and-sdks/_category_.json | 7 + docs/software-and-sdks/index.mdx | 2 +- docs/software-and-sdks/metadata.json | 4 - docs/start/_category_.json | 7 + docs/start/introduction.mdx | 2 +- docs/start/list-of-operations.mdx | 2 +- docs/start/metadata.json | 4 - docs/start/stellar-stack.mdx | 2 +- docs/tutorials/_category_.json | 7 + docs/tutorials/create-account.mdx | 2 +- docs/tutorials/follow-received-payments.mdx | 2 +- docs/tutorials/handling-errors.mdx | 2 +- docs/tutorials/metadata.json | 4 - .../moneygram-access-integration-guide.mdx | 6 +- docs/tutorials/securing-projects.mdx | 2 +- docs/tutorials/send-and-receive-payments.mdx | 2 +- docusaurus.config.js | 263 ++-- openapi/account.yml | 92 ++ openapi/main.yml | 18 + openapi/multi-file/components/pets.yaml | 145 +++ openapi/multi-file/openapi.yaml | 1062 +++++++++++++++++ package.json | 1 + sidebars.js | 135 +-- .../assets}/SEP24-state-diagram.png | Bin .../assets}/anchor-validation-suite.png | Bin .../assets}/demo-client.png | Bin .../assets}/demo-wallet-sep31.png | Bin .../assets}/demo_wallet_sep24dep.png | Bin .../assets}/first-deposit-anchor-flow.png | Bin .../first-deposit-claimable-balance-flow.png | Bin .../assets}/first-deposit-wallet-flow.png | Bin .../assets}/horizon-scaling/Topology-1VM.png | Bin .../assets}/horizon-scaling/Topology-2VMs.png | Bin .../assets}/horizon-scaling/Topology-3VMs.png | Bin .../Topology-Enterprise-HotBackup.png | Bin .../horizon-scaling/Topology-Enterprise.png | Bin .../assets}/orderbook.png | Bin .../web-assets => static/assets}/polaris.png | Bin .../assets}/ready-to-rock.png | Bin .../assets}/select-currency.png | Bin .../assets}/stellar-wallet-file.png | Bin .../assets}/wallet-mgi-architecture-1.png | Bin .../assets}/wallet-mgi-architecture-2.png | Bin yarn.lock | 697 ++++++++++- 137 files changed, 2319 insertions(+), 432 deletions(-) create mode 100644 docs/anchoring-assets/_category_.json create mode 100644 docs/anchoring-assets/enabling-cross-border-payments/_category_.json delete mode 100644 docs/anchoring-assets/enabling-cross-border-payments/metadata.json create mode 100644 docs/anchoring-assets/enabling-deposit-and-withdrawal/_category_.json delete mode 100644 docs/anchoring-assets/enabling-deposit-and-withdrawal/metadata.json delete mode 100644 docs/anchoring-assets/metadata.json create mode 100644 docs/building-apps/_category_.json create mode 100644 docs/building-apps/connect-to-anchors/_category_.json delete mode 100644 docs/building-apps/connect-to-anchors/metadata.json delete mode 100644 docs/building-apps/metadata.json create mode 100644 docs/glossary/_category_.json delete mode 100644 docs/glossary/metadata.json create mode 100644 docs/issuing-assets/_category_.json delete mode 100644 docs/issuing-assets/metadata.json delete mode 100644 docs/metadata.json create mode 100644 docs/run-api-server/_category_.json delete mode 100644 docs/run-api-server/metadata.json create mode 100644 docs/run-core-node/_category_.json delete mode 100644 docs/run-core-node/metadata.json create mode 100644 docs/software-and-sdks/_category_.json delete mode 100644 docs/software-and-sdks/metadata.json create mode 100644 docs/start/_category_.json delete mode 100644 docs/start/metadata.json create mode 100644 docs/tutorials/_category_.json delete mode 100644 docs/tutorials/metadata.json create mode 100644 openapi/account.yml create mode 100644 openapi/main.yml create mode 100644 openapi/multi-file/components/pets.yaml create mode 100644 openapi/multi-file/openapi.yaml rename {docs/web-assets => static/assets}/SEP24-state-diagram.png (100%) rename {docs/web-assets => static/assets}/anchor-validation-suite.png (100%) rename {docs/web-assets => static/assets}/demo-client.png (100%) rename {docs/web-assets => static/assets}/demo-wallet-sep31.png (100%) rename {docs/web-assets => static/assets}/demo_wallet_sep24dep.png (100%) rename {docs/web-assets => static/assets}/first-deposit-anchor-flow.png (100%) rename {docs/web-assets => static/assets}/first-deposit-claimable-balance-flow.png (100%) rename {docs/web-assets => static/assets}/first-deposit-wallet-flow.png (100%) rename {docs/web-assets => static/assets}/horizon-scaling/Topology-1VM.png (100%) rename {docs/web-assets => static/assets}/horizon-scaling/Topology-2VMs.png (100%) rename {docs/web-assets => static/assets}/horizon-scaling/Topology-3VMs.png (100%) rename {docs/web-assets => static/assets}/horizon-scaling/Topology-Enterprise-HotBackup.png (100%) rename {docs/web-assets => static/assets}/horizon-scaling/Topology-Enterprise.png (100%) rename {docs/web-assets => static/assets}/orderbook.png (100%) rename {docs/web-assets => static/assets}/polaris.png (100%) rename {docs/web-assets => static/assets}/ready-to-rock.png (100%) rename {docs/web-assets => static/assets}/select-currency.png (100%) rename {docs/web-assets => static/assets}/stellar-wallet-file.png (100%) rename {docs/web-assets => static/assets}/wallet-mgi-architecture-1.png (100%) rename {docs/web-assets => static/assets}/wallet-mgi-architecture-2.png (100%) diff --git a/docs/anchoring-assets/_category_.json b/docs/anchoring-assets/_category_.json new file mode 100644 index 000000000..6f48b048c --- /dev/null +++ b/docs/anchoring-assets/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 40, + "label": "Anchor Assets", + "link": { + "type": "generated-index" + } +} \ No newline at end of file diff --git a/docs/anchoring-assets/enabling-cross-border-payments/_category_.json b/docs/anchoring-assets/enabling-cross-border-payments/_category_.json new file mode 100644 index 000000000..e05b3bb19 --- /dev/null +++ b/docs/anchoring-assets/enabling-cross-border-payments/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 20, + "label": "Enable Cross-border Payments", + "link": { + "type": "doc", "id": "index" + } +} \ No newline at end of file diff --git a/docs/anchoring-assets/enabling-cross-border-payments/index.mdx b/docs/anchoring-assets/enabling-cross-border-payments/index.mdx index b3b212f50..9b78cd88c 100644 --- a/docs/anchoring-assets/enabling-cross-border-payments/index.mdx +++ b/docs/anchoring-assets/enabling-cross-border-payments/index.mdx @@ -1,6 +1,6 @@ --- title: Overview -order: 10 +sidebar_position: 10 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/anchoring-assets/enabling-cross-border-payments/launch.mdx b/docs/anchoring-assets/enabling-cross-border-payments/launch.mdx index ed5b34812..2f9cedc57 100644 --- a/docs/anchoring-assets/enabling-cross-border-payments/launch.mdx +++ b/docs/anchoring-assets/enabling-cross-border-payments/launch.mdx @@ -1,6 +1,6 @@ --- title: Launch -order: 50 +sidebar_position: 50 --- Once the testnet and mainnet servers are deployed, KYC collection conforms to regulations, banking rails are integrated, and the whole system is audited, it's time to prepare for launch. diff --git a/docs/anchoring-assets/enabling-cross-border-payments/metadata.json b/docs/anchoring-assets/enabling-cross-border-payments/metadata.json deleted file mode 100644 index 9209772f9..000000000 --- a/docs/anchoring-assets/enabling-cross-border-payments/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "title": "Enable Cross-border Payments", - "order": 30 -} diff --git a/docs/anchoring-assets/enabling-cross-border-payments/reference-implementations.mdx b/docs/anchoring-assets/enabling-cross-border-payments/reference-implementations.mdx index bbaf301bf..005ca0a19 100644 --- a/docs/anchoring-assets/enabling-cross-border-payments/reference-implementations.mdx +++ b/docs/anchoring-assets/enabling-cross-border-payments/reference-implementations.mdx @@ -1,6 +1,6 @@ --- title: Tools and References -order: 20 +sidebar_position: 20 --- These docs walk through the steps necessary to set up and launch both a test server and a production server for SEP-31 cross-border payments, but before you get any deeper, it's worth noting: you don't have to start from scratch. SDF offers some tools that make it easy to implement those servers, and test them from the sending anchor (**SA**) side. @@ -9,7 +9,7 @@ These docs walk through the steps necessary to set up and launch both a test ser To help with server setup, SDF created [Polaris](https://github.com/stellar/django-polaris), an extendable django reusable-app that comes with fully-implemented endpoints, templates, and database models. It's built in Python using the community-supported [Stellar Python SDK](https://github.com/StellarCN/py-stellar-base), and is compliant with the Stellar Ecosystem Protocols mentioned in the previous section. -TODO: REPLACE PNG ![Screenshots of the reference implementation](../../web-assets/polaris.png) +TODO: REPLACE PNG ![Screenshots of the reference implementation](/assets/polaris.png) Polaris modularizes the parts of the codebase that interface with the Stellar network, and provides clear methods for developers to integrate their own customer registrations, banking connections, and KYC and transcation processing. That means you can focus on implementing the business- and country-related aspects of your product without having to spend much time defining how to connect the server to the Stellar Network. @@ -21,7 +21,7 @@ Once you have a server set up, SDF also maintains a [Demo Wallet Project](https: This allows you to run through your receiving anchor's flow by entering information to a fake wallet application like a real sending user would. -![Screenshot of the demo client](../../web-assets/demo-wallet-sep31.png) +![Screenshot of the demo client](/assets/demo-wallet-sep31.png) With the demo client, you can test your payment flows, and get information about the transactions that are created during those processes. It gives a clear step-by-step visual example of how the functionalities work along with insightful information about the requests, protocols, and possible validation messages. To start testing the deploys, simply update the settings of the Demo Client (click the gear button on the bottom right) to include your project's information. @@ -29,6 +29,6 @@ With the demo client, you can test your payment flows, and get information about The Anchor Validation Suite is a set of tests that helps confirming if your anchor implementation is compliant with the latest specifications of the SEP-31 standard. This is a great resource for people that are getting started building an anchor and want to check what's still missing in their implementation, or for teams that have already finalized the anchor development and want an extra validation on the codebase. Also, the Anchor Validation Suite doesn't replace the necessity of having a professional security auditor reviewing the whole project. -TODO: REPLACE PNG ![Screenshot of the Anchor Validation Suite's UI](../../web-assets/anchor-validation-suite.png) +TODO: REPLACE PNG ![Screenshot of the Anchor Validation Suite's UI](/assets/anchor-validation-suite.png) The Anchor Validation Suite codebase is available in an open-sourced [Github Repository](https://github.com/stellar/transfer-server-validator/), where you can check in details exactly how all tests work. SDF also maintains a [deployed version of the Validation Suite](http://anchor-validator.stellar.org/) with a UI for running the tests without the need to setup your own infrastructure. In order to also test the interactive parts of SEP-24, you'll need to add test values to all the required interactive flow fields. The [Github Repository Readme file](https://github.com/stellar/transfer-server-validator/#providing-field-values) has more information on how exactly those fields need to be added. Finally, you can also trigger the tests directly from a Continuous Integration tool (like CircleCI or Jenkins), in order to have continuous monitoring of your anchor infrastructure. diff --git a/docs/anchoring-assets/enabling-cross-border-payments/setting-up-production-server.mdx b/docs/anchoring-assets/enabling-cross-border-payments/setting-up-production-server.mdx index c4c74ec85..bb4bf03fa 100644 --- a/docs/anchoring-assets/enabling-cross-border-payments/setting-up-production-server.mdx +++ b/docs/anchoring-assets/enabling-cross-border-payments/setting-up-production-server.mdx @@ -1,6 +1,6 @@ --- title: Deploy a Production Version on Mainnet -order: 40 +sidebar_position: 40 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/anchoring-assets/enabling-cross-border-payments/setting-up-test-server.mdx b/docs/anchoring-assets/enabling-cross-border-payments/setting-up-test-server.mdx index 014d292f1..1961f8120 100644 --- a/docs/anchoring-assets/enabling-cross-border-payments/setting-up-test-server.mdx +++ b/docs/anchoring-assets/enabling-cross-border-payments/setting-up-test-server.mdx @@ -1,6 +1,6 @@ --- title: Build a SEP-31 Anchor on Testnet -order: 30 +sidebar_position: 30 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/_category_.json b/docs/anchoring-assets/enabling-deposit-and-withdrawal/_category_.json new file mode 100644 index 000000000..cedf70c2c --- /dev/null +++ b/docs/anchoring-assets/enabling-deposit-and-withdrawal/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 30, + "label": "Enable Deposits and Withdrawals", + "link": { + "type": "doc", "id": "index" + } +} \ No newline at end of file diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/index.mdx b/docs/anchoring-assets/enabling-deposit-and-withdrawal/index.mdx index f48cb81ea..86016a80b 100644 --- a/docs/anchoring-assets/enabling-deposit-and-withdrawal/index.mdx +++ b/docs/anchoring-assets/enabling-deposit-and-withdrawal/index.mdx @@ -1,6 +1,6 @@ --- title: "SEP-24: Deposits & Withdrawals" -order: 10 +sidebar_position: 10 --- Supporting deposits and withdrawals of an asset on and off the Stellar network requires cooperation between wallet (client) and anchor (server) applications. In this section, we'll only go over the steps necessary for building a SEP-24 server, but we also have documentation for [building a wallet](../../building-apps/index.mdx). diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/launch.mdx b/docs/anchoring-assets/enabling-deposit-and-withdrawal/launch.mdx index f5ed1fe80..10096333c 100644 --- a/docs/anchoring-assets/enabling-deposit-and-withdrawal/launch.mdx +++ b/docs/anchoring-assets/enabling-deposit-and-withdrawal/launch.mdx @@ -1,6 +1,6 @@ --- title: Launch -order: 50 +sidebar_position: 50 --- Once the testnet and mainnet servers are deployed, KYC collection conforms to regulations, banking rails are integrated, and the whole system is audited, it's time to prepare for launch. diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/metadata.json b/docs/anchoring-assets/enabling-deposit-and-withdrawal/metadata.json deleted file mode 100644 index 13f879bdf..000000000 --- a/docs/anchoring-assets/enabling-deposit-and-withdrawal/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "title": "Enable Deposits and Withdrawals", - "order": 20 -} diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/reference-implementations.mdx b/docs/anchoring-assets/enabling-deposit-and-withdrawal/reference-implementations.mdx index e96b4892f..d3312aa9b 100644 --- a/docs/anchoring-assets/enabling-deposit-and-withdrawal/reference-implementations.mdx +++ b/docs/anchoring-assets/enabling-deposit-and-withdrawal/reference-implementations.mdx @@ -1,6 +1,6 @@ --- title: Tools and References -order: 20 +sidebar_position: 20 --- These docs walk through the steps necessary to set up and launch both a test server and a production server to handle deposits and withdrawals, but before you get any deeper, it's worth noting: you don't have to start from scratch. SDF offers some tools that make it easy to implement those servers, and test them from the client side. @@ -9,7 +9,7 @@ These docs walk through the steps necessary to set up and launch both a test ser To help with server setup, SDF created [Polaris](https://github.com/stellar/django-polaris), an extendable django reusable-app that comes with fully-implemented endpoints, templates, and database models. It's built in Python using the community-supported [Stellar Python SDK](https://github.com/StellarCN/py-stellar-base), and is compliant with the Stellar Ecosystem Protocols mentioned in the previous section. -![Screenshots of the reference implementation](../../web-assets/polaris.png) +![Screenshots of the reference implementation](/assets/polaris.png) Polaris modularizes the parts of the codebase that interface with the Stellar network, and provides clear methods for developers to integrate their own deposit and withdrawal forms, KYC process, and banking rails connections. That means you can focus on implementing the business- and country-related aspects of your product without having to spend much time defining how to connect the server to the Stellar Network. @@ -21,7 +21,7 @@ Once you have a server set up, SDF also maintains a [Demo Wallet Project](https: This allows you to run those tests with a UI without needing to set up a new hosting infrastructure for that project. -![Screenshot of the demo wallet](../../web-assets/demo_wallet_sep24dep.png) +![Screenshot of the demo wallet](/assets/demo_wallet_sep24dep.png) With the demo client, you can test your deposit and withdraw flows, and get information about the transactions that are created during those processes. It gives a clear step-by-step visual example of how the functionalities work along with insightful information about the requests, protocols, and possible validation messages. To start testing the deploys, simply update the settings of the Demo Client (click the gear button on the bottom right) to include your project's information. @@ -29,6 +29,6 @@ With the demo client, you can test your deposit and withdraw flows, and get info The SEP-24 Anchor Validation Suite is a set of tests that helps confirming if your anchor implementation is compliant with the latest specifications of the SEP-24 standard. This is a great resource for people that are getting started building an anchor and want to check what's still missing in their implementation, or for teams that have already finalized the anchor development and want an extra validation on the codebase. Also, the Anchor Validation Suite doesn't replace the necessity of having a professional security auditor reviewing the whole project. -![Screenshot of the Anchor Validation Suite's UI](../../web-assets/anchor-validation-suite.png) +![Screenshot of the Anchor Validation Suite's UI](/assets/anchor-validation-suite.png) The SEP-24 Anchor Validation Suite codebase is available in an open-sourced [Github Repository](https://github.com/stellar/transfer-server-validator/), where you can check in details exactly how all tests work. SDF also maintains a [deployed version of the Validation Suite](http://anchor-validator.stellar.org/) with a UI for running the tests without the need to setup your own infrastructure. In order to also test the interactive parts of SEP-24, you'll need to add test values to all the required interactive flow fields. The [Github Repository Readme file](https://github.com/stellar/transfer-server-validator/#providing-field-values) has more information on how exactly those fields need to be added. Finally, you can also trigger the tests directly from a Continuous Integration tool (like CircleCI or Jenkins), in order to have continuous monitoring of your anchor infrastructure. diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-production-server.mdx b/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-production-server.mdx index 04c204f10..5c7d224be 100644 --- a/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-production-server.mdx +++ b/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-production-server.mdx @@ -1,6 +1,6 @@ --- title: Set Up a Production Server -order: 40 +sidebar_position: 40 --- Once the test server is live and you have tested both deposit and withdraw flows, it's time to get started with the real deploy connected to real KYC and real banking rails providers. Before using any banking APIs, it's critical that you perform a full security audit on the system to make sure that there aren't any vulnerabilities. diff --git a/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-test-server.mdx b/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-test-server.mdx index 81357e139..e5fa02545 100644 --- a/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-test-server.mdx +++ b/docs/anchoring-assets/enabling-deposit-and-withdrawal/setting-up-test-server.mdx @@ -1,6 +1,6 @@ --- title: Set Up a Test Server -order: 30 +sidebar_position: 30 --- import { CodeExample } from "@site/src/components/CodeExample"; @@ -177,7 +177,7 @@ Wallets poll the `/transaction` endpoint when waiting for a transaction’s stat Wallets need access to the transactions associated with the user’s account for displaying history or past activity. This can be accomplished with a `/transactions` endpoint. Wallets may also use this endpoint after making a POST request to `/transactions/deposit/interactive` to make sure a transaction was successfully created. -![Status Diagram of SEP-24 transactions](../../web-assets/SEP24-state-diagram.png) +![Status Diagram of SEP-24 transactions](/assets/SEP24-state-diagram.png) ### Transactions History Endpoint diff --git a/docs/anchoring-assets/index.mdx b/docs/anchoring-assets/index.mdx index 3a2b50150..192aad504 100644 --- a/docs/anchoring-assets/index.mdx +++ b/docs/anchoring-assets/index.mdx @@ -1,6 +1,6 @@ --- title: Overview -order: 0 +sidebar_position: 0 --- _Stellar Anchors_ are the on/off ramps of the Stellar network: they accept deposits of fiat currencies (such as USD, CNY, and BRL) via existing rails (such as bank deposits or cash-in points), and send a user the equivalent digital tokens representing those deposits on the Stellar network. On the flipside, they allow holders to redeem those tokens for the real-world assets they represent. To read more about the kinds of things you can do with digital fiat currency, check out [this explainer](https://www.stellar.org/learn/the-power-of-stellar). diff --git a/docs/anchoring-assets/metadata.json b/docs/anchoring-assets/metadata.json deleted file mode 100644 index 011acab4d..000000000 --- a/docs/anchoring-assets/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 40, - "title": "Anchor Assets" -} diff --git a/docs/building-apps/_category_.json b/docs/building-apps/_category_.json new file mode 100644 index 000000000..9647fd8e1 --- /dev/null +++ b/docs/building-apps/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 50, + "label": "Build Apps", + "link": { + "type": "generated-index" + } +} \ No newline at end of file diff --git a/docs/building-apps/basic-wallet.mdx b/docs/building-apps/basic-wallet.mdx index 554756420..42bc9e226 100644 --- a/docs/building-apps/basic-wallet.mdx +++ b/docs/building-apps/basic-wallet.mdx @@ -1,6 +1,6 @@ --- title: Create a Basic Wallet -order: 40 +sidebar_position: 40 --- import { CodeExample } from "@site/src/components/CodeExample"; @@ -45,7 +45,7 @@ Call it `stellar-prompt`, and deselect both test files leaving only the styling. font-size: 15px; .prompt-wrapper { - position: absolute; + sidebar_position: absolute; top: 0; left: 0; bottom: 0; @@ -64,7 +64,7 @@ Call it `stellar-prompt`, and deselect both test files leaving only the styling. padding: 20px; max-width: 350px; width: 100%; - position: relative; + sidebar_position: relative; p { margin-bottom: 10px; @@ -74,7 +74,7 @@ Call it `stellar-prompt`, and deselect both test files leaving only the styling. margin: 0; padding: 5px; outline: none; - border: 1px solid black; + bsidebar_position: 1px solid black; text-transform: uppercase; &:focus { @@ -83,7 +83,7 @@ Call it `stellar-prompt`, and deselect both test files leaving only the styling. } } .select-wrapper { - position: relative; + sidebar_position: relative; display: inline-flex; select { @@ -95,7 +95,7 @@ Call it `stellar-prompt`, and deselect both test files leaving only the styling. &:after, &:before { font-size: 12px; - position: absolute; + sidebar_position: absolute; right: 10px; color: blue; } @@ -121,7 +121,7 @@ Call it `stellar-prompt`, and deselect both test files leaving only the styling. } .cancel { background: none; - border: 1px solid blue; + bsidebar_position: 1px solid blue; color: blue; } .submit { diff --git a/docs/building-apps/connect-to-anchors/_category_.json b/docs/building-apps/connect-to-anchors/_category_.json new file mode 100644 index 000000000..26c36affb --- /dev/null +++ b/docs/building-apps/connect-to-anchors/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 70, + "label": "Deposit and Withdraw From Anchors", + "link": { + "type": "generated-index" + } +} \ No newline at end of file diff --git a/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx b/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx index a15de4406..c75e836b2 100644 --- a/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx +++ b/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx @@ -1,6 +1,6 @@ --- title: Deposit Anchored Assets -order: 20 +sidebar_position: 20 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/building-apps/connect-to-anchors/index.mdx b/docs/building-apps/connect-to-anchors/index.mdx index ae06fb605..2857644ef 100644 --- a/docs/building-apps/connect-to-anchors/index.mdx +++ b/docs/building-apps/connect-to-anchors/index.mdx @@ -1,6 +1,6 @@ --- title: Interoperability Basics -order: 0 +sidebar_position: 0 --- Stellar makes it easy to issue assets and to connect them to existing banking rails so that users can move value onto — and off of — the network. The services that create those connections are called **anchors**, and you can read all about how they work and what they do in [Enable Deposit and Withdrawal](../../anchoring-assets/enabling-deposit-and-withdrawal/index.mdx). diff --git a/docs/building-apps/connect-to-anchors/metadata.json b/docs/building-apps/connect-to-anchors/metadata.json deleted file mode 100644 index 930f2b0a1..000000000 --- a/docs/building-apps/connect-to-anchors/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 70, - "title": "Deposit and Withdraw From Anchors" -} diff --git a/docs/building-apps/connect-to-anchors/setup-for-anchored-assets.mdx b/docs/building-apps/connect-to-anchors/setup-for-anchored-assets.mdx index 2dd944169..bbf10b5a9 100644 --- a/docs/building-apps/connect-to-anchors/setup-for-anchored-assets.mdx +++ b/docs/building-apps/connect-to-anchors/setup-for-anchored-assets.mdx @@ -1,6 +1,6 @@ --- title: Setup for Anchored Assets -order: 10 +sidebar_position: 10 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx b/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx index 92a2abb11..35f698dec 100644 --- a/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx +++ b/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx @@ -1,6 +1,6 @@ --- title: Withdraw Anchored Assets -order: 30 +sidebar_position: 30 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/building-apps/custom-assets.mdx b/docs/building-apps/custom-assets.mdx index dac84c93f..f4d7b82c6 100644 --- a/docs/building-apps/custom-assets.mdx +++ b/docs/building-apps/custom-assets.mdx @@ -1,6 +1,6 @@ --- title: Handle Custom Assets -order: 60 +sidebar_position: 60 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/building-apps/first-deposit.mdx b/docs/building-apps/first-deposit.mdx index 95f2b7378..a19fae1a6 100644 --- a/docs/building-apps/first-deposit.mdx +++ b/docs/building-apps/first-deposit.mdx @@ -1,6 +1,6 @@ --- title: Fund the Account and make the First Deposit -order: 65 +sidebar_position: 65 --- In this section, we will go over the new user account creation flow between non-custodial wallets and anchors with SEP-24 and/or SEP-6 implementations. Before we dive into the flow, it’s important to understand how Stellar accounts are created in the first place. @@ -26,7 +26,7 @@ For this option, the wallet needs to allow users to initiate their first deposit **Note**: An anchor should always maintain a healthy amount of XLM in its distribution account to support new account creations. If doing so becomes unsustainable, it’s recommended that the anchor collaborates with wallets to determine a strategy based on the number of account creation requests. The recommended amount is 2XLM per user account creation (1XLM to meet the minimum balance requirement, and 1XLM for establishing trustlines and covering transaction fees). -![anchor creates account flow](../web-assets/first-deposit-anchor-flow.png) +![anchor creates account flow](/assets/first-deposit-anchor-flow.png) With the flow described above, the wallet and the anchor have to facilitate listening for and responding to the trustline status, which can create user experience frictions when waiting for the trustline to be established. To address this issue, Protocol 15 introduced [Claimable Balances](../glossary/claimable-balance.mdx), which enhance the flow by allowing users to start using the wallet without having to secure XLM wait to create the trustline after they made their first deposit. Both the wallet and the anchor have to implement Claimable Balance support in order to make this flow work. @@ -40,7 +40,7 @@ The flow with Claimable Balances looks like this: 1. The anchor creates a Claimable Balance. 1. The wallet detects the Claimable Balance for the account, claims the funds, and posts it in the wallet. -![anchor creates account claimable balance flow](../web-assets/first-deposit-claimable-balance-flow.png) +![anchor creates account claimable balance flow](/assets/first-deposit-claimable-balance-flow.png) ### Option 2: The wallet creates and funds the Stellar account upon user sign-up @@ -55,6 +55,6 @@ The flow looks like this: 1. The anchor receives the funds, then sends them to the user’s Stellar account. 1. The wallet detects that funds were sent and notifies the user. -![wallet creates account flow](../web-assets/first-deposit-wallet-flow.png) +![wallet creates account flow](/assets/first-deposit-wallet-flow.png) **Note**: In the examples above, we suggest having the anchor or wallet cover minimum balance and trustline XLM requirements by depositing funds directly into a user's account. We made that suggestion for the sake of simplicity, but in all cases, the anchor or wallet could instead use [Sponsored Reserves](../glossary/sponsored-reserves.mdx) to ensure that when a user closes a trustline or merges their account, the reserve reverts to the sponsoring account rather than to the user's account. diff --git a/docs/building-apps/index.mdx b/docs/building-apps/index.mdx index 85ecac084..225000640 100644 --- a/docs/building-apps/index.mdx +++ b/docs/building-apps/index.mdx @@ -1,6 +1,6 @@ --- title: Overview -order: 0 +sidebar_position: 0 --- Stellar is a self-serve distributed ledger that you can use as a backend to power all kinds of apps and services. It has built-in logic for creating accounts, signing transactions, and tracking balances, and anyone can use it to issue, store, transfer, and trade assets. Since many of those assets connect to real-world currencies, and since there are open protocols for integrating deposit and withdrawal of those assets, a Stellar-based app can take advantage of real banking rails and connect to real money. diff --git a/docs/building-apps/key-management.mdx b/docs/building-apps/key-management.mdx index c5d6c66b6..f8d702403 100644 --- a/docs/building-apps/key-management.mdx +++ b/docs/building-apps/key-management.mdx @@ -1,6 +1,6 @@ --- title: Key Management Basics -order: 30 +sidebar_position: 30 --- Step one for any app is to sort out user onboarding. Since a Stellar wallet is an interface that gives a user access to an account stored on the ledger, and since that access is controlled by the account's secret key, the first thing you have to decide is how to handle a user's secret key, and how to append the Stellar account it unlocks to a user object. diff --git a/docs/building-apps/metadata.json b/docs/building-apps/metadata.json deleted file mode 100644 index 81d0c1c37..000000000 --- a/docs/building-apps/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 50, - "title": "Build Apps" -} diff --git a/docs/building-apps/project-setup.mdx b/docs/building-apps/project-setup.mdx index 64cc85522..af75fa05b 100644 --- a/docs/building-apps/project-setup.mdx +++ b/docs/building-apps/project-setup.mdx @@ -1,6 +1,6 @@ --- title: Project Setup -order: 20 +sidebar_position: 20 --- import { CodeExample } from "@site/src/components/CodeExample"; @@ -225,7 +225,7 @@ With that file saved, pop over to the `src/components/wallet/` and rename the `w } stellar-loader { - position: absolute; + sidebar_position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); @@ -323,7 +323,7 @@ audio, video { margin: 0; padding: 0; - border: 0; + bsidebar_position: 0; font-size: 100%; font: inherit; vertical-align: baseline; @@ -384,9 +384,9 @@ button { height: 30px; } button { - border: none; + bsidebar_position: none; appearance: none; - position: relative; + sidebar_position: relative; background-color: blue; color: white; margin: 0; diff --git a/docs/building-apps/setup-custodial-account.mdx b/docs/building-apps/setup-custodial-account.mdx index 62e46d557..a6d3dde8d 100644 --- a/docs/building-apps/setup-custodial-account.mdx +++ b/docs/building-apps/setup-custodial-account.mdx @@ -1,6 +1,6 @@ --- title: Set Up a Custodial Account -order: 45 +sidebar_position: 45 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/building-apps/xlm-payments.mdx b/docs/building-apps/xlm-payments.mdx index 3163d72b0..64f1dd8c6 100644 --- a/docs/building-apps/xlm-payments.mdx +++ b/docs/building-apps/xlm-payments.mdx @@ -1,6 +1,6 @@ --- title: Make XLM Payments -order: 50 +sidebar_position: 50 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/_category_.json b/docs/glossary/_category_.json new file mode 100644 index 000000000..2c7cae430 --- /dev/null +++ b/docs/glossary/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 90, + "label": "Glossary", + "link": { + "type": "generated-index" + } +} \ No newline at end of file diff --git a/docs/glossary/accounts.mdx b/docs/glossary/accounts.mdx index fe763062c..20f877df5 100644 --- a/docs/glossary/accounts.mdx +++ b/docs/glossary/accounts.mdx @@ -1,6 +1,5 @@ --- title: Accounts -order: --- Accounts are the central data structure in Stellar. They hold balances, sign transactions, and issue assets. All entries that persist on the ledger are owned by a particular account. diff --git a/docs/glossary/assets.mdx b/docs/glossary/assets.mdx index 42212b1ce..9e59e1e2a 100644 --- a/docs/glossary/assets.mdx +++ b/docs/glossary/assets.mdx @@ -1,6 +1,5 @@ --- title: Assets -order: --- The Stellar distributed network can be used to track, hold, and transfer any type of **asset**: dollars, euros, bitcoin, stocks, gold, and other tokens of value. Any asset on the network can be traded and exchanged with any other using Stellar's built-in [decentralized exchange](./decentralized-exchange.mdx). diff --git a/docs/glossary/channels.mdx b/docs/glossary/channels.mdx index fbc22299c..025bae83f 100644 --- a/docs/glossary/channels.mdx +++ b/docs/glossary/channels.mdx @@ -1,6 +1,5 @@ --- title: Channels -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/claimable-balance.mdx b/docs/glossary/claimable-balance.mdx index ebb34d5ab..9da9566ee 100644 --- a/docs/glossary/claimable-balance.mdx +++ b/docs/glossary/claimable-balance.mdx @@ -1,6 +1,5 @@ --- title: Claimable Balance -order: --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/glossary/clawback.mdx b/docs/glossary/clawback.mdx index 966a77c80..8d0b4c64a 100644 --- a/docs/glossary/clawback.mdx +++ b/docs/glossary/clawback.mdx @@ -1,6 +1,5 @@ --- title: Clawbacks -order: --- import { CodeExample } from "@site/src/components/CodeExample"; @@ -186,7 +185,7 @@ function getBalance(account) { -These snippets will help us with the final composition: making some payments to distribute the asset to the world and clawing some of it back. +These snippets will help us with the final comsidebar_position: making some payments to distribute the asset to the world and clawing some of it back. diff --git a/docs/glossary/decentralized-exchange.mdx b/docs/glossary/decentralized-exchange.mdx index 2257e77f2..27286786b 100644 --- a/docs/glossary/decentralized-exchange.mdx +++ b/docs/glossary/decentralized-exchange.mdx @@ -1,6 +1,5 @@ --- title: Decentralized Exchange -order: --- In addition to supporting the issuing and movement of [assets](./assets.mdx), the Stellar network also acts as a decentralized **distributed exchange** that allows you to trade and convert assets on the network. The Stellar ledger stores both balances held by user accounts and orders that user accounts make to buy or sell assets. @@ -51,7 +50,7 @@ The diagram is split into two stacks of orders. Each stack is the set of orders For mnemonic purposes we've arranged the diagram with the sheep "on top" of the wheat here. If it helps you can picture a bunch of sheep standing on a field of wheat or some bushels of wheat, an arrangement less likely to cause chaos than trying to stack bushels of wheat on top of sheep. -![Diagram of orderbook](../web-assets/orderbook.png) +![Diagram of orderbook](/assets/orderbook.png) Looking at the diagram, there are a few orientation things to notice and think about: diff --git a/docs/glossary/federation.mdx b/docs/glossary/federation.mdx index 82d8b0c61..ca3356fdc 100644 --- a/docs/glossary/federation.mdx +++ b/docs/glossary/federation.mdx @@ -1,6 +1,5 @@ --- title: Federation -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/fee-bumps.mdx b/docs/glossary/fee-bumps.mdx index 750ebfb1a..a34adc91a 100644 --- a/docs/glossary/fee-bumps.mdx +++ b/docs/glossary/fee-bumps.mdx @@ -1,6 +1,5 @@ --- title: Fee-Bump Transactions -order: --- A fee-bump transaction enables any account to pay the fee for an existing [transaction](./transactions.mdx) without the need to re-sign the existing transaction or manage sequence numbers. They're useful if you need to increase the fee on a pre-signed transaction, or if you want to build a service that covers user fees. Like a regular transaction, these are submitted to the [`/transactions` endpoint](/api/resources/transactions/). _Unlike_ a regular transaction, however, which contains 1-100 [operations](./operations.mdx), a fee-bump transaction contains a single [transaction envelope](./transactions.mdx/#transaction-envelopes). diff --git a/docs/glossary/fees.mdx b/docs/glossary/fees.mdx index f26180e70..966dfb03a 100644 --- a/docs/glossary/fees.mdx +++ b/docs/glossary/fees.mdx @@ -1,6 +1,5 @@ --- title: Fees -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/inflation.mdx b/docs/glossary/inflation.mdx index e305291c4..d3f90d810 100644 --- a/docs/glossary/inflation.mdx +++ b/docs/glossary/inflation.mdx @@ -1,6 +1,5 @@ --- title: Inflation -order: --- Prior to Protocol 12, Stellar had a built-in inflation mechanism conceived to allow account holders to collectively direct inflation-generated lumens toward projects built on Stellar. diff --git a/docs/glossary/ledger.mdx b/docs/glossary/ledger.mdx index f5b695638..b580ceec1 100644 --- a/docs/glossary/ledger.mdx +++ b/docs/glossary/ledger.mdx @@ -1,6 +1,5 @@ --- title: Ledger -order: --- A ledger represents the state of the Stellar universe at a given point in time. It’s shared across all the nodes that make up the network, and contains the list of all accounts and balances, all orders on the distributed exchange, and any other data that persists. diff --git a/docs/glossary/liquidity-pool.mdx b/docs/glossary/liquidity-pool.mdx index b387f0a29..f86c847fe 100644 --- a/docs/glossary/liquidity-pool.mdx +++ b/docs/glossary/liquidity-pool.mdx @@ -1,6 +1,5 @@ --- title: Liquidity Pools -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/lumen-supply.mdx b/docs/glossary/lumen-supply.mdx index 1c48dc5da..faa483f02 100644 --- a/docs/glossary/lumen-supply.mdx +++ b/docs/glossary/lumen-supply.mdx @@ -1,6 +1,5 @@ --- title: Lumen Supply Metrics -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/metadata.json b/docs/glossary/metadata.json deleted file mode 100644 index 2e6f06970..000000000 --- a/docs/glossary/metadata.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "order": 90, - "title": "Glossary", - "sortMethod": "alphabetical" -} diff --git a/docs/glossary/minimum-balance.mdx b/docs/glossary/minimum-balance.mdx index 30cb27b8f..37aecd36d 100644 --- a/docs/glossary/minimum-balance.mdx +++ b/docs/glossary/minimum-balance.mdx @@ -1,6 +1,5 @@ --- title: Minimum Balance -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/miscellaneous-core-objects.mdx b/docs/glossary/miscellaneous-core-objects.mdx index da569eb4b..a01c3b33c 100644 --- a/docs/glossary/miscellaneous-core-objects.mdx +++ b/docs/glossary/miscellaneous-core-objects.mdx @@ -1,6 +1,5 @@ --- title: Miscellaneous Stellar Core Objects -order: --- ## LedgerKey diff --git a/docs/glossary/multisig.mdx b/docs/glossary/multisig.mdx index be8b8cbc3..8557660d6 100644 --- a/docs/glossary/multisig.mdx +++ b/docs/glossary/multisig.mdx @@ -1,6 +1,5 @@ --- title: Multisignature -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/muxed-accounts.mdx b/docs/glossary/muxed-accounts.mdx index 75850bd3b..213302a48 100644 --- a/docs/glossary/muxed-accounts.mdx +++ b/docs/glossary/muxed-accounts.mdx @@ -1,6 +1,5 @@ --- title: Muxed Accounts -order: --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/glossary/network-passphrase.mdx b/docs/glossary/network-passphrase.mdx index 72c5a8428..abe770ecb 100644 --- a/docs/glossary/network-passphrase.mdx +++ b/docs/glossary/network-passphrase.mdx @@ -1,6 +1,5 @@ --- title: Network Passphrase -order: --- Stellar has two public networks: the Public Network (pubnet), which is the main network used by applications in production, and the Test Network ([testnet](./testnet.mdx)), which is a network maintained by the Stellar Development Foundation that developers can use to test their Applications. diff --git a/docs/glossary/operations.mdx b/docs/glossary/operations.mdx index e558eaa54..deac200fa 100644 --- a/docs/glossary/operations.mdx +++ b/docs/glossary/operations.mdx @@ -1,6 +1,5 @@ --- title: Operations -order: --- Operations are the bread and butter of Stellar: they’re the individual commands that mutate the ledger. Transactions, which accounts sign and submit for inclusion in the ledger, are really just bundles of operations. Transactions can, by definition, include anywhere from 1 to 100 operations. diff --git a/docs/glossary/scp.mdx b/docs/glossary/scp.mdx index d1f753479..9f5e4c3ae 100644 --- a/docs/glossary/scp.mdx +++ b/docs/glossary/scp.mdx @@ -1,6 +1,5 @@ --- title: Stellar Consensus Protocol -order: --- The Stellar Consensus Protocol (SCP) provides a way to reach consensus without relying on a closed system to accurately record financial transactions. SCP has a set of provable safety properties that optimize for safety over liveness—in the event of partition or misbehaving nodes, it halts progress of the network until consensus can be reached. SCP simultaneously enjoys four key properties: decentralized control, low latency, flexible trust, and asymptotic security. diff --git a/docs/glossary/sponsored-reserves.mdx b/docs/glossary/sponsored-reserves.mdx index 12ebb256a..7ab47223a 100644 --- a/docs/glossary/sponsored-reserves.mdx +++ b/docs/glossary/sponsored-reserves.mdx @@ -1,6 +1,5 @@ --- title: Sponsored Reserves -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/testnet.mdx b/docs/glossary/testnet.mdx index 0a3de6054..374d1e257 100644 --- a/docs/glossary/testnet.mdx +++ b/docs/glossary/testnet.mdx @@ -1,6 +1,5 @@ --- title: Testnet -order: --- The testnet is a small test Stellar network, run by the Stellar Development Foundation (SDF). It's free to use, functions just like the main public network, and is the best place to start developing on Stellar since it doesn't connect to real money. diff --git a/docs/glossary/transactions.mdx b/docs/glossary/transactions.mdx index 69ba60bd8..ddbbc220b 100644 --- a/docs/glossary/transactions.mdx +++ b/docs/glossary/transactions.mdx @@ -1,6 +1,5 @@ --- title: Transactions -order: --- Transactions are commands that modify the ledger state. They consist of a list of anywhere from 1 to 100 operations, and they are signed, submitted to the network, and considered for inclusion in the transaction set via [SCP](./scp.mdx). They contain the operations used to send payments, enter orders into the [decentralized exchange](./decentralized-exchange.mdx), change settings on accounts, and authorize accounts to hold assets. If you think of the ledger as a database, then transactions are SQL commands. diff --git a/docs/glossary/versioning.mdx b/docs/glossary/versioning.mdx index f28aef268..f347a568b 100644 --- a/docs/glossary/versioning.mdx +++ b/docs/glossary/versioning.mdx @@ -1,6 +1,5 @@ --- title: Versioning and Network Upgrades -order: --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/glossary/xdr.mdx b/docs/glossary/xdr.mdx index 0222078f4..821cd8f75 100644 --- a/docs/glossary/xdr.mdx +++ b/docs/glossary/xdr.mdx @@ -1,6 +1,5 @@ --- title: XDR -order: --- **XDR**, also known as _External Data Representation_, is used throughout the Stellar network and protocol. The ledger, transactions, results, history, and even the messages passed between computers running stellar-core are encoded using XDR. diff --git a/docs/index.mdx b/docs/index.mdx index 9e3cecbd7..aaeadc99c 100644 --- a/docs/index.mdx +++ b/docs/index.mdx @@ -1,6 +1,6 @@ --- +sidebar_position: 0 title: Welcome -order: -100 --- import { ReadMore } from "@site/src/components/ReadMore"; diff --git a/docs/issuing-assets/_category_.json b/docs/issuing-assets/_category_.json new file mode 100644 index 000000000..5d1a4ef6a --- /dev/null +++ b/docs/issuing-assets/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 30, + "label": "Issue Assets", + "link": { + "type": "generated-index" + } +} \ No newline at end of file diff --git a/docs/issuing-assets/anatomy-of-an-asset.mdx b/docs/issuing-assets/anatomy-of-an-asset.mdx index 26f98d212..d0cd57780 100644 --- a/docs/issuing-assets/anatomy-of-an-asset.mdx +++ b/docs/issuing-assets/anatomy-of-an-asset.mdx @@ -1,6 +1,6 @@ --- title: Anatomy of an Asset -order: 15 +sidebar_position: 15 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/issuing-assets/control-asset-access.mdx b/docs/issuing-assets/control-asset-access.mdx index b49dc3e5c..9e526ce0b 100644 --- a/docs/issuing-assets/control-asset-access.mdx +++ b/docs/issuing-assets/control-asset-access.mdx @@ -1,6 +1,6 @@ --- title: Control Access to an Asset -order: 50 +sidebar_position: 50 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/issuing-assets/how-to-issue-an-asset.mdx b/docs/issuing-assets/how-to-issue-an-asset.mdx index 6e0630ef0..91ce7e97b 100644 --- a/docs/issuing-assets/how-to-issue-an-asset.mdx +++ b/docs/issuing-assets/how-to-issue-an-asset.mdx @@ -1,6 +1,6 @@ --- title: Issue an Asset -order: 20 +sidebar_position: 20 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/issuing-assets/index.mdx b/docs/issuing-assets/index.mdx index 77042aee7..f6779fc5c 100644 --- a/docs/issuing-assets/index.mdx +++ b/docs/issuing-assets/index.mdx @@ -1,6 +1,6 @@ --- title: Overview -order: 10 +sidebar_position: 10 --- The ability to issue assets is a core feature of Stellar. In a few simple operations, you can create Stellar-network tokens, and this section of the docs will show you how. diff --git a/docs/issuing-assets/metadata.json b/docs/issuing-assets/metadata.json deleted file mode 100644 index ea2535805..000000000 --- a/docs/issuing-assets/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 30, - "title": "Issue Assets" -} diff --git a/docs/issuing-assets/publishing-asset-info.mdx b/docs/issuing-assets/publishing-asset-info.mdx index 8769ee1d7..e1e2e7c0b 100644 --- a/docs/issuing-assets/publishing-asset-info.mdx +++ b/docs/issuing-assets/publishing-asset-info.mdx @@ -1,6 +1,6 @@ --- title: Publish Information About an Asset -order: 40 +sidebar_position: 40 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/metadata.json b/docs/metadata.json deleted file mode 100644 index 25b512673..000000000 --- a/docs/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 0, - "title": "Documentation" -} diff --git a/docs/run-api-server/_category_.json b/docs/run-api-server/_category_.json new file mode 100644 index 000000000..e67c1f781 --- /dev/null +++ b/docs/run-api-server/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 70, + "label": "Run an API Server", + "link": { + "type": "generated-index" + } +} diff --git a/docs/run-api-server/configuring.mdx b/docs/run-api-server/configuring.mdx index 4da4b8c63..28856674b 100644 --- a/docs/run-api-server/configuring.mdx +++ b/docs/run-api-server/configuring.mdx @@ -1,6 +1,6 @@ --- title: Configuring -order: 30 +sidebar_position: 30 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/run-api-server/index.mdx b/docs/run-api-server/index.mdx index 6d9f7f3f2..6dc21ec1e 100644 --- a/docs/run-api-server/index.mdx +++ b/docs/run-api-server/index.mdx @@ -1,6 +1,6 @@ --- title: "Overview" -order: 0 +sidebar_position: 0 --- Horizon is responsible for providing an HTTP API to data in the Stellar network. It ingests and re-serves the data produced by the Stellar network in a form that is easier to consume by the average application relative to the performance-oriented data representations used by Stellar Core. diff --git a/docs/run-api-server/ingestion.mdx b/docs/run-api-server/ingestion.mdx index 9939442aa..c19f76102 100644 --- a/docs/run-api-server/ingestion.mdx +++ b/docs/run-api-server/ingestion.mdx @@ -1,6 +1,6 @@ --- title: Ingestion -order: 45 +sidebar_position: 45 --- Horizon provides access to both current and historical state on the Stellar network through a process called **ingestion**. diff --git a/docs/run-api-server/installing.mdx b/docs/run-api-server/installing.mdx index d711b62a9..2fa997861 100644 --- a/docs/run-api-server/installing.mdx +++ b/docs/run-api-server/installing.mdx @@ -1,6 +1,6 @@ --- title: Installing -order: 20 +sidebar_position: 20 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-api-server/metadata.json b/docs/run-api-server/metadata.json deleted file mode 100644 index 2ffa1a14a..000000000 --- a/docs/run-api-server/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 70, - "title": "Run an API Server" -} diff --git a/docs/run-api-server/migrating.mdx b/docs/run-api-server/migrating.mdx index a47dc157f..8a5dc6762 100644 --- a/docs/run-api-server/migrating.mdx +++ b/docs/run-api-server/migrating.mdx @@ -1,6 +1,6 @@ --- title: Migrating From 1.x -order: 15 +sidebar_position: 15 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/run-api-server/monitoring.mdx b/docs/run-api-server/monitoring.mdx index 264642264..dc2b5aa3f 100644 --- a/docs/run-api-server/monitoring.mdx +++ b/docs/run-api-server/monitoring.mdx @@ -1,6 +1,6 @@ --- title: Monitoring -order: 60 +sidebar_position: 60 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-api-server/prerequisites.mdx b/docs/run-api-server/prerequisites.mdx index 71b9eb87f..2e4316db3 100644 --- a/docs/run-api-server/prerequisites.mdx +++ b/docs/run-api-server/prerequisites.mdx @@ -1,6 +1,6 @@ --- title: Prerequisites -order: 10 +sidebar_position: 10 --- Horizon only has one true dependency: a PostgreSQL server that it uses to store data that has been processed and ingested from Stellar Core. **Horizon requires PostgreSQL version >= 9.5**. diff --git a/docs/run-api-server/remote-core.mdx b/docs/run-api-server/remote-core.mdx index 62649c63b..201245ead 100644 --- a/docs/run-api-server/remote-core.mdx +++ b/docs/run-api-server/remote-core.mdx @@ -1,6 +1,6 @@ --- title: Remote Captive Core -order: 35 +sidebar_position: 35 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/run-api-server/running.mdx b/docs/run-api-server/running.mdx index c090bf55a..378a0be2e 100644 --- a/docs/run-api-server/running.mdx +++ b/docs/run-api-server/running.mdx @@ -1,6 +1,6 @@ --- title: Running -order: 40 +sidebar_position: 40 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-api-server/scaling.mdx b/docs/run-api-server/scaling.mdx index 267a47219..5ed600723 100644 --- a/docs/run-api-server/scaling.mdx +++ b/docs/run-api-server/scaling.mdx @@ -1,6 +1,6 @@ --- title: Scaling -order: 70 +sidebar_position: 70 --- As alluded to in the discussion on [Prerequisites](./prerequisites.mdx), Horizon encompasses different logical tiers that can be scaled independently for high throughput, isolation, and high availability. The following components can be independently scaled: @@ -15,19 +15,19 @@ As always, scaling encompasses a spectrum. A few common scaling architectures fo As a starting point, for development purposes or low load environments with limited history retention (e.g. a few ledger entries), a single VM would suffice. -![](../web-assets/horizon-scaling/Topology-1VM.png) +![](/assets/horizon-scaling/Topology-1VM.png) ## Low to Medium Load For low to medium load environments with up to 30-90 days of data history retention and modest API request traffic, this configuration isolates the database instance from the API service and ingestion process. -![](../web-assets/horizon-scaling/Topology-2VMs.png) +![](/assets/horizon-scaling/Topology-2VMs.png) ### Extension: Isolating Captive Core Additionally, Captive Core can be further isolated into its own VM, especially for isolating high throughput historical catch-up with parallel workers, leaving it unaffected by API request servicing load. -![](../web-assets/horizon-scaling/Topology-3VMs.png) +![](/assets/horizon-scaling/Topology-3VMs.png) ## Enterprise _n_-Tier @@ -37,10 +37,10 @@ Database instances can be scaled when the I/O limit is reached by using read-onl Additionally, a second Captive Core instance shares ingestion load and serves as a backup in case of an instance failure. -![](../web-assets/horizon-scaling/Topology-Enterprise.png) +![](/assets/horizon-scaling/Topology-Enterprise.png) ### Extension: Redundant Hot Backup The entire architecture can be replicated to a second cluster. The backup cluster can be upgraded independently or fail-overed to with no downtime. Additionally, capacity can be doubled in an emergency if needed. -![](../web-assets/horizon-scaling/Topology-Enterprise-HotBackup.png) +![](/assets/horizon-scaling/Topology-Enterprise-HotBackup.png) diff --git a/docs/run-core-node/_category_.json b/docs/run-core-node/_category_.json new file mode 100644 index 000000000..9249a37e0 --- /dev/null +++ b/docs/run-core-node/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 60, + "label": "Run a Core Node", + "link": { + "type": "generated-index" + } +} diff --git a/docs/run-core-node/commands.mdx b/docs/run-core-node/commands.mdx index 98dd3f1b6..2f1b0d2b9 100644 --- a/docs/run-core-node/commands.mdx +++ b/docs/run-core-node/commands.mdx @@ -1,6 +1,6 @@ --- title: Commands -order: 80 +sidebar_position: 80 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-core-node/configuring.mdx b/docs/run-core-node/configuring.mdx index f95e00906..321ba672a 100644 --- a/docs/run-core-node/configuring.mdx +++ b/docs/run-core-node/configuring.mdx @@ -1,6 +1,6 @@ --- title: Configuring -order: 40 +sidebar_position: 40 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-core-node/index.mdx b/docs/run-core-node/index.mdx index 187243ea7..6ccfa9275 100644 --- a/docs/run-core-node/index.mdx +++ b/docs/run-core-node/index.mdx @@ -1,6 +1,6 @@ --- title: "Overview" -order: 10 +sidebar_position: 10 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/run-core-node/installation.mdx b/docs/run-core-node/installation.mdx index 4f2823379..98a03a4cd 100644 --- a/docs/run-core-node/installation.mdx +++ b/docs/run-core-node/installation.mdx @@ -1,6 +1,6 @@ --- title: Installing -order: 30 +sidebar_position: 30 --- There are three ways to install Stellar Core: you can use a Docker image, use pre-built packages, or build from source. Using a Docker image is the quickest and easiest method, so it's a good choice for a lot of developers, but if you're running Stellar Core in production you may need to use packages or, if you want to sacrifice convenience for maximum control, build from source. Whichever method you use, you should make sure to install the latest [release](https://github.com/stellar/stellar-core/releases) since releases are cumulative and backwards compatible. diff --git a/docs/run-core-node/metadata.json b/docs/run-core-node/metadata.json deleted file mode 100644 index 2f579a424..000000000 --- a/docs/run-core-node/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 60, - "title": "Run a Core Node" -} diff --git a/docs/run-core-node/monitoring.mdx b/docs/run-core-node/monitoring.mdx index b97ef7c74..9d93a8fde 100644 --- a/docs/run-core-node/monitoring.mdx +++ b/docs/run-core-node/monitoring.mdx @@ -1,6 +1,6 @@ --- title: Monitoring -order: 70 +sidebar_position: 70 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-core-node/network-upgrades.mdx b/docs/run-core-node/network-upgrades.mdx index f86df32fb..f6f9cb7f3 100644 --- a/docs/run-core-node/network-upgrades.mdx +++ b/docs/run-core-node/network-upgrades.mdx @@ -1,6 +1,6 @@ --- title: Upgrading the Network -order: 80 +sidebar_position: 80 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-core-node/prerequisites.mdx b/docs/run-core-node/prerequisites.mdx index 357b5954b..f15296137 100644 --- a/docs/run-core-node/prerequisites.mdx +++ b/docs/run-core-node/prerequisites.mdx @@ -1,6 +1,6 @@ --- title: Prerequisites -order: 20 +sidebar_position: 20 --- You can install Stellar Core a [number of different ways](./installation.mdx), and once you do, you can [configure](./configuring.mdx) it to participate in the network on a several [different levels](./index.mdx#types-of-nodes): it can be either a Basic Validator or a Full Validator. No matter how you install Stellar Core or what kind of node you run, however, you need to set up to connect to the peer-to-peer network and store the state of the ledger in a SQL [database](configuring.mdx#database). diff --git a/docs/run-core-node/publishing-history-archives.mdx b/docs/run-core-node/publishing-history-archives.mdx index c33de6295..db103a045 100644 --- a/docs/run-core-node/publishing-history-archives.mdx +++ b/docs/run-core-node/publishing-history-archives.mdx @@ -1,6 +1,6 @@ --- title: Publishing History Archives -order: 50 +sidebar_position: 50 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-core-node/running-node.mdx b/docs/run-core-node/running-node.mdx index 5d8742337..389c4269c 100644 --- a/docs/run-core-node/running-node.mdx +++ b/docs/run-core-node/running-node.mdx @@ -1,6 +1,6 @@ --- title: Running -order: 60 +sidebar_position: 60 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/run-core-node/tier-1-orgs.mdx b/docs/run-core-node/tier-1-orgs.mdx index 04c2ad015..623162711 100644 --- a/docs/run-core-node/tier-1-orgs.mdx +++ b/docs/run-core-node/tier-1-orgs.mdx @@ -1,6 +1,6 @@ --- title: Tier 1 Organizations -order: 120 +sidebar_position: 120 --- To help with Stellar’s decentralization, the most reliable and advanced Stellar teams join the ranks of “Tier 1 Organizations.” These organizations run three validators, coordinate any changes to their quorumsets, and hold themselves to a higher standard of uptime and responsiveness. diff --git a/docs/software-and-sdks/_category_.json b/docs/software-and-sdks/_category_.json new file mode 100644 index 000000000..4126f4d95 --- /dev/null +++ b/docs/software-and-sdks/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 80, + "label": "Software and SDKs", + "link": { + "type": "doc", "id": "index" + } +} diff --git a/docs/software-and-sdks/index.mdx b/docs/software-and-sdks/index.mdx index 3fa8122c4..c6558c694 100644 --- a/docs/software-and-sdks/index.mdx +++ b/docs/software-and-sdks/index.mdx @@ -1,6 +1,6 @@ --- title: "Software and SDKs" -order: 0 +sidebar_position: 0 --- ## Software diff --git a/docs/software-and-sdks/metadata.json b/docs/software-and-sdks/metadata.json deleted file mode 100644 index 1c747a7ca..000000000 --- a/docs/software-and-sdks/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 80, - "title": "Software and SDKs" -} diff --git a/docs/start/_category_.json b/docs/start/_category_.json new file mode 100644 index 000000000..f0a5ef4e0 --- /dev/null +++ b/docs/start/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 10, + "label": "Where to Start", + "link": { + "type": "generated-index" + } +} diff --git a/docs/start/introduction.mdx b/docs/start/introduction.mdx index f0e8f2e0a..c04dd1929 100644 --- a/docs/start/introduction.mdx +++ b/docs/start/introduction.mdx @@ -1,6 +1,6 @@ --- title: Introduction -order: 0 +sidebar_position: 0 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/start/list-of-operations.mdx b/docs/start/list-of-operations.mdx index e40d49258..1019acbb6 100644 --- a/docs/start/list-of-operations.mdx +++ b/docs/start/list-of-operations.mdx @@ -1,6 +1,6 @@ --- title: List of Operations -order: 30 +sidebar_position: 30 --- import { Alert } from "@site/src/components/Alert"; diff --git a/docs/start/metadata.json b/docs/start/metadata.json deleted file mode 100644 index 83f2bea41..000000000 --- a/docs/start/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 10, - "title": "Where to Start" -} diff --git a/docs/start/stellar-stack.mdx b/docs/start/stellar-stack.mdx index 1e88906d0..8b50260ed 100644 --- a/docs/start/stellar-stack.mdx +++ b/docs/start/stellar-stack.mdx @@ -1,6 +1,6 @@ --- title: The Stellar Stack -order: 10 +sidebar_position: 10 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/tutorials/_category_.json b/docs/tutorials/_category_.json new file mode 100644 index 000000000..e74dec28a --- /dev/null +++ b/docs/tutorials/_category_.json @@ -0,0 +1,7 @@ +{ + "position": 20, + "label": "Tutorials", + "link": { + "type": "generated-index" + } +} diff --git a/docs/tutorials/create-account.mdx b/docs/tutorials/create-account.mdx index 0687fdda8..7802e29cd 100644 --- a/docs/tutorials/create-account.mdx +++ b/docs/tutorials/create-account.mdx @@ -1,6 +1,6 @@ --- title: Create an Account -order: 10 +sidebar_position: 10 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/tutorials/follow-received-payments.mdx b/docs/tutorials/follow-received-payments.mdx index 3386b7ee8..64abdcfaf 100644 --- a/docs/tutorials/follow-received-payments.mdx +++ b/docs/tutorials/follow-received-payments.mdx @@ -1,6 +1,6 @@ --- title: Follow Received Payments -order: 30 +sidebar_position: 30 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/tutorials/handling-errors.mdx b/docs/tutorials/handling-errors.mdx index 3c18b4aa3..efcbdaeb4 100644 --- a/docs/tutorials/handling-errors.mdx +++ b/docs/tutorials/handling-errors.mdx @@ -1,6 +1,6 @@ --- title: Handling Errors Gracefully -order: 100 +sidebar_position: 100 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docs/tutorials/metadata.json b/docs/tutorials/metadata.json deleted file mode 100644 index d855de20d..000000000 --- a/docs/tutorials/metadata.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "order": 20, - "title": "Tutorials" -} diff --git a/docs/tutorials/moneygram-access-integration-guide.mdx b/docs/tutorials/moneygram-access-integration-guide.mdx index 43f166794..fe36d783c 100644 --- a/docs/tutorials/moneygram-access-integration-guide.mdx +++ b/docs/tutorials/moneygram-access-integration-guide.mdx @@ -1,6 +1,6 @@ --- title: Integrate with MoneyGram Access -order: 140 +sidebar_position: 140 --- import { CodeExample } from "@site/src/components/CodeExample"; @@ -62,11 +62,11 @@ This guide will assume the application has a basic client-server architecture. T Below are the 7 high-level steps to take to facilitate a cash-out (withdrawal) transaction. -![Wallet - MoneyGram Page 1](../web-assets/wallet-mgi-architecture-1.png) +![Wallet - MoneyGram Page 1](/assets/wallet-mgi-architecture-1.png) After Step 4, the application should open the URL provided by MoneyGram in a mobile webview or browser tab. MoneyGram will then prompt the user to provide KYC and transaction information. On completion of this flow, the application’s client should close the MoneyGram tab or webview and initiate the disbursement of funds. -![Wallet - MoneyGram Page 2](../web-assets/wallet-mgi-architecture-2.png) +![Wallet - MoneyGram Page 2](/assets/wallet-mgi-architecture-2.png) The provided reference number would then be taken to any MoneyGram cash agent in order to receive cash in the user’s fiat currency. These steps document the cash-out, or withdrawal flow. The deposit flow is similar and detailed in the steps below. diff --git a/docs/tutorials/securing-projects.mdx b/docs/tutorials/securing-projects.mdx index 98c5ae6a6..8f222aae7 100644 --- a/docs/tutorials/securing-projects.mdx +++ b/docs/tutorials/securing-projects.mdx @@ -1,6 +1,6 @@ --- title: Securing Web-based Projects -order: 120 +sidebar_position: 120 --- It’s critical for any app managing the flow of cryptocurrency to architect their app to follow security best-practices. Cryptocurrency-enabled apps are significant targets for malicious actors in the sense they enable the attacker to realize immediate monetary gain from exploits. The following checklist offers guidance on the most common vulnerabilities. Even if every piece of advice is followed, security is not guaranteed. Web security is constantly evolving, which warrants a certain degree of paranoia. diff --git a/docs/tutorials/send-and-receive-payments.mdx b/docs/tutorials/send-and-receive-payments.mdx index 5889a2278..2b68fdef5 100644 --- a/docs/tutorials/send-and-receive-payments.mdx +++ b/docs/tutorials/send-and-receive-payments.mdx @@ -1,6 +1,6 @@ --- title: Send and Receive Payments -order: 20 +sidebar_position: 20 --- import { CodeExample } from "@site/src/components/CodeExample"; diff --git a/docusaurus.config.js b/docusaurus.config.js index e7d87ab0e..3217a497b 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -1,20 +1,23 @@ // @ts-check -const lightCodeTheme = require("prism-react-renderer/themes/nightOwl"); -const darkCodeTheme = require("prism-react-renderer/themes/dracula"); +// const lightCodeTheme = require("prism-react-renderer/themes/nightOwl"); +// const darkCodeTheme = require("prism-react-renderer/themes/dracula"); /** @type {import('@docusaurus/types').Config} */ const config = { title: "Stellar Documentation", - tagline: - "Stellar is a self-serve distributed ledger that you can use as a backend to power all kinds of apps and services", + tagline: "Stellar is a self-serve distributed ledger that you can use as a backend to power all kinds of apps and services", + url: "https://developers.stellar.org", + baseUrl: "/", onBrokenLinks: "warn", onBrokenMarkdownLinks: "warn", favicon: "img/favicon-96x96.png", organizationName: "stellar", projectName: "stellar-docs", - url: "https://developers.stellar.org", - baseUrl: "/", + i18n: { + defaultLocale: 'en', + locales: ['en'], + }, plugins: ["docusaurus-plugin-sass"], presets: [ [ @@ -23,10 +26,10 @@ const config = { ({ blog: false, docs: { - routeBasePath: "/", showLastUpdateTime: true, breadcrumbs: true, - remarkPlugins: [require("mdx-mermaid")], + routeBasePath: "/docs", + // remarkPlugins: [require("mdx-mermaid")], sidebarPath: require.resolve("./sidebars.js"), editUrl: "https://github.com/stellar/stellar-docs/tree/main/", }, @@ -35,117 +38,149 @@ const config = { }, }), ], - ], - themeConfig: - /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ - ({ - docs: { sidebar: { autoCollapseCategories: true } }, - navbar: { - hideOnScroll: true, - logo: { - width: 100, - src: "img/stellar-logo.svg", - srcDark: "img/stellar-logo-dark.svg", - href: "/docs", - }, - items: [ - { - href: "https://developers.stellar.org/api", - label: "API", - position: "right", - }, - { - href: "https://github.com/stellar/stellar-docs", - label: "GitHub", - position: "right", - }, - { - type: "search", - position: "right", - }, - ], - }, - // TODO: update after site is deployed to production - algolia: { - appId: "testingPJZPDNR7VG", - apiKey: "1f36375ebbc70d65c5b8165ecf52a1f2", - indexName: "crawler_Docusaurus", - }, - footer: { - links: [ - { - title: "Resources", - items: [ - { - label: "Get Started", - href: "https://www.stellar.org/start", - }, - { - label: "Learn", - href: "https://www.stellar.org/learn/intro-to-stellar", - }, - { - label: "Case Studies", - href: "https://www.stellar.org/case-studies", - }, - { - label: "Stellar Quest", - href: "https://quest.stellar.org/", - }, - ], - }, - { - title: "Tools", - items: [ - { - label: "Account Viewer", - href: "https://accountviewer.stellar.org/", - }, - { - label: "Laboratory", - href: "https://laboratory.stellar.org/", - }, - { - label: "Dashboard", - href: "https://dashboard.stellar.org/", - }, - { - label: "Ledger Explorer", - href: "https://stellar.expert/explorer/public", - }, - { label: "All Tools", href: "https://www.stellar.org/tools" }, - ], - }, + + [ + 'redocusaurus', + { + // Plugin Options for loading OpenAPI files + specs: [ { - title: "Developers", - items: [ - { - label: "Developer Resources", - href: "https://www.stellar.org/developers-legacy", - }, - { - label: "Status", - href: "https://status.stellar.org/", - }, - { - label: "Technical Papers", - to: "https://www.stellar.org/developers/guides/concepts/scp.html", - }, - { - label: "Developer Blog", - href: "https://www.stellar.org/developers-blog", - }, - ], + // spec: 'openapi/multi-file/openapi.yaml', + spec: 'openapi/main.yml', + route: '/api/', }, ], + // Theme Options for modifying how redoc renders them + theme: { + // Change with your site colors + // primaryColor: '#1890ff', + options: { disableSearch: true }, + }, }, - prism: { - theme: lightCodeTheme, - darkTheme: darkCodeTheme, - additionalLanguages: ["java"], + ], + ], + themeConfig: + /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ + ({ + docs: { + sidebar: { + autoCollapseCategories: false + } + }, + navbar: { + logo: { + width: 100, + src: "img/stellar-logo.svg", + srcDark: "img/stellar-logo-dark.svg", + href: "/docs", }, - tableOfContents: { maxHeadingLevel: 2 }, - }), + items: [ + { + to: '/docs', + label: 'Docs', + position: 'left' + }, + { + to: '/api', + label: 'API', + position: 'left' + }, + // { + // href: "https://developers.stellar.org/api", + // label: "API", + // position: "right", + // }, + { + href: "https://github.com/stellar/stellar-docs", + label: "GitHub", + position: "right", + }, + { + type: "search", + position: "right", + }, + ], + }, + // TODO: update after site is deployed to production + algolia: { + appId: "testingPJZPDNR7VG", + apiKey: "1f36375ebbc70d65c5b8165ecf52a1f2", + indexName: "crawler_Docusaurus", + }, + footer: { + links: [ + { + title: "Resources", + items: [ + { + label: "Get Started", + href: "https://www.stellar.org/start", + }, + { + label: "Learn", + href: "https://www.stellar.org/learn/intro-to-stellar", + }, + { + label: "Case Studies", + href: "https://www.stellar.org/case-studies", + }, + { + label: "Stellar Quest", + href: "https://quest.stellar.org/", + }, + ], + }, + { + title: "Tools", + items: [ + { + label: "Account Viewer", + href: "https://accountviewer.stellar.org/", + }, + { + label: "Laboratory", + href: "https://laboratory.stellar.org/", + }, + { + label: "Dashboard", + href: "https://dashboard.stellar.org/", + }, + { + label: "Ledger Explorer", + href: "https://stellar.expert/explorer/public", + }, + { label: "All Tools", href: "https://www.stellar.org/tools" }, + ], + }, + { + title: "Developers", + items: [ + { + label: "Developer Resources", + href: "https://www.stellar.org/developers-legacy", + }, + { + label: "Status", + href: "https://status.stellar.org/", + }, + { + label: "Technical Papers", + to: "https://www.stellar.org/developers/guides/concepts/scp.html", + }, + { + label: "Developer Blog", + href: "https://www.stellar.org/developers-blog", + }, + ], + }, + ], + }, + prism: { + // theme: lightCodeTheme, + // darkTheme: darkCodeTheme, + // additionalLanguages: ["java"], + }, + }), }; module.exports = config; diff --git a/openapi/account.yml b/openapi/account.yml new file mode 100644 index 000000000..b860838be --- /dev/null +++ b/openapi/account.yml @@ -0,0 +1,92 @@ +openapi: 3.0.3 +info: + title: Horizon Account API + version: 0.0.1 + +tags: + - name: account + description: Users interact with the Stellar network through accounts. Everything else in the ledger—assets, offers, trustlines, etc. are owned by accounts, and accounts must authorize all changes to the ledger through signed transactions. + externalDocs: + description: Learn more about accounts here + url: https://developers.stellar.org/docs/glossary/accounts/ + +paths: + + /accounts/{account_id}/operations: + get: + tags: + - account + summary: Get operations by account_id and paged list + description: This endpoint represents successful operations for a given account and can be used in streaming mode. Streaming mode allows you to listen for new operations for this account as they are added to the Stellar ledger. If called in streaming mode, Horizon will start at the earliest known operation unless a cursor is set, in which case it will start from that cursor. By setting the cursor value to now, you can stream operations created since your request time. + operationId: GetOperationsByAccountid + parameters: + - $ref: '#/components/parameters/AccountIDParam' + - $ref: '#/components/parameters/CursorParam' + - $ref: '#/components/parameters/OrderParam' + - $ref: '#/components/parameters/LimitParam' + - $ref: '#/components/parameters/IncludeFailedParam' + responses: + '200': + description: OK + + /accounts/{account_id}: + get: + tags: + - account + summary: Retrieves information about a specific account + description: The single account endpoint provides information on a specific account. + The balances section in the response will also list all the trustlines this account has established, including trustlines that haven’t been authorized yet. + operationId: RetrieveAnAccount + parameters: + - $ref: '#/components/parameters/AccountIDParam' + responses: + '200': + description: OK + +components: + parameters: + CursorParam: + name: cursor + in: query + required: false + description: A number that points to a specific location in a collection of responses and is pulled from the paging_token value of a record. + schema: + type: integer + example: 6606617478959105 + LimitParam: + name: limit + in: query + required: false + description: The maximum number of records returned. The limit can range from 1 to 200 - an upper limit that is hardcoded in Horizon for performance reasons. If this argument isn’t designated, it defaults to 10. + schema: + type: integer + example: 10 + AccountIDParam: + name: account_id + in: path + required: true + description: This account’s public key encoded in a base32 string representation. + schema: + type: string + example: GDMQQNJM4UL7QIA66P7R2PZHMQINWZBM77BEBMHLFXD5JEUAHGJ7R4JZ + OrderParam: + name: order + in: query + required: false + description: A designation of the order in which records should appear. Options include asc (ascending) or desc (descending). If this argument isn’t set, it defaults to asc. + schema: + type: integer + enum: + - asc + - desc + IncludeFailedParam: + name: includefailed + in: query + required: false + description: Set to true to include failed operations in results. Options include true and false. + schema: + type: boolean + enum: + - true + - false + \ No newline at end of file diff --git a/openapi/main.yml b/openapi/main.yml new file mode 100644 index 000000000..2d553957b --- /dev/null +++ b/openapi/main.yml @@ -0,0 +1,18 @@ +openapi: 3.0.3 +info: + title: Horizon + version: 0.0.1 +tags: + - name: account + description: Users interact with the Stellar network through accounts. Everything else in the ledger—assets, offers, trustlines, etc. are owned by accounts, and accounts must authorize all changes to the ledger through signed transactions. + - name: assets + description: Assets are representations of value issued on the Stellar network. An asset consists of a type, code, and issuer. + +paths: + /accounts/{account_id}: + $ref: 'account.yml#/paths/~1accounts~1{account_id}' + /accounts/{account_id}/operations: + $ref : 'account.yml#/paths/~1accounts~1{account_id}~1operations' + + + diff --git a/openapi/multi-file/components/pets.yaml b/openapi/multi-file/components/pets.yaml new file mode 100644 index 000000000..020aa0686 --- /dev/null +++ b/openapi/multi-file/components/pets.yaml @@ -0,0 +1,145 @@ +components: + schemas: + Id: + type: integer + format: int64 + readOnly: true + Tag: + type: object + properties: + id: + description: Tag ID + allOf: + - $ref: '#/components/schemas/Id' + name: + description: Tag name + type: string + minLength: 1 + xml: + name: Tag + Category: + type: object + properties: + id: + description: Category ID + allOf: + - $ref: '#/components/schemas/Id' + name: + description: Category name + type: string + minLength: 1 + sub: + description: Test Sub Category + type: object + properties: + prop1: + type: string + description: Dumb Property + xml: + name: Category + Cat: + description: A representation of a cat + allOf: + - $ref: '#/components/schemas/Pet' + - type: object + properties: + huntingSkill: + type: string + description: The measured skill for hunting + default: lazy + example: adventurous + enum: + - clueless + - lazy + - adventurous + - aggressive + required: + - huntingSkill + Dog: + description: A representation of a dog + allOf: + - $ref: '#/components/schemas/Pet' + - type: object + properties: + packSize: + type: integer + format: int32 + description: The size of the pack the dog is from + default: 1 + minimum: 1 + required: + - packSize + HoneyBee: + description: A representation of a honey bee + allOf: + - $ref: '#/components/schemas/Pet' + - type: object + properties: + honeyPerDay: + type: number + description: Average amount of honey produced per day in ounces + example: 3.14 + multipleOf: .01 + required: + - honeyPerDay + Pet: + type: object + required: + - name + - photoUrls + discriminator: + propertyName: petType + mapping: + cat: '#/components/schemas/Cat' + dog: '#/components/schemas/Dog' + bee: '#/components/schemas/HoneyBee' + properties: + id: + externalDocs: + description: 'Find more info here' + url: 'https://example.com' + description: Pet ID + allOf: + - $ref: '#/components/schemas/Id' + category: + description: Categories this pet belongs to + allOf: + - $ref: '#/components/schemas/Category' + name: + description: The name given to a pet + type: string + example: Guru + photoUrls: + description: The list of URL to a cute photos featuring pet + type: array + maxItems: 20 + xml: + name: photoUrl + wrapped: true + items: + type: string + format: url + friend: + allOf: + - $ref: '#/components/schemas/Pet' + tags: + description: Tags attached to the pet + type: array + minItems: 1 + xml: + name: tag + wrapped: true + items: + $ref: '#/components/schemas/Tag' + status: + type: string + description: Pet status in the store + enum: + - available + - pending + - sold + petType: + description: Type of a pet + type: string + xml: + name: Pet diff --git a/openapi/multi-file/openapi.yaml b/openapi/multi-file/openapi.yaml new file mode 100644 index 000000000..099d6d01e --- /dev/null +++ b/openapi/multi-file/openapi.yaml @@ -0,0 +1,1062 @@ +openapi: 3.0.0 +servers: + - url: //petstore.swagger.io/v2 + description: Default server + - url: //petstore.swagger.io/sandbox + description: Sandbox server +info: + description: | + This is a sample server Petstore server. + You can find out more about Swagger at + [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). + For this sample, you can use the api key `special-key` to test the authorization filters. + + # Introduction + This API is documented in **OpenAPI format** and is based on + [Petstore sample](http://petstore.swagger.io/) provided by [swagger.io](http://swagger.io) team. + It was **extended** to illustrate features of [generator-openapi-repo](https://github.com/Rebilly/generator-openapi-repo) + tool and [ReDoc](https://github.com/Redocly/redoc) documentation. In addition to standard + OpenAPI syntax we use a few [vendor extensions](https://github.com/Redocly/redoc/blob/master/docs/redoc-vendor-extensions.md). + + # OpenAPI Specification + This API is documented in **OpenAPI format** and is based on + [Petstore sample](http://petstore.swagger.io/) provided by [swagger.io](http://swagger.io) team. + It was **extended** to illustrate features of [generator-openapi-repo](https://github.com/Rebilly/generator-openapi-repo) + tool and [ReDoc](https://github.com/Redocly/redoc) documentation. In addition to standard + OpenAPI syntax we use a few [vendor extensions](https://github.com/Redocly/redoc/blob/master/docs/redoc-vendor-extensions.md). + + # Cross-Origin Resource Sharing + This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). + And that allows cross-domain communication from the browser. + All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site. + + # Authentication + + Petstore offers two forms of authentication: + - API Key + - OAuth2 + OAuth2 - an open protocol to allow secure authorization in a simple + and standard method from web, mobile and desktop applications. + + + + version: 1.0.0 + title: Swagger Petstore [Automatic Page From File] + termsOfService: 'http://swagger.io/terms/' + contact: + name: API Support + email: apiteam@swagger.io + url: https://github.com/Redocly/redoc + x-logo: + url: 'https://redocly.github.io/redoc/petstore-logo.png' + altText: Petstore logo + license: + name: Apache 2.0 + url: 'http://www.apache.org/licenses/LICENSE-2.0.html' +externalDocs: + description: Find out how to create Github repo for your OpenAPI spec. + url: 'https://github.com/Rebilly/generator-openapi-repo' +tags: + - name: pet + description: Everything about your Pets + - name: store + description: Access to Petstore orders + - name: user + description: Operations about user + - name: pet_model + x-displayName: The Pet Model + description: | + + - name: store_model + x-displayName: The Order Model + description: | + +x-tagGroups: + - name: General + tags: + - pet + - store + - name: User Management + tags: + - user + - name: Models + tags: + - pet_model + - store_model +paths: + /pet: + parameters: + - name: Accept-Language + in: header + description: 'The language you prefer for messages. Supported values are en-AU, en-CA, en-GB, en-US' + example: en-US + required: false + schema: + type: string + default: en-AU + - name: cookieParam + in: cookie + description: Some cookie + required: true + schema: + type: integer + format: int64 + post: + tags: + - pet + summary: Add a new pet to the store + description: Add new pet to the store inventory. + operationId: addPet + responses: + '405': + description: Invalid input + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + x-codeSamples: + - lang: 'C#' + source: | + PetStore.v1.Pet pet = new PetStore.v1.Pet(); + pet.setApiKey("your api key"); + pet.petType = PetStore.v1.Pet.TYPE_DOG; + pet.name = "Rex"; + // set other fields + PetStoreResponse response = pet.create(); + if (response.statusCode == HttpStatusCode.Created) + { + // Successfully created + } + else + { + // Something wrong -- check response for errors + Console.WriteLine(response.getRawResponse()); + } + - lang: PHP + source: | + $form = new \PetStore\Entities\Pet(); + $form->setPetType("Dog"); + $form->setName("Rex"); + // set other fields + try { + $pet = $client->pets()->create($form); + } catch (UnprocessableEntityException $e) { + var_dump($e->getErrors()); + } + requestBody: + $ref: '#/components/requestBodies/Pet' + put: + tags: + - pet + summary: Update an existing pet + description: '' + operationId: updatePet + responses: + '400': + description: Invalid ID supplied + '404': + description: Pet not found + '405': + description: Validation exception + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + x-codeSamples: + - lang: PHP + source: | + $form = new \PetStore\Entities\Pet(); + $form->setPetId(1); + $form->setPetType("Dog"); + $form->setName("Rex"); + // set other fields + try { + $pet = $client->pets()->update($form); + } catch (UnprocessableEntityException $e) { + var_dump($e->getErrors()); + } + requestBody: + $ref: '#/components/requestBodies/Pet' + '/pet/{petId}': + get: + tags: + - pet + summary: Find pet by ID + description: Returns a single pet + operationId: getPetById + parameters: + - name: petId + in: path + description: ID of pet to return + required: true + deprecated: true + schema: + type: integer + format: int64 + responses: + '200': + description: successful operation + content: + application/json: + schema: + $ref: 'components/pets.yaml#/components/schemas/Pet' + application/xml: + schema: + $ref: 'components/pets.yaml#/components/schemas/Pet' + '400': + description: Invalid ID supplied + '404': + description: Pet not found + security: + - api_key: [] + post: + tags: + - pet + summary: Updates a pet in the store with form data + description: '' + operationId: updatePetWithForm + parameters: + - name: petId + in: path + description: ID of pet that needs to be updated + required: true + schema: + type: integer + format: int64 + responses: + '405': + description: Invalid input + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + requestBody: + content: + application/x-www-form-urlencoded: + schema: + type: object + properties: + name: + description: Updated name of the pet + type: string + status: + description: Updated status of the pet + type: string + delete: + tags: + - pet + summary: Deletes a pet + description: '' + operationId: deletePet + parameters: + - name: api_key + in: header + required: false + schema: + type: string + example: 'Bearer ' + - name: petId + in: path + description: Pet id to delete + required: true + schema: + type: integer + format: int64 + responses: + '400': + description: Invalid pet value + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + '/pet/{petId}/uploadImage': + post: + tags: + - pet + summary: uploads an image + description: '' + operationId: uploadFile + parameters: + - name: petId + in: path + description: ID of pet to update + required: true + schema: + type: integer + format: int64 + responses: + '200': + description: successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/ApiResponse' + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + requestBody: + content: + application/octet-stream: + schema: + type: string + format: binary + /pet/findByStatus: + get: + tags: + - pet + summary: Finds Pets by status + description: Multiple status values can be provided with comma separated strings + operationId: findPetsByStatus + parameters: + - name: status + in: query + description: Status values that need to be considered for filter + required: true + style: form + schema: + type: array + minItems: 1 + maxItems: 3 + items: + type: string + enum: + - available + - pending + - sold + default: available + responses: + '200': + description: successful operation + content: + application/json: + schema: + type: array + items: + $ref: 'components/pets.yaml#/components/schemas/Pet' + application/xml: + schema: + type: array + items: + $ref: 'components/pets.yaml#/components/schemas/Pet' + '400': + description: Invalid status value + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + /pet/findByTags: + get: + tags: + - pet + summary: Finds Pets by tags + description: >- + Multiple tags can be provided with comma separated strings. Use tag1, + tag2, tag3 for testing. + operationId: findPetsByTags + deprecated: true + parameters: + - name: tags + in: query + description: Tags to filter by + required: true + style: form + schema: + type: array + items: + type: string + responses: + '200': + description: successful operation + content: + application/json: + schema: + type: array + items: + $ref: 'components/pets.yaml#/components/schemas/Pet' + application/xml: + schema: + type: array + items: + $ref: 'components/pets.yaml#/components/schemas/Pet' + '400': + description: Invalid tag value + security: + - petstore_auth: + - 'write:pets' + - 'read:pets' + /store/inventory: + get: + tags: + - store + summary: Returns pet inventories by status + description: Returns a map of status codes to quantities + operationId: getInventory + responses: + '200': + description: successful operation + content: + application/json: + schema: + type: object + additionalProperties: + type: integer + format: int32 + security: + - api_key: [] + /store/order: + post: + tags: + - store + summary: Place an order for a pet + description: '' + operationId: placeOrder + responses: + '200': + description: successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/Order' + application/xml: + schema: + $ref: '#/components/schemas/Order' + '400': + description: Invalid Order + content: + application/json: + example: + status: 400 + message: 'Invalid Order' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/Order' + description: order placed for purchasing the pet + required: true + '/store/order/{orderId}': + get: + tags: + - store + summary: Find purchase order by ID + description: >- + For valid response try integer IDs with value <= 5 or > 10. Other values + will generated exceptions + operationId: getOrderById + parameters: + - name: orderId + in: path + description: ID of pet that needs to be fetched + required: true + schema: + type: integer + format: int64 + minimum: 1 + maximum: 5 + responses: + '200': + description: successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/Order' + application/xml: + schema: + $ref: '#/components/schemas/Order' + '400': + description: Invalid ID supplied + '404': + description: Order not found + delete: + tags: + - store + summary: Delete purchase order by ID + description: >- + For valid response try integer IDs with value < 1000. Anything above + 1000 or nonintegers will generate API errors + operationId: deleteOrder + parameters: + - name: orderId + in: path + description: ID of the order that needs to be deleted + required: true + schema: + type: string + minimum: 1 + responses: + '400': + description: Invalid ID supplied + '404': + description: Order not found + /store/subscribe: + post: + tags: + - store + summary: Subscribe to the Store events + description: Add subscription for a store events + requestBody: + content: + application/json: + schema: + type: object + properties: + callbackUrl: + type: string + format: uri + description: This URL will be called by the server when the desired event will occur + example: https://myserver.com/send/callback/here + eventName: + type: string + description: Event name for the subscription + enum: + - orderInProgress + - orderShipped + - orderDelivered + example: orderInProgress + required: + - callbackUrl + - eventName + responses: + '201': + description: Subscription added + content: + application/json: + schema: + type: object + properties: + subscriptionId: + type: string + example: AAA-123-BBB-456 + callbacks: + orderInProgress: + '{$request.body#/callbackUrl}?event={$request.body#/eventName}': + servers: + - url: //callback-url.path-level/v1 + description: Path level server 1 + - url: //callback-url.path-level/v2 + description: Path level server 2 + post: + summary: Order in Progress (Summary) + description: A callback triggered every time an Order is updated status to "inProgress" (Description) + externalDocs: + description: Find out more + url: 'https://more-details.com/demo' + requestBody: + content: + application/json: + schema: + type: object + properties: + orderId: + type: string + example: '123' + timestamp: + type: string + format: date-time + example: '2018-10-19T16:46:45Z' + status: + type: string + example: 'inProgress' + application/xml: + schema: + type: object + properties: + orderId: + type: string + example: '123' + example: | + + + 123 + inProgress + 2018-10-19T16:46:45Z + + responses: + '200': + description: Callback successfully processed and no retries will be performed + content: + application/json: + schema: + type: object + properties: + someProp: + type: string + example: '123' + '299': + description: Response for cancelling subscription + '500': + description: Callback processing failed and retries will be performed + x-codeSamples: + - lang: 'C#' + source: | + PetStore.v1.Pet pet = new PetStore.v1.Pet(); + pet.setApiKey("your api key"); + pet.petType = PetStore.v1.Pet.TYPE_DOG; + pet.name = "Rex"; + // set other fields + PetStoreResponse response = pet.create(); + if (response.statusCode == HttpStatusCode.Created) + { + // Successfully created + } + else + { + // Something wrong -- check response for errors + Console.WriteLine(response.getRawResponse()); + } + - lang: PHP + source: | + $form = new \PetStore\Entities\Pet(); + $form->setPetType("Dog"); + $form->setName("Rex"); + // set other fields + try { + $pet = $client->pets()->create($form); + } catch (UnprocessableEntityException $e) { + var_dump($e->getErrors()); + } + put: + description: Order in Progress (Only Description) + servers: + - url: //callback-url.operation-level/v1 + description: Operation level server 1 (Operation override) + - url: //callback-url.operation-level/v2 + description: Operation level server 2 (Operation override) + requestBody: + content: + application/json: + schema: + type: object + properties: + orderId: + type: string + example: '123' + timestamp: + type: string + format: date-time + example: '2018-10-19T16:46:45Z' + status: + type: string + example: 'inProgress' + application/xml: + schema: + type: object + properties: + orderId: + type: string + example: '123' + example: | + + + 123 + inProgress + 2018-10-19T16:46:45Z + + responses: + '200': + description: Callback successfully processed and no retries will be performed + content: + application/json: + schema: + type: object + properties: + someProp: + type: string + example: '123' + orderShipped: + '{$request.body#/callbackUrl}?event={$request.body#/eventName}': + post: + description: | + Very long description + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor + incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis + nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. + Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu + fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in + culpa qui officia deserunt mollit anim id est laborum. + requestBody: + content: + application/json: + schema: + type: object + properties: + orderId: + type: string + example: '123' + timestamp: + type: string + format: date-time + example: '2018-10-19T16:46:45Z' + estimatedDeliveryDate: + type: string + format: date-time + example: '2018-11-11T16:00:00Z' + responses: + '200': + description: Callback successfully processed and no retries will be performed + orderDelivered: + 'http://notificationServer.com?url={$request.body#/callbackUrl}&event={$request.body#/eventName}': + post: + deprecated: true + summary: Order delivered + description: A callback triggered every time an Order is delivered to the recipient + requestBody: + content: + application/json: + schema: + type: object + properties: + orderId: + type: string + example: '123' + timestamp: + type: string + format: date-time + example: '2018-10-19T16:46:45Z' + responses: + '200': + description: Callback successfully processed and no retries will be performed + /user: + post: + tags: + - user + summary: Create user + description: This can only be done by the logged in user. + operationId: createUser + responses: + default: + description: successful operation + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/User' + description: Created user object + required: true + '/user/{username}': + get: + tags: + - user + summary: Get user by user name + description: '' + operationId: getUserByName + parameters: + - name: username + in: path + description: 'The name that needs to be fetched. Use user1 for testing. ' + required: true + schema: + type: string + responses: + '200': + description: successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/User' + application/xml: + schema: + $ref: '#/components/schemas/User' + '400': + description: Invalid username supplied + '404': + description: User not found + put: + tags: + - user + summary: Updated user + description: This can only be done by the logged in user. + operationId: updateUser + parameters: + - name: username + in: path + description: name that need to be deleted + required: true + schema: + type: string + responses: + '400': + description: Invalid user supplied + '404': + description: User not found + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/User' + description: Updated user object + required: true + delete: + tags: + - user + summary: Delete user + description: This can only be done by the logged in user. + operationId: deleteUser + parameters: + - name: username + in: path + description: The name that needs to be deleted + required: true + schema: + type: string + responses: + '400': + description: Invalid username supplied + '404': + description: User not found + /user/createWithArray: + post: + tags: + - user + summary: Creates list of users with given input array + description: '' + operationId: createUsersWithArrayInput + responses: + default: + description: successful operation + requestBody: + $ref: '#/components/requestBodies/UserArray' + /user/createWithList: + post: + tags: + - user + summary: Creates list of users with given input array + description: '' + operationId: createUsersWithListInput + responses: + default: + description: successful operation + requestBody: + $ref: '#/components/requestBodies/UserArray' + /user/login: + get: + tags: + - user + summary: Logs user into the system + description: '' + operationId: loginUser + parameters: + - name: username + in: query + description: The user name for login + required: true + schema: + type: string + - name: password + in: query + description: The password for login in clear text + required: true + schema: + type: string + responses: + '200': + description: successful operation + headers: + X-Rate-Limit: + description: calls per hour allowed by the user + schema: + type: integer + format: int32 + X-Expires-After: + description: date in UTC when token expires + schema: + type: string + format: date-time + content: + application/json: + schema: + type: string + examples: + response: + value: OK + application/xml: + schema: + type: string + examples: + response: + value: OK + text/plain: + examples: + response: + value: OK + '400': + description: Invalid username/password supplied + /user/logout: + get: + tags: + - user + summary: Logs out current logged in user session + description: '' + operationId: logoutUser + responses: + default: + description: successful operation +components: + schemas: + ApiResponse: + type: object + properties: + code: + type: integer + format: int32 + type: + type: string + message: + type: string + Order: + type: object + properties: + id: + description: Order ID + allOf: + - $ref: 'components/pets.yaml#/components/schemas/Id' + petId: + description: Pet ID + allOf: + - $ref: 'components/pets.yaml#/components/schemas/Id' + quantity: + type: integer + format: int32 + minimum: 1 + default: 1 + shipDate: + description: Estimated ship date + type: string + format: date-time + status: + type: string + description: Order Status + enum: + - placed + - approved + - delivered + complete: + description: Indicates whenever order was completed or not + type: boolean + default: false + readOnly: true + requestId: + description: Unique Request Id + type: string + writeOnly: true + xml: + name: Order + User: + type: object + properties: + id: + $ref: 'components/pets.yaml#/components/schemas/Id' + pet: + oneOf: + - $ref: 'components/pets.yaml#/components/schemas/Pet' + - $ref: 'components/pets.yaml#/components/schemas/Tag' + username: + description: User supplied username + type: string + minLength: 4 + example: John78 + firstName: + description: User first name + type: string + minLength: 1 + example: John + lastName: + description: User last name + type: string + minLength: 1 + example: Smith + email: + description: User email address + type: string + format: email + example: john.smith@example.com + password: + type: string + description: >- + User password, MUST contain a mix of upper and lower case letters, + as well as digits + format: password + minLength: 8 + pattern: '/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])/' + example: drowssaP123 + phone: + description: User phone number in international format + type: string + pattern: '/^\+(?:[0-9]-?){6,14}[0-9]$/' + example: +1-202-555-0192 + userStatus: + description: User status + type: integer + format: int32 + xml: + name: User + requestBodies: + Pet: + content: + application/json: + schema: + allOf: + - description: My Pet + title: Pettie + - $ref: 'components/pets.yaml#/components/schemas/Pet' + application/xml: + schema: + type: 'object' + properties: + name: + type: string + description: hooray + description: Pet object that needs to be added to the store + required: true + UserArray: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/User' + description: List of user object + required: true + securitySchemes: + petstore_auth: + description: | + Get access to data while protecting your account credentials. + OAuth2 is also a safer and more secure way to give you access. + type: oauth2 + flows: + implicit: + authorizationUrl: 'http://petstore.swagger.io/api/oauth/dialog' + scopes: + 'write:pets': modify pets in your account + 'read:pets': read your pets + api_key: + description: > + For this sample, you can use the api key `special-key` to test the + authorization filters. + type: apiKey + name: api_key + in: header + examples: + Order: + value: + quantity: 1 + shipDate: '2018-10-19T16:46:45Z' + status: placed + complete: false +x-webhooks: + newPet: + post: + summary: New pet + description: Information about a new pet in the systems + operationId: newPet + tags: + - pet + requestBody: + content: + application/json: + schema: + $ref: 'components/pets.yaml#/components/schemas/Pet' + responses: + '200': + description: Return a 200 status to indicate that the data was received successfully diff --git a/package.json b/package.json index 67ab87097..40a97baff 100644 --- a/package.json +++ b/package.json @@ -28,6 +28,7 @@ "prism-react-renderer": "^1.3.1", "react": "^17.0.2", "react-dom": "^17.0.2", + "redocusaurus": "^1.3.0", "sass": "^1.50.1" }, "browserslist": { diff --git a/sidebars.js b/sidebars.js index d3524df2d..dcf934ace 100644 --- a/sidebars.js +++ b/sidebars.js @@ -2,139 +2,10 @@ /** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ const sidebars = { - tutorialSidebar: [ - "index", + myAutogeneratedSidebar: [ { - type: "category", - label: "Where to Start", - items: [ - "start/introduction", - "start/stellar-stack", - "start/list-of-operations", - ], - }, - { - type: "category", - label: "Tutorials", - items: [ - "tutorials/create-account", - "tutorials/send-and-receive-payments", - "tutorials/follow-received-payments", - "tutorials/handling-errors", - "tutorials/securing-projects", - ], - }, - { - type: "category", - label: "Issuing Assets", - items: [ - "issuing-assets/index", - "issuing-assets/anatomy-of-an-asset", - "issuing-assets/how-to-issue-an-asset", - "issuing-assets/publishing-asset-info", - "issuing-assets/control-asset-access", - ], - }, - { - type: "category", - label: "Anchor Assets", - items: [ - "anchoring-assets/index", - { - type: "category", - label: "Enabling Cross-border Payments", - link: { - type: "doc", - id: "anchoring-assets/enabling-cross-border-payments/index", - }, - items: [ - "anchoring-assets/enabling-cross-border-payments/reference-implementations", - "anchoring-assets/enabling-cross-border-payments/setting-up-test-server", - "anchoring-assets/enabling-cross-border-payments/setting-up-production-server", - "anchoring-assets/enabling-cross-border-payments/launch", - ], - }, - { - type: "category", - label: "Enable Deposits and Withdrawals", - link: { - type: "doc", - id: "anchoring-assets/enabling-deposit-and-withdrawal/index", - }, - items: [ - "anchoring-assets/enabling-deposit-and-withdrawal/reference-implementations", - "anchoring-assets/enabling-deposit-and-withdrawal/setting-up-test-server", - "anchoring-assets/enabling-deposit-and-withdrawal/setting-up-production-server", - "anchoring-assets/enabling-deposit-and-withdrawal/launch", - ], - }, - ], - }, - { - type: "category", - label: "Build Apps", - items: [ - "building-apps/index", - "building-apps/project-setup", - "building-apps/key-management", - "building-apps/basic-wallet", - "building-apps/setup-custodial-account", - "building-apps/xlm-payments", - "building-apps/custom-assets", - "building-apps/first-deposit", - { - type: "category", - label: "Deposit and Withdraw From Anchors", - link: { type: "doc", id: "building-apps/connect-to-anchors/index" }, - items: [ - "building-apps/connect-to-anchors/setup-for-anchored-assets", - "building-apps/connect-to-anchors/deposit-anchored-assets", - "building-apps/connect-to-anchors/withdraw-anchored-assets", - ], - }, - ], - }, - { - type: "category", - label: "Run a Core Node", - items: [ - "run-core-node/index", - "run-core-node/prerequisites", - "run-core-node/installation", - "run-core-node/configuring", - "run-core-node/publishing-history-archives", - "run-core-node/running-node", - "run-core-node/monitoring", - "run-core-node/commands", - "run-core-node/network-upgrades", - "run-core-node/tier-1-orgs", - ], - }, - { - type: "category", - label: "Run an API Server", - items: [ - "run-api-server/index", - "run-api-server/prerequisites", - "run-api-server/migrating", - "run-api-server/installing", - "run-api-server/configuring", - "run-api-server/remote-core", - "run-api-server/running", - "run-api-server/ingestion", - "run-api-server/monitoring", - "run-api-server/scaling", - ], - }, - { - type: "category", - label: "Software and SDKs", - items: ["software-and-sdks/index"], - }, - { - type: "category", - label: "Glossary", - items: [{ type: "autogenerated", dirName: "glossary" }], + type: 'autogenerated', + dirName: '.', }, ], }; diff --git a/docs/web-assets/SEP24-state-diagram.png b/static/assets/SEP24-state-diagram.png similarity index 100% rename from docs/web-assets/SEP24-state-diagram.png rename to static/assets/SEP24-state-diagram.png diff --git a/docs/web-assets/anchor-validation-suite.png b/static/assets/anchor-validation-suite.png similarity index 100% rename from docs/web-assets/anchor-validation-suite.png rename to static/assets/anchor-validation-suite.png diff --git a/docs/web-assets/demo-client.png b/static/assets/demo-client.png similarity index 100% rename from docs/web-assets/demo-client.png rename to static/assets/demo-client.png diff --git a/docs/web-assets/demo-wallet-sep31.png b/static/assets/demo-wallet-sep31.png similarity index 100% rename from docs/web-assets/demo-wallet-sep31.png rename to static/assets/demo-wallet-sep31.png diff --git a/docs/web-assets/demo_wallet_sep24dep.png b/static/assets/demo_wallet_sep24dep.png similarity index 100% rename from docs/web-assets/demo_wallet_sep24dep.png rename to static/assets/demo_wallet_sep24dep.png diff --git a/docs/web-assets/first-deposit-anchor-flow.png b/static/assets/first-deposit-anchor-flow.png similarity index 100% rename from docs/web-assets/first-deposit-anchor-flow.png rename to static/assets/first-deposit-anchor-flow.png diff --git a/docs/web-assets/first-deposit-claimable-balance-flow.png b/static/assets/first-deposit-claimable-balance-flow.png similarity index 100% rename from docs/web-assets/first-deposit-claimable-balance-flow.png rename to static/assets/first-deposit-claimable-balance-flow.png diff --git a/docs/web-assets/first-deposit-wallet-flow.png b/static/assets/first-deposit-wallet-flow.png similarity index 100% rename from docs/web-assets/first-deposit-wallet-flow.png rename to static/assets/first-deposit-wallet-flow.png diff --git a/docs/web-assets/horizon-scaling/Topology-1VM.png b/static/assets/horizon-scaling/Topology-1VM.png similarity index 100% rename from docs/web-assets/horizon-scaling/Topology-1VM.png rename to static/assets/horizon-scaling/Topology-1VM.png diff --git a/docs/web-assets/horizon-scaling/Topology-2VMs.png b/static/assets/horizon-scaling/Topology-2VMs.png similarity index 100% rename from docs/web-assets/horizon-scaling/Topology-2VMs.png rename to static/assets/horizon-scaling/Topology-2VMs.png diff --git a/docs/web-assets/horizon-scaling/Topology-3VMs.png b/static/assets/horizon-scaling/Topology-3VMs.png similarity index 100% rename from docs/web-assets/horizon-scaling/Topology-3VMs.png rename to static/assets/horizon-scaling/Topology-3VMs.png diff --git a/docs/web-assets/horizon-scaling/Topology-Enterprise-HotBackup.png b/static/assets/horizon-scaling/Topology-Enterprise-HotBackup.png similarity index 100% rename from docs/web-assets/horizon-scaling/Topology-Enterprise-HotBackup.png rename to static/assets/horizon-scaling/Topology-Enterprise-HotBackup.png diff --git a/docs/web-assets/horizon-scaling/Topology-Enterprise.png b/static/assets/horizon-scaling/Topology-Enterprise.png similarity index 100% rename from docs/web-assets/horizon-scaling/Topology-Enterprise.png rename to static/assets/horizon-scaling/Topology-Enterprise.png diff --git a/docs/web-assets/orderbook.png b/static/assets/orderbook.png similarity index 100% rename from docs/web-assets/orderbook.png rename to static/assets/orderbook.png diff --git a/docs/web-assets/polaris.png b/static/assets/polaris.png similarity index 100% rename from docs/web-assets/polaris.png rename to static/assets/polaris.png diff --git a/docs/web-assets/ready-to-rock.png b/static/assets/ready-to-rock.png similarity index 100% rename from docs/web-assets/ready-to-rock.png rename to static/assets/ready-to-rock.png diff --git a/docs/web-assets/select-currency.png b/static/assets/select-currency.png similarity index 100% rename from docs/web-assets/select-currency.png rename to static/assets/select-currency.png diff --git a/docs/web-assets/stellar-wallet-file.png b/static/assets/stellar-wallet-file.png similarity index 100% rename from docs/web-assets/stellar-wallet-file.png rename to static/assets/stellar-wallet-file.png diff --git a/docs/web-assets/wallet-mgi-architecture-1.png b/static/assets/wallet-mgi-architecture-1.png similarity index 100% rename from docs/web-assets/wallet-mgi-architecture-1.png rename to static/assets/wallet-mgi-architecture-1.png diff --git a/docs/web-assets/wallet-mgi-architecture-2.png b/static/assets/wallet-mgi-architecture-2.png similarity index 100% rename from docs/web-assets/wallet-mgi-architecture-2.png rename to static/assets/wallet-mgi-architecture-2.png diff --git a/yarn.lock b/yarn.lock index a8bf39a1c..f20b1baed 100644 --- a/yarn.lock +++ b/yarn.lock @@ -211,7 +211,16 @@ "@jridgewell/gen-mapping" "^0.3.2" jsesc "^2.5.1" -"@babel/helper-annotate-as-pure@^7.18.6": +"@babel/generator@^7.18.10": + version "7.18.12" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.18.12.tgz#fa58daa303757bd6f5e4bbca91b342040463d9f4" + integrity sha512-dfQ8ebCN98SvyL7IxNMCUtZQSq5R7kxgN+r8qYTGDmmSion1hX2C0zq2yo1bsCDhXixokv1SAWTZUMYbO/V5zg== + dependencies: + "@babel/types" "^7.18.10" + "@jridgewell/gen-mapping" "^0.3.2" + jsesc "^2.5.1" + +"@babel/helper-annotate-as-pure@^7.16.0", "@babel/helper-annotate-as-pure@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.18.6.tgz#eaa49f6f80d5a33f9a5dd2276e6d6e451be0a6bb" integrity sha512-duORpUiYrEpzKIop6iNbjnwKLAKnJ47csTyRACyEmWj0QdUrm5aqNJGHSSEQSUAvNW0ojX0dOmK9dZduvkfeXA== @@ -276,6 +285,11 @@ resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.6.tgz#b7eee2b5b9d70602e59d1a6cad7dd24de7ca6cd7" integrity sha512-8n6gSfn2baOY+qlp+VSzsosjCVGFqWKmDF0cCWOybh52Dw3SEyoWR1KrhMJASjLwIEkkAufZ0xvr+SxLHSpy2Q== +"@babel/helper-environment-visitor@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz#0c0cee9b35d2ca190478756865bb3528422f51be" + integrity sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg== + "@babel/helper-explode-assignable-expression@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.18.6.tgz#41f8228ef0a6f1a036b8dfdfec7ce94f9a6bc096" @@ -291,6 +305,14 @@ "@babel/template" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helper-function-name@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.18.9.tgz#940e6084a55dee867d33b4e487da2676365e86b0" + integrity sha512-fJgWlZt7nxGksJS9a0XdSaI4XvpExnNIgRP+rVefWh5U7BL8pPuir6SJUmFKRfjWQ51OtWSzwOxhaH/EBWWc0A== + dependencies: + "@babel/template" "^7.18.6" + "@babel/types" "^7.18.9" + "@babel/helper-hoist-variables@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.18.6.tgz#d4d2c8fb4baeaa5c68b99cc8245c56554f926678" @@ -305,7 +327,7 @@ dependencies: "@babel/types" "^7.18.6" -"@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.18.6": +"@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.16.0", "@babel/helper-module-imports@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz#1e3ebdbbd08aad1437b428c50204db13c5a3ca6e" integrity sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA== @@ -385,6 +407,11 @@ dependencies: "@babel/types" "^7.18.6" +"@babel/helper-string-parser@^7.18.10": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.18.10.tgz#181f22d28ebe1b3857fa575f5c290b1aaf659b56" + integrity sha512-XtIfWmeNY3i4t7t4D2t02q50HvqHybPqW2ki1kosnvWCwuCMeo81Jf0gwr85jy/neUdg5XDdeFE/80DXiO+njw== + "@babel/helper-validator-identifier@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.18.6.tgz#9c97e30d31b2b8c72a1d08984f2ca9b574d7a076" @@ -428,6 +455,11 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.8.tgz#822146080ac9c62dac0823bb3489622e0bc1cbdf" integrity sha512-RSKRfYX20dyH+elbJK2uqAkVyucL+xXzhqlMD5/ZXx+dAAwpyB7HsvnHe/ZUGOF+xLr5Wx9/JoXVTj6BQE2/oA== +"@babel/parser@^7.18.11": + version "7.18.11" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.11.tgz#68bb07ab3d380affa9a3f96728df07969645d2d9" + integrity sha512-9JKn5vN+hDt0Hdqn1PiJ2guflwP+B6Ga8qbDuoF0PzzVhrzsKIJo8yGqVk6CmMHiMei9w1C1Bp9IMJSIK+HPIQ== + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.18.6.tgz#da5b8f9a580acdfbe53494dba45ea389fb09a4d2" @@ -1182,6 +1214,13 @@ dependencies: regenerator-runtime "^0.13.4" +"@babel/runtime@^7.17.8": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.18.9.tgz#b4fcfce55db3d2e5e080d2490f608a3b9f407f4a" + integrity sha512-lkqXDcvlFT5rvEjiu6+QYO+1GXrEHRo2LOtS7E4GtX5ESIZOgepqsZBVIj6Pv+a6zqsya9VCgiK1KAK4BvJDAw== + dependencies: + regenerator-runtime "^0.13.4" + "@babel/template@^7.12.7", "@babel/template@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.6.tgz#1283f4993e00b929d6e2d3c72fdc9168a2977a31" @@ -1207,6 +1246,22 @@ debug "^4.1.0" globals "^11.1.0" +"@babel/traverse@^7.4.5": + version "7.18.11" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.18.11.tgz#3d51f2afbd83ecf9912bcbb5c4d94e3d2ddaa16f" + integrity sha512-TG9PiM2R/cWCAy6BPJKeHzNbu4lPzOSZpeMfeNErskGpTJx6trEvFaVCbDvpcxwy49BKWmEPwiW8mrysNiDvIQ== + dependencies: + "@babel/code-frame" "^7.18.6" + "@babel/generator" "^7.18.10" + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-function-name" "^7.18.9" + "@babel/helper-hoist-variables" "^7.18.6" + "@babel/helper-split-export-declaration" "^7.18.6" + "@babel/parser" "^7.18.11" + "@babel/types" "^7.18.10" + debug "^4.1.0" + globals "^11.1.0" + "@babel/types@^7.12.7", "@babel/types@^7.15.6", "@babel/types@^7.18.6", "@babel/types@^7.18.7", "@babel/types@^7.18.8", "@babel/types@^7.4.4": version "7.18.8" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.8.tgz#c5af199951bf41ba4a6a9a6d0d8ad722b30cd42f" @@ -1215,6 +1270,15 @@ "@babel/helper-validator-identifier" "^7.18.6" to-fast-properties "^2.0.0" +"@babel/types@^7.18.10", "@babel/types@^7.18.9": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.10.tgz#4908e81b6b339ca7c6b7a555a5fc29446f26dde6" + integrity sha512-MJvnbEiiNkpjo+LknnmRrqbY1GPUUggjv+wQVjetM/AONoupqRALB7I6jGqNUAZsKcRIEu2J6FRFvsczljjsaQ== + dependencies: + "@babel/helper-string-parser" "^7.18.10" + "@babel/helper-validator-identifier" "^7.18.6" + to-fast-properties "^2.0.0" + "@braintree/sanitize-url@^3.1.0": version "3.1.0" resolved "https://registry.yarnpkg.com/@braintree/sanitize-url/-/sanitize-url-3.1.0.tgz#8ff71d51053cd5ee4981e5a501d80a536244f7fd" @@ -1645,6 +1709,28 @@ url-loader "^4.1.1" webpack "^5.73.0" +"@emotion/is-prop-valid@^1.1.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@emotion/is-prop-valid/-/is-prop-valid-1.2.0.tgz#7f2d35c97891669f7e276eb71c83376a5dc44c83" + integrity sha512-3aDpDprjM0AwaxGE09bOPkNxHpBd+kA6jty3RnaEXdweX1DF1U3VQpPYb0g1IStAuK7SVQ1cy+bNBBKp4W3Fjg== + dependencies: + "@emotion/memoize" "^0.8.0" + +"@emotion/memoize@^0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@emotion/memoize/-/memoize-0.8.0.tgz#f580f9beb67176fa57aae70b08ed510e1b18980f" + integrity sha512-G/YwXTkv7Den9mXDO7AhLWkE3q+I92B+VqAE+dYG4NGPaHZGvt3G8Q0p9vmE+sq7rTGphUbAvmQ9YpbfMQGGlA== + +"@emotion/stylis@^0.8.4": + version "0.8.5" + resolved "https://registry.yarnpkg.com/@emotion/stylis/-/stylis-0.8.5.tgz#deacb389bd6ee77d1e7fcaccce9e16c5c7e78e04" + integrity sha512-h6KtPihKFn3T9fuIrwvXXUOwlx3rfUvfZIcP5a6rh8Y7zjE3O06hT5Ss4S/YI1AYhuZ1kjaE/5EaOOI2NqSylQ== + +"@emotion/unitless@^0.7.4": + version "0.7.5" + resolved "https://registry.yarnpkg.com/@emotion/unitless/-/unitless-0.7.5.tgz#77211291c1900a700b8a78cfafda3160d76949ed" + integrity sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg== + "@es-joy/jsdoccomment@~0.31.0": version "0.31.0" resolved "https://registry.yarnpkg.com/@es-joy/jsdoccomment/-/jsdoccomment-0.31.0.tgz#dbc342cc38eb6878c12727985e693eaef34302bc" @@ -1669,6 +1755,11 @@ minimatch "^3.1.2" strip-json-comments "^3.1.1" +"@exodus/schemasafe@^1.0.0-rc.2": + version "1.0.0-rc.7" + resolved "https://registry.yarnpkg.com/@exodus/schemasafe/-/schemasafe-1.0.0-rc.7.tgz#aded6839c2369883dafa46608a135c82b42ed76b" + integrity sha512-+1mBLsa+vvlV0lwEAP1hwgmOPkjMnoJ8hyCMfCCJga0sVDwDzrPJjnxZwdDaUmOh/vbFHQGBTk+FxsVjoI/CjQ== + "@hapi/hoek@^9.0.0": version "9.3.0" resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-9.3.0.tgz#8368869dcb735be2e7f5cb7647de78e167a251fb" @@ -1809,6 +1900,48 @@ resolved "https://registry.yarnpkg.com/@polka/url/-/url-1.0.0-next.21.tgz#5de5a2385a35309427f6011992b544514d559aa1" integrity sha512-a5Sab1C4/icpTZVzZc5Ghpz88yQtGOyNqYXcZgOssB2uuAr+wF/MvN6bgtW32q7HHrvBki+BsZ0OuNv6EV3K9g== +"@redocly/ajv@^8.6.4": + version "8.6.5" + resolved "https://registry.yarnpkg.com/@redocly/ajv/-/ajv-8.6.5.tgz#b6e737248b791905b3f600fb329779a807f0f774" + integrity sha512-3P2TY/u4c6OBqkP+1cTH1iGAEv0O34PV3vV2Wnos/nNHu62OTrtC4zcaxttG0pHtPtn42StrhGq7SsiFgP4Bfw== + dependencies: + fast-deep-equal "^3.1.1" + json-schema-traverse "^1.0.0" + require-from-string "^2.0.2" + uri-js "^4.2.2" + +"@redocly/openapi-core@1.0.0-beta.102": + version "1.0.0-beta.102" + resolved "https://registry.yarnpkg.com/@redocly/openapi-core/-/openapi-core-1.0.0-beta.102.tgz#e1cd049979f05812c594063fec71e618201319c4" + integrity sha512-3Fr3fg+9VEF4+4uoyvOOk+9ipmX2GYhlb18uZbpC4v3cUgGpkTRGZM2Qetfah7Tgx2LgqLuw8A1icDD6Zed2Gw== + dependencies: + "@redocly/ajv" "^8.6.4" + "@types/node" "^14.11.8" + colorette "^1.2.0" + js-levenshtein "^1.1.6" + js-yaml "^4.1.0" + lodash.isequal "^4.5.0" + minimatch "^5.0.1" + node-fetch "^2.6.1" + pluralize "^8.0.0" + yaml-ast-parser "0.0.43" + +"@redocly/openapi-core@^1.0.0-beta.97": + version "1.0.0-beta.106" + resolved "https://registry.yarnpkg.com/@redocly/openapi-core/-/openapi-core-1.0.0-beta.106.tgz#5df810aee2ed64ecadf3d5100d8fbdf0d74c2924" + integrity sha512-ZHeczZ6iJrHL7K1v4s+NRFUOHsfZ1ZrB+bcS42CP4bhL/Y17PkOMWA+6Ubk0NVT4Ihdt5cLLWGfjVABD/bEM2A== + dependencies: + "@redocly/ajv" "^8.6.4" + "@types/node" "^14.11.8" + colorette "^1.2.0" + js-levenshtein "^1.1.6" + js-yaml "^4.1.0" + lodash.isequal "^4.5.0" + minimatch "^5.0.1" + node-fetch "^2.6.1" + pluralize "^8.0.0" + yaml-ast-parser "0.0.43" + "@rushstack/eslint-patch@^1.1.0": version "1.1.4" resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.1.4.tgz#0c8b74c50f29ee44f423f7416829c0bf8bb5eb27" @@ -2075,7 +2208,7 @@ dependencies: "@types/node" "*" -"@types/json-schema@*", "@types/json-schema@^7.0.4", "@types/json-schema@^7.0.5", "@types/json-schema@^7.0.8", "@types/json-schema@^7.0.9": +"@types/json-schema@*", "@types/json-schema@^7.0.4", "@types/json-schema@^7.0.5", "@types/json-schema@^7.0.7", "@types/json-schema@^7.0.8", "@types/json-schema@^7.0.9": version "7.0.11" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.11.tgz#d421b6c527a3037f7c84433fd2c4229e016863d3" integrity sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ== @@ -2102,6 +2235,11 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-18.0.3.tgz#463fc47f13ec0688a33aec75d078a0541a447199" integrity sha512-HzNRZtp4eepNitP+BD6k2L6DROIDG4Q0fm4x+dwfsr6LGmROENnok75VGw40628xf+iR24WeMFcHuuBDUAzzsQ== +"@types/node@^14.11.8": + version "14.18.23" + resolved "https://registry.yarnpkg.com/@types/node/-/node-14.18.23.tgz#70f5f20b0b1b38f696848c1d3647bb95694e615e" + integrity sha512-MhbCWN18R4GhO8ewQWAFK4TGQdBpXWByukz7cWyJmXhvRuCIaM/oWytGPqVmDzgEnnaIc9ss6HbU5mUi+vyZPA== + "@types/node@^17.0.5": version "17.0.45" resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.45.tgz#2c0fafd78705e7a18b7906b5201a522719dc5190" @@ -2772,6 +2910,22 @@ babel-plugin-polyfill-regenerator@^0.3.1: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" +"babel-plugin-styled-components@>= 1.12.0": + version "2.0.7" + resolved "https://registry.yarnpkg.com/babel-plugin-styled-components/-/babel-plugin-styled-components-2.0.7.tgz#c81ef34b713f9da2b7d3f5550df0d1e19e798086" + integrity sha512-i7YhvPgVqRKfoQ66toiZ06jPNA3p6ierpfUuEWxNF+fV27Uv5gxBkf8KZLHUCc1nFA9j6+80pYoIpqCeyW3/bA== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-module-imports" "^7.16.0" + babel-plugin-syntax-jsx "^6.18.0" + lodash "^4.17.11" + picomatch "^2.3.0" + +babel-plugin-syntax-jsx@^6.18.0: + version "6.18.0" + resolved "https://registry.yarnpkg.com/babel-plugin-syntax-jsx/-/babel-plugin-syntax-jsx-6.18.0.tgz#0af32a9a6e13ca7a3fd5069e62d7b0f58d0d8946" + integrity sha512-qrPaCSo9c8RHNRHIotaufGbuOBN8rtdC4QrrFFc43vyWCCz7Kl7GL1PGaXtMGQZUXrkCjNEgxDfmAuAabr/rlw== + babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-remove-prop-types/-/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" @@ -2898,6 +3052,13 @@ brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" +brace-expansion@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.1.tgz#1edc459e0f0c548486ecf9fc99f2221364b9a0ae" + integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA== + dependencies: + balanced-match "^1.0.0" + braces@^3.0.2, braces@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" @@ -2951,6 +3112,11 @@ call-bind@^1.0.0, call-bind@^1.0.2: function-bind "^1.1.1" get-intrinsic "^1.0.2" +call-me-maybe@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/call-me-maybe/-/call-me-maybe-1.0.1.tgz#26d208ea89e37b5cbde60250a15f031c16a4d66b" + integrity sha512-wCyFsDQkKPwwF8BDwOiWNx/9K45L/hvggQiDbve+viMNMQnWhrlYIuBk09offfwCRtCO9P6XwUttufzU11WCVw== + callsites@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" @@ -2974,6 +3140,11 @@ camelcase@^6.2.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== +camelize@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/camelize/-/camelize-1.0.0.tgz#164a5483e630fa4321e5af07020e531831b2609b" + integrity sha512-W2lPwkBkMZwFlPCXhIlYgxu+7gC/NUlCtdK652DAJ1JdgV0sTrvuPFshNPrFa1TY2JOkLhgdeEBplB4ezEa+xg== + caniuse-api@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/caniuse-api/-/caniuse-api-3.0.0.tgz#5e4d90e2274961d46291997df599e3ed008ee4c0" @@ -3076,6 +3247,11 @@ ci-info@^2.0.0: resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-2.0.0.tgz#67a9e964be31a51e15e5010d58e6f12834002f46" integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== +classnames@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/classnames/-/classnames-2.3.1.tgz#dfcfa3891e306ec1dad105d0e88f4417b8535e8e" + integrity sha512-OlQdbZ7gLfGarSqxesMesDa5uz7KFbID8Kpq/SxIoNGDqY8lSYs0D+hhtBXhcdB3rcbXArFr7vlHheLk1voeNA== + clean-css@^5.2.2, clean-css@^5.3.0: version "5.3.0" resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-5.3.0.tgz#ad3d8238d5f3549e83d5f87205189494bc7cbb59" @@ -3107,6 +3283,15 @@ cli-table3@^0.6.2: optionalDependencies: "@colors/colors" "1.5.0" +cliui@^7.0.2: + version "7.0.4" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-7.0.4.tgz#a0265ee655476fc807aea9df3df8df7783808b4f" + integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^7.0.0" + clone-deep@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/clone-deep/-/clone-deep-4.0.1.tgz#c19fd9bdbbf85942b4fd979c84dcf7d5f07c2387" @@ -3123,7 +3308,7 @@ clone-response@^1.0.2: dependencies: mimic-response "^1.0.0" -clsx@^1.1.1, clsx@^1.2.1: +clsx@^1.1.0, clsx@^1.1.1, clsx@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.2.1.tgz#0ddc4a20a549b59c93a4116bb26f5294ca17dc12" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== @@ -3162,6 +3347,11 @@ colord@^2.9.1: resolved "https://registry.yarnpkg.com/colord/-/colord-2.9.2.tgz#25e2bacbbaa65991422c07ea209e2089428effb1" integrity sha512-Uqbg+J445nc1TKn4FoDPS6ZZqAvEDnwrH42yo8B40JSOgSLxMZ/gt3h4nmCtPLQeXhjJJkqBx7SCY35WnIixaQ== +colorette@^1.2.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/colorette/-/colorette-1.4.0.tgz#5190fbb87276259a86ad700bff2c6d6faa3fca40" + integrity sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g== + colorette@^2.0.10: version "2.0.19" resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.19.tgz#cdf044f47ad41a0f4b56b3a0d5b4e6e1a2d5a798" @@ -3310,6 +3500,19 @@ copy-webpack-plugin@^11.0.0: schema-utils "^4.0.0" serialize-javascript "^6.0.0" +copyfiles@^2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/copyfiles/-/copyfiles-2.4.1.tgz#d2dcff60aaad1015f09d0b66e7f0f1c5cd3c5da5" + integrity sha512-fereAvAvxDrQDOXybk3Qu3dPbOoKoysFMWtkY3mv5BsL8//OSZVL5DCLYqgRfY5cWirgRzlC+WSrxp6Bo3eNZg== + dependencies: + glob "^7.0.5" + minimatch "^3.0.3" + mkdirp "^1.0.4" + noms "0.0.0" + through2 "^2.0.1" + untildify "^4.0.0" + yargs "^16.1.0" + core-js-compat@^3.21.0, core-js-compat@^3.22.1: version "3.23.3" resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.23.3.tgz#7d8503185be76bb6d8d592c291a4457a8e440aa9" @@ -3376,6 +3579,11 @@ crypto-random-string@^2.0.0: resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-2.0.0.tgz#ef2a7a966ec11083388369baa02ebead229b30d5" integrity sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA== +css-color-keywords@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/css-color-keywords/-/css-color-keywords-1.0.0.tgz#fea2616dc676b2962686b3af8dbdbe180b244e05" + integrity sha512-FyyrDHZKEjXDpNJYvVsV960FiqQyXc/LlYmsxl2BcdMb2WPx0OGRVgTg55rPSyLSNMqP52R9r8geSp7apN3Ofg== + css-declaration-sorter@^6.3.0: version "6.3.0" resolved "https://registry.yarnpkg.com/css-declaration-sorter/-/css-declaration-sorter-6.3.0.tgz#72ebd995c8f4532ff0036631f7365cce9759df14" @@ -3429,6 +3637,15 @@ css-select@^5.1.0: domutils "^3.0.1" nth-check "^2.0.1" +css-to-react-native@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/css-to-react-native/-/css-to-react-native-3.0.0.tgz#62dbe678072a824a689bcfee011fc96e02a7d756" + integrity sha512-Ro1yETZA813eoyUp2GDBhG2j+YggidUmzO1/v9eYBKR2EHVEniE2MI/NqpTQ954BMpTPZFsGNPm46qFB9dpaPQ== + dependencies: + camelize "^1.0.0" + css-color-keywords "^1.0.0" + postcss-value-parser "^4.0.2" + css-tree@^1.1.2, css-tree@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.1.3.tgz#eb4870fb6fd7707327ec95c2ff2ab09b5e8db91d" @@ -4056,6 +4273,11 @@ debug@^4.1.0, debug@^4.1.1, debug@^4.3.2, debug@^4.3.4: dependencies: ms "2.1.2" +decko@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/decko/-/decko-1.2.0.tgz#fd43c735e967b8013306884a56fbe665996b6817" + integrity sha512-m8FnyHXV1QX+S1cl+KPFDIl6NMkxtKsy6+U/aYyjrOqWMuwAwYWu7ePqrsUHtDR5Y8Yk2pi/KIDSgF+vT4cPOQ== + decompress-response@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/decompress-response/-/decompress-response-3.3.0.tgz#80a4dd323748384bfa248083622aedec982adff3" @@ -4200,6 +4422,15 @@ doctrine@^3.0.0: dependencies: esutils "^2.0.2" +docusaurus-plugin-redoc@1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/docusaurus-plugin-redoc/-/docusaurus-plugin-redoc-1.2.3.tgz#24be9d5f38ee126133fd0173a56aab743bc44b42" + integrity sha512-1g7rBlQVtfz6Ham7tXkyTOxNxSG+uNnoz7GqoTcyBWSKGYyG64Acxh37l4mlhAZVrIK4ZpTr+BsRb4O5UDdbLg== + dependencies: + "@redocly/openapi-core" "1.0.0-beta.102" + joi "^17.5.0" + redoc "2.0.0-rc.72" + docusaurus-plugin-sass@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/docusaurus-plugin-sass/-/docusaurus-plugin-sass-0.2.2.tgz#9b7f8c6fbe833677064ec05b09b98d90b50be324" @@ -4207,6 +4438,18 @@ docusaurus-plugin-sass@^0.2.2: dependencies: sass-loader "^10.1.1" +docusaurus-theme-redoc@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/docusaurus-theme-redoc/-/docusaurus-theme-redoc-1.3.0.tgz#ab5e2cd330981284def78522bab4f8ef4cd91590" + integrity sha512-MP/MjxKHRm3IYdl+LNa6aLFgPcpUDf1oYjob2ab1HV+LXtJcXCThaQpCwRk6Q8/CtYYfLQ259qx9jcssqnxSNQ== + dependencies: + clsx "^1.1.1" + copyfiles "^2.4.1" + lodash "^4.17.21" + mobx "^6.5.0" + redoc "2.0.0-rc.72" + styled-components "^5.3.5" + dom-converter@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/dom-converter/-/dom-converter-0.2.0.tgz#6721a9daee2e293682955b6afe416771627bb768" @@ -4256,6 +4499,11 @@ dompurify@2.3.5: resolved "https://registry.yarnpkg.com/dompurify/-/dompurify-2.3.5.tgz#c83ed5a3ae5ce23e52efe654ea052ffb358dd7e3" integrity sha512-kD+f8qEaa42+mjdOpKeztu9Mfx5bv9gVLO6K9jRx4uGvh6Wv06Srn4jr1wPNY2OOUGGSKHNFN+A8MA3v0E0QAQ== +dompurify@^2.2.8: + version "2.3.10" + resolved "https://registry.yarnpkg.com/dompurify/-/dompurify-2.3.10.tgz#901f7390ffe16a91a5a556b94043314cd4850385" + integrity sha512-o7Fg/AgC7p/XpKjf/+RC3Ok6k4St5F7Q6q6+Nnm3p2zGWioAY6dh0CbbuwOhH2UcSzKsdniE/YnE2/92JcsA+g== + domutils@^2.5.2, domutils@^2.8.0: version "2.8.0" resolved "https://registry.yarnpkg.com/domutils/-/domutils-2.8.0.tgz#4437def5db6e2d1f5d6ee859bd95ca7d02048135" @@ -4426,6 +4674,11 @@ es-to-primitive@^1.2.1: is-date-object "^1.0.1" is-symbol "^1.0.2" +es6-promise@^3.2.1: + version "3.3.1" + resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-3.3.1.tgz#a08cdde84ccdbf34d027a1451bc91d4bcd28a613" + integrity sha512-SOp9Phqvqn7jtEUxPWdWfWoLmyt2VaJ6MpvP9Comy1MceMXqE6bxvaTu4iaxpYYPzhny28Lc+M87/c2cPK6lDg== + escalade@^3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" @@ -4730,7 +4983,7 @@ eval@^0.1.8: "@types/node" "*" require-like ">= 0.1.1" -eventemitter3@^4.0.0: +eventemitter3@^4.0.0, eventemitter3@^4.0.7: version "4.0.7" resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" integrity sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw== @@ -4830,6 +5083,11 @@ fast-levenshtein@^2.0.6: resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw== +fast-safe-stringify@^2.0.7: + version "2.1.1" + resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz#c406a83b6e70d9e35ce3b30a81141df30aeba884" + integrity sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA== + fast-url-parser@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/fast-url-parser/-/fast-url-parser-1.1.3.tgz#f4af3ea9f34d8a271cf58ad2b3759f431f0b318d" @@ -4988,6 +5246,11 @@ follow-redirects@^1.0.0, follow-redirects@^1.14.7: resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.1.tgz#0ca6a452306c9b276e4d3127483e29575e207ad5" integrity sha512-yLAMQs+k0b2m7cVxpS1VKJVvoz7SS9Td1zss3XRwXj+ZDH00RJgnuLx7E44wx02kQLrdM3aOOy+FpzS7+8OizA== +foreach@^2.0.4: + version "2.0.6" + resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.6.tgz#87bcc8a1a0e74000ff2bf9802110708cfb02eb6e" + integrity sha512-k6GAGDyqLe9JaebCsFCoudPPWfihKu8pylYXRlqP1J7ms39iPoTtk2fviNglIeQEwdh0bQeKJ01ZPyuyQvKzwg== + fork-ts-checker-webpack-plugin@^6.5.0: version "6.5.2" resolved "https://registry.yarnpkg.com/fork-ts-checker-webpack-plugin/-/fork-ts-checker-webpack-plugin-6.5.2.tgz#4f67183f2f9eb8ba7df7177ce3cf3e75cdafb340" @@ -5086,6 +5349,11 @@ gensync@^1.0.0-beta.1, gensync@^1.0.0-beta.2: resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== +get-caller-file@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== + get-intrinsic@^1.0.2, get-intrinsic@^1.1.0, get-intrinsic@^1.1.1: version "1.1.2" resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.2.tgz#336975123e05ad0b7ba41f152ee4aadbea6cf598" @@ -5151,7 +5419,7 @@ glob-to-regexp@^0.4.1: resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e" integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== -glob@^7.0.0, glob@^7.1.3, glob@^7.1.6: +glob@^7.0.0, glob@^7.0.5, glob@^7.1.3, glob@^7.1.6: version "7.2.3" resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== @@ -5403,7 +5671,7 @@ history@^4.9.0: tiny-warning "^1.0.0" value-equal "^1.0.1" -hoist-non-react-statics@^3.1.0: +hoist-non-react-statics@^3.0.0, hoist-non-react-statics@^3.1.0: version "3.3.2" resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45" integrity sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw== @@ -5535,6 +5803,11 @@ http-proxy@^1.18.1: follow-redirects "^1.0.0" requires-port "^1.0.0" +http2-client@^1.2.5: + version "1.3.5" + resolved "https://registry.yarnpkg.com/http2-client/-/http2-client-1.3.5.tgz#20c9dc909e3cc98284dd20af2432c524086df181" + integrity sha512-EC2utToWl4RKfs5zd36Mxq7nzHHBuomZboI0yYL6Y0RmBgT7Sgkq4rQ0ezFTYoIsSs7Tm9SJe+o2FcAg6GBhGA== + human-signals@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" @@ -5617,7 +5890,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@2.0.4, inherits@^2.0.0, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.3: +inherits@2, inherits@2.0.4, inherits@^2.0.0, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.1, inherits@~2.0.3: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -5960,7 +6233,7 @@ jest-worker@^27.4.5, jest-worker@^27.5.1: merge-stream "^2.0.0" supports-color "^8.0.0" -joi@^17.6.0: +joi@^17.5.0, joi@^17.6.0: version "17.6.0" resolved "https://registry.yarnpkg.com/joi/-/joi-17.6.0.tgz#0bb54f2f006c09a96e75ce687957bd04290054b2" integrity sha512-OX5dG6DTbcr/kbMFj0KGYxuew69HPcAE3K/sZpEV2nP6e/j/C0HV+HNiBPCASxdx5T7DMoa0s8UeHWMnb6n2zw== @@ -5971,6 +6244,11 @@ joi@^17.6.0: "@sideway/formula" "^3.0.0" "@sideway/pinpoint" "^2.0.0" +js-levenshtein@^1.1.6: + version "1.1.6" + resolved "https://registry.yarnpkg.com/js-levenshtein/-/js-levenshtein-1.1.6.tgz#c6cee58eb3550372df8deb85fad5ce66ce01d59d" + integrity sha512-X2BB11YZtrRqY4EnQcLX5Rh373zbK4alC1FW7D7MBhL2gtcC17cTnr6DmfHZeS0s2rTHjUTMMHfG7gO8SSdw+g== + "js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" @@ -6016,6 +6294,13 @@ json-parse-even-better-errors@^2.3.0, json-parse-even-better-errors@^2.3.1: resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== +json-pointer@0.6.2, json-pointer@^0.6.2: + version "0.6.2" + resolved "https://registry.yarnpkg.com/json-pointer/-/json-pointer-0.6.2.tgz#f97bd7550be5e9ea901f8c9264c9d436a22a93cd" + integrity sha512-vLWcKbOaXlO+jvRy4qNd+TI1QUPZzfJj1tpJ3vAXDych5XJf93ftpUKe5pKCrzyIIwgBJcOcCVRUfqQP25afBw== + dependencies: + foreach "^2.0.4" + json-schema-traverse@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" @@ -6193,6 +6478,11 @@ lodash.flow@^3.3.0: resolved "https://registry.yarnpkg.com/lodash.flow/-/lodash.flow-3.5.0.tgz#87bf40292b8cf83e4e8ce1a3ae4209e20071675a" integrity sha512-ff3BX/tSioo+XojX4MOsOMhJw0nZoUEF011LX8g8d3gvjVbxd89cCio4BCXronjxcTUIJUoqKEUA+n4CqvvRPw== +lodash.isequal@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0" + integrity sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ== + lodash.memoize@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" @@ -6208,7 +6498,7 @@ lodash.uniq@4.5.0, lodash.uniq@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ== -lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21: +lodash@^4.17.11, lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21: version "4.17.21" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== @@ -6244,6 +6534,11 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" +lunr@^2.3.9: + version "2.3.9" + resolved "https://registry.yarnpkg.com/lunr/-/lunr-2.3.9.tgz#18b123142832337dd6e964df1a5a7707b25d35e1" + integrity sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow== + make-dir@^3.0.0, make-dir@^3.0.2, make-dir@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-3.1.0.tgz#415e967046b3a7f1d185277d84aa58203726a13f" @@ -6251,11 +6546,21 @@ make-dir@^3.0.0, make-dir@^3.0.2, make-dir@^3.1.0: dependencies: semver "^6.0.0" +mark.js@^8.11.1: + version "8.11.1" + resolved "https://registry.yarnpkg.com/mark.js/-/mark.js-8.11.1.tgz#180f1f9ebef8b0e638e4166ad52db879beb2ffc5" + integrity sha512-1I+1qpDt4idfgLQG+BNWmrqku+7/2bi5nLf4YwF8y8zXvmfiTBY3PV3ZibfrjBueCByROpuBjLLFCajqkgYoLQ== + markdown-escapes@^1.0.0: version "1.0.4" resolved "https://registry.yarnpkg.com/markdown-escapes/-/markdown-escapes-1.0.4.tgz#c95415ef451499d7602b91095f3c8e8975f78535" integrity sha512-8z4efJYk43E0upd0NbVXwgSTQs6cT3T06etieCMEg7dRbzCbxUCK/GHlX8mhHRDcp+OLlHkPKsvqQTCvsRl2cg== +marked@^4.0.15: + version "4.0.18" + resolved "https://registry.yarnpkg.com/marked/-/marked-4.0.18.tgz#cd0ac54b2e5610cfb90e8fd46ccaa8292c9ed569" + integrity sha512-wbLDJ7Zh0sqA0Vdg6aqlbT+yPxqLblpAZh1mK2+AO2twQkPywvvqQNfEPVwSSRjZ7dZcdeVBIAgiO7MMp3Dszw== + mdast-squeeze-paragraphs@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/mdast-squeeze-paragraphs/-/mdast-squeeze-paragraphs-4.0.0.tgz#7c4c114679c3bee27ef10b58e2e015be79f1ef97" @@ -6425,18 +6730,47 @@ minimatch@3.0.4: dependencies: brace-expansion "^1.1.7" -minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: +minimatch@^3.0.3, minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== dependencies: brace-expansion "^1.1.7" +minimatch@^5.0.1: + version "5.1.0" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.0.tgz#1717b464f4971b144f6aabe8f2d0b8e4511e09c7" + integrity sha512-9TPBGGak4nHfGZsPBohm9AWg6NoT7QTCehS3BIJABslyZbzxfV78QM2Y6+i741OPZIafFAaiiEMh5OyIrJPgtg== + dependencies: + brace-expansion "^2.0.1" + minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6: version "1.2.6" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== +mkdirp@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" + integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== + +mobx-react-lite@^3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/mobx-react-lite/-/mobx-react-lite-3.4.0.tgz#d59156a96889cdadad751e5e4dab95f28926dfff" + integrity sha512-bRuZp3C0itgLKHu/VNxi66DN/XVkQG7xtoBVWxpvC5FhAqbOCP21+nPhULjnzEqd7xBMybp6KwytdUpZKEgpIQ== + +mobx-react@^7.2.0: + version "7.5.2" + resolved "https://registry.yarnpkg.com/mobx-react/-/mobx-react-7.5.2.tgz#362d6dc7271698caf3b56229c3c68fb0b30e682e" + integrity sha512-NP44ONwSqTy+3KlD7y9k7xbsuGD+8mgUj3IeI65SbxF1IOB42/j9TbosgUEDn//CCuU6OmQ7k9oiu9eSpRBHnw== + dependencies: + mobx-react-lite "^3.4.0" + +mobx@^6.5.0: + version "6.6.1" + resolved "https://registry.yarnpkg.com/mobx/-/mobx-6.6.1.tgz#70ee6aa82f25aeb7e7d522bd621207434e509318" + integrity sha512-7su3UZv5JF+ohLr2opabjbUAERfXstMY+wiBtey8yNAPoB8H187RaQXuhFjNkH8aE4iHbDWnhDFZw0+5ic4nGQ== + moment-mini@^2.24.0: version "2.24.0" resolved "https://registry.yarnpkg.com/moment-mini/-/moment-mini-2.24.0.tgz#fa68d98f7fe93ae65bf1262f6abb5fb6983d8d18" @@ -6505,7 +6839,14 @@ node-emoji@^1.10.0: dependencies: lodash "^4.17.21" -node-fetch@2.6.7: +node-fetch-h2@^2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/node-fetch-h2/-/node-fetch-h2-2.3.0.tgz#c6188325f9bd3d834020bf0f2d6dc17ced2241ac" + integrity sha512-ofRW94Ab0T4AOh5Fk8t0h8OBWrmjb0SSB20xh1H8YnPV9EJ+f5AMoYSUQ2zgJ4Iq2HAK0I2l5/Nequ8YzFS3Hg== + dependencies: + http2-client "^1.2.5" + +node-fetch@2.6.7, node-fetch@^2.6.1: version "2.6.7" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ== @@ -6517,11 +6858,26 @@ node-forge@^1: resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-1.3.1.tgz#be8da2af243b2417d5f646a770663a92b7e9ded3" integrity sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA== +node-readfiles@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/node-readfiles/-/node-readfiles-0.2.0.tgz#dbbd4af12134e2e635c245ef93ffcf6f60673a5d" + integrity sha512-SU00ZarexNlE4Rjdm83vglt5Y9yiQ+XI1XpflWlb7q7UTN1JUItm69xMeiQCTxtTfnzt+83T8Cx+vI2ED++VDA== + dependencies: + es6-promise "^3.2.1" + node-releases@^2.0.5: version "2.0.6" resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.6.tgz#8a7088c63a55e493845683ebf3c828d8c51c5503" integrity sha512-PiVXnNuFm5+iYkLBNeq5211hvO38y63T0i2KKh2KnUs3RpzJ+JtODFjkD8yjLwnDkTYF1eKXheUwdssR+NRZdg== +noms@0.0.0: + version "0.0.0" + resolved "https://registry.yarnpkg.com/noms/-/noms-0.0.0.tgz#da8ebd9f3af9d6760919b27d9cdc8092a7332859" + integrity sha512-lNDU9VJaOPxUmXcLb+HQFeUgQQPtMI24Gt6hgfuMHRJgMRHMF/qZ4HJD3GDru4sSw9IQl2jPjAYnQrdIeLbwow== + dependencies: + inherits "^2.0.1" + readable-stream "~1.0.31" + normalize-path@^3.0.0, normalize-path@~3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" @@ -6561,6 +6917,52 @@ nth-check@^2.0.1: dependencies: boolbase "^1.0.0" +oas-kit-common@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/oas-kit-common/-/oas-kit-common-1.0.8.tgz#6d8cacf6e9097967a4c7ea8bcbcbd77018e1f535" + integrity sha512-pJTS2+T0oGIwgjGpw7sIRU8RQMcUoKCDWFLdBqKB2BNmGpbBMH2sdqAaOXUg8OzonZHU0L7vfJu1mJFEiYDWOQ== + dependencies: + fast-safe-stringify "^2.0.7" + +oas-linter@^3.2.2: + version "3.2.2" + resolved "https://registry.yarnpkg.com/oas-linter/-/oas-linter-3.2.2.tgz#ab6a33736313490659035ca6802dc4b35d48aa1e" + integrity sha512-KEGjPDVoU5K6swgo9hJVA/qYGlwfbFx+Kg2QB/kd7rzV5N8N5Mg6PlsoCMohVnQmo+pzJap/F610qTodKzecGQ== + dependencies: + "@exodus/schemasafe" "^1.0.0-rc.2" + should "^13.2.1" + yaml "^1.10.0" + +oas-resolver@^2.5.6: + version "2.5.6" + resolved "https://registry.yarnpkg.com/oas-resolver/-/oas-resolver-2.5.6.tgz#10430569cb7daca56115c915e611ebc5515c561b" + integrity sha512-Yx5PWQNZomfEhPPOphFbZKi9W93CocQj18NlD2Pa4GWZzdZpSJvYwoiuurRI7m3SpcChrnO08hkuQDL3FGsVFQ== + dependencies: + node-fetch-h2 "^2.3.0" + oas-kit-common "^1.0.8" + reftools "^1.1.9" + yaml "^1.10.0" + yargs "^17.0.1" + +oas-schema-walker@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/oas-schema-walker/-/oas-schema-walker-1.1.5.tgz#74c3cd47b70ff8e0b19adada14455b5d3ac38a22" + integrity sha512-2yucenq1a9YPmeNExoUa9Qwrt9RFkjqaMAA1X+U7sbb0AqBeTIdMHky9SQQ6iN94bO5NW0W4TRYXerG+BdAvAQ== + +oas-validator@^5.0.8: + version "5.0.8" + resolved "https://registry.yarnpkg.com/oas-validator/-/oas-validator-5.0.8.tgz#387e90df7cafa2d3ffc83b5fb976052b87e73c28" + integrity sha512-cu20/HE5N5HKqVygs3dt94eYJfBi0TsZvPVXDhbXQHiEityDN+RROTleefoKRKKJ9dFAF2JBkDHgvWj0sjKGmw== + dependencies: + call-me-maybe "^1.0.1" + oas-kit-common "^1.0.8" + oas-linter "^3.2.2" + oas-resolver "^2.5.6" + oas-schema-walker "^1.1.5" + reftools "^1.1.9" + should "^13.2.1" + yaml "^1.10.0" + object-assign@^4.1.0, object-assign@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" @@ -6661,6 +7063,14 @@ open@^8.0.9, open@^8.4.0: is-docker "^2.1.1" is-wsl "^2.2.0" +openapi-sampler@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/openapi-sampler/-/openapi-sampler-1.3.0.tgz#5b99ceb4156b00d2aa3f860e52ccb768a5695793" + integrity sha512-2QfjK1oM9Sv0q82Ae1RrUe3yfFmAyjF548+6eAeb+h/cL1Uj51TW4UezraBEvwEdzoBgfo4AaTLVFGTKj+yYDw== + dependencies: + "@types/json-schema" "^7.0.7" + json-pointer "0.6.2" + opener@^1.5.2: version "1.5.2" resolved "https://registry.yarnpkg.com/opener/-/opener-1.5.2.tgz#5d37e1f35077b9dcac4301372271afdeb2a13598" @@ -6842,6 +7252,11 @@ pascal-case@^3.1.2: no-case "^3.0.4" tslib "^2.0.3" +path-browserify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-1.0.1.tgz#d98454a9c3753d5790860f16f68867b9e46be1fd" + integrity sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g== + path-exists@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" @@ -6894,12 +7309,17 @@ path-type@^4.0.0: resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== +perfect-scrollbar@^1.5.1: + version "1.5.5" + resolved "https://registry.yarnpkg.com/perfect-scrollbar/-/perfect-scrollbar-1.5.5.tgz#41a211a2fb52a7191eff301432134ea47052b27f" + integrity sha512-dzalfutyP3e/FOpdlhVryN4AJ5XDVauVWxybSkLZmakFE2sS3y3pc4JnSprw8tGmHvkaG5Edr5T7LBTZ+WWU2g== + picocolors@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== -picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.3.1: +picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.3.0, picomatch@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== @@ -6918,6 +7338,18 @@ pkg-up@^3.1.0: dependencies: find-up "^3.0.0" +pluralize@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-8.0.0.tgz#1a6fa16a38d12a1901e0320fa017051c539ce3b1" + integrity sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA== + +polished@^4.1.3: + version "4.2.2" + resolved "https://registry.yarnpkg.com/polished/-/polished-4.2.2.tgz#2529bb7c3198945373c52e34618c8fe7b1aa84d1" + integrity sha512-Sz2Lkdxz6F2Pgnpi9U5Ng/WdWAUZxmHrNPoVlm3aAemxoy2Qy7LGjQg4uf8qKelDAUW94F4np3iH2YPf2qefcQ== + dependencies: + "@babel/runtime" "^7.17.8" + postcss-calc@^8.2.3: version "8.2.4" resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-8.2.4.tgz#77b9c29bfcbe8a07ff6693dc87050828889739a5" @@ -7189,7 +7621,7 @@ postcss-unique-selectors@^5.1.1: dependencies: postcss-selector-parser "^6.0.5" -postcss-value-parser@^4.1.0, postcss-value-parser@^4.2.0: +postcss-value-parser@^4.0.2, postcss-value-parser@^4.1.0, postcss-value-parser@^4.2.0: version "4.2.0" resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz#723c09920836ba6d3e5af019f92bc0971c02e514" integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ== @@ -7241,7 +7673,7 @@ prism-react-renderer@^1.3.1, prism-react-renderer@^1.3.5: resolved "https://registry.yarnpkg.com/prism-react-renderer/-/prism-react-renderer-1.3.5.tgz#786bb69aa6f73c32ba1ee813fbe17a0115435085" integrity sha512-IJ+MSwBWKG+SM3b2SUfdrhC+gu01QkV2KmRQgREThBfSQRoufqRfxfHUxpG1WcaFjP+kojcFyO9Qqtpgt3qLCg== -prismjs@^1.28.0: +prismjs@^1.27.0, prismjs@^1.28.0: version "1.28.0" resolved "https://registry.yarnpkg.com/prismjs/-/prismjs-1.28.0.tgz#0d8f561fa0f7cf6ebca901747828b149147044b6" integrity sha512-8aaXdYvl1F7iC7Xm1spqSaY/OJBpYW3v+KJ+F17iYxvdc8sfjW194COK5wVhMZX45tGteiBQgdvD/nhxcRwylw== @@ -7266,7 +7698,7 @@ prompts@^2.4.2: kleur "^3.0.3" sisteransi "^1.0.5" -prop-types@^15.6.2, prop-types@^15.7.2, prop-types@^15.8.1: +prop-types@^15.5.0, prop-types@^15.6.2, prop-types@^15.7.2, prop-types@^15.8.1: version "15.8.1" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.1.tgz#67d87bf1a694f48435cf332c24af10214a3140b5" integrity sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg== @@ -7509,6 +7941,14 @@ react-router@5.3.3, react-router@^5.3.3: tiny-invariant "^1.0.2" tiny-warning "^1.0.0" +react-tabs@^3.2.2: + version "3.2.3" + resolved "https://registry.yarnpkg.com/react-tabs/-/react-tabs-3.2.3.tgz#ccbb3e1241ad3f601047305c75db661239977f2f" + integrity sha512-jx325RhRVnS9DdFbeF511z0T0WEqEoMl1uCE3LoZ6VaZZm7ytatxbum0B8bCTmaiV0KsU+4TtLGTGevCic7SWg== + dependencies: + clsx "^1.1.0" + prop-types "^15.5.0" + react-textarea-autosize@^8.3.2: version "8.3.4" resolved "https://registry.yarnpkg.com/react-textarea-autosize/-/react-textarea-autosize-8.3.4.tgz#270a343de7ad350534141b02c9cb78903e553524" @@ -7526,7 +7966,7 @@ react@^17.0.2: loose-envify "^1.1.0" object-assign "^4.1.1" -readable-stream@^2.0.1: +readable-stream@^2.0.1, readable-stream@~2.3.6: version "2.3.7" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" integrity sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw== @@ -7548,6 +7988,16 @@ readable-stream@^3.0.6: string_decoder "^1.1.1" util-deprecate "^1.0.1" +readable-stream@~1.0.31: + version "1.0.34" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" + integrity sha512-ok1qVCJuRkNmvebYikljxJA/UEsKwLl2nI1OmaqAu4/UE+h0wKCHok4XkL/gvi39OacXvw59RJUOFUkDib2rHg== + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.1" + isarray "0.0.1" + string_decoder "~0.10.x" + readdirp@~3.6.0: version "3.6.0" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" @@ -7574,6 +8024,47 @@ recursive-readdir@^2.2.2: dependencies: minimatch "3.0.4" +redoc@2.0.0-rc.72: + version "2.0.0-rc.72" + resolved "https://registry.yarnpkg.com/redoc/-/redoc-2.0.0-rc.72.tgz#9eee22104d652b4a90e19ca50009b0b623a7b5b3" + integrity sha512-IX/WvVh4N3zwo4sAjnQFz6ffIUd6G47hcflxPtrpxblJaeOy0MBSzzY8f179WjssWPYcSmmndP5v0hgEXFiimg== + dependencies: + "@redocly/openapi-core" "^1.0.0-beta.97" + classnames "^2.3.1" + decko "^1.2.0" + dompurify "^2.2.8" + eventemitter3 "^4.0.7" + json-pointer "^0.6.2" + lunr "^2.3.9" + mark.js "^8.11.1" + marked "^4.0.15" + mobx-react "^7.2.0" + openapi-sampler "^1.3.0" + path-browserify "^1.0.1" + perfect-scrollbar "^1.5.1" + polished "^4.1.3" + prismjs "^1.27.0" + prop-types "^15.7.2" + react-tabs "^3.2.2" + slugify "~1.4.7" + stickyfill "^1.1.1" + style-loader "^3.3.1" + swagger2openapi "^7.0.6" + url-template "^2.0.8" + +redocusaurus@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/redocusaurus/-/redocusaurus-1.3.0.tgz#01b65fd46b6633cf7eaf195b113bdc8ce6070e11" + integrity sha512-rq6f7+VaPbj63ZEAIFpYwi4gy0GvD0YhBoICaxlj0j8o2Z0opl4IjWTSrIhc6mA09kOtX6R3xPctaSBN+ReItA== + dependencies: + docusaurus-plugin-redoc "1.2.3" + docusaurus-theme-redoc "1.3.0" + +reftools@^1.1.9: + version "1.1.9" + resolved "https://registry.yarnpkg.com/reftools/-/reftools-1.1.9.tgz#e16e19f662ccd4648605312c06d34e5da3a2b77e" + integrity sha512-OVede/NQE13xBQ+ob5CKd5KyeJYU2YInb1bmV4nRoOfquZPkAkxuOXicSe1PvqIuZZ4kD13sPKBbR7UFDmli6w== + regenerate-unicode-properties@^10.0.1: version "10.0.1" resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-10.0.1.tgz#7f442732aa7934a3740c779bb9b3340dccc1fb56" @@ -7728,6 +8219,11 @@ repeat-string@^1.5.4: resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" integrity sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w== +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== + require-from-string@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" @@ -8084,6 +8580,50 @@ shelljs@^0.8.5: interpret "^1.0.0" rechoir "^0.6.2" +should-equal@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/should-equal/-/should-equal-2.0.0.tgz#6072cf83047360867e68e98b09d71143d04ee0c3" + integrity sha512-ZP36TMrK9euEuWQYBig9W55WPC7uo37qzAEmbjHz4gfyuXrEUgF8cUvQVO+w+d3OMfPvSRQJ22lSm8MQJ43LTA== + dependencies: + should-type "^1.4.0" + +should-format@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/should-format/-/should-format-3.0.3.tgz#9bfc8f74fa39205c53d38c34d717303e277124f1" + integrity sha512-hZ58adtulAk0gKtua7QxevgUaXTTXxIi8t41L3zo9AHvjXO1/7sdLECuHeIN2SRtYXpNkmhoUP2pdeWgricQ+Q== + dependencies: + should-type "^1.3.0" + should-type-adaptors "^1.0.1" + +should-type-adaptors@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/should-type-adaptors/-/should-type-adaptors-1.1.0.tgz#401e7f33b5533033944d5cd8bf2b65027792e27a" + integrity sha512-JA4hdoLnN+kebEp2Vs8eBe9g7uy0zbRo+RMcU0EsNy+R+k049Ki+N5tT5Jagst2g7EAja+euFuoXFCa8vIklfA== + dependencies: + should-type "^1.3.0" + should-util "^1.0.0" + +should-type@^1.3.0, should-type@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/should-type/-/should-type-1.4.0.tgz#0756d8ce846dfd09843a6947719dfa0d4cff5cf3" + integrity sha512-MdAsTu3n25yDbIe1NeN69G4n6mUnJGtSJHygX3+oN0ZbO3DTiATnf7XnYJdGT42JCXurTb1JI0qOBR65shvhPQ== + +should-util@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/should-util/-/should-util-1.0.1.tgz#fb0d71338f532a3a149213639e2d32cbea8bcb28" + integrity sha512-oXF8tfxx5cDk8r2kYqlkUJzZpDBqVY/II2WhvU0n9Y3XYvAYRmeaf1PvvIvTgPnv4KJ+ES5M0PyDq5Jp+Ygy2g== + +should@^13.2.1: + version "13.2.3" + resolved "https://registry.yarnpkg.com/should/-/should-13.2.3.tgz#96d8e5acf3e97b49d89b51feaa5ae8d07ef58f10" + integrity sha512-ggLesLtu2xp+ZxI+ysJTmNjh2U0TsC+rQ/pfED9bUZZ4DKefP27D+7YJVVTvKsmjLpIi9jAa7itwDGkDDmt1GQ== + dependencies: + should-equal "^2.0.0" + should-format "^3.0.3" + should-type "^1.4.0" + should-type-adaptors "^1.0.1" + should-util "^1.0.0" + side-channel@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" @@ -8132,6 +8672,11 @@ slash@^4.0.0: resolved "https://registry.yarnpkg.com/slash/-/slash-4.0.0.tgz#2422372176c4c6c5addb5e2ada885af984b396a7" integrity sha512-3dOsAHXXUkQTpOYcoAxLIorMTp4gIQr5IW3iVb7A7lFIp0VHhnynm9izx6TssdrIcVIESAlVjtnO2K8bg+Coew== +slugify@~1.4.7: + version "1.4.7" + resolved "https://registry.yarnpkg.com/slugify/-/slugify-1.4.7.tgz#e42359d505afd84a44513280868e31202a79a628" + integrity sha512-tf+h5W1IrjNm/9rKKj0JU2MDMruiopx0jjVA5zCdBtcGjfp0+c5rHw/zADLC3IeKlGHtVbHtpfzvYA0OYT+HKg== + sockjs@^0.3.24: version "0.3.24" resolved "https://registry.yarnpkg.com/sockjs/-/sockjs-0.3.24.tgz#c9bc8995f33a111bea0395ec30aa3206bdb5ccce" @@ -8245,12 +8790,17 @@ std-env@^3.0.1: resolved "https://registry.yarnpkg.com/std-env/-/std-env-3.1.1.tgz#1f19c4d3f6278c52efd08a94574a2a8d32b7d092" integrity sha512-/c645XdExBypL01TpFKiG/3RAa/Qmu+zRi0MwAmrdEkwHNuN0ebo8ccAXBBDa5Z0QOJgBskUIbuCK91x0sCVEw== +stickyfill@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/stickyfill/-/stickyfill-1.1.1.tgz#39413fee9d025c74a7e59ceecb23784cc0f17f02" + integrity sha512-GCp7vHAfpao+Qh/3Flh9DXEJ/qSi0KJwJw6zYlZOtRYXWUIpMM6mC2rIep/dK8RQqwW0KxGJIllmjPIBOGN8AA== + string-natural-compare@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/string-natural-compare/-/string-natural-compare-3.0.1.tgz#7a42d58474454963759e8e8b7ae63d71c1e7fdf4" integrity sha512-n3sPwynL1nwKi3WJ6AIsClwBMa0zTi54fn2oLU6ndfTSIO05xaznjSf15PcBZU6FNWbmN5Q6cxT4V5hGvB4taw== -string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.2: +string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.2, string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -8307,6 +8857,11 @@ string_decoder@^1.1.1: dependencies: safe-buffer "~5.2.0" +string_decoder@~0.10.x: + version "0.10.31" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" + integrity sha512-ev2QzSzWPYmy9GuqfIVildA4OdcGLeFZQrq5ys6RtiuF+RQQiZWr8TZNyAcuVXyQRYfEO+MsoB/1BuQVhOJuoQ== + string_decoder@~1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" @@ -8362,6 +8917,11 @@ strip-json-comments@~2.0.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" integrity sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ== +style-loader@^3.3.1: + version "3.3.1" + resolved "https://registry.yarnpkg.com/style-loader/-/style-loader-3.3.1.tgz#057dfa6b3d4d7c7064462830f9113ed417d38575" + integrity sha512-GPcQ+LDJbrcxHORTRes6Jy2sfvK2kS6hpSfI/fXhPt+spVzxF6LJ1dHLN9zIGmVaaP044YKaIatFaufENRiDoQ== + style-to-object@0.3.0, style-to-object@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/style-to-object/-/style-to-object-0.3.0.tgz#b1b790d205991cc783801967214979ee19a76e46" @@ -8369,6 +8929,22 @@ style-to-object@0.3.0, style-to-object@^0.3.0: dependencies: inline-style-parser "0.1.1" +styled-components@^5.3.5: + version "5.3.5" + resolved "https://registry.yarnpkg.com/styled-components/-/styled-components-5.3.5.tgz#a750a398d01f1ca73af16a241dec3da6deae5ec4" + integrity sha512-ndETJ9RKaaL6q41B69WudeqLzOpY1A/ET/glXkNZ2T7dPjPqpPCXXQjDFYZWwNnE5co0wX+gTCqx9mfxTmSIPg== + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/traverse" "^7.4.5" + "@emotion/is-prop-valid" "^1.1.0" + "@emotion/stylis" "^0.8.4" + "@emotion/unitless" "^0.7.4" + babel-plugin-styled-components ">= 1.12.0" + css-to-react-native "^3.0.0" + hoist-non-react-statics "^3.0.0" + shallowequal "^1.1.0" + supports-color "^5.5.0" + stylehacks@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/stylehacks/-/stylehacks-5.1.0.tgz#a40066490ca0caca04e96c6b02153ddc39913520" @@ -8382,7 +8958,7 @@ stylis@^4.0.10: resolved "https://registry.yarnpkg.com/stylis/-/stylis-4.1.1.tgz#e46c6a9bbf7c58db1e65bb730be157311ae1fe12" integrity sha512-lVrM/bNdhVX2OgBFNa2YJ9Lxj7kPzylieHd3TNjuGE0Re9JB7joL5VUKOVH1kdNNJTgGPpT8hmwIAPLaSyEVFQ== -supports-color@^5.3.0: +supports-color@^5.3.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== @@ -8426,6 +9002,23 @@ svgo@^2.5.0, svgo@^2.7.0: picocolors "^1.0.0" stable "^0.1.8" +swagger2openapi@^7.0.6: + version "7.0.8" + resolved "https://registry.yarnpkg.com/swagger2openapi/-/swagger2openapi-7.0.8.tgz#12c88d5de776cb1cbba758994930f40ad0afac59" + integrity sha512-upi/0ZGkYgEcLeGieoz8gT74oWHA0E7JivX7aN9mAf+Tc7BQoRBvnIGHoPDw+f9TXTW4s6kGYCZJtauP6OYp7g== + dependencies: + call-me-maybe "^1.0.1" + node-fetch "^2.6.1" + node-fetch-h2 "^2.3.0" + node-readfiles "^0.2.0" + oas-kit-common "^1.0.8" + oas-resolver "^2.5.6" + oas-schema-walker "^1.1.5" + oas-validator "^5.0.8" + reftools "^1.1.9" + yaml "^1.10.0" + yargs "^17.0.1" + tapable@^1.0.0: version "1.1.3" resolved "https://registry.yarnpkg.com/tapable/-/tapable-1.1.3.tgz#a1fccc06b58db61fd7a45da2da44f5f3a3e67ba2" @@ -8462,6 +9055,14 @@ text-table@^0.2.0: resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" integrity sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw== +through2@^2.0.1: + version "2.0.5" + resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" + integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== + dependencies: + readable-stream "~2.3.6" + xtend "~4.0.1" + thunky@^1.0.2: version "1.1.0" resolved "https://registry.yarnpkg.com/thunky/-/thunky-1.1.0.tgz#5abaf714a9405db0504732bbccd2cedd9ef9537d" @@ -8733,6 +9334,11 @@ unpipe@1.0.0, unpipe@~1.0.0: resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" integrity sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ== +untildify@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/untildify/-/untildify-4.0.0.tgz#2bc947b953652487e4600949fb091e3ae8cd919b" + integrity sha512-KK8xQ1mkzZeg9inewmFVDNkg3l5LUhoq9kN6iWYB/CC9YMG8HA+c1Q8HwDe6dEX7kErrEVNVBO3fWsVq5iDgtw== + update-browserslist-db@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.0.4.tgz#dbfc5a789caa26b1db8990796c2c8ebbce304824" @@ -8784,6 +9390,11 @@ url-parse-lax@^3.0.0: dependencies: prepend-http "^2.0.0" +url-template@^2.0.8: + version "2.0.8" + resolved "https://registry.yarnpkg.com/url-template/-/url-template-2.0.8.tgz#fc565a3cccbff7730c775f5641f9555791439f21" + integrity sha512-XdVKMF4SJ0nP/O7XIPB0JwAEuT9lDIYnNsK8yGVe43y0AWoKeJNdv3ZNWh7ksJ6KqQFjOO6ox/VEitLnaVNufw== + use-composed-ref@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/use-composed-ref/-/use-composed-ref-1.3.0.tgz#3d8104db34b7b264030a9d916c5e94fbe280dbda" @@ -9140,21 +9751,67 @@ xml-js@^1.6.11: dependencies: sax "^1.2.4" -xtend@^4.0.0, xtend@^4.0.1: +xtend@^4.0.0, xtend@^4.0.1, xtend@~4.0.1: version "4.0.2" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== +y18n@^5.0.5: + version "5.0.8" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55" + integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== + yallist@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== +yaml-ast-parser@0.0.43: + version "0.0.43" + resolved "https://registry.yarnpkg.com/yaml-ast-parser/-/yaml-ast-parser-0.0.43.tgz#e8a23e6fb4c38076ab92995c5dca33f3d3d7c9bb" + integrity sha512-2PTINUwsRqSd+s8XxKaJWQlUuEMHJQyEuh2edBbW8KNJz0SJPwUSD2zRWqezFEdN7IzAgeuYHFUCF7o8zRdZ0A== + yaml@^1.10.0, yaml@^1.10.2, yaml@^1.7.2: version "1.10.2" resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b" integrity sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg== +yargs-parser@^20.2.2: + version "20.2.9" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee" + integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== + +yargs-parser@^21.0.0: + version "21.1.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" + integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== + +yargs@^16.1.0: + version "16.2.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-16.2.0.tgz#1c82bf0f6b6a66eafce7ef30e376f49a12477f66" + integrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw== + dependencies: + cliui "^7.0.2" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.0" + y18n "^5.0.5" + yargs-parser "^20.2.2" + +yargs@^17.0.1: + version "17.5.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.5.1.tgz#e109900cab6fcb7fd44b1d8249166feb0b36e58e" + integrity sha512-t6YAJcxDkNX7NFYiVtKvWUz8l+PaKTLiL63mJYWR2GnHq2gjEWISzsLp9wg3aY36dY1j+gfIEL3pIF+XlJJfbA== + dependencies: + cliui "^7.0.2" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.3" + y18n "^5.0.5" + yargs-parser "^21.0.0" + yocto-queue@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" From 662ca918ee1bafb6c15f525ba2a7ac684813dcaf Mon Sep 17 00:00:00 2001 From: Tyler van der Hoeven Date: Wed, 10 Aug 2022 22:09:36 -0400 Subject: [PATCH 2/5] slight linting stuff --- docusaurus.config.js | 4 +++- src/components/Alert.js | 4 +--- src/components/CodeExample.js | 6 ++---- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/docusaurus.config.js b/docusaurus.config.js index 8ec18db22..6623dc65e 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -54,7 +54,9 @@ const config = { theme: { // Change with your site colors // primaryColor: '#1890ff', - options: { disableSearch: true }, + options: { + disableSearch: true + }, }, }, ], diff --git a/src/components/Alert.js b/src/components/Alert.js index ebbb2e219..2d40e69aa 100644 --- a/src/components/Alert.js +++ b/src/components/Alert.js @@ -1,6 +1,4 @@ import React from 'react'; import Admonition from '@theme/Admonition'; -export const Alert = ({ children }) => { - return {children}; -}; +export const Alert = ({ children }) => {children}; diff --git a/src/components/CodeExample.js b/src/components/CodeExample.js index edbb45bf4..a02ebd3dc 100644 --- a/src/components/CodeExample.js +++ b/src/components/CodeExample.js @@ -20,14 +20,13 @@ const CODE_LANGS = { yaml: 'YAML', }; -export const CodeExample = ({ children }) => { - return ( +export const CodeExample = ({ children }) => ( {React.Children.map(children, (child, index) => { const codeProps = child.props.children.props; const { className = '' } = codeProps; - const [_, language] = className.split('-'); + const [, language] = className.split('-'); return ( { })} ); -}; From 8316da0ea6895f60b624527b5a773b2bd9b43935 Mon Sep 17 00:00:00 2001 From: Tyler van der Hoeven Date: Wed, 10 Aug 2022 22:10:29 -0400 Subject: [PATCH 3/5] ran mdx linter --- .../deposit-anchored-assets.mdx | 4 +- .../withdraw-anchored-assets.mdx | 2 +- docs/building-apps/first-deposit.mdx | 4 +- docs/glossary/claimable-balance.mdx | 91 +++++---- docs/glossary/clawback.mdx | 190 ++++++++++-------- docs/glossary/fee-bumps.mdx | 23 +-- docs/glossary/fees.mdx | 2 +- docs/glossary/ledger.mdx | 2 +- docs/glossary/liquidity-pool.mdx | 136 +++++++------ docs/glossary/minimum-balance.mdx | 2 +- docs/glossary/muxed-accounts.mdx | 76 ++++--- docs/glossary/sponsored-reserves.mdx | 164 ++++++++------- docs/glossary/testnet.mdx | 4 +- docs/glossary/transactions.mdx | 95 +++------ docs/issuing-assets/anatomy-of-an-asset.mdx | 4 +- docs/issuing-assets/control-asset-access.mdx | 4 +- docs/issuing-assets/how-to-issue-an-asset.mdx | 4 +- docs/run-api-server/configuring.mdx | 12 +- docs/run-api-server/ingestion.mdx | 5 +- docs/run-api-server/monitoring.mdx | 6 +- docs/run-api-server/prerequisites.mdx | 14 +- docs/run-api-server/remote-core.mdx | 4 +- docs/run-api-server/running.mdx | 2 +- docs/start/stellar-stack.mdx | 16 +- docs/tutorials/follow-received-payments.mdx | 6 +- docs/tutorials/handling-errors.mdx | 12 +- docs/tutorials/securing-projects.mdx | 2 +- docs/tutorials/send-and-receive-payments.mdx | 4 +- 28 files changed, 463 insertions(+), 427 deletions(-) diff --git a/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx b/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx index c75e836b2..f81708d70 100644 --- a/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx +++ b/docs/building-apps/connect-to-anchors/deposit-anchored-assets.mdx @@ -140,7 +140,7 @@ export default async function depositAsset(e: Event) { if (!popup) { this.loading = { ...this.loading, deposit: false }; - throw 'Popups are blocked. You\'ll need to enable popups for this demo to work'; + throw "Popups are blocked. You'll need to enable popups for this demo to work"; } window.onmessage = ({ data: { transaction } }) => { @@ -401,7 +401,7 @@ const popup = open(urlBuilder.toString(), "popup", "width=500,height=800"); if (!popup) { this.loading = { ...this.loading, deposit: false }; - throw 'Popups are blocked. You\'ll need to enable popups for this demo to work'; + throw "Popups are blocked. You'll need to enable popups for this demo to work"; } ``` diff --git a/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx b/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx index 35f698dec..d5fcd0a3c 100644 --- a/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx +++ b/docs/building-apps/connect-to-anchors/withdraw-anchored-assets.mdx @@ -151,7 +151,7 @@ export default async function withdrawAsset(e: Event) { if (!popup) { this.loading = { ...this.loading, withdraw: false }; - throw 'Popups are blocked. You\'ll need to enable popups for this demo to work'; + throw "Popups are blocked. You'll need to enable popups for this demo to work"; } await new Promise((resolve, reject) => { diff --git a/docs/building-apps/first-deposit.mdx b/docs/building-apps/first-deposit.mdx index a19fae1a6..d53f6bbac 100644 --- a/docs/building-apps/first-deposit.mdx +++ b/docs/building-apps/first-deposit.mdx @@ -36,7 +36,7 @@ The flow with Claimable Balances looks like this: 1. The wallet initiates a deposit on behalf of a user. 1. The anchor provides deposit instructions to the wallet. 1. The user transfers money from a bank account to the anchor’s account. -1. The anchor creates and funds the user's Stellar account plus the amount required for trustlines and transaction fees. Again, we suggest 2 XLM to start. +1. The anchor creates and funds the user's Stellar account plus the amount required for trustlines and transaction fees. Again, we suggest 2 XLM to start. 1. The anchor creates a Claimable Balance. 1. The wallet detects the Claimable Balance for the account, claims the funds, and posts it in the wallet. @@ -57,4 +57,4 @@ The flow looks like this: ![wallet creates account flow](/assets/first-deposit-wallet-flow.png) -**Note**: In the examples above, we suggest having the anchor or wallet cover minimum balance and trustline XLM requirements by depositing funds directly into a user's account. We made that suggestion for the sake of simplicity, but in all cases, the anchor or wallet could instead use [Sponsored Reserves](../glossary/sponsored-reserves.mdx) to ensure that when a user closes a trustline or merges their account, the reserve reverts to the sponsoring account rather than to the user's account. +**Note**: In the examples above, we suggest having the anchor or wallet cover minimum balance and trustline XLM requirements by depositing funds directly into a user's account. We made that suggestion for the sake of simplicity, but in all cases, the anchor or wallet could instead use [Sponsored Reserves](../glossary/sponsored-reserves.mdx) to ensure that when a user closes a trustline or merges their account, the reserve reverts to the sponsoring account rather than to the user's account. diff --git a/docs/glossary/claimable-balance.mdx b/docs/glossary/claimable-balance.mdx index 9da9566ee..055db1fa4 100644 --- a/docs/glossary/claimable-balance.mdx +++ b/docs/glossary/claimable-balance.mdx @@ -72,45 +72,54 @@ const sdk = require("stellar-sdk"); async function main() { let server = new sdk.Server("https://horizon-testnet.stellar.org"); - let A = sdk.Keypair.fromSecret("SAQLZCQA6AYUXK6JSKVPJ2MZ5K5IIABJOEQIG4RVBHX4PG2KMRKWXCHJ"); - let B = sdk.Keypair.fromPublicKey("GAS4V4O2B7DW5T7IQRPEEVCRXMDZESKISR7DVIGKZQYYV3OSQ5SH5LVP"); + let A = sdk.Keypair.fromSecret( + "SAQLZCQA6AYUXK6JSKVPJ2MZ5K5IIABJOEQIG4RVBHX4PG2KMRKWXCHJ", + ); + let B = sdk.Keypair.fromPublicKey( + "GAS4V4O2B7DW5T7IQRPEEVCRXMDZESKISR7DVIGKZQYYV3OSQ5SH5LVP", + ); // NOTE: Proper error checks are omitted for brevity; always validate things! let aAccount = await server.loadAccount(A.publicKey()).catch(function (err) { - console.error(`Failed to load ${A.publicKey()}: ${err}`) - }) - if (!aAccount) { return } + console.error(`Failed to load ${A.publicKey()}: ${err}`); + }); + if (!aAccount) { + return; + } // Create a claimable balance with our two above-described conditions. - let soon = Math.ceil((Date.now() / 1000) + 60); // .now() is in ms + let soon = Math.ceil(Date.now() / 1000 + 60); // .now() is in ms let bCanClaim = sdk.Claimant.predicateBeforeRelativeTime("60"); let aCanReclaim = sdk.Claimant.predicateNot( - sdk.Claimant.predicateBeforeAbsoluteTime(soon.toString()) + sdk.Claimant.predicateBeforeAbsoluteTime(soon.toString()), ); // Create the operation and submit it in a transaction. let claimableBalanceEntry = sdk.Operation.createClaimableBalance({ claimants: [ new sdk.Claimant(B.publicKey(), bCanClaim), - new sdk.Claimant(A.publicKey(), aCanReclaim) + new sdk.Claimant(A.publicKey(), aCanReclaim), ], asset: sdk.Asset.native(), amount: "420", }); - let tx = new sdk.TransactionBuilder(aAccount, {fee: sdk.BASE_FEE}) + let tx = new sdk.TransactionBuilder(aAccount, { fee: sdk.BASE_FEE }) .addOperation(claimableBalanceEntry) .setNetworkPassphrase(sdk.Networks.TESTNET) .setTimeout(180) .build(); tx.sign(A); - let txResponse = await server.submitTransaction(tx).then(function() { - console.log("Claimable balance created!"); - }).catch(function (err) { - console.error(`Tx submission failed: ${err}`) - }); + let txResponse = await server + .submitTransaction(tx) + .then(function () { + console.log("Claimable balance created!"); + }) + .catch(function (err) { + console.error(`Tx submission failed: ${err}`); + }); } ``` @@ -188,16 +197,16 @@ import time from stellar_sdk.xdr import TransactionResult, OperationType from stellar_sdk.exceptions import NotFoundError, BadResponseError, BadRequestError from stellar_sdk import ( - Keypair, - Network, + Keypair, + Network, Server, - TransactionBuilder, - Transaction, - Asset, + TransactionBuilder, + Transaction, + Asset, Operation, - Claimant, - ClaimPredicate, - CreateClaimableBalance, + Claimant, + ClaimPredicate, + CreateClaimableBalance, ClaimClaimableBalance ) @@ -241,7 +250,7 @@ tx = ( .build() ) -tx.sign(A) +tx.sign(A) try: txResponse = server.submit_transaction(tx) print("Claimable balance created!") @@ -267,7 +276,9 @@ Either party could also check the `/effects` of the transaction, query `/claimab // Method 2: Suppose `txResponse` comes from the transaction submission // above. let txResult = sdk.xdr.TransactionResult.fromXDR( - txResponse.result_xdr, "base64"); + txResponse.result_xdr, + "base64", +); let results = txResult.result().results(); // We look at the first result since our first (and only) operation @@ -278,15 +289,17 @@ console.log("Balance ID (2):", balanceId); // Method 3: Account B could alternatively do something like: let balances = await server - .claimableBalances() - .claimant(B.publicKey()) - .limit(1) // there may be many in general - .order("desc") // so always get the latest one - .call() - .catch(function(err) { - console.error(`Claimable balance retrieval failed: ${err}`) - }); -if (!balances) { return; } + .claimableBalances() + .claimant(B.publicKey()) + .limit(1) // there may be many in general + .order("desc") // so always get the latest one + .call() + .catch(function (err) { + console.error(`Claimable balance retrieval failed: ${err}`); + }); +if (!balances) { + return; +} balanceId = balances.records[0].id; console.log("Balance ID (3):", balanceId); @@ -320,7 +333,7 @@ balanceId := balances.Embedded.Records[0].BalanceID ```python # Method 1: Not available in the Python SDK yet. - + # Method 2: Suppose `txResponse` comes from the transaction submission # above. txResult = TransactionResult.from_xdr(txResponse["result_xdr"]) @@ -330,7 +343,7 @@ results = txResult.result.results # in the transaction was the CreateClaimableBalanceOp. operationResult = results[0].tr.create_claimable_balance_result balanceId = operationResult.balance_id.to_xdr_bytes().hex() -print(f"Balance ID (2): {balanceId}") +print(f"Balance ID (2): {balanceId}") # Method 3: Account B could alternatively do something like: try: @@ -356,10 +369,12 @@ With the claimable balance ID acquired, either Account B or A can actually submi ```js -let claimBalance = sdk.Operation.claimClaimableBalance({ balanceId: balanceId }); +let claimBalance = sdk.Operation.claimClaimableBalance({ + balanceId: balanceId, +}); console.log(A.publicKey(), "claiming", balanceId); -let tx = new sdk.TransactionBuilder(aAccount, {fee: sdk.BASE_FEE}) +let tx = new sdk.TransactionBuilder(aAccount, { fee: sdk.BASE_FEE }) .addOperation(claimBalance) .setNetworkPassphrase(sdk.Networks.TESTNET) .setTimeout(180) @@ -367,7 +382,7 @@ let tx = new sdk.TransactionBuilder(aAccount, {fee: sdk.BASE_FEE}) tx.sign(A); await server.submitTransaction(tx).catch(function (err) { - console.error(`Tx submission failed: ${err}`) + console.error(`Tx submission failed: ${err}`); }); ``` diff --git a/docs/glossary/clawback.mdx b/docs/glossary/clawback.mdx index 8d0b4c64a..02562b1a1 100644 --- a/docs/glossary/clawback.mdx +++ b/docs/glossary/clawback.mdx @@ -63,33 +63,39 @@ const sdk = require("stellar-sdk"); let server = new sdk.Server("https://horizon-testnet.stellar.org"); -const A = sdk.Keypair.fromSecret("SAQLZCQA6AYUXK6JSKVPJ2MZ5K5IIABJOEQIG4RVBHX4PG2KMRKWXCHJ"); -const B = sdk.Keypair.fromSecret("SAAY2H7SANIS3JLFBFPLJRTYNLUYH4UTROIKRVFI4FEYV4LDW5Y7HDZ4"); -const C = sdk.Keypair.fromSecret("SCZANGBA5YHTNYVVV4C3U252E2B6P6F5T3U6MM63WBSBZATAQI3EBTQ4"); +const A = sdk.Keypair.fromSecret( + "SAQLZCQA6AYUXK6JSKVPJ2MZ5K5IIABJOEQIG4RVBHX4PG2KMRKWXCHJ", +); +const B = sdk.Keypair.fromSecret( + "SAAY2H7SANIS3JLFBFPLJRTYNLUYH4UTROIKRVFI4FEYV4LDW5Y7HDZ4", +); +const C = sdk.Keypair.fromSecret( + "SCZANGBA5YHTNYVVV4C3U252E2B6P6F5T3U6MM63WBSBZATAQI3EBTQ4", +); const ASSET = new sdk.Asset("CLAW", A.publicKey()); /// Enables AuthClawbackEnabledFlag on an account. function enableClawback(account, keys) { - return server.submitTransaction(buildTx( - account, keys, [ + return server.submitTransaction( + buildTx(account, keys, [ sdk.Operation.setOptions({ setFlags: sdk.AuthClawbackEnabledFlag | sdk.AuthRevocableFlag, }), - ], - )); + ]), + ); } /// Establishes a trustline for `recipient` for ASSET (from above). const establishTrustline = function (recipient, key) { - return server.submitTransaction(buildTx( - recipient, key, [ + return server.submitTransaction( + buildTx(recipient, key, [ sdk.Operation.changeTrust({ asset: ASSET, limit: "5000", // arbitrary }), - ], - )); + ]), + ); }; /// Retrieves latest account info for all accounts. @@ -104,12 +110,12 @@ function getAccounts() { /// Enables clawback on A, and establishes trustlines from C, B -> A. function preamble() { return getAccounts().then(function (accounts) { - let [ accountA, accountB, accountC ] = accounts; - return enableClawback(accountA, A) - .then(Promise.all([ + let [accountA, accountB, accountC] = accounts; + return enableClawback(accountA, A).then( + Promise.all([ establishTrustline(accountB, B), establishTrustline(accountC, C), - ]) + ]), ); }); } @@ -149,35 +155,36 @@ In our scenario, Account A will pay Account B with 1000 tokens of its custom ass ```js /// Make a payment to `toAccount` from `fromAccount` for `amount`. function makePayment(toAccount, fromAccount, fromKey, amount) { - return server.submitTransaction(buildTx( - fromAccount, fromKey, [ + return server.submitTransaction( + buildTx(fromAccount, fromKey, [ sdk.Operation.payment({ destination: toAccount.accountId(), - asset: ASSET, // defined in preamble + asset: ASSET, // defined in preamble amount: amount, }), - ], - )); -}; + ]), + ); +} /// Perform a clawback by `byAccount` of `amount` from `fromAccount`. function doClawback(byAccount, byKey, fromAccount, amount) { - return server.submitTransaction(buildTx( - byAccount, byKey, [ + return server.submitTransaction( + buildTx(byAccount, byKey, [ sdk.Operation.clawback({ from: fromAccount.accountId(), - asset: ASSET, // defined in preamble + asset: ASSET, // defined in preamble amount: amount, }), - ], - )); -}; + ]), + ); +} /// Retrieves the balance of ASSET in `account`. function getBalance(account) { const balances = account.balances.filter((balance) => { - return (balance.asset_code == ASSET.code && - balance.asset_issuer == ASSET.issuer); + return ( + balance.asset_code == ASSET.code && balance.asset_issuer == ASSET.issuer + ); }); return balances.length > 0 ? balances[0].balance : "0"; } @@ -191,14 +198,15 @@ These snippets will help us with the final comsidebar_position: making some paym ```js function examplePaymentClawback() { - return getAccounts().then(function(accounts) { - let [ accountA, accountB, accountC ] = accounts; - return makePayment(accountB, accountA, A, "1000") - .then(makePayment(accountC, accountB, B, "500")) - .then(doClawback( accountA, A, accountC, "250")); - }) - .then(getAccounts) - .then(showBalances); + return getAccounts() + .then(function (accounts) { + let [accountA, accountB, accountC] = accounts; + return makePayment(accountB, accountA, A, "1000") + .then(makePayment(accountC, accountB, B, "500")) + .then(doClawback(accountA, A, accountC, "250")); + }) + .then(getAccounts) + .then(showBalances); } preamble().then(examplePaymentClawback); @@ -232,23 +240,23 @@ We need some additional helper methods to get started working efficiently with c ```js function createClaimable(fromAccount, fromKey, toAccount, amount) { - return server.submitTransaction(buildTx( - fromAccount, fromKey, [ + return server.submitTransaction( + buildTx(fromAccount, fromKey, [ sdk.Operation.createClaimableBalance({ asset: ASSET, amount: amount, - claimants: [ - new sdk.Claimant(toAccount.accountId()), - ], + claimants: [new sdk.Claimant(toAccount.accountId())], }), - ], - )); + ]), + ); } // https://developers.stellar.org/docs/glossary/claimable-balance/#example function getBalanceId(txResponse) { const txResult = sdk.xdr.TransactionResult.fromXDR( - txResponse.result_xdr, "base64"); + txResponse.result_xdr, + "base64", + ); const operationResult = txResult.result().results()[0]; let creationResult = operationResult.value().createClaimableBalanceResult(); @@ -256,11 +264,11 @@ function getBalanceId(txResponse) { } function clawbackClaimable(issuerAccount, issuerKey, balanceId) { - return server.submitTransaction(buildTx( - issuerAccount, issuerKey, [ - sdk.Operation.clawbackClaimableBalance({ balanceId }) - ], - )); + return server.submitTransaction( + buildTx(issuerAccount, issuerKey, [ + sdk.Operation.clawbackClaimableBalance({ balanceId }), + ]), + ); } ``` @@ -273,8 +281,8 @@ Now, we can fulfill the flow: A pays B, who sends a claimable balance to C, who ```js function exampleClaimableBalanceClawback() { return getAccounts() - .then(function(accounts) { - let [ accountA, accountB, accountC ] = accounts; + .then(function (accounts) { + let [accountA, accountB, accountC] = accounts; return makePayment(accountB, accountA, A, "1000") .then(() => createClaimable(accountB, B, accountC, "500")) @@ -323,8 +331,9 @@ function getAccounts() { function preambleRedux() { return getAccounts().then((accounts) => { - return enableClawback(accounts[0], A) - .then(() => establishTrustline(accounts[1], B)); + return enableClawback(accounts[0], A).then(() => + establishTrustline(accounts[1], B), + ); }); } ``` @@ -337,48 +346,57 @@ Now, let's distribute some of our asset to Account B, just to claw it back. Then ```js function disableClawback(issuerAccount, issuerKeys, forTrustor) { - return server.submitTransaction(buildTx( - issuerAccount, issuerKeys, [ + return server.submitTransaction( + buildTx(issuerAccount, issuerKeys, [ sdk.Operation.setTrustLineFlags({ - trustor: forTrustor.accountId(), - asset: ASSET, // defined in the (original) preamble + trustor: forTrustor.accountId(), + asset: ASSET, // defined in the (original) preamble flags: { clawbackEnabled: false, }, }), - ] - )); + ]), + ); } function exampleSelectiveClawback() { - return getAccounts().then((accounts) => { - let [ accountA, accountB ] = accounts; - return makePayment(accountB, accountA, A, "1000") - .then(getAccounts).then(showBalances) - .then(() => doClawback(accountA, A, accountB, "500")) - .then(getAccounts).then(showBalances) - .then(() => disableClawback(accountA, A, accountB)) - .then(() => doClawback(accountA, A, accountB, "500")) - .catch((err) => { - if (err.response && err.response.data) { - // Note that this is a *very* specific way to check for an error, and - // you should probably never do it this way. - // We do this here to demonstrate that the clawback error *does* - // occur as expected. - const opErrors = err.response.data.extras.result_codes.operations; - if (opErrors && opErrors.length > 0 && - opErrors[0] === "op_no_clawback_enabled") { - console.info("Clawback failed, as expected!"); + return getAccounts() + .then((accounts) => { + let [accountA, accountB] = accounts; + return makePayment(accountB, accountA, A, "1000") + .then(getAccounts) + .then(showBalances) + .then(() => doClawback(accountA, A, accountB, "500")) + .then(getAccounts) + .then(showBalances) + .then(() => disableClawback(accountA, A, accountB)) + .then(() => doClawback(accountA, A, accountB, "500")) + .catch((err) => { + if (err.response && err.response.data) { + // Note that this is a *very* specific way to check for an error, and + // you should probably never do it this way. + // We do this here to demonstrate that the clawback error *does* + // occur as expected. + const opErrors = err.response.data.extras.result_codes.operations; + if ( + opErrors && + opErrors.length > 0 && + opErrors[0] === "op_no_clawback_enabled" + ) { + console.info("Clawback failed, as expected!"); + } else { + console.error( + "Uh-oh, some other failure occurred:", + err.response.data.extras, + ); + } } else { - console.error("Uh-oh, some other failure occurred:", err.response.data.extras); + console.error("Uh-oh, unknown failure:", err); } - } else { - console.error("Uh-oh, unknown failure:", err); - } - }); - }) - .then(getAccounts) - .then(showBalances); + }); + }) + .then(getAccounts) + .then(showBalances); } ``` diff --git a/docs/glossary/fee-bumps.mdx b/docs/glossary/fee-bumps.mdx index a34adc91a..ca29df78b 100644 --- a/docs/glossary/fee-bumps.mdx +++ b/docs/glossary/fee-bumps.mdx @@ -2,30 +2,29 @@ title: Fee-Bump Transactions --- -A fee-bump transaction enables any account to pay the fee for an existing [transaction](./transactions.mdx) without the need to re-sign the existing transaction or manage sequence numbers. They're useful if you need to increase the fee on a pre-signed transaction, or if you want to build a service that covers user fees. Like a regular transaction, these are submitted to the [`/transactions` endpoint](/api/resources/transactions/). _Unlike_ a regular transaction, however, which contains 1-100 [operations](./operations.mdx), a fee-bump transaction contains a single [transaction envelope](./transactions.mdx/#transaction-envelopes). +A fee-bump transaction enables any account to pay the fee for an existing [transaction](./transactions.mdx) without the need to re-sign the existing transaction or manage sequence numbers. They're useful if you need to increase the fee on a pre-signed transaction, or if you want to build a service that covers user fees. Like a regular transaction, these are submitted to the [`/transactions` endpoint](/api/resources/transactions/). _Unlike_ a regular transaction, however, which contains 1-100 [operations](./operations.mdx), a fee-bump transaction contains a single [transaction envelope](./transactions.mdx/#transaction-envelopes). ## Fee-Bump Transaction Attributes ### Existing Transaction Envelope -Each fee-bump transaction encloses a single transaction envelope, which itself encloses a single inner transaction. Before creating a fee-bump transaction, in other words, you must first have a [transaction](./transactions.mdx) wrapped with requisite signatures in a [transaction envelope](./transactions.mdx/#transaction-envelopes). +Each fee-bump transaction encloses a single transaction envelope, which itself encloses a single inner transaction. Before creating a fee-bump transaction, in other words, you must first have a [transaction](./transactions.mdx) wrapped with requisite signatures in a [transaction envelope](./transactions.mdx/#transaction-envelopes). In addition to a transaction envelope, each fee-bump transaction has the following attributes: ### Fee Account -The account that provides the fee for the fee-bump transaction. It incurs the fee instead of the source account specified in the inner transaction. The sequence number for the fee-bump transaction, however, is still taken from the source account specified in the inner transaction. +The account that provides the fee for the fee-bump transaction. It incurs the fee instead of the source account specified in the inner transaction. The sequence number for the fee-bump transaction, however, is still taken from the source account specified in the inner transaction. ### Fee The maximum per-operation fee you are willing to pay for the fee-bump transaction. -A fee-bump transaction has an effective number of operations equal to one plus the number of operations in the inner transaction. Therefore, the minimum fee for a fee-bump transaction is one base fee _more_ than the minimum fee for -the inner transaction, and the fee rate is normalized by one plus the number of operations in the inner transaction. For more info on fee rate calculation, see [Fees](./fees.mdx). +A fee-bump transaction has an effective number of operations equal to one plus the number of operations in the inner transaction. Therefore, the minimum fee for a fee-bump transaction is one base fee _more_ than the minimum fee for the inner transaction, and the fee rate is normalized by one plus the number of operations in the inner transaction. For more info on fee rate calculation, see [Fees](./fees.mdx). #### Replace-by-Fee -You can use a fee-bump transaction to increase the fee on a transaction originating from your own account — something you may want to consider if a transaction is failing to make the ledger due to surge pricing. However, there is a condition: if you submit two distinct transactions with the same source account and sequence number, and the second transaction is a fee-bump transaction, the second transaction will be included in the transaction queue in place of the first transaction if and only if the fee bid of the second transaction is _at least 10x the fee bid of the first transaction_. Though that limit may seem somewhat arbitrary, it was a deliberate design decision to limit DOS attacks without introducing too much complexity to the protocol. +You can use a fee-bump transaction to increase the fee on a transaction originating from your own account — something you may want to consider if a transaction is failing to make the ledger due to surge pricing. However, there is a condition: if you submit two distinct transactions with the same source account and sequence number, and the second transaction is a fee-bump transaction, the second transaction will be included in the transaction queue in place of the first transaction if and only if the fee bid of the second transaction is _at least 10x the fee bid of the first transaction_. Though that limit may seem somewhat arbitrary, it was a deliberate design decision to limit DOS attacks without introducing too much complexity to the protocol. ## Fee-Bump Transaction Envelopes @@ -39,13 +38,13 @@ A fee-bump transaction goes through a series of checks in its lifecycle to deter - **Fee Account** — The fee account for the fee-bump transaction must exist on the ledger. -- **Fee** — The fee must be greater than or equal to the [network minimum fee](./fees.mdx) for the number of operations in the inner transaction, +1 for the fee bump. It must also be greater than or equal to the fee specfied in the inner transaction. Additionally, if the fee-bump transaction is taking advantage of the [replace-by-fee](#replace-by-fee) feature, in which a transaction envelope in the transaction queue is replaced by a fee-bump transaction envelope with the same sequence number and source account, the fee must be at least 10x higher. +- **Fee** — The fee must be greater than or equal to the [network minimum fee](./fees.mdx) for the number of operations in the inner transaction, +1 for the fee bump. It must also be greater than or equal to the fee specfied in the inner transaction. Additionally, if the fee-bump transaction is taking advantage of the [replace-by-fee](#replace-by-fee) feature, in which a transaction envelope in the transaction queue is replaced by a fee-bump transaction envelope with the same sequence number and source account, the fee must be at least 10x higher. -- **Fee Account Signature** — The fee-bump transaction envelope must contain a valid signaure for the fee account. Additionally, the weight of that signature must meet the low threshold for the fee account, and the appropriate network passphrase must be part of the transaction hash signed by the fee account. See [Network Passphrases](./network-passphrase.mdx) for more. +- **Fee Account Signature** — The fee-bump transaction envelope must contain a valid signaure for the fee account. Additionally, the weight of that signature must meet the low threshold for the fee account, and the appropriate network passphrase must be part of the transaction hash signed by the fee account. See [Network Passphrases](./network-passphrase.mdx) for more. - **Fee Account Balance** — The fee account must have a sufficient XLM balance to cover the fee. -- **Inner Transaction** — For a fee-bump to succeed, the inner transaction must be valid, which means that it must meet the requirements described in the [Validity of a Transaction](./transactions.mdx/#validity-of-a-transaction) section. If validation of the inner transaction is successful, then the result is `FEE_BUMP_INNER_SUCCESS`, and the validation results from the validation of the inner transaction appear in the inner result. If the inner transaction is invalid, the result is `FEE_BUMP_INNER_FAILED`, and the fee-bump transaction is invalid because the inner transaction is invalid. +- **Inner Transaction** — For a fee-bump to succeed, the inner transaction must be valid, which means that it must meet the requirements described in the [Validity of a Transaction](./transactions.mdx/#validity-of-a-transaction) section. If validation of the inner transaction is successful, then the result is `FEE_BUMP_INNER_SUCCESS`, and the validation results from the validation of the inner transaction appear in the inner result. If the inner transaction is invalid, the result is `FEE_BUMP_INNER_FAILED`, and the fee-bump transaction is invalid because the inner transaction is invalid. ## Application @@ -53,11 +52,11 @@ The sole purpose of a fee-bump transaction is to get an inner transaction includ Every fee-bump transaction result contains a complete inner transaction result. This inner-transaction result is exactly what would have been produced had there been no fee-bump transaction, except that the inner fee will always be 0. -A fee-bump transaction is essentially a wrapper around a transaction that has been bundled with requisite signatures into a transaction envelope. Therefore, before creating a fee-bump transaction, you must first create a regular transaction and transaction envelope. For more on regular transaction creation and a summary of the lifecycle of a transaction, see [Transactions](./transactions.mdx). +A fee-bump transaction is essentially a wrapper around a transaction that has been bundled with requisite signatures into a transaction envelope. Therefore, before creating a fee-bump transaction, you must first create a regular transaction and transaction envelope. For more on regular transaction creation and a summary of the lifecycle of a transaction, see [Transactions](./transactions.mdx). ## Result Codes -Fee-bump transactions share result codes with regular transactions. They're listed in a table below. Error reference for operations can be found in [List of Operations](../start/list-of-operations.mdx) doc. +Fee-bump transactions share result codes with regular transactions. They're listed in a table below. Error reference for operations can be found in [List of Operations](../start/list-of-operations.mdx) doc. | Result | Code | Description | | --- | --- | --- | @@ -75,4 +74,4 @@ Fee-bump transactions share result codes with regular transactions. They're lis | BAD_AUTH_EXTRA | -10 | Unused signatures attached to transaction. | | INTERNAL_ERROR | -11 | An unknown error occured. | | NOT_SUPPORTED | -12 | The transaction type is not supported | -| FEE_BUMP_INNER_FAILED | -13 | The fee bump inner transaction failed. See [Fee Bumps](./fee-bumps.mdx) for more info.| +| FEE_BUMP_INNER_FAILED | -13 | The fee bump inner transaction failed. See [Fee Bumps](./fee-bumps.mdx) for more info. | diff --git a/docs/glossary/fees.mdx b/docs/glossary/fees.mdx index 966dfb03a..e65fb027d 100644 --- a/docs/glossary/fees.mdx +++ b/docs/glossary/fees.mdx @@ -7,7 +7,7 @@ import { Alert } from "@site/src/components/Alert"; -This doc explains transaction fees. Stellar also requires accounts to have a minimum balance, which you can read about in the [Minimum Balance](./minimum-balance.mdx) doc. +This doc explains transaction fees. Stellar also requires accounts to have a minimum balance, which you can read about in the [Minimum Balance](./minimum-balance.mdx) doc. diff --git a/docs/glossary/ledger.mdx b/docs/glossary/ledger.mdx index b580ceec1..6c5931f60 100644 --- a/docs/glossary/ledger.mdx +++ b/docs/glossary/ledger.mdx @@ -45,7 +45,7 @@ Every ledger header has the following fields: - **Fee pool**: Number of lumens that have been paid in fees. Note this is denominated in lumens, even though a transaction’s [`fee`](./transactions.mdx#fee) field is in stroops. -- **Inflation sequence**: Number of times inflation has been run. Note: the inflation operation was deprecated when validators voted to upgrade the network to Protocol 12 on 10/28/2019. Therefore, inflation no longer runs, so this sequence number no longer changes. +- **Inflation sequence**: Number of times inflation has been run. Note: the inflation operation was deprecated when validators voted to upgrade the network to Protocol 12 on 10/28/2019. Therefore, inflation no longer runs, so this sequence number no longer changes. - **ID pool**: The last used global ID. These IDs are used for generating objects. diff --git a/docs/glossary/liquidity-pool.mdx b/docs/glossary/liquidity-pool.mdx index f86c847fe..3a73f03f3 100644 --- a/docs/glossary/liquidity-pool.mdx +++ b/docs/glossary/liquidity-pool.mdx @@ -95,7 +95,7 @@ function buildTx(source, signer, ...ops) { networkPassphrase: sdk.Networks.TESTNET, withMuxing: true, }); - ops.forEach(op => tx.addOperation(op)); + ops.forEach((op) => tx.addOperation(op)); tx = tx.setTimeout(30).build(); tx.sign(signer); return tx; @@ -103,33 +103,31 @@ function buildTx(source, signer, ...ops) { /// Returns the given asset pair in "protocol order." function orderAssets(A, B) { - return (sdk.Asset.compare(A, B) <= 0) ? [A, B] : [B, A]; + return sdk.Asset.compare(A, B) <= 0 ? [A, B] : [B, A]; } /// Returns all of the accounts we'll be using. function getAccounts() { - return Promise.all(kps.map(kp => server.loadAccount(kp.publicKey()))); + return Promise.all(kps.map((kp) => server.loadAccount(kp.publicKey()))); } const kps = [ "SBGCD73TK2PTW2DQNWUYZSTCTHHVJPL4GZF3GVZMCDL6GYETYNAYOADN", "SAAQFHI2FMSIC6OFPWZ3PDIIX3OF64RS3EB52VLYYZBX6GYB54TW3Q4U", "SCJWYFTBDMDPAABHVJZE3DRMBRTEH4AIC5YUM54QGW57NUBM2XX6433P", -].map(s => sdk.Keypair.fromSecret(s)); +].map((s) => sdk.Keypair.fromSecret(s)); // kp1 issues the assets const kp1 = kps[0]; -const [ A, B ] = orderAssets(...[ - new sdk.Asset("A", kp1.publicKey()), - new sdk.Asset("B", kp1.publicKey()), -]); +const [A, B] = orderAssets( + ...[new sdk.Asset("A", kp1.publicKey()), new sdk.Asset("B", kp1.publicKey())], +); /// Establishes trustlines and funds `recipientKp` for all `assets`. function distributeAssets(issuerKp, recipientKp, ...assets) { - return server - .loadAccount(issuerKp.publicKey()) - .then(issuer => { - const ops = assets.map(asset => [ + return server.loadAccount(issuerKp.publicKey()).then((issuer) => { + const ops = assets + .map((asset) => [ sdk.Operation.changeTrust({ source: recipientKp.publicKey(), limit: "100000", @@ -141,16 +139,17 @@ function distributeAssets(issuerKp, recipientKp, ...assets) { amount: "100000", asset: asset, }), - ]).flat(); + ]) + .flat(); - let tx = buildTx(issuer, issuerKp, ...ops); - tx.sign(recipientKp); - return server.submitTransaction(tx); - }); + let tx = buildTx(issuer, issuerKp, ...ops); + tx.sign(recipientKp); + return server.submitTransaction(tx); + }); } function preamble() { - return Promise.all([1, 2].map(i => distributeAssets(kp1, kps[i], A, B))); + return Promise.all([1, 2].map((i) => distributeAssets(kp1, kps[i], A, B))); } ``` @@ -231,16 +230,22 @@ First, lets create a liquidity pool for the asset pair defined in the preamble. ```js -const poolShareAsset = new sdk.LiquidityPoolAsset(A, B, sdk.LiquidityPoolFeeV18); +const poolShareAsset = new sdk.LiquidityPoolAsset( + A, + B, + sdk.LiquidityPoolFeeV18, +); function establishPoolTrustline(account, keypair, poolAsset) { return server.submitTransaction( - buildTx(account, keypair, + buildTx( + account, + keypair, sdk.Operation.changeTrust({ asset: poolAsset, - limit: "100000" - }) - ) + limit: "100000", + }), + ), ); } ``` @@ -270,26 +275,30 @@ To work with a liquidity pool, you need to know its ID beforehand. It's a determ ```js -const poolId = sdk.getLiquidityPoolId( - "constant_product", - poolShareAsset.getLiquidityPoolParameters() -).toString("hex"); +const poolId = sdk + .getLiquidityPoolId( + "constant_product", + poolShareAsset.getLiquidityPoolParameters(), + ) + .toString("hex"); function addLiquidity(source, signer, poolId, maxReserveA, maxReserveB) { const exactPrice = reserveA / reserveB; - const minPrice = exactPrice - (exactPrice * 0.10); - const maxPrice = exactPrice + (exactPrice * 0.10); + const minPrice = exactPrice - exactPrice * 0.1; + const maxPrice = exactPrice + exactPrice * 0.1; return server.submitTransaction( - buildTx(source, signer, + buildTx( + source, + signer, sdk.Operation.liquidityPoolDeposit({ liquidityPoolId: poolId, maxAmountA: maxReserveA, maxAmountB: maxReserveB, minPrice: minPrice.toFixed(7), maxPrice: maxPrice.toFixed(7), - }) - ) + }), + ), ); } ``` @@ -337,14 +346,16 @@ If you own shares of a particular pool, you can withdraw reserves from it. The o ```js function removeLiquidity(source, signer, poolId, minReserveA, minReserveB) { return server.submitTransaction( - buildTx(source, signer, + buildTx( + source, + signer, sdk.Operation.liquidityPoolWithdraw({ liquidityPoolId: poolId, minAmountA: minReserveA, minAmountB: minReserveB, - }) - ) - ) + }), + ), + ); } ``` @@ -358,8 +369,8 @@ def remove_liquidity( shares_amount / total_shares * Decimal(pool_info["reserves"][0]["amount"]) - * Decimal("0.95") - ) # + * Decimal("0.95") + ) # min_reserve_b = ( shares_amount / total_shares @@ -393,28 +404,31 @@ Finally, we can combine these pieces together to simulate some participation in ```js function main() { return getAccounts() - .then(accounts => - Promise.all(kps.map((kp, i) => { - const acc = accounts[i]; - const depositA = ((i+1)*1000).toString(); - const depositB = ((i+1)*3000).toString(); // maintain a 1:3 ratio - - return establishPoolTrustline(acc, kp, poolShareAsset) - .then(_ => addLiquidity(acc, kp, poolId, depositA, depositB)) - .then(_ => getSpotPrice()); - })) + .then((accounts) => + Promise.all( + kps.map((kp, i) => { + const acc = accounts[i]; + const depositA = ((i + 1) * 1000).toString(); + const depositB = ((i + 1) * 3000).toString(); // maintain a 1:3 ratio + + return establishPoolTrustline(acc, kp, poolShareAsset) + .then((_) => addLiquidity(acc, kp, poolId, depositA, depositB)) + .then((_) => getSpotPrice()); + }), + ), ) - .then(_ => withdrawLiquidity(accounts[1], kps[1], "500", "2000")) - .then(_ => getSpotPrice()); + .then((_) => withdrawLiquidity(accounts[1], kps[1], "500", "2000")) + .then((_) => getSpotPrice()); } function getSpotPrice() { - return server.liquidityPools() + return server + .liquidityPools() .liquidityPoolId(poolId) .call() - .then(pool => { - const [a, b] = pool.reserves.map(r => r.amount); - const spotPrice = (new BigNumber(a)).div(b); + .then((pool) => { + const [a, b] = pool.reserves.map((r) => r.amount); + const spotPrice = new BigNumber(a).div(b); console.log(`Price: ${a}/${b} = ${spotPrice.toFormat(2)}`); }); } @@ -471,16 +485,18 @@ You can access the transactions, operations, and effects related to a liquidity ```js -server.operations() +server + .operations() .forLiquidityPool(poolId) .call() - .then(ops => { + .then((ops) => { ops.records - .filter(op => op.type == "liquidity_pool_deposit") - .forEach(op => { + .filter((op) => op.type == "liquidity_pool_deposit") + .forEach((op) => { console.log("Reserves deposited:"); - op.reserves_deposited.forEach( - r => console.log(` ${r.amount} of ${r.asset}`)); + op.reserves_deposited.forEach((r) => + console.log(` ${r.amount} of ${r.asset}`), + ); console.log(" for pool shares: ", op.shares_received); }); }); diff --git a/docs/glossary/minimum-balance.mdx b/docs/glossary/minimum-balance.mdx index 37aecd36d..22dae5bf1 100644 --- a/docs/glossary/minimum-balance.mdx +++ b/docs/glossary/minimum-balance.mdx @@ -7,7 +7,7 @@ import { Alert } from "@site/src/components/Alert"; -This doc explains minimum balance requirements. If you want to know about transaction fees, check out the [Fees](./fees.mdx) doc. +This doc explains minimum balance requirements. If you want to know about transaction fees, check out the [Fees](./fees.mdx) doc. diff --git a/docs/glossary/muxed-accounts.mdx b/docs/glossary/muxed-accounts.mdx index 213302a48..0b9562c54 100644 --- a/docs/glossary/muxed-accounts.mdx +++ b/docs/glossary/muxed-accounts.mdx @@ -9,8 +9,7 @@ A **muxed** (or _multiplexed_) **account** is an account that exists "virtually" -**Warning**: _This feature is in active rollout._ -Muxed accounts are gaining adoption but may not be fully supported. Some wallets may not display a muxed account address and instead display the account ID address, ignoring the 64-bit ID. Continued adoption efforts are actively in progress. +**Warning**: _This feature is in active rollout._ Muxed accounts are gaining adoption but may not be fully supported. Some wallets may not display a muxed account address and instead display the account ID address, ignoring the 64-bit ID. Continued adoption efforts are actively in progress. @@ -87,24 +86,30 @@ const passphrase = "Test SDF Network ; September 2015"; const url = "https://horizon-testnet.stellar.org"; let server = new sdk.Server(url); -const custodian = sdk.Keypair.fromSecret("SAQLZCQA6AYUXK6JSKVPJ2MZ5K5IIABJOEQIG4RVBHX4PG2KMRKWXCHJ"); -const outsider = sdk.Keypair.fromSecret("SAAY2H7SANIS3JLFBFPLJRTYNLUYH4UTROIKRVFI4FEYV4LDW5Y7HDZ4"); +const custodian = sdk.Keypair.fromSecret( + "SAQLZCQA6AYUXK6JSKVPJ2MZ5K5IIABJOEQIG4RVBHX4PG2KMRKWXCHJ", +); +const outsider = sdk.Keypair.fromSecret( + "SAAY2H7SANIS3JLFBFPLJRTYNLUYH4UTROIKRVFI4FEYV4LDW5Y7HDZ4", +); async function preamble() { - [ custodianAcc, outsiderAcc ] = await Promise.all([ + [custodianAcc, outsiderAcc] = await Promise.all([ server.loadAccount(custodian.publicKey()), server.loadAccount(outsider.publicKey()), ]); customers = ["1", "22", "333", "4444"].map( - (id) => new sdk.MuxedAccount(custodianAcc, id) + (id) => new sdk.MuxedAccount(custodianAcc, id), ); console.log("Custodian:\n ", custodian.publicKey()); - console.log("Customers:") + console.log("Customers:"); customers.forEach((customer) => { - console.log(" " + customer.id().padStart(4, ' ') + ":", - customer.accountId()); + console.log( + " " + customer.id().padStart(4, " ") + ":", + customer.accountId(), + ); }); console.log(); } @@ -172,13 +177,13 @@ function doPayment(source, dest) { source: source.accountId(), destination: dest.accountId(), asset: sdk.Asset.native(), - amount: "10" + amount: "10", }); let tx = new sdk.TransactionBuilder(accountBeforePayment, { - networkPassphrase: StellarSdk.Networks.TESTNET, - fee: StellarSdk.BASE_FEE, - }) + networkPassphrase: StellarSdk.Networks.TESTNET, + fee: StellarSdk.BASE_FEE, + }) .addOperation(payment) .setTimeout(30) .build(); @@ -202,12 +207,15 @@ The codeblock above covers all payment operations, abstracting away any need for ```js -preamble - .then(() => { - const src = customers[0]; - console.log(`Sending 10 XLM from Customer ${src.id()} to ${outsiderAcc.accountId().substring(0, 5)}.`) - return doPayment(src, outsiderAcc); - }); +preamble.then(() => { + const src = customers[0]; + console.log( + `Sending 10 XLM from Customer ${src.id()} to ${outsiderAcc + .accountId() + .substring(0, 5)}.`, + ); + return doPayment(src, outsiderAcc); +}); ``` @@ -233,12 +241,13 @@ As we've mentioned, muxed account actions aren't represented in the Stellar ledg ```js -preamble() - .then(() => { - const [ src, dst ] = customers.slice(0, 2); - console.log(`Sending 10 XLM from Customer ${src.id()} to Customer ${dst.id()}.`) - return doPayment(src, dst); - }); +preamble().then(() => { + const [src, dst] = customers.slice(0, 2); + console.log( + `Sending 10 XLM from Customer ${src.id()} to Customer ${dst.id()}.`, + ); + return doPayment(src, dst); +}); ``` @@ -314,14 +323,15 @@ For example, when using the JavaScript SDK incorrectly: ```js - const mAddress = "MA7QYNF7SOWQ3GLR2BGMZEHXAVIRZA4KVWLTJJFC7MGXUA74P7UJUAAAAAAAAAABUTGI4"; - transactionBuilder.addOperation( - Operation.setTrustLineFlags({ - trustor: mAddress, // wrong! - asset: someAsset, - flags: { clawbackEnabled: false } - }) - ); +const mAddress = + "MA7QYNF7SOWQ3GLR2BGMZEHXAVIRZA4KVWLTJJFC7MGXUA74P7UJUAAAAAAAAAABUTGI4"; +transactionBuilder.addOperation( + Operation.setTrustLineFlags({ + trustor: mAddress, // wrong! + asset: someAsset, + flags: { clawbackEnabled: false }, + }), +); ``` diff --git a/docs/glossary/sponsored-reserves.mdx b/docs/glossary/sponsored-reserves.mdx index 7ab47223a..a30a113dc 100644 --- a/docs/glossary/sponsored-reserves.mdx +++ b/docs/glossary/sponsored-reserves.mdx @@ -101,7 +101,7 @@ async function main() { console.log(`Funding:\n ${keypair.secret()}\n ${keypair.publicKey()}`); - // We use the "got" library here to do the HTTP request synchronously, but + // We use the "got" library here to do the HTTP request synchronously, but // you can obviously use any method you'd like for this. const response = await http(path).catch(function (error) { console.error(" failed:", error.response.body); @@ -174,68 +174,86 @@ Now, let's sponsor trustlines for Account A. Notice how the `CHANGE_TRUST` opera ```js - // - // 1. S1 will sponsor a trustline for Account A. - // - let s1Account = await server.loadAccount(S1.publicKey()).catch(accountFail); - let tx = new sdk.TransactionBuilder(s1Account, {fee: sdk.BASE_FEE}) - .addOperation(sdk.Operation.beginSponsoringFutureReserves({ +// +// 1. S1 will sponsor a trustline for Account A. +// +let s1Account = await server.loadAccount(S1.publicKey()).catch(accountFail); +let tx = new sdk.TransactionBuilder(s1Account, { fee: sdk.BASE_FEE }) + .addOperation( + sdk.Operation.beginSponsoringFutureReserves({ sponsoredId: A.publicKey(), - })) - .addOperation(sdk.Operation.changeTrust({ + }), + ) + .addOperation( + sdk.Operation.changeTrust({ source: A.publicKey(), asset: assets[0], limit: "1000", // This limit can vary according with your application; - // if left empty, it defaults to the max limit. - })) - .addOperation(sdk.Operation.endSponsoringFutureReserves({ + // if left empty, it defaults to the max limit. + }), + ) + .addOperation( + sdk.Operation.endSponsoringFutureReserves({ source: A.publicKey(), - })) - .setNetworkPassphrase(sdk.Networks.TESTNET) - .setTimeout(180) - .build(); - - // Note that while either can submit this transaction, both must sign it. - tx.sign(S1, A); - let txResponse = await server.submitTransaction(tx).catch(txCheck); - if (!txResponse) { return; } + }), + ) + .setNetworkPassphrase(sdk.Networks.TESTNET) + .setTimeout(180) + .build(); + +// Note that while either can submit this transaction, both must sign it. +tx.sign(S1, A); +let txResponse = await server.submitTransaction(tx).catch(txCheck); +if (!txResponse) { + return; +} - console.log("Sponsored a trustline of", A.publicKey()); +console.log("Sponsored a trustline of", A.publicKey()); - // - // 2. Both S1 and S2 sponsor trustlines for Account A for different assets. - // - let aAccount = await server.loadAccount(A.publicKey()).catch(accountFail); - let tx = new sdk.TransactionBuilder(aAccount, {fee: sdk.BASE_FEE}) - .addOperation(sdk.Operation.beginSponsoringFutureReserves({ +// +// 2. Both S1 and S2 sponsor trustlines for Account A for different assets. +// +let aAccount = await server.loadAccount(A.publicKey()).catch(accountFail); +let tx = new sdk.TransactionBuilder(aAccount, { fee: sdk.BASE_FEE }) + .addOperation( + sdk.Operation.beginSponsoringFutureReserves({ source: S1.publicKey(), - sponsoredId: A.publicKey() - })) - .addOperation(sdk.Operation.changeTrust({ + sponsoredId: A.publicKey(), + }), + ) + .addOperation( + sdk.Operation.changeTrust({ asset: assets[1], - limit: "5000" - })) - .addOperation(sdk.Operation.endSponsoringFutureReserves()) + limit: "5000", + }), + ) + .addOperation(sdk.Operation.endSponsoringFutureReserves()) - .addOperation(sdk.Operation.beginSponsoringFutureReserves({ + .addOperation( + sdk.Operation.beginSponsoringFutureReserves({ source: S2.publicKey(), - sponsoredId: A.publicKey() - })) - .addOperation(sdk.Operation.changeTrust({ + sponsoredId: A.publicKey(), + }), + ) + .addOperation( + sdk.Operation.changeTrust({ asset: assets[2], - limit: "2500" - })) - .addOperation(sdk.Operation.endSponsoringFutureReserves()) - .setNetworkPassphrase(sdk.Networks.TESTNET) - .setTimeout(180) - .build(); - - // Note that all 3 accounts must approve/sign this transaction. - tx.sign(S1, S2, A); - let txResponse = await server.submitTransaction(tx).catch(txCheck); - if (!txResponse) { return; } + limit: "2500", + }), + ) + .addOperation(sdk.Operation.endSponsoringFutureReserves()) + .setNetworkPassphrase(sdk.Networks.TESTNET) + .setTimeout(180) + .build(); + +// Note that all 3 accounts must approve/sign this transaction. +tx.sign(S1, S2, A); +let txResponse = await server.submitTransaction(tx).catch(txCheck); +if (!txResponse) { + return; +} - console.log("Sponsored two trustlines of", A.publicKey()); +console.log("Sponsored two trustlines of", A.publicKey()); ``` ```go @@ -299,30 +317,36 @@ An intuitive way to think of a sponsorship transfer is that the very act of spon ```js - // - // 3. Transfer sponsorship of B's second trustline from S1 to S2. - // - let tx = new sdk.TransactionBuilder(s1Account, {fee: sdk.BASE_FEE}) - .addOperation(sdk.Operation.beginSponsoringFutureReserves({ +// +// 3. Transfer sponsorship of B's second trustline from S1 to S2. +// +let tx = new sdk.TransactionBuilder(s1Account, { fee: sdk.BASE_FEE }) + .addOperation( + sdk.Operation.beginSponsoringFutureReserves({ source: S2.publicKey(), - sponsoredId: S1.publicKey() - })) - .addOperation(sdk.Operation.revokeTrustlineSponsorship({ + sponsoredId: S1.publicKey(), + }), + ) + .addOperation( + sdk.Operation.revokeTrustlineSponsorship({ account: A.publicKey(), asset: assets[1], - })) - .addOperation(sdk.Operation.endSponsoringFutureReserves()) - .setNetworkPassphrase(sdk.Networks.TESTNET) - .setTimeout(180) - .build(); - - // Notice that while the old sponsor *sends* the transaction, both sponsors - // must *approve* the transfer. - tx.sign(S1, S2); - let txResponse = await server.submitTransaction(tx).catch(txCheck); - if (!txResponse) { return; } + }), + ) + .addOperation(sdk.Operation.endSponsoringFutureReserves()) + .setNetworkPassphrase(sdk.Networks.TESTNET) + .setTimeout(180) + .build(); + +// Notice that while the old sponsor *sends* the transaction, both sponsors +// must *approve* the transfer. +tx.sign(S1, S2); +let txResponse = await server.submitTransaction(tx).catch(txCheck); +if (!txResponse) { + return; +} - console.log("Transferred sponsorship for", A.publicKey()); +console.log("Transferred sponsorship for", A.publicKey()); ``` ```go diff --git a/docs/glossary/testnet.mdx b/docs/glossary/testnet.mdx index 374d1e257..1044e7bbf 100644 --- a/docs/glossary/testnet.mdx +++ b/docs/glossary/testnet.mdx @@ -38,9 +38,9 @@ If you are having trouble submitting transactions to the testnet, you may need t ### Friendbot, the Testnet XLM Faucet -When building on the testnet, developers can request testnet XLM from Friendbot, which is an XLM faucet. You can use the [Stellar Laboratory](https://laboratory.stellar.org/#?network=test) to fund an account with Friendbot, or you can check out the [Create an Account tutorial](../tutorials/create-account.mdx) to see how to do it with various Stellar SDKs. +When building on the testnet, developers can request testnet XLM from Friendbot, which is an XLM faucet. You can use the [Stellar Laboratory](https://laboratory.stellar.org/#?network=test) to fund an account with Friendbot, or you can check out the [Create an Account tutorial](../tutorials/create-account.mdx) to see how to do it with various Stellar SDKs. -To keep things fair for everyone, requests to Friendbot are rate limited, so please use it judiciously. When called, Friendbot provides 10,000 testnet XLM to create a new testnet account. If you need to create multiple testnet accounts, use Friendbot to create one account, and then use that account to fund the rest using the [Create Account operation](../start/list-of-operations/#create-account). +To keep things fair for everyone, requests to Friendbot are rate limited, so please use it judiciously. When called, Friendbot provides 10,000 testnet XLM to create a new testnet account. If you need to create multiple testnet accounts, use Friendbot to create one account, and then use that account to fund the rest using the [Create Account operation](../start/list-of-operations/#create-account). ### Periodic Reset of Testnet Data diff --git a/docs/glossary/transactions.mdx b/docs/glossary/transactions.mdx index ddbbc220b..721347859 100644 --- a/docs/glossary/transactions.mdx +++ b/docs/glossary/transactions.mdx @@ -110,79 +110,34 @@ To determine if a transaction is valid, many checks take place over the course o ## Transaction Lifecycle -1. **Creation (Transaction Creator)**: A user creates a transaction by setting the source - account, sequence number, list of operations and their respective parameters, fee, and - optionally a memo and timebounds. You can try this out [using the Stellar - Laboratory](https://laboratory.stellar.org/#txbuilder?network=test). - -1. **Signing (Transaction Signers)**: Once the transaction is completely filled out, the - transaction is formed into a transaction envelope, which contains the transaction itself and a - list of signers. All the required signatures must be collected and added to the transaction - envelope's list of signers. Commonly it's just the signature of the account doing the - transaction, but more complicated setups can require collecting [signatures from multiple - parties](./multisig.mdx). - -1. **Submitting (Transaction Submitter)**: After signing, the transaction must be valid and can now - be submitted to the Stellar network. If the transaction is invalid, it will be immediately - rejected by stellar-core based on [the validity rules of a - transaction](#validity-of-a-transaction), the account's sequence number will not be incremented, - and no fee will be consumed from the source account. Multiple transactions for the same account - can be submitted, provided each of their sequence numbers are off by one. If they are all valid, - Stellar Core will craft a transaction set with each of those transactions applied in sequence - number order. Transactions are typically submitted using [Horizon](/api/introduction/), but you - can also submit the transaction directly to an instance of - [Stellar Core](..//run-core-node/index.mdx). - -1. **Propagating (Validator)**: Once Stellar Core has determined that a transaction is valid, it - will then propagate the transaction to all of the other servers to which it's connected. In this - way, a valid transaction is flooded to the entire Stellar network. - -1. **Crafting a candidate transaction set (Validator)**: When it's time to close the ledger, each - Stellar Core validator (a Stellar Core node participating in consensus) takes - all valid transactions it is aware of since the last ledger close and collects them into a - candidate transaction set. If it hears about any incoming transactions now, it puts them aside - for the next ledger close. If the number of operations in the candidate transaction set is - greater than the maximum number of operations per ledger, transactions will be prioritized by - their fee for inclusion in the set. See the [Fees](./fees.mdx) doc for more info. - -1. **Nominating a transaction set (Validator)**: Once each validator has crafted a candidate - transaction set, the set is nominated to the network. - -1. **Stellar Consensus Protocol (SCP) determines the final transaction set (Validator Network)**: - [SCP](./scp.mdx) resolves any differences between candidate transaction sets, and ultimately determines a - single transaction set to apply, the close time of the ledger, and any upgrades to the protocol - that need to be applied network wide at apply time. - - If a transaction doesn't make it into the transaction set, it is kept around in memory in - order to be added to the next transaction set on a best effort basis. - - If a transaction is kept in memory after a certain number of ledger closes, it will be banned - for several additional ledgers. This means no attempt will be made to include it in a - candidate transaction set additional ledgers during this time. - -1. **Transaction apply order is determined (Validator Network)**: Once SCP agrees on a particular - transaction set, the apply order is computed for the transaction set. This both shuffles the - order of the set to create uncertainty for competing transactions and maintains the - order of sequence numbers for multiple transactions per account. - -1. **Fees are collected (Validator)**: [Fees](./fees.mdx) are collected for all transactions - simultaneously. - -1. **Application (Validator)**: Each transaction is applied in the order previously determined. - For each transaction, the account's sequence number is consumed (increased by 1), the - transaction's validity is checked again, and each operation is applied in the order they occur - in the transaction. Operations may fail at this stage due to errors that can occur outside of - the transaction and operation validity checks. For example, an insufficient balance for a - payment is not checked at submission, and would fail at this time. If any operation fails, the - entire transaction will fail, and all previous operations will be rolled back. - -1. **Protocol Upgrades (Validator)**: Finally, upgrades are run if an upgrade took place. This - can include arbitrary logic to upgrade the ledger state for protocol upgrades, along with - ledger header modifications including the protocol version, base fee, maximum number of - operations per ledger, etc. Once this has completed, the life cycle begins anew. +1. **Creation (Transaction Creator)**: A user creates a transaction by setting the source account, sequence number, list of operations and their respective parameters, fee, and optionally a memo and timebounds. You can try this out [using the Stellar Laboratory](https://laboratory.stellar.org/#txbuilder?network=test). + +1. **Signing (Transaction Signers)**: Once the transaction is completely filled out, the transaction is formed into a transaction envelope, which contains the transaction itself and a list of signers. All the required signatures must be collected and added to the transaction envelope's list of signers. Commonly it's just the signature of the account doing the transaction, but more complicated setups can require collecting [signatures from multiple parties](./multisig.mdx). + +1. **Submitting (Transaction Submitter)**: After signing, the transaction must be valid and can now be submitted to the Stellar network. If the transaction is invalid, it will be immediately rejected by stellar-core based on [the validity rules of a transaction](#validity-of-a-transaction), the account's sequence number will not be incremented, and no fee will be consumed from the source account. Multiple transactions for the same account can be submitted, provided each of their sequence numbers are off by one. If they are all valid, Stellar Core will craft a transaction set with each of those transactions applied in sequence number order. Transactions are typically submitted using [Horizon](/api/introduction/), but you can also submit the transaction directly to an instance of [Stellar Core](..//run-core-node/index.mdx). + +1. **Propagating (Validator)**: Once Stellar Core has determined that a transaction is valid, it will then propagate the transaction to all of the other servers to which it's connected. In this way, a valid transaction is flooded to the entire Stellar network. + +1. **Crafting a candidate transaction set (Validator)**: When it's time to close the ledger, each Stellar Core validator (a Stellar Core node participating in consensus) takes all valid transactions it is aware of since the last ledger close and collects them into a candidate transaction set. If it hears about any incoming transactions now, it puts them aside for the next ledger close. If the number of operations in the candidate transaction set is greater than the maximum number of operations per ledger, transactions will be prioritized by their fee for inclusion in the set. See the [Fees](./fees.mdx) doc for more info. + +1. **Nominating a transaction set (Validator)**: Once each validator has crafted a candidate transaction set, the set is nominated to the network. + +1. **Stellar Consensus Protocol (SCP) determines the final transaction set (Validator Network)**: [SCP](./scp.mdx) resolves any differences between candidate transaction sets, and ultimately determines a single transaction set to apply, the close time of the ledger, and any upgrades to the protocol that need to be applied network wide at apply time. + + - If a transaction doesn't make it into the transaction set, it is kept around in memory in order to be added to the next transaction set on a best effort basis. + - If a transaction is kept in memory after a certain number of ledger closes, it will be banned for several additional ledgers. This means no attempt will be made to include it in a candidate transaction set additional ledgers during this time. + +1. **Transaction apply order is determined (Validator Network)**: Once SCP agrees on a particular transaction set, the apply order is computed for the transaction set. This both shuffles the order of the set to create uncertainty for competing transactions and maintains the order of sequence numbers for multiple transactions per account. + +1. **Fees are collected (Validator)**: [Fees](./fees.mdx) are collected for all transactions simultaneously. + +1. **Application (Validator)**: Each transaction is applied in the order previously determined. For each transaction, the account's sequence number is consumed (increased by 1), the transaction's validity is checked again, and each operation is applied in the order they occur in the transaction. Operations may fail at this stage due to errors that can occur outside of the transaction and operation validity checks. For example, an insufficient balance for a payment is not checked at submission, and would fail at this time. If any operation fails, the entire transaction will fail, and all previous operations will be rolled back. + +1. **Protocol Upgrades (Validator)**: Finally, upgrades are run if an upgrade took place. This can include arbitrary logic to upgrade the ledger state for protocol upgrades, along with ledger header modifications including the protocol version, base fee, maximum number of operations per ledger, etc. Once this has completed, the life cycle begins anew. ## Result Codes -Transactions return a result code listed in a table below. Error reference for operations can be -found in [List of Operations](../start/list-of-operations.mdx) doc. +Transactions return a result code listed in a table below. Error reference for operations can be found in [List of Operations](../start/list-of-operations.mdx) doc. | Result | Code | Description | | --- | --- | --- | diff --git a/docs/issuing-assets/anatomy-of-an-asset.mdx b/docs/issuing-assets/anatomy-of-an-asset.mdx index d0cd57780..ef529b780 100644 --- a/docs/issuing-assets/anatomy-of-an-asset.mdx +++ b/docs/issuing-assets/anatomy-of-an-asset.mdx @@ -15,8 +15,8 @@ However, the combination of asset code and issuer allows each asset to be unique When you issue an asset, the first thing you do is choose an identifying code. Currently, there are two supported formats. -- **Alphanumeric 4-character maximum**: Any characters from the set [a-z][A-Z][0-9] are allowed. The code can be shorter than 4 characters, but the trailing characters must all be empty. -- **Alphanumeric 12-character maximum**: Any characters from the set [a-z][A-Z][0-9] are allowed. The code can be any number of characters from 5 to 12, but the trailing characters must all be empty. +- **Alphanumeric 4-character maximum**: Any characters from the set [a-z][a-z][0-9] are allowed. The code can be shorter than 4 characters, but the trailing characters must all be empty. +- **Alphanumeric 12-character maximum**: Any characters from the set [a-z][a-z][0-9] are allowed. The code can be any number of characters from 5 to 12, but the trailing characters must all be empty. Provided it falls into one of those two buckets, you can choose any asset code you like. That said, if you’re issuing a currency, you should use the appropriate [ISO 4217 code](https://en.wikipedia.org/wiki/ISO_4217), and if you’re issuing a stock or bond, the appropriate [ISIN number](https://en.wikipedia.org/wiki/International_Securities_Identification_Number). Doing so makes it easier for Stellar interfaces to properly display and sort your token in their listings, and allows potential token holders to understand, at a glance, what your token represents. diff --git a/docs/issuing-assets/control-asset-access.mdx b/docs/issuing-assets/control-asset-access.mdx index 9e526ce0b..861f52632 100644 --- a/docs/issuing-assets/control-asset-access.mdx +++ b/docs/issuing-assets/control-asset-access.mdx @@ -29,7 +29,7 @@ There are two levels of authorization an asset issuer can grant using the `allow When `AUTHORIZATION_REVOCABLE` is enabled, an issuer can revoke an existing trustline's authorization, thereby freezing the asset held by an account. Doing so prevents that account from transfering or trading the asset, and cancels the account’s open orders for the asset. -`AUTHORIZATION_REVOCABLE` also allows an issuer to reduce authorization from complete to limited, which prevents the account from transferring or trading the asset, but does not cancel the account's open orders for the asset. This setting is useful for issuers of regulated assets who need to authorize transactions on a case-by-case basis to ensure each conforms to certain requirements. +`AUTHORIZATION_REVOCABLE` also allows an issuer to reduce authorization from complete to limited, which prevents the account from transferring or trading the asset, but does not cancel the account's open orders for the asset. This setting is useful for issuers of regulated assets who need to authorize transactions on a case-by-case basis to ensure each conforms to certain requirements. All changes to asset authorization are performed with the [`allow_trust`](../start/list-of-operations.mdx#allow-trust) operation. @@ -59,7 +59,7 @@ Here's a payment from A to B sandwiched between [`set_trust_line_flags`](../star - Operation 4: Issuer uses `SetTrustLineFlags` to set account B, asset X to `AUTHORIZED_TO_MAINTAIN_LIABILITIES_FLAG` state - Operation 5: Issuer uses `SetTrustLineFlags` to set account A, asset X to `AUTHORIZED_TO_MAINTAIN_LIABILITIES_FLAG` state -The authorization sandwich allows the issuer to inspect the specifc payment, and to grant authorization for it and it alone. Since operations bundled in a transaction are simultaneous, A and B are only authorized for the specific, pre-approved payment operation. Complete authorization does not extend beyond the specific transaction. +The authorization sandwich allows the issuer to inspect the specifc payment, and to grant authorization for it and it alone. Since operations bundled in a transaction are simultaneous, A and B are only authorized for the specific, pre-approved payment operation. Complete authorization does not extend beyond the specific transaction. ## Sample code diff --git a/docs/issuing-assets/how-to-issue-an-asset.mdx b/docs/issuing-assets/how-to-issue-an-asset.mdx index 91ce7e97b..b1b9783aa 100644 --- a/docs/issuing-assets/how-to-issue-an-asset.mdx +++ b/docs/issuing-assets/how-to-issue-an-asset.mdx @@ -62,8 +62,8 @@ The distribution account specifies the issuer’s public key and the asset code Currently, there are two supported formats for asset codes. -- **Alphanumeric 4-character maximum**: Any characters from the set [a-z][A-Z][0-9] are allowed. The code can be shorter than 4 characters, but the trailing characters must all be empty. -- **Alphanumeric 12-character maximum**: Any characters from the set [a-z][A-Z][0-9] are allowed. The code can be any number of characters from 5 to 12, but the trailing characters must all be empty. +- **Alphanumeric 4-character maximum**: Any characters from the set [a-z][a-z][0-9] are allowed. The code can be shorter than 4 characters, but the trailing characters must all be empty. +- **Alphanumeric 12-character maximum**: Any characters from the set [a-z][a-z][0-9] are allowed. The code can be any number of characters from 5 to 12, but the trailing characters must all be empty. Any asset code works provided it falls into one of those two buckets. That said, if you’re issuing a currency, you should use the appropriate [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code, and if you’re issuing a stock or bond, the appropriate [ISIN number](https://en.wikipedia.org/wiki/International_Securities_Identification_Number). Doing so makes it easier for Stellar interfaces to properly display and sort your token in their listings, and allows potential token holders to understand, at a glance, what your token represents. diff --git a/docs/run-api-server/configuring.mdx b/docs/run-api-server/configuring.mdx index 28856674b..9a4ecad7e 100644 --- a/docs/run-api-server/configuring.mdx +++ b/docs/run-api-server/configuring.mdx @@ -31,7 +31,7 @@ stellar-horizon --help You'll see that Horizon defines a large number of flags; however, only a handful are required to get started: | flag | envvar | example | -| ---- | ------ | ------- | +| --- | --- | --- | | `--db-url` | `DATABASE_URL` | postgres://localhost/horizon_testnet | | `--history-archive-urls` | `HISTORY_ARCHIVE_URLS` | https://history.stellar.org/prd/core-testnet/core_testnet_001,https://history.stellar.org/prd/core-testnet/core_testnet_002 | @@ -43,7 +43,7 @@ You'll see that Horizon defines a large number of flags; however, only a handful As outlined at the beginning, we presume you are interested in starting an ingesting instance. For this, you need to specify some additional flags: | flag | envvar | example | -| ---- | ------ | ------- | +| --- | --- | --- | | `--captive-core-config-path` | `CAPTIVE_CORE_CONFIG_PATH` | /etc/default/stellar-captive-core.toml | | `--stellar-core-binary-path` | `STELLAR_CORE_BINARY_PATH` | /usr/bin/stellar-core | | `--captive-core-use-db` | `CAPTIVE_CORE_USE_DB` | true | @@ -52,15 +52,15 @@ Note that **ingestion is enabled by default**. - The first parameter, `--captive-core-config-path`, points to a Captive Core configuration file. This TOML file only requires a few fields (explained [below](#configuring-captive-core)) to get up and running. - The second parameter, `--stellar-core-binary-path`, is a filesystem path to a Stellar Core binary. Horizon will actually search your PATH for `stellar-core` by default, so if your environment is configured appropriately, you don't need to pass this. -- The third parameter, `--captive-core-use-db`, by default this value is false, which means Captive Core ingestion will run with ledger states stored in RAM. When set to true, enables Captive Core ingestion to store ledger states in local SQLite database rather than in memory (RAM). As of this writing, ledger states require approximately 8GB, but this will continue to increase as the ledger grows over time. The database location is determined by the `DATABASE` parameter within the `--captive-core-config-path` file. By default, it is set to `sqlite3://stellar.db`, which resolves to runtime directory location derived from `--captive-core-storage-path`. +- The third parameter, `--captive-core-use-db`, by default this value is false, which means Captive Core ingestion will run with ledger states stored in RAM. When set to true, enables Captive Core ingestion to store ledger states in local SQLite database rather than in memory (RAM). As of this writing, ledger states require approximately 8GB, but this will continue to increase as the ledger grows over time. The database location is determined by the `DATABASE` parameter within the `--captive-core-config-path` file. By default, it is set to `sqlite3://stellar.db`, which resolves to runtime directory location derived from `--captive-core-storage-path`. #### Without Ingestion If you aren't configuring your Horizon instance to perform ingestion, it still needs awareness about what's going on in the Stellar network to be useful. Thus, you need to point Horizon to a running Stellar Core instance: -| flag | envvar | example | -| ---- | ------ | ------- | -| `--ingest` | `INGEST` | false | +| flag | envvar | example | +| -------------------- | ------------------ | ---------------------- | +| `--ingest` | `INGEST` | false | | `--stellar-core-url` | `STELLAR_CORE_URL` | http://127.0.0.1:11626 | This can be a [Remote Captive Core](./remote-core.mdx) instance with its underlying Core node exposed or a [standalone](../run-core-node/) Stellar-Core instance. diff --git a/docs/run-api-server/ingestion.mdx b/docs/run-api-server/ingestion.mdx index c19f76102..e257368de 100644 --- a/docs/run-api-server/ingestion.mdx +++ b/docs/run-api-server/ingestion.mdx @@ -50,7 +50,7 @@ Even a massively-popular, well-established custodial service probably doesn't ne #### Reingestion -Regardless of whether you are running live ingestion or building up historical data, you may occasionally need to _re_ingest ledgers anew (for example on certain upgrades of Horizon). For this, you use the same command as above. +Regardless of whether you are running live ingestion or building up historical data, you may occasionally need to \_re_ingest ledgers anew (for example on certain upgrades of Horizon). For this, you use the same command as above. #### Parallel ingestion @@ -132,8 +132,7 @@ As the DB storage grows, the IO capacity will grow along with it. The number of ### Parallel Reingestion -Once the prerequisites are satisfied, we can spawn two Horizon reingestion -processes in parallel: +Once the prerequisites are satisfied, we can spawn two Horizon reingestion processes in parallel: 1. One for the first 17 million ledgers (which are almost empty). 1. Another one for the rest of the history. diff --git a/docs/run-api-server/monitoring.mdx b/docs/run-api-server/monitoring.mdx index dc2b5aa3f..582961d32 100644 --- a/docs/run-api-server/monitoring.mdx +++ b/docs/run-api-server/monitoring.mdx @@ -42,7 +42,7 @@ Below we present a few standard log entries with associated fields. You can use ### Starting HTTP request | Key | Value | -| --- | ----- | +| --- | --- | | **`msg`** | **`Starting request`** | | `client_name` | Value of `X-Client-Name` HTTP header representing client name | | `client_version` | Value of `X-Client-Version` HTTP header representing client version | @@ -61,7 +61,7 @@ Below we present a few standard log entries with associated fields. You can use ### Finished HTTP request | Key | Value | -| --- | ----- | +| --- | --- | | **`msg`** | **`Finished request`** | | `bytes` | Number of response bytes sent | | `client_name` | Value of `X-Client-Name` HTTP header representing client name | @@ -102,7 +102,7 @@ Using the entries above you can build metrics that will help understand performa Below are example alerts with potential causes and solutions. Feel free to add more alerts using your metrics: | Alert | Cause | Solution | -| ----- | ----- | -------- | +| --- | --- | --- | | Spike in number of requests | Potential DoS attack | Lower rate-limiting threshold | | Large number of rate-limited requests | Rate-limiting threshold too low | Increase rate-limiting threshold | | Ingestion is slow | Horizon server spec too low | Increase hardware spec | diff --git a/docs/run-api-server/prerequisites.mdx b/docs/run-api-server/prerequisites.mdx index 2e4316db3..38f7b45d4 100644 --- a/docs/run-api-server/prerequisites.mdx +++ b/docs/run-api-server/prerequisites.mdx @@ -31,14 +31,14 @@ Minimally, your disk storage type **must** be an SSD (e.g. NVMe, Direct Attached Note that each component can be scaled independently and for redundancy, in the manner of traditional _n_-tier systems which is covered later in [Scaling](./scaling.mdx). Ingestion can be sped up via configuring more Captive Core parallel workers (requiring more compute and RAM). -| Component | | Retention Period | -|:----------|:--|:-----------------| -| | **30 days** | **90 days** | **Full History** | +| Component | | Retention Period | +| :-- | :-- | :-- | --- | +| | **30 days** | **90 days** | **Full History** | | **Parallel worker count**
(est. ingestion time) | 6 workers (1 day) | 10 workers (1 day) | 20+ workers (2 days) | | **Horizon** | **CPU**: 10 cores (min: 6)
**RAM**: 64 GB (min: 32)
| **CPU**: 16 (min: 8)
**RAM**: 128 GB (64)
| **CPU**: 16 (10)
**RAM**: 512 GB (256) | | **Database** | **CPU**: 16 cores (min: 8)
**RAM**: 64 GB (min: 32GB)
**Storage**: 2 TB
**IOPS**: 20K (min: 15K) | **CPU**: 16 (12)
**RAM**: 128 GB (64)
**Storage**: 4 TB
**IOPS**: 20K (15K) | **CPU**: 64 (32)
**RAM**: 512 GB (256)
**Storage**: 10 TB
**IOPS**: 20k (15k) | -| **Storage**
(all same) | | **SSD** (NVMe, Direct Attached Storage preferred) | | -| **AWS**
(reference) | **Captive Core**: `m5.2xlarge`
**Database**: `r5.2xlarge` | **Captive Core**: `m5.4xlarge`
**DB**: `r5.4xlarge` | **Captive Core**: `c5.2xlarge` (x2)
**DB**: `r5.16xlarge` (ro)
`r5.8xlarge` (rw) | +| **Storage**
(all same) | | **SSD** (NVMe, Direct Attached Storage preferred) | | +| **AWS**
(reference) | **Captive Core**: `m5.2xlarge`
**Database**: `r5.2xlarge` | **Captive Core**: `m5.4xlarge`
**DB**: `r5.4xlarge` | **Captive Core**: `c5.2xlarge` (x2)
**DB**: `r5.16xlarge` (ro)
`r5.8xlarge` (rw) | ### Real-Time Ingestion @@ -51,8 +51,8 @@ There are two extremes to this spectrum: running a **single private instance** o The following table breaks down requirements along this spectrum; if you fall somewhere in between, interpolate the requirements accordingly. | Category | Private Instance | Enterprise Public Instance | -|:---------|:-----------------|:---------------------------| +| :-- | :-- | :-- | | **Compute** | Both **API Service** + **Captive Core**:
**CPU**: 4
**RAM**: 32 GB | **API Service**
**CPU**: 4
**RAM**: 8 GB
N instances, load balanced

**Captive Core**
**CPU**: 8
**RAM**: 256 GB
2 instances for redundancy | -| **Database** | **CPU**: 4
**RAM**: 32 GB
**IOPS**: 7k (min: 2.5k) | **CPU**: 32 - 64
**RAM**: 256 - 512 GB
**IOPS**: 20k (min: 15k)
2 HA instances: 1RO, 1RW | +| **Database** | **CPU**: 4
**RAM**: 32 GB
**IOPS**: 7k (min: 2.5k) | **CPU**: 32 - 64
**RAM**: 256 - 512 GB
**IOPS**: 20k (min: 15k)
2 HA instances: 1RO, 1RW | | **Storage** (SSD) | depends on retention period | 10 TB | | **AWS** (reference) | **API Service + Captive Core**
`m5.2xlarge`

**Database**
`r5.2xlarge` (ro)
`r5.xlarge` (rw) | **API Service**
`c5.xlarge` (_n_)

**Captive Core**
`c5.2xlarge` (x2)

**Database** `r5.16xlarge` (ro)
`r5.8xlarge` (rw) | diff --git a/docs/run-api-server/remote-core.mdx b/docs/run-api-server/remote-core.mdx index 201245ead..011799af8 100644 --- a/docs/run-api-server/remote-core.mdx +++ b/docs/run-api-server/remote-core.mdx @@ -39,7 +39,7 @@ _(You should refer to the list of [Horizon releases](https://github.com/stellar/ Running the API requires some familiar parameters: | flag | envvar | example | -| ---- | ------ | ------- | +| --- | --- | --- | | `--captive-core-config-append-path` | `CAPTIVE_CORE_CONFIG_PATH` | /etc/default/stellar-captive-core.toml | | `--history-archive-urls` | `HISTORY_ARCHIVE_URLS` | https://history.stellar.org/prd/core-testnet/core_testnet_001,https://history.stellar.org/prd/core-testnet/core_testnet_002 | | `--stellar-core-binary-path` | `STELLAR_CORE_BINARY_PATH` | /usr/bin/stellar-core | @@ -80,7 +80,7 @@ For using pubnet, refer to the earlier section on [Configuring Captive Core](./c With the Captive Core API server running, you can now point Horizon to this remote instance for ingestion. Rather than passing the configuration and binary paths described [earlier](./configuring.mdx#with-ingestion), you instead point Horizon to the remote instance: | flag | envvar | example | -| ---- | ------ | ------- | +| --- | --- | --- | | `--remote-captive-core-url` | `REMOTE_CAPTIVE_CORE_URL` | http://10.0.0.42:8000 | | `--stellar-core-url` | `STELLAR_CORE_URL` | http://127.0.0.1:11626 | diff --git a/docs/run-api-server/running.mdx b/docs/run-api-server/running.mdx index 378a0be2e..b05c6e969 100644 --- a/docs/run-api-server/running.mdx +++ b/docs/run-api-server/running.mdx @@ -32,7 +32,7 @@ Next, you can confirm that Horizon is responding correctly by loading the root r "href": "http://127.0.0.1:8000/accounts{?signer,sponsor,asset,cursor,limit,order}", "templated": true } - }, + } // etc. } ``` diff --git a/docs/start/stellar-stack.mdx b/docs/start/stellar-stack.mdx index 8b50260ed..c55039505 100644 --- a/docs/start/stellar-stack.mdx +++ b/docs/start/stellar-stack.mdx @@ -5,31 +5,31 @@ sidebar_position: 10 import { CodeExample } from "@site/src/components/CodeExample"; -Fundamentally, Stellar is a collection of Stellar Core nodes, which are computers that keep a common ledger of accounts and balances, listen for incoming transactions, and, using the Stellar Consensus Protocol, agree to apply a valid set of those transactions to update the ledger. Each transaction applied to the ledger incurs a small fee — which is necessary to prevent bad actors from spamming the network — and the ledger is generally updated every 3-5 seconds. +Fundamentally, Stellar is a collection of Stellar Core nodes, which are computers that keep a common ledger of accounts and balances, listen for incoming transactions, and, using the Stellar Consensus Protocol, agree to apply a valid set of those transactions to update the ledger. Each transaction applied to the ledger incurs a small fee — which is necessary to prevent bad actors from spamming the network — and the ledger is generally updated every 3-5 seconds. -However, most developers don't interact directly with a Stellar Core node. Rather, they program using a Software Development Kit written in their preferred language, and those SDKs in turn interact with Horizon, the Stellar-network API. This three-tiered stack divides responsibilities so each piece of software can focus on a specific purpose. Stellar Core concentrates on transaction submission and consensus; Horizon handles queries and converts network data into a friendly format; SDKs abstract away complexity and offer ergonomic access in a variety of languages. +However, most developers don't interact directly with a Stellar Core node. Rather, they program using a Software Development Kit written in their preferred language, and those SDKs in turn interact with Horizon, the Stellar-network API. This three-tiered stack divides responsibilities so each piece of software can focus on a specific purpose. Stellar Core concentrates on transaction submission and consensus; Horizon handles queries and converts network data into a friendly format; SDKs abstract away complexity and offer ergonomic access in a variety of languages. ## Stellar SDKs -SDKs make it easy to craft code and handle network queries and transaction submissions. They're linked to in the [SDK section of the docs](../software-and-sdks/index.mdx), and each is robust, and has its own documentation showing you how to request data and create and submit transactions. When you start developing on Stellar, the first step is usually to find the SDK in your language of choice and familiarize yourself with how it works. +SDKs make it easy to craft code and handle network queries and transaction submissions. They're linked to in the [SDK section of the docs](../software-and-sdks/index.mdx), and each is robust, and has its own documentation showing you how to request data and create and submit transactions. When you start developing on Stellar, the first step is usually to find the SDK in your language of choice and familiarize yourself with how it works. ## API: Horizon -[Horizon](../run-api-server/index.mdx) is a RESTful HTTP API server that provides a straightforward way to submit transactions, check accounts, and subscribe to events. Because it’s HTTP, you can communicate with Horizon using an SDK, but you can also use your web browser, or simple command line tools like cURL. Everything there is to know about Horizon is documented in the [API Reference](/api/introduction/) section of the docs. +[Horizon](../run-api-server/index.mdx) is a RESTful HTTP API server that provides a straightforward way to submit transactions, check accounts, and subscribe to events. Because it’s HTTP, you can communicate with Horizon using an SDK, but you can also use your web browser, or simple command line tools like cURL. Everything there is to know about Horizon is documented in the [API Reference](/api/introduction/) section of the docs. At the moment, Horizon requires access to Stellar Core's database to function properly — so every Horizon instance connects to a Stellar Core node — but we are increasing its independence from Stellar Core, and soon developers will be able deploy the API without having to run their own node. ## Network Backbone: Stellar Core -The Stellar Core software does the hard work of validating and agreeing with other instances of Core on the status of every transaction through the [Stellar Consensus Protocol](../glossary/scp.mdx) (SCP). The ledger, transactions, results, history, and even the messages passed between computers running Stellar Core are encoded using XDR, which is incredibly efficient, but not human readable. Stellar Core nodes make up the network — and running a node is crucial if you want to ensure constant access or contribute to the health and decentralization of the network — but most developers don't work directly with Stellar Core. For more on how to set up a node, consult the [Run a Core Node](../run-core-node/index.mdx) section. +The Stellar Core software does the hard work of validating and agreeing with other instances of Core on the status of every transaction through the [Stellar Consensus Protocol](../glossary/scp.mdx) (SCP). The ledger, transactions, results, history, and even the messages passed between computers running Stellar Core are encoded using XDR, which is incredibly efficient, but not human readable. Stellar Core nodes make up the network — and running a node is crucial if you want to ensure constant access or contribute to the health and decentralization of the network — but most developers don't work directly with Stellar Core. For more on how to set up a node, consult the [Run a Core Node](../run-core-node/index.mdx) section. ## The Public Network and the Test Network -There are two different versions of the Stellar network: one for testing and one for real-world deployments. The Stellar Development Foundation provides a free public Horizon instance for each, which you can use to submit transactions or query network data. +There are two different versions of the Stellar network: one for testing and one for real-world deployments. The Stellar Development Foundation provides a free public Horizon instance for each, which you can use to submit transactions or query network data. - https://horizon.stellar.org/ is for interacting with the public network - https://horizon-testnet.stellar.org/ is for interacting with the testnet -Assets on the testnet don't represent anything in the real world, and when you're developing on the testnet, you can get free test XLM from a tool called Friendbot. On the testnet, you're free to experiment, create, and troubleshoot without risking the loss of funds. It generally upgrades a month before the public network — so if you're using it, you need to keep an eye out for major protocol releases — and unlike the public network — where data persists forever — the testnet gets reset every quarter. Additionally, it has a lower ledger limit than the public network: currently, the testnet tops out at 100 operations/ledger; the public network at 1,000 operations/ledger. +Assets on the testnet don't represent anything in the real world, and when you're developing on the testnet, you can get free test XLM from a tool called Friendbot. On the testnet, you're free to experiment, create, and troubleshoot without risking the loss of funds. It generally upgrades a month before the public network — so if you're using it, you need to keep an eye out for major protocol releases — and unlike the public network — where data persists forever — the testnet gets reset every quarter. Additionally, it has a lower ledger limit than the public network: currently, the testnet tops out at 100 operations/ledger; the public network at 1,000 operations/ledger. -Other than that, the two networks are the same: they consist of Stellar Core nodes, support the Horizon API, and work with Stellar SDKs. Both support the same operations, process transactions in 3-5 seconds, and require the same fees and network minimum. In fact, if you build something on the testnet and decide you're ready to deploy it on the public network, all you need to do is change the [Network Passphrase](../glossary/network-passphrase.mdx). For more, check out our [guide to best practices for building on the testnet](../glossary/testnet.mdx). +Other than that, the two networks are the same: they consist of Stellar Core nodes, support the Horizon API, and work with Stellar SDKs. Both support the same operations, process transactions in 3-5 seconds, and require the same fees and network minimum. In fact, if you build something on the testnet and decide you're ready to deploy it on the public network, all you need to do is change the [Network Passphrase](../glossary/network-passphrase.mdx). For more, check out our [guide to best practices for building on the testnet](../glossary/testnet.mdx). diff --git a/docs/tutorials/follow-received-payments.mdx b/docs/tutorials/follow-received-payments.mdx index 64abdcfaf..ddd65c86c 100644 --- a/docs/tutorials/follow-received-payments.mdx +++ b/docs/tutorials/follow-received-payments.mdx @@ -232,9 +232,9 @@ var account = new StellarBase.Account(keypair.publicKey(), "713226564141056"); var amount = "100"; var transaction = new StellarSdk.TransactionBuilder(account, { - networkPassphrase: StellarBase.Networks.TESTNET, - fee: StellarSdk.BASE_FEE, - }) + networkPassphrase: StellarBase.Networks.TESTNET, + fee: StellarSdk.BASE_FEE, +}) .addOperation( StellarBase.Operation.createAccount({ destination: StellarBase.Keypair.random().publicKey(), diff --git a/docs/tutorials/handling-errors.mdx b/docs/tutorials/handling-errors.mdx index efcbdaeb4..f5bae5bef 100644 --- a/docs/tutorials/handling-errors.mdx +++ b/docs/tutorials/handling-errors.mdx @@ -93,7 +93,7 @@ function submitTransaction(tx, timeout) { if (Date.now() >= expiration) { return new Error("The transaction timed out."); } - + timeout = timeout || 1; // start the (linear) back-off process return sleep(timeout).then(function () { return submitTransaction(tx, timeout + 5); @@ -124,7 +124,7 @@ These errors typically occur when you have an outdated view of an account due to // suppose `account` is an outdated `AccountResponse` object let tx = sdk.TransactionBuilder(account, ...)/* etc */.build() server.submitTransaction(tx).catch(function (error)) { - if (error.response && error.status == 400 && error.extras && + if (error.response && error.status == 400 && error.extras && error.extras.result_codes.transaction == sdk.TX_BAD_SEQ) { return server.accounts() .accountId(account.accountId()) @@ -175,8 +175,8 @@ If you want to match a fee error **exactly**, you might write something like thi ```js function isFeeError(error) { - return - error.response !== undefined && + return; + error.response !== undefined && error.status == 400 && error.extras && error.extras.result_codes.transaction == sdk.TX_INSUFFICIENT_FEE; @@ -201,7 +201,7 @@ server.feeStats().then(function (response) { fee: (avgFee * 1.10).toFixed(0), // bump & convert to int networkPassphrase: // ... }); - // ...build the rest of the tx... + // ...build the rest of the tx... tx.sign(someAccount); return server.submitTransaction(tx); }); @@ -217,7 +217,7 @@ It's possible that even with a liberal fee-paying policy, your transaction fails ```js // Let `lastTx` be some transaction that fails submission due to high fees, and -// `lastFee` be the maximum fee (expressed as an int) willing to be paid by +// `lastFee` be the maximum fee (expressed as an int) willing to be paid by // `account` for `lastTx`. server.submitTransaction(lastTx).catch(function (error) { if (isFeeError(error)) { diff --git a/docs/tutorials/securing-projects.mdx b/docs/tutorials/securing-projects.mdx index 8f222aae7..939b70ac5 100644 --- a/docs/tutorials/securing-projects.mdx +++ b/docs/tutorials/securing-projects.mdx @@ -31,7 +31,7 @@ In an ideal world, you don’t have to store much sensitive data. If you must, t Consult a good cryptographer and read up on best practices. A good place to start is looking into the documentation of your favorite web framework. -Rolling your own crypto is a bad idea. Always use tried and tested libraries. A good example is [NaCl](https://en.wikipedia.org/wiki/NaCl_\(software\)). +Rolling your own crypto is a bad idea. Always use tried and tested libraries. A good example is [NaCl](). # Monitoring diff --git a/docs/tutorials/send-and-receive-payments.mdx b/docs/tutorials/send-and-receive-payments.mdx index 2b68fdef5..8fdf31dfa 100644 --- a/docs/tutorials/send-and-receive-payments.mdx +++ b/docs/tutorials/send-and-receive-payments.mdx @@ -580,10 +580,10 @@ paymentsRequest.stream(new EventListener() { System.out.println(output.toString()); } } - + @Override public void onFailure(Optional optional, Optional optional1) { - + } }); ``` From ad2095c4ffd730d38c0199c580fdcbd6646864b1 Mon Sep 17 00:00:00 2001 From: Tyler van der Hoeven Date: Wed, 10 Aug 2022 22:11:45 -0400 Subject: [PATCH 4/5] little lint fix --- src/components/CodeExample.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/CodeExample.js b/src/components/CodeExample.js index a02ebd3dc..71ef34e14 100644 --- a/src/components/CodeExample.js +++ b/src/components/CodeExample.js @@ -30,7 +30,7 @@ export const CodeExample = ({ children }) => ( return ( From 525f1b858b7ed08fc01366d5e86b41e4615cdceb Mon Sep 17 00:00:00 2001 From: Tyler van der Hoeven Date: Thu, 11 Aug 2022 13:37:19 -0400 Subject: [PATCH 5/5] noop