Caisse Enregistreuse

Logiciel de caisse enregistreuse gratuit, en ligne depuis 2011.

Suivez-nous

L’aide, à portée de main

Comment pouvons-nous vous aider ?

Un réglage, une question, un geste du quotidien. Trouvez le bon guide et avancez simplement.

API / Webservices

Télécharger vos rapports

Téléchargez vos rapports quotidiens au format HTML, PDF, XLS, CSV...

GET /workers/getSales.php

URL de base : https://kash.click/workers/getSales.php

Paramètres

NomTypeObligatoireDescription
shopIDstringOuiIdentifiant de compte boutique (SHOPID)
keystringOuiVotre token (APIKEY)
dintNonJour (si non précisé, le rapport porte sur le mois entier)
mintNonMois (si jour et mois non précisé, le rapport porte sur l'année entière)
yintNonAnnée (si jour, mois et année non précisés, le rapport porte sur hier)
formatExportstringOuiStd (rapport HTML), PDF, XLS, CSV, frafec (FEC), saft

Exemples JavaScript

// Aide pour construire une URL GETfunction buildUrl(path, params){ const qs = new URLSearchParams(params); return `${path}?${qs.toString()}`;}const SHOPID = SHOPID;const APIKEY = 'REMPLACER_PAR_VOTRE_CLE_API_GENEREE';// 1) Export CSV pour date préciseconst urlCsv = buildUrl("https://kash.click/workers/getSales.php", { shopID: SHOPID, key: APIKEY, d: 16, m: 10, y: 2025, formatExport: "CSV"});fetch(urlCsv).then(r=>r.text()).then(csv=>console.log(csv));// 2) Rapport HTML (Std) pour la veille (sans date)const urlStd = buildUrl("https://kash.click/workers/getSales.php", { shopID: SHOPID, key: APIKEY, formatExport: "Std"});fetch(urlStd).then(r=>r.text()).then(html=>{ document.getElementById("rapport").innerHTML = html;});// 3) Rapport PDF (Blob)const urlPdf = buildUrl("https://kash.click/workers/getSales.php", { shopID: SHOPID, key: APIKEY, d: 16, m: 10, y: 2025, formatExport: "PDF"});fetch(urlPdf).then(r=>r.blob()).then(pdf=>{ const a = document.createElement("a"); a.href = URL.createObjectURL(pdf); a.download = "rapport-ventes.pdf"; a.click();});

Ce document est mis à disposition selon les termes de la licence Creative Commons Attribution 4.0 International (CC BY 4.0).