Skip to content

Commit

Permalink
Add WotThing and WotDirectory service types.
Browse files Browse the repository at this point in the history
Co-authored-by: Ted Thibodeau Jr <[email protected]>
Co-authored-by: Manu Sporny <[email protected]>
  • Loading branch information
3 people authored Jul 20, 2024
1 parent c7b2b71 commit 4efd964
Showing 1 changed file with 76 additions and 1 deletion.
77 changes: 76 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1708,6 +1708,82 @@ <h4>DIDCommMessaging</h4>

</section>

<section id="wot-discovery-service-type">
<h4>Web of Things (WoT) Discovery</h4>
<p>The <code>WotThing</code> and <code>WotDirectory</code> endpoints allow publication of service endpoints in a DID document
that can be used to fetch Web of Things (WoT) Thing Descriptions (TDs).
The <code>WotThing</code> endpoint is a REST service that returns a TD
when the <code>GET</code> method is used.
This can be used for self-describing devices or services, or be a service
separate from the actual device or service described by the TD.
The <code>WotDirectory</code> is also a REST service that returns a TD, but this service is always
a Web of Things (WoT) Thing Description Directory (TDD),
and the TD returned by a <code>GET</code> always describes the TDD's interface.
Details (including normative statements covering the above) are in the
<a href="https://www.w3.org/TR/wot-discovery/">WoT Discovery</a> specification.
</p>

<table class="simple" style="width: 100%;">
<thead>
<tr>
<th>Normative Definition</th>
<th>JSON-LD</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<a href="https://www.w3.org/TR/wot-discovery/">WoT Discovery</a>
</td>
<td>
<a href="https://www.w3.org/2022/wot/discovery-did#WotThing">WotThing</a>
</td>
</tr><tr>
<td>
<a href="https://www.w3.org/TR/wot-discovery/">WoT Discovery</a>
</td>
<td>
<a href="https://www.w3.org/2022/wot/discovery-did#WotDirectory">WotDirectory</a>
</td>
</tr>
</tbody>
</table>
<pre class="example" title="Example of WotThing serviceEndpoint properties">
{
"@context":[
"https://www.w3.org/ns/did/v1",
"https://www.w3.org/2022/wot/discovery-did"
],
...
"service": [{
"id": "did:example:wotdiscoveryexample#td",
"type": "WotThing",
"serviceEndpoint":
"https://wot.example.com/.well-known/wot"
}]
...
}
</pre>

<pre class="example" title="Example of WotDirectory serviceEndpoint properties">
{
"@context":[
"https://www.w3.org/ns/did/v1",
"https://www.w3.org/2022/wot/discovery-did"
],
...
"service": [{
"id": "did:example:wotdiscoveryexample#tdd",
"type": "WotDirectory",
"serviceEndpoint":
"https://wot.example.com/tdd"
}]
...
}
</pre>

</section>

<section>
<h4>CredentialRegistry</h4>
<p>The <code>CredentialRegistry</code> endpoint allows publication of a dedicated service endpoint in a DID document, through which verifiable credentials can be queried. Each registry endpoint is a REST endpoint. When a `GET` request is sent to the URI formed by appending the <code>credentialSubject.id</code> as a URL-encoded string to the given endpoint URI, the registry MUST return an array of verifiable credentials associated with the subject ID. A sample registry endpoint can be found <a href="https://ssi.eecc.de/api/registry/swagger/#/Credentials/get_api_registry_vcs__id_">here</a>.</p>
Expand Down Expand Up @@ -1790,7 +1866,6 @@ <h4>OpenID4 Verifiable Credential Issuance</h4>
</tr>
</tbody>
</table>

<pre class="example" title="Example of service and serviceEndpoint properties">
{
...
Expand Down

0 comments on commit 4efd964

Please sign in to comment.