Initial commit

This commit is contained in:
s4luorth
2026-02-07 13:04:04 +01:00
commit 5e0fceab15
82 changed files with 30348 additions and 0 deletions

View File

@@ -0,0 +1,60 @@
meta {
name: 3 Preview Batch - With Envelope
type: http
seq: 3
}
post {
url: {{baseUrl}}/api/preview/batch
body: json
auth: none
}
body:json {
{
"sessionId": "{{sessionId}}",
"batchIndex": 0,
"forceRegenerate": false,
"config": {
"font": "alva",
"letters": [
{
"index": 0,
"format": "a6p",
"text": "Liebe [[Vorname]],\n\nvielen Dank für deine Bestellung!\n\nHerzliche Grüße",
"placeholders": {
"Vorname": "Anna",
"Nachname": "Schmidt",
"Strasse": "Bahnhofstr. 5",
"PLZ": "80331",
"Ort": "München"
}
}
],
"envelopes": [
{
"index": 0,
"format": "c6",
"type": "recipient",
"data": {
"Vorname": "Anna",
"Nachname": "Schmidt",
"Strasse": "Bahnhofstr. 5",
"PLZ": "80331",
"Ort": "München"
}
}
]
}
}
}
tests {
test("Returns letter and envelope", function() {
const files = res.body.files;
const hasLetter = files.some(f => f.type === "letter");
const hasEnvelope = files.some(f => f.type === "envelope");
expect(hasLetter).to.be.true;
expect(hasEnvelope).to.be.true;
});
}