DIDs
Create and manage decentralized identities
Register a new DID
POST
https://api.borlaug.network/identity/dids
Registers a new DID for the caller. By creating a new DID the caller also becomes a controller of the newly created DID.
If catalogid
is provided, DID is registered and added to this catalog owned by the controller with the given short_name
.
If properties
array is provided, DID is registered with them.
Headers
Content-Type
string
application/json
Authorization
string
BWS authorization token
Request Body
catalogid
number
After DID is created, add to this catalog
short_name
string
A short name for this DID in this catalog
properties
array
Array of DID properties
DID property
A DID property is a JSON object composed of the following keys.
Name
Description
Required
name
Name of the property
Yes
private
If true, this property is not stored on chain
No
type
Value type of this property. Allowed values are Text, Bool, Integer, Date
Yes
value
Actual value to be stored
Yes
Retrieve a DID
GET
https://api.borlaug.network/identity/dids/:did
Retrieve a DID with all its information
Query Parameters
page
string
Zero based pagenation of properties
per_page
string
Items per page (properties)
properties
string
Comma separated property names to retrieve selected properties only
Headers
Authorization
string
BWS authorization token
Retrieve DIDs for a given public key
GET
https://api.borlaug.network/identity/dids?public_key=
Retrieves all DIDs for a subject identified by the public_key
Headers
Authorization
string
BWS authorization token
Modify a DID
PUT
https://api.borlaug.network/identity/dids/:did
Update a DID with given properties. This is an idempotent call. It replaces any properties associated with the DID with given array of properties.
Headers
Content-Type
string
application/json
Authentication
string
BWS authorization token
Request Body
properties
array
array of DID properties
Create a DID with some properties
Add or remove properties of a DID
PATCH
https://api.borlaug.network/identity/dids/:did
Headers
Content-Type
string
application/json
Authorization
string
BWS authorization token
Add or remove controllers
PATCH
https://api.borlaug.network/identity/dids/:did/controllers
Manage controllers for your DID NOTE: Subject can not remove itself from the controller list.
Headers
Content-Type
string
application/json
Authorization
string
BWS authorization token
Request Body
remove
array
Controller DIDs to remove
add
array
Controller DIDs to add
Last updated
Was this helpful?