mirror of
https://github.com/oceanprotocol/ocean.js.git
synced 2024-11-26 20:39:05 +01:00
3.5 KiB
3.5 KiB
@oceanprotocol/lib / Exports / Aquarius
Class: Aquarius
Table of contents
Constructors
Properties
Methods
Constructors
constructor
• new Aquarius(aquariusURL
)
Instantiate Aquarius
Parameters
Name | Type |
---|---|
aquariusURL |
string |
Defined in
Properties
aquariusURL
• aquariusURL: string
Defined in
Methods
getAssetMetadata
▸ getAssetMetadata(did
, signal?
): Promise
<any
>
Search over the DDOs using a query.
Parameters
Name | Type | Description |
---|---|---|
did |
string |
DID of the asset |
signal? |
AbortSignal |
abort signal |
Returns
Promise
<any
>
Defined in
querySearch
▸ querySearch(query
, signal?
): Promise
<any
>
Search over the DDOs using a query.
Parameters
Name | Type | Description |
---|---|---|
query |
SearchQuery |
Query to filter the DDOs. |
signal? |
AbortSignal |
abort signal |
Returns
Promise
<any
>
Defined in
resolve
▸ resolve(did
, signal?
): Promise
<Asset
>
Resolves a DID
Parameters
Name | Type | Description |
---|---|---|
did |
string |
DID of the asset. |
signal? |
AbortSignal |
abort signal |
Returns
Promise
<Asset
>
Asset
Defined in
validate
▸ validate(ddo
, signal?
): Promise
<ValidateMetadata
>
Validate DDO content
Parameters
Name | Type | Description |
---|---|---|
ddo |
DDO |
DID Descriptor Object content. |
signal? |
AbortSignal |
abort signal |
Returns
Promise
<ValidateMetadata
>
.
Defined in
waitForAqua
▸ waitForAqua(did
, txid?
, signal?
): Promise
<Asset
>
Blocks until Aqua will cache the did (or the update for that did) or timeouts
Parameters
Name | Type | Description |
---|---|---|
did |
string |
DID of the asset. |
txid? |
string |
used when the did exists and we expect an update with that txid. |
signal? |
AbortSignal |
abort signal |
Returns
Promise
<Asset
>
DDO of the asset.