Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
paulo-ocean committed Feb 28, 2025
1 parent 2c00003 commit 8444cf2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/classes/Aquarius.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ ___

### validate

**validate**(`ddo`, `signal?`): `Promise`<[`ValidateMetadata`](../interfaces/ValidateMetadata.md)\>
**validate**(`ddo`, `signal?`,`signer?`,`providerUrl?`): `Promise`<[`ValidateMetadata`](../interfaces/ValidateMetadata.md)\>

Validate DDO content

Expand All @@ -132,6 +132,8 @@ Validate DDO content
| Name | Type | Description |
| :------ | :------ | :------ |
| `ddo` | [`DDO`](../interfaces/DDO.md) | DID Descriptor Object content. |
| `signer?` | `Signer` | publisher account (for signature). |
| `providerUrl?` | `string` | Provider url (to get nonce) |
| `signal?` | `AbortSignal` | abort signal |

#### Returns
Expand Down
3 changes: 3 additions & 0 deletions src/services/Aquarius.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ export class Aquarius {
/**
* Validate DDO content
* @param {DDO} ddo DID Descriptor Object content.
* @param {signer} ddo publisher account.
* @param {providerUrl} provider url used to get the nonce.
* @param {AbortSignal} signal abort signal
* @return {Promise<ValidateMetadata>}.
*/
Expand All @@ -116,6 +118,7 @@ export class Aquarius {
const path = this.aquariusURL + '/api/aquarius/assets/ddo/validate'

// Old aquarius API and node API (before publisherAddress, nonce and signature verification)
// Older Providers (before updated Ocean Nodes)
const validateRequestLegacy = async function (): Promise<Response> {
try {
response = await fetch(path, {
Expand Down

0 comments on commit 8444cf2

Please sign in to comment.