调用DescribeFabricOrganizationChaincodes获取组织的链码列表。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
请求参数
名称 |
类型 |
是否必选 |
示例值 |
描述 |
Action | String | 是 | DescribeFabricOrganizationChaincodes | 系统规定参数。取值:DescribeFabricOrganizationChaincodes。 |
OrganizationId | String | 是 | peers-aaaaaa2-1eqnj5o5w**** | 组织ID |
Location | String | 否 | cn-hangzhou | 位置信息 |
返回数据
名称 |
类型 |
示例值 |
描述 |
RequestId | String | 1890FA4F-067A-4CE9-AC9B-2BD2E58FB5D3 | 请求ID |
Success | Boolean | true | 是否成功 |
ErrorCode | Integer | 200 | 错误码 |
Result | Array of OrganizationChaincode | 组织的链码列表 |
|
EndorsePolicy | String | OR ('perf9141MSP.member') | 背书策略 |
State | String | RUNNING | 状态。取值:
|
CreateTime | String | 1533025590 | 创建时间 |
ChaincodeId | String | code-sacc-1pr09q7jmo0np | 链码ID |
Message | String | OK | 消息 |
ChaincodeName | String | mycc | 链码名 |
Installed | String | Installed | 是否安装 |
Creator | String | uid-23425 | 创建者 |
DeployTime | String | 1533025590 | 部署时间 |
ChaincodeVersion | String | 0.3 | 链码版本 |
ConsortiumId | String | consortium-lianmenyumingyi-hc5d1bwlulg7 | 联盟ID |
ChannelName | String | first-channel | 通道名 |
ChannelId | String | chan-first-channel-31hlgpen5k5lig | 通道ID |
示例
请求示例
http(s)://[Endpoint]/?Action=DescribeFabricOrganizationChaincodes
&OrganizationId=peers-aaaaaa2-1eqnj5o5w****
&Location=cn-hangzhou
&公共请求参数
正常返回示例
XML
格式
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeFabricOrganizationChaincodesResponse>
<RequestId>1890FA4F-067A-4CE9-AC9B-2BD2E58FB5D3</RequestId>
<Success>true</Success>
<ErrorCode>200</ErrorCode>
<Result>
<EndorsePolicy>OR (&#39;perf9141MSP.member&#39;)</EndorsePolicy>
<State>RUNNING</State>
<CreateTime>1533025590</CreateTime>
<ChaincodeId>code-sacc-1pr09q7jmo0np</ChaincodeId>
<Message>OK</Message>
<ChaincodeName>mycc</ChaincodeName>
<Installed>Installed</Installed>
<Creator>uid-23425</Creator>
<DeployTime>1533025590</DeployTime>
<ChaincodeVersion>0.3</ChaincodeVersion>
<ConsortiumId>consortium-lianmenyumingyi-hc5d1bwlulg7</ConsortiumId>
<ChannelName>first-channel</ChannelName>
<ChannelId>chan-first-channel-31hlgpen5k5lig</ChannelId>
</Result>
</DescribeFabricOrganizationChaincodesResponse>
JSON
格式
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "1890FA4F-067A-4CE9-AC9B-2BD2E58FB5D3",
"Success" : true,
"ErrorCode" : 200,
"Result" : [ {
"EndorsePolicy" : "OR ('perf9141MSP.member')",
"State" : "RUNNING",
"CreateTime" : "1533025590",
"ChaincodeId" : "code-sacc-1pr09q7jmo0np",
"Message" : "OK",
"ChaincodeName" : "mycc",
"Installed" : "Installed",
"Creator" : "uid-23425",
"DeployTime" : "1533025590",
"ChaincodeVersion" : "0.3",
"ConsortiumId" : "consortium-lianmenyumingyi-hc5d1bwlulg7",
"ChannelName" : "first-channel",
"ChannelId" : "chan-first-channel-31hlgpen5k5lig"
} ]
}
错误码
访问错误中心查看更多错误码。
文档内容是否对您有帮助?