Skip to main content

Process Transformation Event

info

Please note that this content is under development and is not ready for implementation. This status message will be updated as content development progresses.

Description

The processTransformationEvent service is responsible for processing a Transformation Event (DTE), issuing Verifiable Credentials (VCs) for both the Transformation Event and Digital Product Passports (DPPs), uploading them to the Storage service, registering the link to the stored DTE and DPPs with the Identity Resolver service, and managing Transaction events in local storage associated with the event. It handles the entire lifecycle of creating and managing transformation events and associated DPPs.

Diagram

Example

{
"name": "processTransformationEvent",
"parameters": [
{
"vckit": {
"vckitAPIUrl": "https://api.vckit.example.com",
"issuer": "did:example:123456789abcdefghi"
},
"epcisTransformationEvent": {
"context": ["https://www.w3.org/2018/credentials/v1", "https://gs1.org/voc/"],
"type": ["VerifiableCredential", "EPCISTransformationEvent"],
"renderTemplate": [
{
"type": "html",
"template": "<div><h2>Transformation Event</h2><p>Output: {{outputItems.0.epc}}</p></div>"
}
],
"dlrIdentificationKeyType": "gtin",
"dlrLinkTitle": "Transformation Event",
"dlrVerificationPage": "https://verify.example.com"
},
"dlr": {
"dlrAPIUrl": "https://dlr.example.com/api",
"dlrAPIKey": "dlr-api-key-12345"
},
"storage": {
"url": "https://storage.example.com/upload",
"params": {
"resultPath": "/url"
}
},
"dpp": {
"context": ["https://www.w3.org/2018/credentials/v1", "https://schema.org/"],
"type": ["VerifiableCredential", "DigitalProductPassport"],
"renderTemplate": [
{
"type": "html",
"template": "<div><h2>Product DPP</h2><p>EPC: {{epc}}</p></div>"
}
],
"dlrIdentificationKeyType": "gtin",
"dlrLinkTitle": "Product DPP",
"dlrVerificationPage": "https://verify.example.com"
},
"dppCredentials": [
{
"mappingFields": [
{
"sourcePath": "/vc/credentialSubject/outputItems/0/epc",
"destinationPath": "/epc"
}
]
}
],
"identifierKeyPath": "/outputItems/0/epc",
"transformationEventCredential": {
"mappingFields": [
{
"sourcePath": "/inputItems",
"destinationPath": "/inputQuantityList"
},
{
"sourcePath": "/outputItems",
"destinationPath": "/outputQuantityList"
}
],
"generationFields": [
{
"path": "/eventTime",
"handler": "generateCurrentDatetime"
},
{
"path": "/eventID",
"handler": "generateUUID"
}
]
}
}
]
}

Definitions

PropertyRequiredDescriptionType
vckitYesConfiguration for the VCKit serviceVCKit
epcisTransformationEventYesConfiguration for the EPCIS Transformation EventCredential
dlrYesConfiguration for the Digital Link ResolverIDR
storageYesConfiguration for storage serviceStorage
dppYesConfiguration for the Digital Product PassportCredential
dppCredentialsYesMapping configuration for DPP credentialsConstruct Data[]
identifierKeyPathYesJSON path to the identifier in the credential subjectString
transformationEventCredentialYesMapping and generation configuration for the transformation event credentialConstruct Data