> For the complete documentation index, see [llms.txt](https://docs.orbs.network/v2-contract-sdk/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.orbs.network/v2-contract-sdk/getting-started/downloading-the-contract-sdk.md).

# Downloading the Contract SDK

Every feature of the SDK is documented at the [Orbs Contract](/v2-contract-sdk/orbs-contracts/smart-contracts.md) chapter of the Contract SDK documentation. The Contract SDK is also published as a Go Module to ease usage when developing a contract. ([what are Go Modules](https://blog.golang.org/using-go-modules) - from the golang blog)

Having that said, the [examples in the Contract SDK](https://github.com/orbs-network/orbs-contract-sdk/tree/master/go/examples) project can be useful in order to assist with getting started on creating more complex contracts.

## Cloning the SDK

Download the SDK to your computer by running the following in a terminal

```
go get -u github.com/orbs-network/orbs-contract-sdk/...
```

It is recommended to avoid cloning the repo manually with git because the SDK has to be placed in the appropriate path within your Go workspace. The SDK also includes a few git submodules which may be a little tricky to clone recursively.

## Quick tour of the SDK contents

The SDK will download to your Go workspace, typically at

```
~/go/src/github.com/orbs-network/orbs-contract-sdk
```

The first place to explore in the SDK is the contract examples found at

```
~/go/src/github.com/orbs-network/orbs-contract-sdk/go/examples
```

Every example contains a README explaining the nature of the contract and how to test it. The automated tests include both a unit test and an end-to-end test running on Gamma server.

The API of the SDK is found at

```
~/go/src/github.com/orbs-network/orbs-contract-sdk/go/sdk/v1
```

## Updating the SDK

In order to update the SDK to the latest version, run the same command used to download it initially.

Notice that the SDK folder in your workspace is actually a git repo. You can also update the SDK by running git pull manually.


---

# 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, and the optional `goal` query parameter:

```
GET https://docs.orbs.network/v2-contract-sdk/getting-started/downloading-the-contract-sdk.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
