> For the complete documentation index, see [llms.txt](https://docs.catalyx.solutions/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.catalyx.solutions/catalyx-blockchain-manager/hyperledger-fabric/version-2.4/getting-started/commit-a-chaincode-to-the-channel.md).

# Commit a Chaincode to the Channel

Chaincode is the smart contract of Hyperledger Fabric that handles the business logic of a particular application. A smart contract programmatically accesses two distinct pieces of the ledger — a blockchain that immutably records the history of all transactions, and a world state that holds a cache of the current value of these states.

The Catalyst Blockchain Manager Hyperledger Fabric service supports Hyperledger Fabric v2.0 capabilities with the following [chaincode lifecycle](https://hyperledger-fabric.readthedocs.io/en/release-2.2/chaincode_lifecycle.html#fabric-chaincode-lifecycle):

<figure><img src="/files/1ZHTQiix552IFgEZuQvj" alt=""><figcaption></figcaption></figure>

{% stepper %}
{% step %}

#### Add a Chaincode

The current version of Catalyst Blockchain Manager supports external chaincodes. Organizations do not need to package the chaincode — they just need to create a Docker image and provide a link to the Docker repository.

See [Add a Chaincode](file:///7571772/chaincode-management/chaincode.md#add-chaincode).
{% endstep %}

{% step %}

#### Install the Chaincode on Your Peers

Every organization that will use the chaincode to endorse a transaction or query the ledger needs to complete this step.

See [Install the Chaincode](file:///7571772/chaincode-management/chaincode.md#install-the-chaincode).
{% endstep %}

{% step %}

#### Approve a Chaincode Definition for Your Organization

Every organization that will use the chaincode needs to complete this step. The chaincode definition needs to be approved by a sufficient number of organizations with endorser rights to satisfy the channel's policy before the chaincode can be started on the channel.

See [Approve a Chaincode](file:///7571772/chaincode-management/chaincode.md#approve-a-chaincode).
{% endstep %}

{% step %}

#### Commit the Chaincode Definition

Any organization can commit a chaincode if all necessary approvals were done.

See [Commit a Chaincode](file:///7571772/chaincode-management/chaincode.md#commit-a-chaincode) and [Chaincode Lifecycle](file:///7571772/chaincode-management/chaincode.md#chaincodes-lifecycle) for full details.
{% endstep %}
{% endstepper %}


---

# 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://docs.catalyx.solutions/catalyx-blockchain-manager/hyperledger-fabric/version-2.4/getting-started/commit-a-chaincode-to-the-channel.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.
