chaincode_list_info – Get information about all installed and committed chaincodes on a Hyperledger Fabric channel
Synopsis
Get inofrmation on a chaincode definition on a Hyperledger Fabric channel
Parameters
- api_endpoint (required)
The URL for the IBM Blockchain Platform console.
Type: str- api_authtype (required)
ibmcloud
- Authenticate to the IBM Blockchain Platform console using IBM Cloud authentication. You must provide a valid API key using api_key.
basic
- Authenticate to the IBM Blockchain Platform console using basic authentication. You must provide both a valid API key using api_key and API secret using api_secret.Type: str- api_key (required)
The API key for the IBM Blockchain Platform console.
Type: str- api_secret
The API secret for the IBM Blockchain Platform console.
Only required when api_authtype is
basic
.Type: str- api_timeout
The timeout, in seconds, to use when interacting with the IBM Blockchain Platform console.
Type: intDefault value:60
- api_token_endpoint
The IBM Cloud IAM token endpoint to use when using IBM Cloud authentication.
Only required when api_authtype is
ibmcloud
, and you are using IBM internal staging servers for testing.Type: strDefault value:https://iam.cloud.ibm.com/identity/token
- peer (required)
The peer to use to manage the committed chaincode definition.
You can pass a string, which is the display name of a peer registered with the IBM Blockchain Platform console.
You can also pass a dict, which must match the result format of one of the ERROR while parsing: While parsing “M(peer_info)” at index 76: Module name “peer_info” is not a FQCN or ERROR while parsing: While parsing “M(peer)” at index 92: Module name “peer” is not a FQCN modules.
Type: raw- identity (required)
The identity to use when interacting with the peer.
You can pass a string, which is the path to the JSON file where the enrolled identity is stored.
You can also pass a dict, which must match the result format of one of the ERROR while parsing: While parsing “M(enrolled_identity_info)” at index 76: Module name “enrolled_identity_info” is not a FQCN or ERROR while parsing: While parsing “M(enrolled_identity)” at index 105: Module name “enrolled_identity” is not a FQCN modules.
Type: raw- msp_id (required)
The MSP ID to use for interacting with the peer.
Type: str- hsm
The PKCS #11 compliant HSM configuration to use for digital signatures.
Only required if the identity specified in identity was enrolled using an HSM.
Type: dict
- pkcs11library
The PKCS #11 library that should be used for digital signatures.
Type: str- label
The HSM label that should be used for digital signatures.
Type: str- pin
The HSM pin that should be used for digital signatures.
Type: str- channel (required)
The name of the channel.
Type: str
Examples
- name: Show information on 'Org1 Peer' chaincodes
ibm.blockchain_platform.committed_chaincode:
state: present
api_endpoint: https://ibp-console.example.org:32000
api_authtype: basic
api_key: xxxxxxxx
api_secret: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
peer: Org1 Peer
identity: Org1 Admin.json
msp_id: Org1MSP
channel: mychannel
Return Values
- committed_chaincode
The committed chaincode definition.
Returned: when state ispresent
Type: dict
- installed_chaincodes
list of installed chaincodes on the peer
Type: array- committed_chaincodes
List of committed chaincode definitions
Type: array