fetchProtectedData
This method allows the user to retrieve all protected data for a given owner, data schema, or both. Only protected data objects the invoker has permissions to access are included in the result set. You must include at least one of the optional parameters when invoking this method.
A data schema is the metadata describing the contents of the protected data object. The schema is returned as part of the protectedData method invocation.
Usage
Return value example
The name
and address
fields in the result object(s) represent the name provided when creating the protected data and the eth address respectively. This method also returns the owner and associated data schema, regardless of which invocation method is used.
Parameters
owner (optional)
Provides a list of protected data objects owned by the user with this ETH address.
dataSchema (optional)
Provides a list of protected data objects matching this schema.
Result
This method returns an array of objects containing the protectedData information queried. Each object contains the following parameters:
name: Name specified when the protected data was created. This information is public and visible on-chain.
adress: Ethereum address of the protected data.
owner: Ethereum address of the protected data owner.
creationTimestamp: Timestamp specifying when the protected data was created, expressed in milliseconds since the epoch. This timestamp provides precise information about the moment of creation and can be used for chronological ordering or time-based operations.
schema: Data schema for the protected data as defined when the protected data was created (see protectedData).
schema
provides a structured representation of the protected data format and attributes. This field plays a crucial role in understanding and interpreting the underlying structure of the sensitive information.
Last updated