Input descriptors
Input descriptors are used to specify the data or credentials needed to issue a credential. It is a main feature of DIF Presentation Exchange. See https://identity.foundation/presentation-exchange/#presentation-definition for more information.
An example here with only input descriptors (EmailPass required to issue a credential) :
{
"credential_manifest": {
"presentation_definition": {
"id": "32f54163-7166-48f1-93d8-ff217bdb0653",
"input_descriptors": [
{
"id": "emailPass_input_1",
"constraints": {
"fields": [
{
"path": [
"$.type"
],
"filter": {
"type": "string",
"pattern": "EmailPass"
}
}
]
}
}
]
}
}
}
Example to request any credentials with the attribute birthDate
{
"credential_manifest": {
"presentation_definition": {
"id": "32f54163-7166-48f1-93d8-ff217bdb0653",
"input_descriptors": [
{
"id": "#765765",
"constraints":
"fields": [
{
"path": [
"$.credentiaSubject.birthDate"
]
}
]
}
}
]
}
}
}
Last updated