11.2.4.3 Save Resource


Interface Address /hub/saveResource
Description Store the resource to the Hub. If the user stores it himself, the uid and the ownerUid should be the same. At this time, there is no need to create permissions to call directly; if the issuer stores it for the user after issuing the credentials, the uid should be the issuer, and the ownerUid should be the user. At this time, the user must have created “WRITE” permissions for it, otherwise the storage will fail.
Interface request parameter
No. Parameter Type Required Description
1 SaveResourceReq Y Wrapper class
SaveResourceReq
1 uid String Y ID in the Hub
2 content String Y Resource information
3 url String N The path of the resource storage. Null when it is user self-storage; required when the issuer stores it for the user
4 ownerUid String Y Resource owner
5 grant String Y WRITE means add;UPDATE means update
6 key String Y Key
7 sign String Y Signature
Interface response parameter
No. Parameter Type Description
1 SaveResourceResp Wrapper class
SaveResourceResp
1 url String The path of the stored resource
2 encryptKey String Null when the issuer stores it for users; if it is the user self-storage, returns the KeyA encrypted by the user's Public key, and the user's private key decrypts KeyA to derive the plaintext Key. The resource stored in the Hub is encrypted by Key with AES-ECB algorithm.
© 2019-2021 Red Date (Hong Kong) Technology Limited. all right reserved,powered by GitbookFile Modify: 2022-05-05 16:00:00

results matching ""

    No results matching ""

    results matching ""

      No results matching ""