| Version 17 (modified by , 4 years ago) ( diff ) |
|---|
Clariprint Json API
Listes utilisées
Structure d'une requête
Requête
- Type : HTTP POST
- url : [clariprint host]/optimproject/json.wcl
- variables :
- login (Client Optimproject)
- password
- action : chaine de charatere
- datas : donnes au formant JSON
Réponse
- format : Json encoded raw
Actions
CheckAuth
Vérification des données d'authentification voir : JsonApiCheckAuth
QuoteRequest
Demande de prix
datas :
{
clariprint_product: {
group:string // groupe de classement dans optimproject),
reference:string // reference du projet
labels:list[string] // liste de label
quantity:integer // quantité du produit
}
Exemples produits
Feuillet
{
"clariprint_product": {
"reference": "Feuillet simple", // libre
"kind": "leaflet", // leaflet:"feuillet" // folded:"dépliant" // book:"brochure" // cover:"couverture" // section:"intérieur de brochure"
"quantity": "2000", // libre obligatoire
// uniquement si multi-modèle de quantité identite, "_assembed" si les modèles sont assemblés
"models_qt_mode": "same_qt", // ou "same_qt_assembled"
"models_qt" : "12" // nombre de modèles
// uniquement si multi-modèle de quantité différentes
"models": [ {
"reference": "Model 2",
"quantity": "3000"
},
{
"reference": "Model 3",
"quantity": "1500"
}
],
"size": "21x29.7:A4", // lxh:commentaires peut etre remplace par width: et height:
"width": "21", // optionnel, soit size soit width + height
"height": "29.7", // optionnel
"with_bleeds": "1", // 1 avec blanc tournant, 0 sans fonds perdus
"pms1": { // optionnel, définition d'une teinte Pantone
"class": "PMS", // PMS:Pantone std / Spot:Pantone fluo / Metal:Pantone métallique
"back": "1", // 1 présente au verso, 0 non présente
"front": "1", // 1 présente au recto, 0 non présente
"code": "253"
},
"front_colors": [
"4-color" /// liste des encres : c/m/y/b/4-color/quadri/q
],
"back_colors": [
"4-color"
],
"finishing_front": "OFFSET_SATIN", // liste des finitions
"finishing_back": [ // exemple finition combinée
"PELLIC_ACETATE_BRILLANT",
"UVS_MAT_RESERVE"
],
"papers": { // obligatoire
"custom": { // "of" pour offset ou "custom"
"processes": [ // optionnel liste des procédés d'impression autorisés, si absent sont actifs : of, n, ofuv, or
"of", // procédé offset feuille
"n", // procédé numérique
"ofuv", // procédé offset UV
"or", // procédé Offset Roto
"h" // procédé hélio
]
"quality": "Couché Brillant PEFC", // texte exact de la qualité dans le référentiel
"weight": "250", // grammage
"brand": "Condat Gloss", // optionnel : texte exact de la marque dans le référentiel
"color": "blanc" // optionnel : texte exact de la couleur dans le référentiel
}
},
// paramètres de façonnage optionnel
"creasing": "0", // rainage, 0: pas de rainage, 1:rainage au mieux, 2:rainage sur typo imposé
"embossing_top": "", // embossing = gaufrage
"embossing_left": "",
"embossing_height": "",
"embossing_width": "",
"gilding": "", // gilding = dorure
"gilding_side": "",
"gilding_top": "",
"gilding_left": "",
"gilding_height": "",
"gilding_width": "",
"gilding3d": "", // gilding3d = dorure 3D
"cutting_die_exists": "0", // cutting_die = forme de découpe, 1:l'outil de forme existe, 0: il n'existe pas
"cutting_die": "0", // 0 si pas de forme, si forme :id de forme de découpe, voir aide JsonFolderDie
"holes": "0", // holes: trous, 0: pas de trous, 1 2 ou 4 trous classeurs
// wrapping : conditionnement,
"wrapping_0": {
"method": "shrink", // shrink:mise sous film
/*
{"shrink" } MISE_SOUS_FILM,
{"cardboard" } MISE_EN_CARTON,
{"cardboardbox" } MISE_EN_POCHETTE_CARTON,
{"lostpallet" } MISE_EN_PALETTE,
{"halfpallet" } MISE_EN_DEMI_PALETTE,
{"boxpallet" } MISE_EN_BOX_PALETTE,
{"eupallet" } MISE_EN_PALETTE_EUROPE,
{"elasticband" } MISE_SOUS_ELASTIQUE,
{"kraft" } MISE_SOUS_PAPIER_KRAFT,
{"crosslink"} MISE_SOUS_LIEN_CROISE,
{"roundtube"} MISE_EN_TUBE_ROND,
{"squaretube"} MISE_EN_TUBE_CARRE,
{"triangletube"} MISE_EN_TUBE_TRIANGLE,
*/
"quantity": "1000" // optionnel, si rien calcul au mieux
"etiket" : "1" // vide si pas identifié, "1" si identifié
},
"wrapping_1": {
"method": "cardboard", // cardboard: mise en carton
"quantity": "10"
},
"wrapping_2": {
"method": "",
"quantity": ""
},
// deliveries : livraison,
"deliveries": {
// 1 structure par point de livraison
"d55044": { // texte libre
"iso": "FR-17", // obligatoire : code iso de la zone (voir la liste dans Clariprint/optimProcess/Paramétrage/Zones géo iso
"address": "", // indicatif : champs libre
"quantity": "100" // obligatoire : quantité
}
},
"proofing": "soft", // ne pas tenir compte
"discounts_group": "" // ne pas tenir compte
},
"clariprint_product_paper_iso": "" // ne pas tenir compte
}
Dépliant
{
"clariprint_product": {
"reference": "depliant",
"kind": "folded",
"quantity": "3000",
"size": "21x29,7",
"with_bleeds": "",
"folds": "2", // !!! type de plis
"label": "",
"papers": {
"of": {
"quality": "Offset Blanc",
"weight": "100",
"brand": "",
"color": "BLANC"
}
},
"front_colors": [
"4color"
],
"finishing_front": "",
"finishing_back": "",
"creasing": "0",
"embossing_top": "",
"embossing_left": "",
"embossing_height": "",
"embossing_width": "",
"gilding_top": "",
"gilding_left": "",
"gilding_height": "",
"gilding_width": "",
"gilding_material": "",
"cutting_die_exists": "0",
"cutting_die": "0",
"holes": "1",
"linear_perforating": "1", // perfo linéaire 0: pas de perfo, 1: perfo
"numbering": "1", // numérotation, 0: non, 1: oui
"wrapping_0": {
"method": "",
"quantity": ""
},
"wrapping_1": {
"method": "",
"quantity": ""
},
"wrapping_2": {
"method": "",
"quantity": ""
},
"deliveries": [
{
"iso": "",
"address": "",
"quantity": ""
}
],
"proofing": "soft",
"extra": {
"justificative": {
"mode": "",
"delivery_cost": "",
"invoice_cost": "",
"other_cost": "",
"address": ""
}
},
"discounts_group": ""
}
}
Brochure simple
{
"clariprint_product": {
"reference": "",
"kind": "book",
"quantity": "2000",
"size": "21x29", // definition du format fini de la brochure
"binding": "Stitching3", // binding: méthode d'assemblage,
// "PerfectBinding","DCC" : BrochageDosCarreColleItem(),
// "PerfectBindingPUR","DCCPUR" : BrochageDosCarreColleItem(PUR? = true),
// "SewnBinding","DCCC" : BrochageDosCarreCousuItem(),
// "Stitching2","PC" : PiqureChevalItem(nbPiqures = 2),
// "Stitching3" : PiqureChevalItem(nbPiqures = 3),
// "Stitching4" : PiqureChevalItem(nbPiqures = 4),
// "OpenEyesStitching2","PB" : PiqureBoucletteItem(nbPiqures = 2),
// "OpenEyesStitching3" : PiqureBoucletteItem(nbPiqures = 3),
// "OpenEyesStitching4" : PiqureBoucletteItem(nbPiqures = 4),
// "WireO","WO" : ReliureWireOItem(),
// "InlineStiching","PL" : PiqureEnLigneItem(),
// "GluedOnFold","CP" : CollageAuPliItem(),
"cover": {
"label": "", // optionnel
"papers": {
"of": {
"quality": "Couché Brillant PEFC",
"weight": "300",
"brand": "",
"color": ""
}
}
},
"components": {
"component_5490c092c962e": { // nom libre
"kind": "section",
"pages": 64, // nombre de pages de la section
"size" : "override", // optionnel : prend la dimension generale sinon on peut preciser une autre dimension ex 19x18
"papers": {
"of": {
"quality": "Offset Blanc",
"weight": "100",
"brand": "",
"color": ""
}
},
"front_colors": [
"4color"
],
"back_colors": [
"4color"
],
}
},
"deliveries": [
{
"iso": "FR-12",
"address": "",
"quantity": "2000"
}
]
}
}
Reponse
{
"success":true,
"action":"QuoteRequest",
"total_process_duration":30,
"delais":1,
"weight":7.371, // masse en kg
"html":"", // description html de la demande
"text":"", // description texte de la demande
"quote_process":"", // gamme en PDF en base 64
// details des couts
"costs":{
"paper":8.098834,
"print":129.49,
"makeready":37.36,
"packaging":4.0,
"delivery":0.0,
"total":178.948834},
// cout simplifié
"response":178
}
Attachments (5)
- PaperCatalog.png (160.4 KB ) - added by 4 years ago.
- QuoteRequest.png (160.1 KB ) - added by 4 years ago.
- GetNewProjectId.png (105.6 KB ) - added by 4 years ago.
- solverfq.png (295.1 KB ) - added by 4 years ago.
- fetchrfq.png (114.4 KB ) - added by 4 years ago.
Download all attachments as: .zip
Note:
See TracWiki
for help on using the wiki.