Skip to content
📢 Kafinea is a compatible solution for electronic invoicing! Learn more ➔
kafinea logo svg

Kafinea

  • Features
        • Finance
          • Purchases
          • Audits & KPIs
          • Accounting
          • Invoicing
        • Management
          • Documents
          • Project Management
          • Inventory Management
          • Maintenance
        • HR
          • Employees
          • Timesheets
          • Absence Management
          • Recruitment
        • Customer Service
          • Service Contracts
          • Interventions
          • Warranty Tracking
          • Tickets
        • Sales
          • Subscriptions
          • Sales Automation
          • CRM
          • Points of Sale
        • Cross-Features
          • API
          • Extranet
          • Electronic Signature
          • Workflows
  • Use Cases
  • Pricing
  • Login
  • Discover the demo
📢 Kafinea is electronic invoicing compatible! ➔
kafinea logo svg
Kafinea

API

16
  • REST API – Bulk import (upsert)
  • REST API – Authentication
  • REST API – Retrieve a Document’s PDF
  • REST API – File Management
  • REST API – Entity Relationships
  • REST API – Introduction
  • REST API – Taxes, Tax Regions, and Territorial Rules
  • REST API – Requests and Querying
  • REST API – Refresh an online store order
  • REST API – Bulk deletion (trash)
  • REST API – Cost Accounting
  • REST API – Product Kits
  • REST API – Generic and Specific Products
  • REST API – Action links
  • REST API – Approvals
  • REST API – Full Reference (OpenAPI)

Marketing

1
  • Leads

Sales

14
  • Customer purchase orders
  • Customer accounts
  • Customer Quotes
  • Customer credit notes
  • Company Search (Sirene)
  • Margins in quotes
  • Invoicing
    • Classic Invoicing
    • Progress Invoicing
    • Issue an electronic invoice
    • Invoicing Article Consumption
    • Recurring invoicing
  • Payments
    • Customer payments
    • Linking a payment to one or more invoices
  • Price list
    • Price list administrator guide

Purchases

5
  • Supplier invoices
  • Supplier Purchase Orders
  • Suppliers
  • Supplier Credits
  • Receiving an Electronic Invoice

Catalog

8
  • Units of measure
  • Products
  • Services
  • Sourcing Management
  • The Purchase Order Assistant
  • Generic products
  • Product kits
  • Catalog margin analysis

Finance

11
  • Bank Accounts
  • Manual entries
  • SEPA Mandates
  • Third-party bank accounts
  • Bank Transactions
  • Accounting
    • Cash accounting
    • Accounting entries
    • Tools for Checking Your Accounting
    • Accounting
    • Financial statements
    • Fiscal years

Human Resources

5
  • Timesheets
  • Activities
  • Pay Slips
  • Employee Extranet
    • Leave Management
    • The employee portal card

Project management

2
  • Secure assignments using a people list
  • The responder area: view and accept my assignments

Customer Support

1
  • The Client Portal

Inventory management

4
  • Goods receipt notes
  • Delivery Notes
  • Stock movements
  • Inventory Valuation

Cash register

1
  • Cash Registers

Document management

1
  • Electronic signature

Automation

2
  • Forms
  • Workflows

Templates

2
  • Email templates
  • Document templates

Artificial intelligence

4
  • AI Workflows
  • AI Chat
  • AI Text Assistant
  • Connect ChatGPT, Claude, or Gemini to Kafinea (MCP)

Kafinea interface

9
  • Automatic saving
  • Data Import/Export
  • Navigation
  • Records
  • Lists
  • The Layout Manager
  • Links Between Elements
  • Document Lines
  • List views: Kanban, Cards, Calendar, Planning, Gantt, Geographic map, and Analysis

Settings

10
  • Tax Configuration
  • Global search
  • Access Rights
  • User preferences
  • Numbering formats
  • SMTP Settings
  • Permanent locking
  • Catalog popup filtering
  • AI agents
  • Administer the MCP server

Business Guides

2
  • Enable employees to complete their HR record independently
  • Mobilizing thousands of field workers at scale
  • Kafinea
  • Documentation
  • API
  • REST API – Bulk deletion (trash)
View Categories

REST API – Bulk deletion (trash)

3 minutes

0:00 / 3:09
  • View as Markdown Open this page as plain Markdown (opens in a new tab)
  • Open in ChatGPT Ask questions about this page (opens in a new tab)
  • Open in Claude Ask questions about this page (opens in a new tab)
  • Open in Google AI Studio Ask questions about this page (Google account required) (opens in a new tab)

This page describes the operation to use to move large numbers of records to the trash
at once
, typically to clear out what a previous synchronization or import wrote, before
starting over with a clean database.

Operation Method Description
mass_delete POST Move a batch of records to the trash

Restricted to administrators. Deleting hundreds of records in a single call is a
data recovery task. A non-administrator account keeps delete, one record at a
time, with their own permissions.


Nothing is erased: this is a move to the trash #

mass_delete does exactly what the Delete button does in the interface: the record
goes to the trash. It retains its ID, its links, and its history, and it can be
restored.

Permanent deletion does not exist in the API. Emptying the trash remains a deliberate action,
to be performed from the instance (Settings > Trash). This is intentional: an irreversible deletion
must not be triggerable by a script.


Bulk deletion – Move a batch to the trash #

POST https://apps.kafinea.com/{instance}/webservice.php

Parameter Type Required Description
operation string yes Must be mass_delete
sessionName string yes Session identifier
elementType string yes Name of the target module (e.g.: Products, SalesOrder)
ids JSON yes Array of IDs (500 maximum per call)

IDs can be retrieved with query.

curl -X POST https://apps.kafinea.com/YourKafinea/webservice.php \
  -d "operation=mass_delete" \
  -d "sessionName=YOUR_SESSION_ID" \
  -d "elementType=SalesOrder" \
  -d 'ids=["7x54993","7x54994","7x54995"]'

Response #

{
  "success": true,
  "result": {
    "module": "SalesOrder",
    "processed": 3,
    "deleted": 2,
    "alreadyDeleted": 1,
    "records": [
      { "index": 0, "id": "7x54993", "outcome": "deleted" },
      { "index": 1, "id": "7x54994", "outcome": "deleted" },
      { "index": 2, "id": "7x54995", "outcome": "alreadyDeleted" }
    ],
    "errors": []
  }
}
Field Meaning
processed Number of records processed without error
deleted Records that were just moved to the trash
alreadyDeleted Records that were already there: nothing was done, this is not an error
records Line-by-line details, with the position in the batch
errors Rejected IDs, with their position in the batch and the reason

Safeguards #

A bulk deletion has no second chance, so the operation is deliberately strict:

  • the module is mandatory, and all IDs must belong to it. An ID
    that refers to a record from another module is rejected, with the module actually found included in the
    reason. This is a safeguard against an incorrect prefix in a generated file, which could delete
    something other than what you expect;
  • an ID that doesn’t refer to anything is identified as such, rather than presented as a permissions
    issue;
  • permissions are those of delete: access to the module, deletion rights on the profile, sharing of
    the record. The operation deletes nothing that delete would have refused;
  • a faulty ID does not cancel the others: valid records in the batch go to the
    trash, rejected IDs are returned in errors with their position;
  • if the ids parameter itself is not readable (invalid JSON, more than 500 elements), the entire call
    is rejected
    : processing half of an incomprehensible batch would be worse than processing
    none of it.

Replayable: re-run without worry #

An ID already in the trash is counted in alreadyDeleted, not in errors. You can
therefore resend the same batch as is after an interruption, without having to sort beforehand what has
already been processed.


Related references 🔗 #

  • Full API reference: deleting one record at a time
  • Queries and filtering: retrieving the IDs to delete
  • Bulk import (upsert): the symmetrical operation, for writing a batch
Index
  • Nothing is erased: this is a move to the trash
  • Bulk deletion – Move a batch to the trash
    • Response
  • Safeguards
  • Replayable: re-run without worry
  • Related references 🔗

An all-in-one software designed for SMEs. Take advantage of the automation capabilities and flexibility of our business management platform to make work easier for all your employees.

RESOURCES

Blog
Brand Guidelines
Distributors
Help
Security

Customer portal
ABOUT

About Us
Contact Us
Cookie Policy
FAQ
Legal Notice
Privacy Policy
Terms of Service

Electronic invoicing compatible solution
French Tech Grand Paris Logo
FINANCE

Accounting
Audits & KPIs
Invoicing
Purchases

MANAGEMENT

Documents
Inventory Management
Maintenance
Project Management

HR

Absence Management
Employees
Recruitment
Timesheets

CUSTOMER SERVICE

Interventions
Service Contracts
Tickets
Warranty Tracking

SALES

CRM
Points of Sale
Sales Automation
Subscriptions

© 2026 Madiasoft - Kafinea

24 rue Louis Blanc, 75010 PARIS, France

+33 1 70 06 05 41

Facebook Linkedin
kafinea logo svg
Gérer le consentement aux cookies
Pour offrir les meilleures expériences, nous utilisons des cookies pour stocker et/ou accéder aux informations des appareils. Le fait de consentir à ces cookies nous permettra de traiter des données telles que le comportement de navigation ou les ID uniques sur ce site. Le fait de ne pas consentir ou de retirer son consentement peut avoir un effet négatif sur certaines caractéristiques et fonctions.
Fonctionnel Always active
Le stockage ou l’accès technique est strictement nécessaire dans la finalité d’intérêt légitime de permettre l’utilisation d’un service spécifique explicitement demandé par l’abonné ou l’internaute, ou dans le seul but d’effectuer la transmission d’une communication sur un réseau de communications électroniques.
Préférences
Le stockage ou l’accès technique est nécessaire dans la finalité d’intérêt légitime de stocker des préférences qui ne sont pas demandées par l’abonné ou la personne utilisant le service.
Statistiques
Le stockage ou l’accès technique qui est utilisé exclusivement à des fins statistiques. Le stockage ou l’accès technique qui est utilisé exclusivement dans des finalités statistiques anonymes. En l’absence d’une assignation à comparaître, d’une conformité volontaire de la part de votre fournisseur d’accès à internet ou d’enregistrements supplémentaires provenant d’une tierce partie, les informations stockées ou extraites à cette seule fin ne peuvent généralement pas être utilisées pour vous identifier.
Marketing
Le stockage ou l’accès technique est nécessaire pour créer des profils d’internautes afin d’envoyer des publicités, ou pour suivre l’internaute sur un site web ou sur plusieurs sites web ayant des finalités marketing similaires.
  • Manage options
  • Manage services
  • Manage {vendor_count} vendors
  • Read more about these purposes
Voir les préférences
  • {title}
  • {title}
  • {title}
  • Features
    • Finance
      • Purchases
      • Audits & KPIs
      • Accounting
      • Invoicing
    • Management
      • Documents
      • Interventions
      • Project Management
      • Inventory Management
    • HR
      • Employees
      • Timesheets
      • Absence Management
      • Recruitment
    • Customer Service
      • Service Contracts
      • Warranty Tracking
      • Maintenance
      • Tickets
    • Sales
      • Subscriptions
      • Sales Automation
      • CRM
      • Points of Sale
    • Cross-Features
      • API
      • Extranet
      • Electronic Signature
      • Workflows
  • Use Cases
  • Pricing
  • Login
  • Discover the demo