Krafta operates a network of allied printing workshops (talleres) in Venezuela. The workshops admin atDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/PloutusLab/krafta-web/llms.txt
Use this file to discover all available pages before exploring further.
/admin/workshops provides a CRUD interface for the Workshop model — the entities that actually produce orders once payment is confirmed. Each workshop record holds its contact details, operational capacity, service-level agreement (SLA), payment policy, and geographic base. When the database is unavailable, the API falls back to a local public/workshops.json file seeded with two default workshops.
Workshop model fields
| Field | Type | Description |
|---|---|---|
name | String | Public-facing workshop name |
contactName | String | Primary contact person |
phone | String | Contact phone number (Venezuelan format: 0414...) |
email | String | Contact email address |
cityBase | String | City where the workshop operates |
stateBase | String | Venezuelan state |
capacityPerDay | Int | Maximum units the workshop can produce per day |
slaDays | Int | Standard production lead time in business days |
paymentPolicy | PaymentPolicy | How Krafta pays the workshop (see below) |
active | Boolean | Whether the workshop appears in assignment dropdowns |
Payment policy options
| Enum value | Label | Description |
|---|---|---|
DEPOSITO_TOTAL | Depósito Total | Full payment transferred before production begins |
DEPOSITO_PARCIAL | Depósito Parcial | 50 % upfront, 50 % on completion |
PAGO_AL_FINALIZAR | Pago al Finalizar | Full payment after the order is ready |
PAGO_CONTRA_ENTREGA | Pago Contra Entrega | Payment on physical delivery of the goods |
Create a workshop
POST /api/workshops — request body
Workshop display name.
Full name of the primary point of contact.
Venezuelan mobile number. Used to generate WhatsApp dispatch links in the orders panel.
Contact email. Used to generate production order email links.
Base city. Defaults to
"Barquisimeto" if omitted.Venezuelan state. Defaults to
"Lara" if omitted.Maximum daily production units. Defaults to
10 if omitted.Production lead time in business days. Defaults to
3 if omitted.One of the
PaymentPolicy enum values. Defaults to "PAGO_AL_FINALIZAR".Default seeded workshops
When no workshops exist in the database, the API serves these two defaults from the local fallback file:| Workshop | City | State | Capacity | SLA | Policy |
|---|---|---|---|---|---|
| Taller Creativo Barquisimeto | Barquisimeto | Lara | 50/day | 3 days | PAGO_AL_FINALIZAR |
| Taller Cabudare Premium | Cabudare | Lara | 30/day | 2 days | DEPOSITO_TOTAL |
WorkshopOffer — variant pricing
AWorkshopOffer links a specific workshop to a specific ProductVariant with a production cost. This is how per-product pricing is configured for each workshop.
| Field | Description |
|---|---|
workshopId | The workshop providing the offer |
variantId | The product variant this price applies to |
cost | Production cost in USD charged by the workshop |
currency | Currency code, default "USD" |
minQuantity | Minimum order quantity for this price to apply |
reviewRequired | If true, the price is subject to manual review before confirmation |
active | Whether this offer is currently available for assignment |
WorkshopCoverage — geographic routing
WorkshopCoverage records define which Venezuelan states and cities a workshop can serve. The delivery routing logic uses these records alongside FulfillmentRule to match an order’s shippingState to the appropriate origin city and delivery method.
FulfillmentRule maps a destination state to an originCity (default: "Barquisimeto"), a preferredMethod, and an optional backupMethod using the DeliveryMethod enum (PICKUP, LOCAL_DELIVERY, NATIONAL_SHIPPING).
Production assignment
When an order reachesCONFIRMED status and an admin assigns a workshop in the orders panel, a ProductionAssignment record is created:
| Field | Description |
|---|---|
orderItemId | The specific order item being assigned |
workshopId | The assigned workshop |
workshopOfferId | The WorkshopOffer that determined pricing |
agreedCost | Production cost frozen at the moment of assignment — not affected by future offer price changes |
status | Starts as PENDING_ASSIGNMENT and advances through NOTIFIED → ACCEPTED → IN_PRODUCTION → READY → HANDED_TO_DELIVERY → COMPLETED |
WorkshopPayable lifecycle
EachProductionAssignment generates one or more WorkshopPayable records representing what Krafta owes the workshop:
| Status | Meaning |
|---|---|
PENDING | Payment not yet sent |
PARTIAL | Partial amount paid (applicable under DEPOSITO_PARCIAL policy) |
PAID | Full amount settled |
amount, policy, dueDate, paidAmount, and an optional reference and receiptUrl for the outgoing transfer.