Documentation · API REST · CRM & Ventes

API Tiers (Clients & Fournisseurs) : endpoints et champs

En bref

L’API Tiers (Clients & Fournisseurs) d’IRPEA expose la ressource /api/v1/entities en GET, POST, PUT, PATCH et DELETE, avec 171 champs documentés, filtrables et triables, sous une clé d’API porteuse limitée au dossier, pour lire ou écrire ces données depuis un autre logiciel du groupe « CRM & Ventes ».

Page mise à jour le

À quoi sert la ressource « Tiers (Clients & Fournisseurs) » ?

Fiches TIERS : clients, fournisseurs, adhérents (un tiers peut être les deux), porte l’identité légale, les coordonnées, les contacts et adresses embarqués, les comptes comptables auxiliaires, le mandat SEPA, le canal de facturation électronique et le portail client

Quels endpoints sont disponibles ?

Méthodes réellement acceptées par la route /api/v1/entities
MéthodeAdresseAction
GET/api/v1/entities et /{id}lire (liste paginée ou un élément par identifiant)
POST/api/v1/entitiescréer un élément
PUT/api/v1/entities/{id}remplacer un élément
PATCH/api/v1/entities/{id}modifier certains champs
DELETE/api/v1/entities/{id}supprimer un élément

Quels champs contient la ressource « Tiers (Clients & Fournisseurs) » ?

Champs déclarés de /api/v1/entities (interrogeables en filtre et en tri)
ChampType et description
registrationNumberstring
versionnumber (concurrence optimiste : incrémentée à chaque enregistrement, une écriture sur une version périmée est fusionnée par champ ou refusée en conflit)
gdprConsentDateISO8601 — preuve du consentement (art. 7-1 RGPD)
gdprConsentSourcestring — canal/source du consentement
gdprConsentPurposestring — finalité
gdprConsentWithdrawnAtISO8601 — date du RETRAIT du consentement (art. 7 §3), sans elle, une case décochée ne prouve rien : un consentement jamais donné et un consentement retiré seraient indistinguables
gdprConsentWithdrawnSourcestring — origine du retrait (lien public en un clic, saisie en fiche, propagation depuis le registre unique services/consentLedgerService.ts)
idstring
tenantIdstring
typeclient|supplier|both|adherent
socialReasonstring
siretstring
vatNumberstring
ibanstring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
emailstring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
phonestring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
statusstring
namestring
commercialNamestring
apeCodestring
dunsNumberstring
registrationCountrystring
shareCapitalstring
legalStatusstring
address1string — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
address2string — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
postalCodestring
citystring
countrystring
countryCodestring
regionstring
mobilestring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
websitestring
linkedinstring
twitterstring
facebookstring — page Facebook du tiers
contactsContactPerson[] — contacts embarqués sur la fiche, firstName, lastName, email, phone, mobile et birthDate y sont CHIFFRÉS au repos et déchiffrés à la lecture
addressesAddress[] — adresses embarquées, address1 et address2 y sont CHIFFRÉS au repos
clientCodestring
supplierCodestring
clientSegmentstring
acquisitionChannelstring
priorityScorestring
gdprConsentboolean
currencystring
creditLimitnumber
paymentTermsDaysnumber
preferredPaymentModestring
discountPercentnumber
priceGridstring
accountingAccountCustomerstring — compte auxiliaire client (411xxx)
accountingAccountSupplierstring — compte auxiliaire fournisseur (401xxx)
legalStatusDetailstring
rcsNumberstring
rmNumberstring
greffestring
eoriNumberstring
fiscalRegimestring
isVatOnPaymentboolean — TVA sur les encaissements pour ce tiers (exigibilité)
sepaMandateRumstring
sepaMandateDatestring
sepaMandateSchemeCORE|B2B — schéma du mandat de prélèvement
sepaMandateOneOffboolean
sepaMandateFirstCollectedAtstring
sepaMandateRevokedAtstring
capitalSocialAmountnumber
capitalSocialCurrencystring
nafCodestring
einvoicingStatusactive|pending|refused — état du raccordement du tiers
pdpIdentifierstring
ppfIdentifierstring
routingCodestring
einvoicingMethodpdp|ppf|chorus — canal de transmission de la facture électronique
einvoicingEmailstring
acceptedInvoiceFormatsstring[] — formats acceptés (Factur-X, UBL, CII)
portalEnabledboolean — accès au portail client ouvert
portalUserIdstring — compte du portail rattaché au tiers
portalInvitedAtstring
clientGroupstring
sectorstring
employeeCountnumber
languagestring
supplierCategorystring
supplierTypestring
bicstring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
bankNamestring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
bankAddressstring — CHIFFRÉ au repos (services/cryptoService.ts) mais DÉCHIFFRÉ par db.getAll : servi EN CLAIR
latePaymentPenaltyPercentnumber
creditInsuranceLimitnumber
fiscalYearEndstring
consolidationMethodstring
vatExemptionReasonstring
paymentReminderExclusionboolean
automaticRemindersboolean
outstandingBalancenumber
earlyPaymentDiscountPercentnumber
costCenterstring
analyticCodestring
billingCurrencystring
preferredWarehouseIdstring
preferredCarrierIdstring
deliverySlotStartstring
deliverySlotEndstring
moqnumber
avgLeadTimeDaysnumber
incotermstring
shippingInstructionsstring
backOrderAllowedboolean
freeShippingThresholdnumber
geoZonestring
internalReferencestring
glnNumberstring
receptionWarehouseIdstring
supplierReferencestring
supplyLeadTimenumber
minOrderAmountnumber
purchasingFamilystring
buyerIdstring
healthStatusoptimal|warning|critical|dormant
riskLevelLow|Medium|High|Extreme
qualityScorenumber
deliverySpeedScorenumber
priceIndexScorenumber
churnProbabilitynumber
npsScorenumber
nonConformityCountnumber
improvementPlanstring
rcInsurancestring
accountManagerIdstring
salesTeamIdstring
marketingSegmentstring
ediIdentifierstring
isBlacklistedboolean
blacklistReasonstring — motif du blocage (Achats → Conformité, statut Suspendu ou Blacklisté)
modernSlaveryStatementboolean — déclaration contre l’esclavage moderne (cartographie RSE, note RSE suggérée)
marketingOptInboolean
marketingOptInDateISO8601 — date de l’accord de prospection (posée par la boutique en ligne avec la case consentement, lib/ecommerce/ecomFacturation.ts)
paymentBlockboolean — blocage de paiement du compte client : même effet que le blocage de la fiche, la commande est refusée (lib/collections/blocageEncours.ts, portail B2B)
leadSourcestring
campaignIdstring
internalNotesstring
contractNumberstring
contractTypestring
contractStartDatestring
contractEndDatestring
slaLevelstring
specialConditionsstring
autoRenewalboolean
frameworkContractRefstring
carbonFootprintIndexnumber
csrRatingstring
ethicsSignatoryboolean
iso9001Certifiedboolean
iso14001Certifiedboolean
iso27001Certifiedboolean
decennialInsuranceRefstring
decennialInsuranceExpirystring
laborComplianceVerifiedboolean
laborComplianceExpirystring
genderEqualityIndexnumber
antiCorruptionPolicyboolean
externalAuditorstring
tagsstring[]
customFieldsRecord<string, any>
isSoftDeletedboolean — fiche archivée (jamais purgée : les pièces comptables la référencent)
logoUrlstring
attachmentsstring[]
mergedIntoEntityIdstring — fiche absorbante après fusion de doublons
mergedAtstring
createdAtstring
updatedAtstring

Comment filtrer, trier et paginer ?

Exemple de lecture filtrée et triée : GET /api/v1/entities?filter[registrationNumber]=…&sort=version:desc&limit=50.

Le filtre est une égalité stricte sur un champ déclaré, le tri s’écrit champ:asc ou champ:desc, la page contient 50 éléments par défaut et 200 au plus, un champ inconnu renvoie une erreur 400 plutôt qu’un résultat faux.

Quelles autorisations faut-il ?

  • Une offre qui inclut l’API publique : Enterprise.
  • Une clé d’API créée dans Système › Intégrations, envoyée dans l’en-tête Authorization: Bearer, limitée au dossier qui l’a émise.
  • Une portée accordée à la clé pour cette ressource : lecture, écriture et suppression.

Questions fréquentes

Comment lire « Tiers (Clients & Fournisseurs) » par API ?

Envoyez GET /api/v1/entities avec la clé d’API en en-tête Authorization: Bearer, la réponse contient les données, le total et les liens de pagination.

Peut-on créer ou modifier « Tiers (Clients & Fournisseurs) » par API ?

Oui, la route accepte POST, PUT, PATCH et DELETE sur cette ressource, dans la limite de la portée accordée à la clé.

L’API est-elle incluse dans l’essai gratuit ?

La démo gratuite de 30 jours ouvre toutes les fonctions, l’API comprise, sur des données d’exemple.

Essayer IRPEA ERP sur vos données

Démo gratuite, démo gratuite, toutes les fonctions ouvertes, aucun moyen de paiement demandé.

Version texte pour les assistants : /md/aide-erp/api/tiers-clients-fournisseurs