Check Commit Readiness
post
/console/admin/api/v2/channels/{channelName}/chaincodeDefinitions/checkCommitReadiness
Checks the commit readiness of a given chaincode definition in a channel.
Request
Supported Media Types
- application/json
Path Parameters
-
channelName: string
ID of the channel
Details about the chaincode definition to check commit readiness
Root Schema : CheckCommitReadinessCCReq
Type:
Show Source
object
-
chaincodeInitRequired:
boolean
-
chaincodeName:
string
-
chaincodeSequence(optional):
string
-
chaincodeVersion:
string
-
dataCollectionConfig(optional):
array dataCollectionConfig
-
endorsementPolicy(optional):
object endorsementPolicy
Example:
{
"chaincodeName":"myCC1",
"chaincodeVersion":"v1",
"chaincodeInitRequired":false,
"endorsementPolicy":{
"type":"signature-policy",
"policy":"OR('org1.member')"
},
"dataCollectionConfig":[
{
"name":"test",
"policy":"OR('org1.member')",
"requiredPeerCount":1,
"maxPeerCount":2,
"blockToLive":10,
"memberOnlyRead":true,
"memberOnlyWrite":true,
"endorsementPolicy":{
"signaturePolicy":"OutOf(1,'org1.member')"
}
}
]
}
Nested Schema : endorsementPolicy
Type:
Show Source
object
-
policy:
string
-
type:
string
Allowed Values:
[ "signature-policy", "channel-config-policy" ]
Response
Supported Media Types
- application/json
200 Response
Success
Nested Schema : approvals
Type:
object
400 Response
Invalid Arguments
401 Response
Unauthorized
403 Response
Forbidden
500 Response
Internal Server Error
Default Response
Unexpected error