关于RPC请求文档的需求
【产品名称/功能模块】
关于RPC方面的问题
【问题描述】
- 1.文档中中关于这RPC方面描述的比较少,而且没有说明各个字段的说明,比如加密字段是如何加密的
- 2.我参考了GO-SDK中关于user_contract_claim_restful_api文件夹下的参数,然后通过php curl post 请求数据,接口返回没数据请求,附接口请求代码:
$url = "http://10.10.3.4:12301/v1/sendrequest";
$data = [];
$time = time();
$data['payload']['chain_id'] = 'chain1';
// $data['payload']['tx_id'] = 'chain1';
$data['payload']['timestamp'] = $time;
$data['payload']['contract_name'] = 'claim_restful_001';
$data['payload']['method'] = 'save';
$data['payload']['parameters']['time'] = $time;
$data['payload']['parameters']['file_hash'] = 'ad2a0b571fba45ccba5f6c3d8d2cff26';
$data['payload']['parameters']['file_name'] = 'file_'.$time;
$data['signer']['signer']['org_id'] = 'wx-org1.chainmaker.org';
$data['signer']['signer']['member_info'] = '-----BEGIN CERTIFICATE-----\nMIICeDCCAh6gAwIBAgIDB6YuMAoGCCqGSM49BAMCMIGKMQswCQYDVQQGEwJDTjEQ\nMA4GA1UECBMHQmVpamluZzEQMA4GA1UEBxMHQmVpamluZzEfMB0GA1UEChMWd3gt\nb3JnMS5jaGFpbm1ha2VyLm9yZzESMBAGA1UECxMJcm9vdC1jZXJ0MSIwIAYDVQQD\nExljYS53eC1vcmcxLmNoYWlubWFrZXIub3JnMB4XDTIyMTAxMzA1MjIwNFoXDTI3\nMTAxMjA1MjIwNFowgZExCzAJBgNVBAYTAkNOMRAwDgYDVQQIEwdCZWlqaW5nMRAw\nDgYDVQQHEwdCZWlqaW5nMR8wHQYDVQQKExZ3eC1vcmcxLmNoYWlubWFrZXIub3Jn\nMQ8wDQYDVQQLEwZjbGllbnQxLDAqBgNVBAMTI2NsaWVudDEuc2lnbi53eC1vcmcx\nLmNoYWlubWFrZXIub3JnMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEawSHkpHU\nJQrcoDOXb9EFcPxFlKeWdCychi0+E0ZNhnzuM576I0SVuGuI/Ok4KtzgyzEVm20v\nLIS+ZmEGaQP1PaNqMGgwDgYDVR0PAQH/BAQDAgbAMCkGA1UdDgQiBCD4J2R0fIzd\nDlY+ej8BTgspLGXW1NfQl6ymAMc6GACjJzArBgNVHSMEJDAigCDKVL5WjkndHQDV\nTN53nO13dZlkADu1b2T1Zwn1qkvsJjAKBggqhkjOPQQDAgNIADBFAiEAkcgMUXVb\nA6WaHHYpiggW11rlnOdOqu0u0arbGYf5PzECIBLU5JuRRYygdQIr7G4OhsOUGLYD\nCTMZccmKQlGpuytX\n-----END CERTIFICATE-----\n';
$data['signer']['signature'] = '0E\002 [8\022\315\r\236a\013\272\030\030\3207\310\020\245&\035^\252lw\016\214\320\'\020\205.@\230\204\002!\000\221e\270\243\355\334uN\270]O>\023\222\350\355\\$Z\3073\355T=\220\221\300\271\305\220a\274';
$ret1 = Http::post($url,json_encode($data));
3、上面的接口传参和RPC文档上描述的不一样。而且加密的signatrue是如何加密的
【期望内容/功能改进】
- 1.既然提供了可以通过HTTP方式直接请求数据,就提供详细点的接口文档吧。
- 2.给出这方面的请求实例DEMO
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information