Skip to main content

LinkedDomainService

@iota/identity-wasm API documentation


Class: LinkedDomainService

A service wrapper for a Linked Domain Service Endpoint.

Constructors​

new LinkedDomainService()​

new LinkedDomainService(options): LinkedDomainService

Constructs a new LinkedDomainService that wraps a spec compliant Linked Domain Service Endpoint.

Domain URLs must include the https scheme in order to pass the domain linkage validation.

Parameters​

options​

ILinkedDomainService

Returns​

LinkedDomainService

Methods​

toJSON()​

toJSON(): Object

  • Return copy of self without private attributes.

Returns​

Object


toString()​

toString(): string

Return stringified version of self.

Returns​

string


domains()​

domains(): string[]

Returns the domains contained in the Linked Domain Service.

Returns​

string[]


toService()​

toService(): Service

Returns the inner service which can be added to a DID Document.

Returns​

Service


fromService()​

static fromService(service): LinkedDomainService

Creates a new LinkedDomainService from a Service.

Error

Errors if service is not a valid Linked Domain Service.

Parameters​

service​

Service

Returns​

LinkedDomainService


isValid()​

static isValid(service): boolean

Returns true if a Service is a valid Linked Domain Service.

Parameters​

service​

Service

Returns​

boolean


clone()​

clone(): LinkedDomainService

Deep clones the object.

Returns​

LinkedDomainService