Profiles

Organization Profiles are used to provide more context for an Issuer DID. Details about the issuer such as name and logo can be added using a Organization Profile. These details will be included in credentials that are issued by the DID.

Endpoints

POST /profiles GET /profiles/{did} GET /profiles PATCH /profiles/{did} DELETE /profiles/{did}

Create Profile

The did and name fields are required to create a new Profile.

Parameters

NameInTypeRequiredDescription

did

body

true

DID as fully qualified, e.g., did:dock:.

name

body

string

true

The name to use for this issuer (e.g. a school name).

description

body

string

false

A description of the issuer.

logo

body

string

false

A Base64 encoded image to use as the logo for the issuer.

Responses

StatusMeaningDescriptionSchema

200

The request was successful and the Profile was created.

400

The request was unsuccessful, because of invalid params.

POST /profiles REQUEST PAYLOAD
{
  "did": "did:dock:xyz",
  "name": "My Test Profile",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}
POST /profiles REQUEST CURL
curl --location --request POST 'https://api.dock.io/profiles' \
--header 'DOCK-API-TOKEN: API_KEY' \
--data-raw '{
  "name": "My Test Profile",
  "did": "did:dock:xyz",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}'
200 Response
{
  "did": "did:dock:xyz",
  "name": "My Test Profile",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}

Get Profile

When a DID is provided in the path, the API will retrieve the Profile associated with that DID.

Parameters

NameInTypeRequiredDescription

did

path

true

Represents a specific DID that uniquely identifies the profile.

Responses

StatusMeaningDescriptionSchema

200

The request was successful and will return the profile.

404

The requested profile was not found.

GET /profiles/{did} REQUEST CURL
curl --location --request GET 'https://api.dock.io/profiles/did:dock:xyz' \
  --header 'DOCK-API-TOKEN: API_KEY' \
  --data-raw ''
200 Response
{
  "did": "did:dock:xyz",
  "name": "My Test Profile",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}

List Profiles

Return a list of all Profiles that your user account controls.

Parameters

NameInTypeRequiredDescription

offset

query

integer

false

How many items to offset by for pagination

limit

query

integer

false

How many items to return at one time (max 64)

Responses

StatusMeaningDescriptionSchema

200

All of a user's profiles.

GET /profiles REQUEST CURL
curl --location --request GET 'https://api.dock.io/profiles' \
  --header 'DOCK-API-TOKEN: API_KEY' \
  --data-raw ''
200 Response
[
  {
    "did": "did:dock:xyz",
    "name": "My Test Profile",
    "description": "Testing out the Organization Profiles API",
    "logo":"data:image/png;base64,SomeBase64EncodedImage=="
  }
]

Update Profile

The update profile operation means that you can update the details of the profile. To do so, you need to provide a different value for at least one of name, description or logo.

Parameters

NameInTypeRequiredDescription

did

body

true

DID as fully qualified, e.g., did:dock:.

name

body

string

true

The name to use for this issuer (e.g. a school name).

description

body

string

false

A description of the issuer.

logo

body

string

false

A Base64 encoded image to use as the logo for the issuer.

Responses

StatusMeaningDescriptionSchema

200

The request was successful and will update the profile.

400

The controller value is incorrect.

401

The request was unsuccessful, because you don't own the profile.

404

The profile does not exist.

PATCH /profiles/{did} REQUEST PAYLOAD
{
  "did": "did:dock:xyz",
  "name": "My Test Profile",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}
PATCH /profiles/{did} REQUEST CURL
curl --location --request PATCH 'https://api.dock.io/profiles/did:dock:xyz' \
  --header 'DOCK-API-TOKEN: API_KEY' \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "did": "did:dock:xyz",
  "name": "My Test Profile",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}'
200 Response
{
  "did": "did:dock:xyz",
  "name": "My Test Profile",
  "description": "Testing out the Organization Profiles API",
  "logo":"data:image/png;base64,SomeBase64EncodedImage=="
}

Delete Profile

Deletes a profile from our platform. It does NOT delete the associated DID, nor revoke the credentials issued for the profile.

Parameters

NameInTypeRequiredDescription

did

path

true

Represents a specific DID that uniquely identifies the profile to delete.

Responses

StatusMeaningDescriptionSchema

200

The request was successful and will remove the profile.

401

The request was unsuccessful because you don't own the profile.

404

The profile does not exist.

405

The {did} value is blank/empty. Please ensure that the {did} value does exist.

DELETE /profiles/{did} REQUEST CURL
curl --location --request DELETE https://api.dock.io/profiles/{did} \
  --header 'DOCK-API-TOKEN: API_KEY' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    }'
200 Response
{
}

Last updated