TimestampDPP

Before you begin

As a brand or service provider, you want to timestamp an Arianee Event on a Digital Product Passport (DPP).
The timestampDPP API provides a single entry point for timestamping, without worrying if the DPP is already minted or needs to be created.

Use case examples:

  • A repair service is completed, you want to timestamp the intervention.
  • A warranty extension is granted, you want to attach it as an event to the product.
  • A product is inspected or transferred, and you want to keep a trace in its passport history.

🎯 Objective

Simplify timestamping by exposing one unique API that:

  • Identifies the right DPP from:
    • a QR code (Smart Link, Arianee Link, or other data carrier),
    • one or multtiple photos of the product’s data plate (nameplate),
    • or manual identifiers.
  • Associates an Arianee Event with the DPP.
  • Creates missing parent DPPs if necessary.

📡 API Request

Example curl

curl --location 'https://url.nmp.arianee.com/certificate/timestamp' \
--header 'x-api-key: ••••••' \
--form 'photo=@"/Users/nameofuser/Downloads/plaquesignalétique.pdf"' \
--form 'arianeeEventTemplate="{ \"id\": \"67bee46014f957ee9baa0f33\", \"data\": {\"duration\":\"14 jours\"} }"' \
--form 'qrcode="https://app.arianee.com/33996814,soi29jo1mwlj,testnet"'

 

📝 Fields

photo DEPRECATED

  • Use "photos" instead. Still working for retro-compatibility.

  • Type: image file

  • Required: No (exclusive with identifiers)

  • Description: A photo of the data plate.

    • Processed by AI to extract identifiers like serialNumber or refTech.

photos

  • Type: images file

  • Required: No (exclusive with identifiers)

  • Description: Multiple photos of the data plate.

    • Processed by AI to extract identifiers like serialNumber or refTech.

qrcode

  • Type: string

  • Required: No

  • Description: A link scanned from a QR code. Can be:

    • Direct Arianee Link (https://wallet.arianee.org/passport/...)
    • Smart Link (https://q.arianee.net/...)
    • Third-party redirect

Behavior:

  • If the link points to an existing DPP → used directly.
  • If not, but a DPP is created from photo or identifiers and the link is a Smart Link → the Smart Link is paired automatically with the new DPP.

arianeeEventTemplate

  • Type: JSON string

  • Required: ✅ Yes

  • Description: Event template to create.

    • id: template ID in Arianee NMP
    • data: dynamic fields (e.g., duration, description)

Example:

{
  "id": "67bee46014f957ee9baa0f33",
  "data": {
    "duration": "14 jours",
    "description": "Révision complète du produit"
  }
}

identifiers

  • Type: JSON string
  • Required: No (exclusive with photo)
  • Description: Data extracted manually from the data plate.

Possible fields:

  • serialNumber (required if no photo)
  • commercialReference
  • productGroupId (codic, etc.)
  • gtin
  • manufacturer (only for parent creation)

🛑 API Error Codes

All processes run in a background job.
The API always returns 200, except for the following errors:

CodeErrorMessageTrigger
400multiple.photosOnly one photo is allowedMore than one photo uploaded
400invalid.photo.typePhoto must be an image fileFile is not image/*
400photo.too.largePhoto must not exceed 5MBFile > 5MB
400missing.photo.or.qrcode.or.identifiersphoto or qrcode or identifiers is requiredNone of the three fields present
400missing.arianeeEventTemplatearianeeEventTemplate.id is requiredEvent template missing/invalid
400missing.identifiersidentifiers requiredNo identifiers provided when no photo
400missing.serialNumberserialNumber requiredMissing serialNumber with no photo
400invalid.qrcodeqrcode must be valid URLInvalid or non-URL string
400arianeeEventTemplate.notfoundEvent template not foundTemplate ID not in DB
400arianeeEventTemplate.invalidIdInvalid MongoDB ObjectIdWrong template ID format
500upload.errorUpload errorFailure uploading to GCS
500Error processing timestampDPPUnexpected errorMain try/catch failed

⚙️ Use Cases

Case 1: QR Code only

{
  "qrcode": "https://q.arianee.net/...",
  "arianeeEventTemplate": { ... }
}
  • Follows redirect to find DPP.
  • ✅ If found → Event applied.
  • ❌ If not → Error.

Case 2: Photo or Identifiers only

{
  "photo": fichier,
  "arianeeEventTemplate": { ... }
}
{
  "identifiers": {
    "serialNumber": "12345",
    "refCom": "ABC-123"
  },
  "arianeeEventTemplate": { ... }
}
  • Identifiers extracted or provided manually.

  • ✅ If unit DPP exists → Event applied.

  • ❌ If not:

    • Looks for parent DPP.
    • If none → creates minimal parent.
    • Creates unit DPP.
    • Applies Event.

Case 3: Photo + QR Code

  • If QR code = Arianee Link → prioritized.

  • If QR code = Smart Link but unpaired:

    • Falls back to identifiers/photo.
    • Creates DPP if needed.
    • Pairs Smart Link ↔ DPP.
    • Applies Event.

Summary of Cases

CaseInputsDPP Found?Action
1qrcode (Arianee Link)✅ yesEvent applied
❌ noError
2photo or identifiers✅ yesEvent applied
❌ no + parent existsCreate unit DPP + Event
❌ no + no parentCreate parent + unit + Event
3photo + qrcode (Smart Link)❌ via QRCreate unit DPP from photo + pair Smart Link + Event
3bphoto + qrcode (Arianee Link)✅ yesEvent applied (photo ignored)

🔍 Examples

Example 1: QR code random + identifiers match a DPP

{
  "qrcode": "https://google.com/random-link",
  "identifiers": {
    "serialNumber": "123456",
    "technicalReference": "ABC-987"
  }
}

Behavior:

  1. QR code not Arianee → no DPP found.
  2. Fallback to identifiers.
  3. ✅ Unit DPP exists → Event applied.
  4. ❌ No Smart Link association (since QR is not Arianee).

Example 2: Arianee Link + conflicting identifiers

{
  "qrcode": "https://wallet.arianee.org/passport/brand/12345,abc",
  "identifiers": {
    "serialNumber": "999999"
  }
}

Behavior:

  • QR code → identifies an existing DPP.
  • Identifiers point to a different one.
  • ✅ QR code takes priority. Event applied to QR code DPP.
  • Optional: log mismatch warning.

Example 3: Smart Link unpaired + identifiers not found

{
  "qrcode": "https://q.arianee.net/abc-uuid-smartlink",
  "identifiers": {
    "serialNumber": "000000"
  }
}

Behavior:

  1. Smart Link not paired → no DPP found.
  2. Identifiers don’t match any DPP.
  3. ❌ No parent → create minimal parent.
  4. ✅ Create new unit DPP.
  5. Pair Smart Link ↔ DPP.
  6. Apply Event.