Skip to content

Commit

Permalink
update service endpoint section
Browse files Browse the repository at this point in the history
  • Loading branch information
LiranCohen committed Apr 3, 2024
1 parent e6297d7 commit d2b9f4b
Showing 1 changed file with 30 additions and 3 deletions.
33 changes: 30 additions & 3 deletions spec/spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,36 @@ Object Signing / Encryption |

## Service Endpoints

::: warning
This will be updated
:::
The following DID Document Service Endpoint entries ****MUST**** be present in the DID Document of a target DID for resolution to properly locate the URI for addressing a DID owner's Decentralized Web Nodes:

```json
{
"id": "did:example:alice",
"service": [{
"id": "#dwn",
"type": "DecentralizedWebNode",
"enc": [
"#dwn-enc"
],
"sig": [
"#dwn-sig"
],
"serviceEndpoint": [
"did:example:host",
"https://dwn.example.com"
]
}]
}
```

- Service Endpoints ****MUST**** contain an `id` property and it ****MUST**** be set to `#dwn`.
- Service Endpoints ****MUST**** contain a `type` property and it ****MUST**** be set to `DecentralizedWebNode`.
- Service Endpoints ****MUST**** contain a `serviceEndpoint` property and it ****MAY**** be set to:
- either a `string` value which represents the `URL` associated with the `DWN`
- an array of `string` values which each value represents a `URL` associated with a `DWN`
- Service Endpoints ****MUST**** contain an `enc` property and it ****MUST**** be a `string` value or an array of `string` values which represent the `keyId` associated with `encrypting` data.
- Service Endpoints ****MUST**** contain a `sig`property and it ****MUST**** be a `string` value or an array of `string` values which represent the `keyId` associated with `signing` data.


## Messages

Expand Down

0 comments on commit d2b9f4b

Please sign in to comment.