Skip to main content

HealthCheck

Health Check

Health is a simple handler that always responds with a 200 OK

Responses

Response samples

Content type
application/json
{
  • "status": "string"
}

Readiness

Readiness

Readiness runs a number of application specific checks to see if all the relied upon services are healthy.

Responses

Response samples

Content type
application/json
{
  • "serviceStatuses": {
    },
  • "status": {
    }
}

CredentialAPI

Get Credentials

Checks for the presence of a query parameter and calls the associated filtered get method. Only one parameter is allowed to be specified.

query Parameters
issuer
string
Example: issuer=did:key:z6MkiTBz1ymuepAQ4HEHYSF1H8quG5GLVVQR3djdX3mDooWp

The issuer id

schema
string

The credentialSchema.id value to filter by

subject
string

The credentialSubject.id value to filter by

Responses

Response samples

Content type
application/json
{
  • "credentials": [
    ]
}

Create Credential

Create a verifiable credential

Request Body schema: application/json

request body

@context
string

A context is optional. If not present, we'll apply default, required context values.

required
object

Claims about the subject. The keys should be predicates (e.g. "alumniOf"), and the values can be any object.

expiry
string

Optional. Corresponds to expirationDate in https://www.w3.org/TR/vc-data-model/#expiration.

issuer
required
string

The issuer id.

issuerKid
required
string

The KID used to sign the credential

revocable
boolean

Whether this credential can be revoked. When true, the created VC will have the "credentialStatus" property set.

schemaId
string

A schema ID is optional. If present, we'll attempt to look it up and validate the data against it.

subject
required
string

The subject id.

suspendable
boolean

Whether this credential can be suspended. When true, the created VC will have the "credentialStatus" property set.

Responses

Request samples

Content type
application/json
{
  • "@context": "string",
  • "data": {
    },
  • "expiry": "2020-01-01T19:23:24Z",
  • "issuer": "did:key:z6MkiTBz1ymuepAQ4HEHYSF1H8quG5GLVVQR3djdX3mDooWp",
  • "issuerKid": "#z6MkiTBz1ymuepAQ4HEHYSF1H8quG5GLVVQR3djdX3mDooWp",
  • "revocable": true,
  • "schemaId": "string",
  • "subject": "did:key:z6MkiTBz1ymuepAQ4HEHYSF1H8quG5GLVVQR3djdX3mDooWp",
  • "suspendable": true
}

Response samples

Content type
application/json
{
  • "credential": {
    },
  • "credentialJwt": "string"
}

Delete Credentials

Delete credential by ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get Credential

Get credential by id

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "credential": {
    },
  • "credentialJwt": "string",
  • "id": "string"
}

Get Credential Status

Get credential status by id

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "revoked": true,
  • "suspended": true
}

Update Credential Status

Update a credential's status

Request Body schema: application/json

request body

revoked
boolean

The new revoked status of this credential. The status will be saved in the encodedList of the StatusList2021 credential associated with this VC.

suspended
boolean

Responses

Request samples

Content type
application/json
{
  • "revoked": true,
  • "suspended": true
}

Response samples

Content type
application/json
{
  • "revoked": true,
  • "suspended": true
}

Get Credential Status List

Get credential status list by id.

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "credential": {
    },
  • "credentialJwt": "string",
  • "id": "string"
}

Verify Credential

Verify a given credential by its id. The system does the following levels of verification:

  1. Makes sure the credential has a valid signature
  2. Makes sure the credential has is not expired
  3. Makes sure the credential complies with the VC Data Model
  4. If the credential has a schema, makes sure its data complies with the schema
Request Body schema: application/json

request body

object (credential.VerifiableCredential)
credentialJwt
string

A JWT that encodes a credential.

Responses

Request samples

Content type
application/json
{
  • "credential": {
    },
  • "credentialJwt": "string"
}

Response samples

Content type
application/json
{
  • "reason": "string",
  • "verified": true
}

DecentralizedIdentityAPI

Get DID Methods

Get supported DID method

Responses

Response samples

Content type
application/json
{
  • "method": [
    ]
}

Get DIDs

Get DIDs by method. Checks for an optional "deleted=true" query parameter, which exclusively returns DIDs that have been "Soft Deleted".

query Parameters
deleted
boolean

When true, returns soft-deleted DIDs. Otherwise, returns DIDs that have not been soft-deleted. Default is false.

Request Body schema: application/json

request body

filter
string

A standard filter expression conforming to https://google.aip.dev/160. Not implemented yet.

Responses

Request samples

Content type
application/json
{
  • "filter": "string"
}

Response samples

Content type
application/json
{
  • "dids": [
    ]
}

Create DID Document

Creates a fully custodial DID document with the given method. The document created is stored internally and can be retrieved using the GetOperation. Method dependent registration (for example, DID web registration) is left up to the clients of this API. The private key(s) created by the method are stored internally never leave the service boundary.

path Parameters
method
required
string

Method

Request Body schema: application/json

request body

keyType
required
string

Identifies the cryptographic algorithm family to use when generating this key. One of the following: "Ed25519", "X25519", "secp256k1", "P-224","P-256","P-384", "P-521", "RSA"

options
any

Options for creating the DID. Implementation dependent on the method.

Responses

Request samples

Content type
application/json
{
  • "keyType": "string",
  • "options": null
}

Response samples

Content type
application/json
{
  • "did": {
    }
}

Soft Delete DID

When this is called with the correct did method and id it will flip the softDelete flag to true for the db entry. A user can still get the did if they know the DID ID, and the did keys will still exist, but this did will not show up in the GetDIDsByMethod call This facilitates a clean SSI-Service Admin UI but not leave any hanging VCs with inaccessible hanging DIDs. Soft Deletes DID by method

path Parameters
method
required
string

Method

id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get DID

Get DID by method

path Parameters
method
required
string

Method

id
required
string

ID

Request Body schema: application/json

request body

keyType
required
string

Identifies the cryptographic algorithm family to use when generating this key. One of the following: "Ed25519", "X25519", "secp256k1", "P-224","P-256","P-384", "P-521", "RSA"

options
any

Options for creating the DID. Implementation dependent on the method.

Responses

Request samples

Content type
application/json
{
  • "keyType": "string",
  • "options": null
}

Response samples

Content type
application/json
{
  • "did": {
    }
}

Resolve a DID

Resolve a DID that may not be stored in this service

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "didDocument": {
    },
  • "didDocumentMetadata": {
    },
  • "didResolutionMetadata": {
    }
}

IssuingAPI

Create issuance template

Create issuance template

Request Body schema: application/json

request body

credentialManifest
required
string

ID of the credential manifest that this template corresponds to.

Array of objects (issuing.CredentialTemplate)

Info required to create a credential from a credential application.

id
string

ID of this template.

issuer
required
string

ID of the issuer that will be issuing the credentials.

issuerKid
required
string

ID of the key that will be used to sign the credentials.

Responses

Request samples

Content type
application/json
{
  • "credentialManifest": "string",
  • "credentials": [
    ],
  • "id": "string",
  • "issuer": "string",
  • "issuerKid": "string"
}

Response samples

Content type
application/json
{
  • "credentialManifest": "string",
  • "credentials": [
    ],
  • "id": "string",
  • "issuer": "string",
  • "issuerKid": "string"
}

Delete issuance template

Delete issuance template by ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get issuance template

Get an issuance template by its id

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "credentialManifest": "string",
  • "credentials": [
    ],
  • "id": "string",
  • "issuer": "string",
  • "issuerKid": "string"
}

KeyStoreAPI

Store Key

Stores a key to be used by the service

Request Body schema: application/json

request body

base58PrivateKey
required
string

Base58 encoding of the bytes that result from marshalling the private key using golang's implementation.

controller
required
id
required
string

The id field is the unique identifier for this object. If set to a resolvable DID, the ssi-service will use the private key encoded in the PrivateKeyBase58 field of this object to sign objects issued or authored by this DID; otherwise, it will only be used to identify this object.

type
required
string

Identifies the cryptographic algorithm family used with the key. One of the following: "Ed25519", "X25519", "secp256k1", "P-224", "P-256", "P-384", "P-521", "RSA".

Responses

Request samples

Content type
application/json
{
  • "base58PrivateKey": "string",
  • "controller": "string",
  • "id": "string",
  • "type": "string"
}

Response samples

Content type
application/json
"string"

Revoke Key

Marks the stored key as being revoked, along with the timestamps of when it was revoked. NB: the key can still be used for signing. This will likely be addressed before v1 is released.

path Parameters
id
required
string

ID of the key to revoke

Responses

Response samples

Content type
application/json
"string"

Get Details For Key

Get details about a stored key

path Parameters
id
required
string

ID of the key to get

Responses

Response samples

Content type
application/json
{
  • "controller": "string",
  • "createdAt": "string",
  • "id": "string",
  • "type": "string"
}

ManifestAPI

Get manifests

Checks for the presence of a query parameter and calls the associated filtered get method

query Parameters
issuer
string

string issuer

schema
string

string schema

subject
string

string subject

Responses

Response samples

Content type
application/json
{
  • "manifests": [
    ]
}

Create manifest

Create manifest

Request Body schema: application/json

request body

description
string
required
object (exchange.ClaimFormat)
issuerDid
required
string
issuerKid
required
string
issuerName
string
name
string
required
Array of objects (manifest.OutputDescriptor)
object (exchange.PresentationDefinition)

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "format": {
    },
  • "issuerDid": "string",
  • "issuerKid": "string",
  • "issuerName": "string",
  • "name": "string",
  • "outputDescriptors": [
    ],
  • "presentationDefinition": {
    }
}

Response samples

Content type
application/json
{
  • "credential_manifest": {
    },
  • "manifestJwt": "string"
}

Delete manifests

Delete manifest by ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get manifest

Get a credential manifest by its id

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "credential_manifest": {
    },
  • "id": "string",
  • "manifestJwt": "string"
}

ApplicationAPI

Get applications

Gets all the existing applications.

Responses

Response samples

Content type
application/json
{
  • "applications": [
    ]
}

Submit application

Submit a credential application in response to a credential manifest. The request body is expected to

Request Body schema: application/json

request body

applicationJwt
required
string

Contains the following properties: Application manifestsdk.CredentialApplication json:"credential_application" validate:"required" Credentials []interface{} json:"vcs" validate:"required"

Responses

Request samples

Content type
application/json
{
  • "applicationJwt": "string"
}

Response samples

Content type
application/json
{
  • "done": true,
  • "id": "string",
  • "result": {
    }
}

Delete applications

Delete application by ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get application

Get application by id

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "application": {
    },
  • "id": "string"
}

Reviews an application

Reviewing an application either fulfills or denies the credential.

Request Body schema: application/json

request body

approved
boolean
object

Overrides to apply to the credentials that will be created. Keys are the ID that corresponds to an OutputDescriptor.ID from the manifest.

reason
string

Responses

Request samples

Content type
application/json
{
  • "approved": true,
  • "credential_overrides": {
    },
  • "reason": "string"
}

Response samples

Content type
application/json
{
  • "credential_response": {
    },
  • "responseJwt": "string",
  • "verifiableCredentials": [
    ]
}

ResponseAPI

Get responses

Checks for the presence of a query parameter and calls the associated filtered get method

Responses

Response samples

Content type
application/json
{
  • "responses": [
    ]
}

Delete responses

Delete response by ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get response

Get response by id

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "credential_response": {
    },
  • "responseJwt": "string",
  • "verifiableCredentials": null
}

OperationAPI

List operations

List operations according to the request

Request Body schema: application/json

request body

filter
string

A standard filter expression conforming to https://google.aip.dev/160. For example: done = true.

parent
string

The name of the parent's resource. For example: "/presentation/submissions".

Responses

Request samples

Content type
application/json
{
  • "filter": "string",
  • "parent": "string"
}

Response samples

Content type
application/json
{
  • "operations": [
    ]
}

Get an operation

Get operation by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "done": true,
  • "id": "string",
  • "result": {
    }
}

Cancel an ongoing operation

Cancels an ongoing operation, if possible.

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "done": true,
  • "id": "string",
  • "result": {
    }
}

PresentationDefinitionAPI

Create PresentationDefinition

Create presentation definition

Request Body schema: application/json

request body

author
required
string

DID of the author of this presentation definition. The DID must have been previously created with the DID API, or the PrivateKey must have been added independently.

authorKid
required
string

The privateKey associated with the KID will be used to sign an envelope that contains the created presentation definition.

object (exchange.ClaimFormat)
required
Array of objects (exchange.InputDescriptor)
name
string
purpose
string
Array of objects (exchange.SubmissionRequirement)

Responses

Request samples

Content type
application/json
{
  • "author": "string",
  • "authorKid": "string",
  • "format": {
    },
  • "inputDescriptors": [
    ],
  • "name": "string",
  • "purpose": "string",
  • "submissionRequirements": [
    ]
}

Response samples

Content type
application/json
{
  • "presentation_definition": {
    },
  • "presentationDefinitionJWT": "string"
}

Delete PresentationDefinition

Delete a presentation definition by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get PresentationDefinition

Get a presentation definition by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "presentation_definition": {
    },
  • "presentationDefinitionJWT": "string"
}

List Presentation Definitions

Lists all the existing presentation definitions

Request Body schema: application/json

request body

object (github.com_tbd54566975_ssi-service_pkg_server_router.ListDefinitionsRequest)

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "definitions": [
    ]
}

PresentationSubmissionAPI

List Submissions

List existing submissions according to a filtering query. The filter field follows the syntax described in https://google.aip.dev/160.

Request Body schema: application/json

request body

filter
string

A standard filter expression conforming to https://google.aip.dev/160. For example: status = "done".

Responses

Request samples

Content type
application/json
{
  • "filter": "string"
}

Response samples

Content type
application/json
{
  • "submissions": [
    ]
}

Create Submission

Creates a submission in this server ready to be reviewed.

Request Body schema: application/json

request body

submissionJwt
required
string

Signed envelope that contains the PresentationDefinition created using the privateKey of the author of the definition.

Responses

Request samples

Content type
application/json
{
  • "submissionJwt": "string"
}

Response samples

Content type
application/json
{
  • "done": true,
  • "id": "string",
  • "result": {
    }
}

Get Submission

Get a submission by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "reason": "string",
  • "status": "string",
  • "verifiablePresentation": {
    }
}

Review a pending submission

Reviews a pending submission. After this method is called, the operation with id==presentations/submissions/{submission_id} will be updated with the result of this invocation.

Request Body schema: application/json

request body

approved
required
boolean
reason
string

Responses

Request samples

Content type
application/json
{
  • "approved": true,
  • "reason": "string"
}

Response samples

Content type
application/json
{
  • "reason": "string",
  • "status": "string",
  • "verifiablePresentation": {
    }
}

SchemaAPI

Get Schemas

Get schemas

Responses

Response samples

Content type
application/json
{
  • "schemas": [
    ]
}

Create SchemaID

Create schema

Request Body schema: application/json

request body

author
required
string
authorKid
string

AuthorKID represents the KID of the author's private key to sign the schema. Required if sign is true.

name
required
string
required
object (schema.JSONSchema)
sign
boolean

Sign represents whether the schema should be signed by the author. Default is false. If sign is true, the schema will be signed by the author's private key with the specified KID

Responses

Request samples

Content type
application/json
{
  • "author": "string",
  • "authorKid": "string",
  • "name": "string",
  • "schema": {
    },
  • "sign": true
}

Response samples

Content type
application/json
{
  • "id": "string",
  • "schema": {
    },
  • "schemaJwt": "string"
}

Delete SchemaID

Delete a schema by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get SchemaID

Get a schema by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "schema": {
    },
  • "schemaJwt": "string"
}

Verify SchemaID

Verify a given schema by its id

Request Body schema: application/json

request body

schemaJwt
required
string

Signed envelope that contains the PresentationDefinition created using the privateKey of the author of the definition.

Responses

Request samples

Content type
application/json
{
  • "schemaJwt": "string"
}

Response samples

Content type
application/json
{
  • "reason": "string",
  • "verified": true
}

WebhookAPI

Get Webhooks

Get webhooks

Responses

Response samples

Content type
application/json
{
  • "webhooks": [
    ]
}

Create Webhook

Create webhook

Request Body schema: application/json

request body

noun
required
string

The noun (entity) for the new webhook.eg: Credential

url
required
string

The URL to post the output of this request to Noun.Verb action to.

verb
required
string

The verb for the new webhook.eg: Create

Responses

Request samples

Content type
application/json
{
  • "noun": "string",
  • "url": "string",
  • "verb": "string"
}

Response samples

Content type
application/json
{
  • "webhook": {
    }
}

Get Webhook

Get a webhook by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
{
  • "webhook": {
    }
}

Delete Webhook

Delete a webhook by its ID

path Parameters
id
required
string

ID

Responses

Response samples

Content type
application/json
"string"

Get Supported Nouns

Get supported nouns for webhook generation

Responses

Response samples

Content type
application/json
{
  • "nouns": [
    ]
}

Get Supported Verbs

Get supported verbs for webhook generation

Responses

Response samples

Content type
application/json
{
  • "verbs": [
    ]
}