# Protocol Overview

Shprd protocol is designed to combine **security** with **decentralisation**.

For this purpose, a **role-based** access system has been set up to drastically reduce the risk of malicious actions. Besides, sensitive smart-contracts use proxies, which allow changes to be made in case of discovered vulnerabilities or the addition of new features.&#x20;

Learn more about Shprd's security measures on [Security](/understand-shprd/pause.md).

### DeFi protocols used by Shprd:

Vault smart contracts rely on two external actors, a **DEX Aggregator API** and **Chainlink price feeds**.&#x20;

1. **Chainlink Price Feeds**: In a vault, each asset is associated with a Chainlink price feed denominated in USD to exactly 8 decimal places. Chainlink price feeds are the fastest, most reliable and most secure way to obtain asset prices in a decentralised manner.
2. **DEX Aggregator and AMM**: The rebalance process is performed via Paraswap which is a swap optimizer like 1inch or 0x. The aim is to swap assets in a decentralised way and at the best prices.

### Factory

The *Factory* enables the creation of vaults and serves as a **registry**.

{% content-ref url="/pages/KP01txS9We0TXmupShSn" %}
[Factory](/technical-reference/core-contracts/factory.md)
{% endcontent-ref %}

### Vault

**Shprd** protocol is mainly represented by one contract, the vault. Vaults are smart contracts deployed by a **Factory** with a set of parameters defined at creation (assets, fees, security constraints). At creation, the vault creates an **ERC20** which will represent its **shares**.

A vault accepts deposits (e.g. in BUSD) and mints new ERC20 shares, in proportion to the deposit. It accepts withdrawals (in shares of the vault) and charges **fees** (management, performance and exit fees) according to the rates defined at creation.

To continuously value itself, it uses **Chainlink oracles** (e.g. USD-BTC, USD-ETH price feed) to determine the prices of volatile assets (e.g. BTC, ETH). Depending on the development of the volatile asset included in the vault, the **value** of the shares in the vault **increases**.

{% content-ref url="/pages/HxlsgisKuAG9RxIGju1p" %}
[Vault](/technical-reference/core-contracts/vault.md)
{% endcontent-ref %}

### FeesManager

The FeesManager contract manages **management** and **performance** fees **receivers**.

{% content-ref url="/pages/c3PkNnPP621B4rTOvQC4" %}
[FeesManager](/technical-reference/core-contracts/feesmanager.md)
{% endcontent-ref %}

### AccessManager

The AccessManager contract manages the **privileges** of protocol users. Indeed, vault creation by the Factory's 'createVault' method is only possible for addresses with the vault creator **role** granted by the AccessManager contract.

{% content-ref url="/pages/jqbcUCvrz4StYr4iWhfy" %}
[AccessManager](/technical-reference/core-contracts/accessmanager.md)
{% endcontent-ref %}

### KYCToken

The KYCToken contract manages the **KYC** of the protocol users. It may be necessary to be KYC to invest in a vault depending on the configuration chosen by the **trader**.

{% content-ref url="/pages/yFVRzPf33yrMiL5pyzZk" %}
[KYCToken](/technical-reference/core-contracts/kyctoken.md)
{% endcontent-ref %}


---

# Agent Instructions: 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://docs.shprd.finance/understand-shprd/protocol-overview.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.
