hyperledger-fabric - Hyperledger Composer 身份发布
问题描述
尝试发布新身份时遇到以下问题:
将未知的远程处理类型“issueidentityrequest”视为“任何”
身份已正确发布(当我检查composer-playground时),但代码以 ERROR 结尾,我无法下载卡。我的代码如下:
`const identity = {
"participant": 'org.acme.sample.Company#'+companyId,
"userID": companyId,
"options": {}
};`
`$.ajax({
url: "http://localhost:3000/api/system/identities/issue",
type: "POST",
dataType: 'blob',
data: identity,`
success: function (cardData) {
console.log('CARD-DATA', cardData);
},`
error: function (xhr, status) {
console.log("Sorry, there was a problem!");
},
complete: function (xhr, status) {
console.log("The request is complete!");
}
});`
请帮我 !
解决方案
最好看一个端到端的例子https://medium.com/@CazChurchUk/developing-multi-user-application-using-the-hyperledger-composer-rest-server-b3b88e857ccc确实端点返回了一个业务被导入的网卡。然后用于在磁盘上创建卡文件
例如
$.ajax({
url: "http://localhost:3000/api/system/issue",
type: "POST",
dataType: 'blob',
data: identity,
xhrFields: {
withCredentials: true
}
推荐阅读
- visual-studio - 无法从文件中读取文本
- networking - 无法使用 Ubuntu 20.04 连接到其他子网设备
- android - Nestedscrollview 嵌套 recyclerview 的问题
- bitbucket - Fortify 不存在 bitbucket repo 自动扫描
- javascript - 如何使用我的实体 php 控制器中的 js 树枝变量?
- github - Github:wiki 页面中没有可用的快捷方式?
- image - 如何在 MainActivity 中导入图像
- reactjs - 使用 react 和 chartjs-plugin-streaming 流式传输实时数据已暂停
- reactjs - 如何显示从 Strapi 的 WYSIWYG 到 NextJS 的 UI 的文本格式?
- python - 有点复杂的熊猫数据透视表