> For the complete documentation index, see [llms.txt](https://metaversenw.gitbook.io/metaversenetwork/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://metaversenw.gitbook.io/metaversenetwork/bit.country-metaverse-whitepaper/developers/wasm/set-up-ink-environment..md).

# Set up !ink environment.

Ink! is a Rust library developed by Parity, that explicitly targets smart contract development for Substrate’s `pallet-contracts`.&#x20;

There are multiple reasons Rust are the best programming language for smart contracts; that's why ink! chooses not to invent a new programming language, but rather adapt a subset of Rust.&#x20;

Complete detail of ink! is [here](https://use.ink/why-rust-for-smart-contracts)

### ink! CLI

The first tool we will be installing is [`cargo-contract`](https://github.com/paritytech/cargo-contract), a CLI tool for helping setting up and managing WebAssembly smart contracts written with ink!.

You can find source code [here on GitHub](https://github.com/paritytech/cargo-contract) and [here on crates.io](https://crates.io/crates/cargo-contract).

Step 1: `rustup component add rust-src`

Step 2: `cargo install cargo-contract --force --locked --version 3.0.1`

Please note, our pallet-contracts support version <= 3.0.1


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://metaversenw.gitbook.io/metaversenetwork/bit.country-metaverse-whitepaper/developers/wasm/set-up-ink-environment..md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
