diff --git a/CHANGELOG.md b/CHANGELOG.md index 464ed5db63..a006cdf84b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,12 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +### [0.1.248](https://github.com/starknet-io/starknet-docs/compare/v0.1.247...v0.1.248) (2023-08-15) + +### [0.1.247](https://github.com/starknet-io/starknet-docs/compare/v0.1.246...v0.1.247) (2023-08-15) + +### [0.1.246](https://github.com/starknet-io/starknet-docs/compare/v0.1.245...v0.1.246) (2023-08-15) + ### [0.1.245](https://github.com/starknet-io/starknet-docs/compare/v0.1.244...v0.1.245) (2023-08-15) ### [0.1.244](https://github.com/starknet-io/starknet-docs/compare/v0.1.243...v0.1.244) (2023-08-09) diff --git a/components/Starknet/modules/api/nav.adoc b/components/Starknet/modules/api/nav.adoc deleted file mode 100644 index b1fa9094e9..0000000000 --- a/components/Starknet/modules/api/nav.adoc +++ /dev/null @@ -1,2 +0,0 @@ -* API reference -** xref:api-reference.adoc[Starknet API reference] \ No newline at end of file diff --git a/components/Starknet/modules/api/pages/api-reference.adoc b/components/Starknet/modules/api/pages/api-reference.adoc deleted file mode 100644 index c67cc01243..0000000000 --- a/components/Starknet/modules/api/pages/api-reference.adoc +++ /dev/null @@ -1,14 +0,0 @@ -= Starknet API reference - - -[subs="html"] ----- -
----- - - -// Todo: https://github.com/open-rpc/playground integrate the OpenRPC playground into the docs site - -// Source files -// https://github.com/starkware-libs/starknet-specs/blob/master/api/starknet_trace_api_openrpc.json -// https://github.com/starkware-libs/starknet-specs/blob/master/api/starknet_write_api.json \ No newline at end of file diff --git a/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/L1-L2_Communication/messaging-mechanism.adoc b/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/L1-L2_Communication/messaging-mechanism.adoc index 2f8721c3a8..25b192f9c3 100644 --- a/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/L1-L2_Communication/messaging-mechanism.adoc +++ b/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/L1-L2_Communication/messaging-mechanism.adoc @@ -117,7 +117,7 @@ To avoid having to interact with both L1 and L2 when sending a message, L1 → L The sequencer takes this fee in exchange for handling the message. The sequencer charges the fee in full upon updating the L1 state with the consumption of this message. The fee itself is calculated in the xref:../Network_Architecture/Fees/fee-mechanism.adoc#overall_fee[same manner] as -"regular" L2 transactions. You can use the xref:documentation:cli:commands.adoc#starknet-estimate_fee[CLI] to get an estimate of an L1 → L2 message fee. +"regular" L2 transactions. You can use the xref:documentation:cli:starkli.adoc#starknet-estimate_fee[CLI] to get an estimate of an L1 → L2 message fee. [id="structure_and_hashing_l1-l2"] === L1 → L2 structure and hashing diff --git a/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/oracles.adoc b/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/oracles.adoc deleted file mode 100644 index 51fdd497bd..0000000000 --- a/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/oracles.adoc +++ /dev/null @@ -1 +0,0 @@ -= Oracles \ No newline at end of file diff --git a/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/storage-proofs.adoc b/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/storage-proofs.adoc deleted file mode 100644 index 3acbcb0aa4..0000000000 --- a/components/Starknet/modules/architecture_and_concepts/pages/Network_Architecture/storage-proofs.adoc +++ /dev/null @@ -1 +0,0 @@ -= Storage proofs \ No newline at end of file diff --git a/components/Starknet/modules/cli/pages/commands.adoc b/components/Starknet/modules/cli/pages/commands.adoc deleted file mode 100644 index 015fe95bba..0000000000 --- a/components/Starknet/modules/cli/pages/commands.adoc +++ /dev/null @@ -1,391 +0,0 @@ -[id="commands"] -= Commands - -[WARNING] -==== -The Starknet CLI will be deprecated soon in favour of xref:starkli.adoc[Starkli CLI]. -==== - - -[id="basic_command_line_syntax"] -== Basic command line syntax - -To enter a starknet command, use the following syntax: - -[source,bash] ----- -$ starknet ----- - -Where: - -`` represents a single command that executes an operation on Starknet. - -`` represents zero or more command line options, each of which modifies the operation of the command. - -[id="setting_the_starknet_network_environment"] -== Setting the Starknet network environment - -You need to set your Starknet network environment to use either testnet or Mainnet. - -You can set the environment using either a command-line option or an environment variable. - -Possible values are: - -`alpha-goerli`:: Sets the Starknet network to testnet -`alpha-mainnet`:: Sets the Starknet network to Mainnet - -.Setting the network environment using a command-line option - -When you enter any command, include the `--network` option. For example to use Mainnet, enter a command as follows: - -[source,bash] ----- -$ starknet --network alpha-mainnet ----- - -[NOTE] -==== -You can place the `--network` option before or after any other option. -==== - -.Setting the network environment using an environment variable - -Set the `STARKNET_NETWORK` environment variable as follows: - -[source,bash] ----- -$ export STARKNET_NETWORK= ----- - -For example, to use testnet, enter the following command: - -[source,bash] ----- -$ export STARKNET_NETWORK=alpha-goerli ----- - -== Setting custom endpoints - -When working with the CLI, you can manually set the endpoints for the gateways that enable you to -interact with Starknet, by including the following options: - -`--feeder_gateway_url`:: Sets the custom endpoint for read commands. -`--gateway_url`:: Sets the custom endpoint for write commands. - -The following are the endpoints for Starknet testnet and Mainnet: - -* Testnet feeder gateway URL: https://alpha4.starknet.io/feeder_gateway/ -* Mainnet feeder gateway URL: https://alpha-mainnet.starknet.io/feeder_gateway/ -* Testnet gateway URL: https://alpha4.starknet.io/gateway/ -* Mainnet gateway URL: https://alpha-mainnet.starknet.io/gateway/ - -.Example: Setting a custom read endpoint - -The following command returns the ABI using the Mainnet feeder gateway. - -[source,bash] ----- -$ starknet get_code --feeder_gateway_url https://alpha-mainnet.starknet.io/feeder_gateway/ ----- - -.Example: Setting a custom write endpoint - -The following command sends a transaction to the Starknet sequencer - using the Mainnet gateway. - -[source,bash] ----- -$ starknet invoke --gateway_url https://alpha-mainnet.starknet.io/gateway/ ----- - - -[id="starknet_call"] -== `starknet call` - -[source,terminal] ----- -starknet call - --address - --abi - --function - --inputs - --block_hash - --block_number - --signature - --wallet - --nonce ----- - -Calls a Starknet contract without affecting the state, accepts the following arguments: - -- `contract_address`* - address of the contract being called -- `contract_abi`* - a path to a JSON file that contains the link:https://www.cairo-lang.org/docs/hello_starknet/intro.html#the-contract-s-abi[abi] of the contract being called -- `function_name`* - name of the function which is called -- `arguments`* - inputs to the function being called, represented by a list of space-delimited values -- `block_hash` - the hash of the block used as the context for the call operation. If this argument is omitted, the latest block is used -- `block_number` - same as block_hash, but specifies the context block by number or xref:block_tag[tag] -- `signature_information` - list of field elements as described xref:architecture_and_concepts:Network_Architecture/Blocks/transactions.adoc#signature[here] -- `wallet_name` - the name of the desired wallet, use xref:starknet_deploy_account[deploy_account] to set-up new accounts in the CLI -- `nonce` - account nonce, only relevant if the call is going through an account - - - -[id="block_tag"] - -[NOTE] -==== -*Block Tag* - -A block context can be specified via the `latest` or `pending` tags, where the former refers to the latest accepted on L2 block and the latter refers to the xref:architecture_and_concepts:Network_Architecture/Blocks/transaction-life-cycle.adoc#the-pending-block[pending block]. -==== - - -[id="starknet_declare"] -== `starknet declare` - -[source,terminal] ----- -starknet declare ---contract ----- - -Declares a new contract class on Starknet, accepts the following arguement: - - - `contract_class` - path to a JSON file containing the contract’s compiled code - - -[id="starknet_deploy"] -== `starknet deploy` - -[source,terminal] ----- -starknet deploy - --salt - --contract - --inputs - --token ----- - -Deploys a new contract, accepts the following arguments: - -- `salt` - a seed that is used in the computation of the contract’s address (if not specified, the sequencer will choose a random string) -- `contract_definition`* - path to a JSON file containing the contract’s bytecode and abi (can be obtained by executing link:https://www.cairo-lang.org/docs/hello_starknet/intro.html#compile-the-contract[starknet-compile]) -- `constructor_inputs`* - the arguments given to the contract’s constructor, represented by a list of space-delimited values -- `token` - a token allowing contract deployment (can be obtained by applying link:https://forms.reform.app/starkware/SN-Alpha-Contract-Deployment/l894lu[here]). Only used in the Alpha stages and will be deprecated in the future - -[NOTE] -==== -The deploy token is a temporary measure which will be deprecated when fees are incorporated in the system. Only relevant for Mainnet. -==== - - -[id="starknet_deploy_account"] -== `starknet deploy_account` - -[source,terminal] ----- -starknet deploy_account - --wallet - --account ----- - -Deploys an account contract, accepts the following arguments: - -- `account_name` - the name given to the account, used for managing multiple accounts from the CLI (if not specified, the name - `+__default__+` is used. -- `wallet_provider`* - the path to module which manages the account (responsible for key generation, signing, etc.) - -[NOTE] -==== - -Today, the Starknet CLI only works with the link:https://github.com/starkware-libs/cairo-lang/blob/master/src/starkware/starknet/third_party/open_zeppelin/Account.cairo[OpenZeppelin account contract]. -The CLI uses this specific link:https://github.com/starkware-libs/cairo-lang/blob/master/src/starkware/starknet/wallets/open_zeppelin.py[wallet provider]. -To use this provider, either set up the following environment variable or pass the same value directly to the `wallet_provider` parameter: - -[source,bash] ----- -$ export STARKNET_WALLET=starkware.starknet.wallets.open_zeppelin.OpenZeppelinAccount ----- -==== - -[CAUTION] -==== -Using the builtin wallet providers that are part of the cairo-lang package (starkware.starknet.wallets...) is _not secure_ (for example, the private key may be kept not encrypted and without backup in your home directory). You should only use them if you’re not overly concerned with losing access to your accounts (for example, for testing purposes). -==== - -[id="starknet-estimate_fee"] -== `starknet estimate_fee` - -[source,terminal] ----- -starknet estimate_fee - --address - --abi - --function - --inputs ----- - -Returns the fee estimation for a given contract call. Accepts the following arguments: - -- `address`* - the address of the contract being called -- `contract_abi`* - a path to a JSON file that contains the xref:architecture_and_concepts:Smart_Contracts/contract-abi.adoc[abi] of the contract being called -- `function_name`*- the name of the function being called -- `arguments`* - inputs to the function being called, represented by a list of space-delimited values` - - -== `starknet estimate_message_fee` - -[source,terminal] ----- -starknet estimate_message_fee - --from_address - --to_address - --function - --inputs ----- -Returns the fee estimation for a given xref:architecture_and_concepts:Network_Architecture/L1-L2_Communication/messaging-mechanism.adoc#l1-l2-message-fees[L1 handler] application. Accepts the following arguments: - - - -- `from_address`* - the L1 address of the sender -- `to_address`* - the L2 address of the recipient -- `contract_abi`* - a path to a JSON file containing the xref:architecture_and_concepts:Smart_Contracts/contract-abi.adoc[abi] of the receiving contract on L2 -- `function_name`*- the name of the desired L1 handler -- `arguments`* - inputs to the called handler, represented by a list of space-delimited values - -== `starknet get_block` - -[source,terminal] ----- -starknet get_block - --hash - --number ----- - -Returns the requested block, exactly one of the following arguments must be given: - -* `block_hash` - hash of the requested block -* `block_number` - number or <> of the requested block - -[id="starknet_get_code"] -== `starknet get_code` - -[source,terminal] ----- -starknet get_code - --contract_address - --block_hash - --block_number ----- - -Returns the ABI and the byte code of the requested contract, accepts the following arguments: - -- `contact_address`* - address of the requested contract -- `block_hash` - the hash of the block used as the context for the operation. If this argument is omitted, the latest block is used -- `block_number` - same as block_hash, but specifies the context block by number or xref:block_tag[tag] - - -== `starknet get_storage_at` - -[source,terminal] ----- -starknet get_storage_at - --contract_address - --key - --block_hash - --block_number ----- - -Queries a contract's storage at a specific key, accepts the following arguments: - -* `contract_address` *- address of the requested contract -* `key`* - the requested key from the given contract's storage -* `block_hash` - the hash of the block relative to which the storage will be provided. In case this argument is not given, the latest block is used -* `block_number` - same as block_hash, but specifies the context block by number or <> - - -[id="starknet_get_transaction"] -== `starknet get_transaction` - -[source,terminal] ----- -starknet get_transaction --hash ----- - -Returns the requested transaction, expects the following argument: - -- `transaction_hash`* - hash of the requested transaction - - -== `starknet get_transaction_receipt` - -[source,terminal] ----- -starknet get_transaction_receipt --hash ----- - -Returns the xref:architecture_and_concepts:Network_Architecture/Blocks/transaction-life-cycle.adoc#transaction-receipt[receipt] associated with the transaction, expects the following argument: - -* `transaction_hash`* - hash of the requested transaction -starknet invoke -starknet tx_status - - -== `starknet invoke` - -[source,terminal] ----- -starknet invoke - --address - --abi - --function - --inputs - --signature - --wallet - --nonce ----- - -Sends a transaction to the Starknet sequencer, accepts the following arguments: - -* `address`* - the address of the contract being called -* `contract_abi`* - a path to a JSON file that contains the https://www.cairo-lang.org/docs/hello_starknet/intro.html#the-contract-s-abi[abi] of the contract being called -* `function_name`*- the name of the function being called -* `arguments`* - inputs to the function being called, represented by a list of space-delimited values -* `signature_information` - list of field elements as described xref:architecture_and_concepts:Network_Architecture/Blocks/transactions.adoc#signature[here] -* `wallet_name` - the name of the desired wallet, use xref:starknet_deploy_account[deploy_account] to set-up new accounts in the CLI. -* `nonce` - account nonce, only relevant if the call is going through an account - -[TIP] -==== - -Today, interaction with Starknet may be done either via account or by a direct call. The `signature` argument can only be provided in the case of a direct call, since otherwise providing the signature is the responsibility of the account module. To use an account you must specify `wallet_name`, otherwise a direct call will be used (you may also explicitly perform a direct call by adding `--no_wallet` to the command). Note that in the future direct calls will be deprecated and the only way to interact with the system would be through accounts. -==== - - -== `starknet tx_status` - -[source,terminal] ----- -starknet tx_status - --hash - --contract - --error_message ----- - -Returns the transaction status, accepts the following arguments: - -* `transaction_hash`* - hash of the requested transaction -* `contract_definition` - path to a JSON file containing the compiled contract to which the transaction was addressed. If supplied, the debug information from the compiled contract will be used to add error locations. -* `error_message` - if specified, only the error message will be returned (or empty response in case the transaction was successful) - -The possible statuses of a transaction are: - -* `NOT_RECEIVED` -* `RECEIVED` -* `PENDING` -* `REJECTED` -* `ACCEPTED_ON_L2` -* `ACCEPTED_ON_L1` - -Refer to xref:architecture_and_concepts:Network_Architecture/Blocks/transaction-life-cycle.adoc[this] section for more information about the transaction lifecycle. \ No newline at end of file diff --git a/components/Starknet/modules/contribute/nav.adoc b/components/Starknet/modules/contribute/nav.adoc deleted file mode 100644 index 820c790409..0000000000 --- a/components/Starknet/modules/contribute/nav.adoc +++ /dev/null @@ -1,3 +0,0 @@ -* Contribute to Starknet -** xref: -** link:https://community.starknet.io/[Community forum] diff --git a/components/Starknet/modules/contribute/pages/bug-bounty.adoc b/components/Starknet/modules/contribute/pages/bug-bounty.adoc deleted file mode 100644 index f141d12ebf..0000000000 --- a/components/Starknet/modules/contribute/pages/bug-bounty.adoc +++ /dev/null @@ -1,9 +0,0 @@ -= Bug bounty - -A successful audit doesn't gurantee that the underlying code is free of bugs. For that purpose, we started a bug bounty program for StarkNet. - -Currently, the bounty program focuses on the StarkNet OS and related L1 contracts that define the protocol. - -In the future it may be extended to cover some of the mathematical foundations described above. -You're welcome to report issues in our link:https://starknet.io/discord[discord]. - diff --git a/components/Starknet/modules/contribute/pages/completed-audits.adoc b/components/Starknet/modules/contribute/pages/completed-audits.adoc deleted file mode 100644 index 5c5f2546d6..0000000000 --- a/components/Starknet/modules/contribute/pages/completed-audits.adoc +++ /dev/null @@ -1,24 +0,0 @@ -= Completed audits - -The following audits have been completed for the Starknet stack: - - - -* An audit for StarkWare's solidity STARK verifier -* An audit for StarkWare's solidity Cairo and the SHARP verifiers -* An audit for StarkWare's Cairo STARK/Cairo verifiers - - -[cols="1,1"] -|=== -|Audit focus|Link: - -|StarkWare's solidity STARK verifier -|https://github.com/starknet-io/starknet-stack-resources/blob/main/Audits/EVM_STARK_Verifier_v4.0_Audit_Report.pdf - -|StarkWare's solidity Cairo and the SHARP verifiers -|https://github.com/starknet-io/starknet-stack-resources/blob/main/Audits/Cairo%20&%20SHARP%20Verifiers.pdf - -|StarkWare's Cairo STARK/Cairo verifiers -|https://github.com/starknet-io/starknet-stack-resources/blob/main/Audits/STARK_Cairo%20Verifiers%20(in%20Cairo)%20Audit%20Report.pdf -|=== \ No newline at end of file diff --git a/components/Starknet/modules/contribute/pages/conduct.adoc b/components/Starknet/modules/contribute/pages/conduct.adoc deleted file mode 100644 index a0477100f2..0000000000 --- a/components/Starknet/modules/contribute/pages/conduct.adoc +++ /dev/null @@ -1 +0,0 @@ -= Starknet contribution: code of conduct \ No newline at end of file diff --git a/components/Starknet/modules/quick_start/pages/index.adoc b/components/Starknet/modules/quick_start/pages/index.adoc deleted file mode 100644 index 51c80d5cc2..0000000000 --- a/components/Starknet/modules/quick_start/pages/index.adoc +++ /dev/null @@ -1,10 +0,0 @@ -[id="getting_started"] -= Getting started - -Starknet is a permissionless decentralized ZK-Rollup operating as an L2 network over Ethereum, -where any dApp can achieve unlimited scale for its computation, without compromising Ethereum’s -composability and security. - -Currently, Starknet’s first step, Starknet Alpha, is deployed. This tutorial walks you through -writing and deploying a Starknet contract. - diff --git a/components/Starknet/modules/tools/pages/rpc.adoc b/components/Starknet/modules/tools/pages/rpc.adoc deleted file mode 100644 index ce053612ed..0000000000 --- a/components/Starknet/modules/tools/pages/rpc.adoc +++ /dev/null @@ -1,27 +0,0 @@ -= Full nodes and API services - -A list of recommended full nodes and API providers. - -.Node providers -[cols="1,2,1",stripes=even] -[%header,cols="2,2,1"] -[%autowidth.stretch] -|=== -| Provider name | Description | More information -|Juno|A Starknet full-node written in go-lang by Nethermind |link:https://github.com/NethermindEth/juno[github.com/NethermindEth/juno] -|Papyrus|A Starknet full-node written in Rust by StarkWare | link:https://github.com/starkware-libs/papyrus[github.com/starkware-libs/papyrus] -|Pathfinder|A Starknet full-node written in Rust by Equilibrium |link:https://github.com/eqlabs/pathfinder[github.com/eqlabs/pathfinder] -|=== - -.API providers -[cols="1,2,1",stripes=even] -[%header,cols="2,2,1"] -[%autowidth.stretch] -|=== -| Provider name | Description | More information -|Alchemy |An API service for Starknet | link:https://www.alchemy.com/starknet[www.alchemy.com/starknet] -|Bware labs | An API service for Starknet| link:https://blastapi.io/public-api/starknet[blastapi.io/public-api/starknet] -|Chainstack | An API service for Starknet| link:https://chainstack.com/build-better-with-starknet/[chainstack.com/build-better-with-starknet] -|Infura | An API service for Starknet|link:https://www.infura.io/networks/ethereum/starknet[www.infura.io/networks/ethereum/starknet] -|Lava Protocol|An open-source protocol for reliable access to RPC data | link:https://www.lavanet.xyz/[www.lavanet.xyz] -|=== diff --git a/package-lock.json b/package-lock.json index e6524db1fb..4368e37c76 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,11 +1,11 @@ { "name": "starknet-docs", - "version": "0.1.245", + "version": "0.1.248", "lockfileVersion": 2, "requires": true, "packages": { "": { - "version": "0.1.245", + "version": "0.1.248", "dependencies": { "@antora/lunr-extension": "^1.0.0-alpha.8", "@asciidoctor/tabs": "^1.0.0-beta.3", diff --git a/package.json b/package.json index c24a15eeed..8079daf5ed 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "starknet-docs", - "version": "0.1.245", + "version": "0.1.248", "private": true, "scripts": { "pre-release": "standard-version --prerelease --skip.changelog --releaseCommitMessageFormat 'chore(prerelease): {{currentTag}}'",