Comptabilite.CompteABudget
En bref
8 opérations sur 4 chemins. Préfixe /v2. Authentification JWT (voir Démarrer).
Opérations
| Méthode | Chemin | Rôle |
|---|---|---|
GET |
/v2/compteabudget |
Liste les éléments (GetAll(QueryFilter)) sur le ou les dossiers cible. Paramètres : targets (CSV), limit, offset (pagination SQL, tri cbMarq par défaut avec offset), sort (colonnes SQL, -Col = décroissant), where (tableau JSON de filtres [{column, operator, value}]). Réponse indexée par dossier (meta.dossiers) ; en pagination, meta.pagination.total = Count des filtres (somme des dossiers). Pour des critères riches, utiliser POST …/recherche. Colonne inconnue de la table de l'objet (filtre ou tri) : liste vide sur le dossier et avertissement QUERY.CRITERIA_INVALID dans meta.warnings ; critère portant une autre table : sans effet, avertissement QUERY.CRITERIA_IGNORED (statut 200 inchangé). |
POST |
/v2/compteabudget |
Crée un élément (201). Corps = JSON partiel du DTO. |
PUT |
/v2/compteabudget |
Modifie un élément existant (200). Corps = JSON partiel du DTO, clé comprise. |
DELETE |
/v2/compteabudget |
Supprime un élément (200). Corps = JSON identifiant l'élément (clé). |
GET |
/v2/compteabudget/count |
Compte les éléments répondant aux filtres (Count(QueryFilter) - tri et pagination ignorés) : where en paramètre de requête. Réponse indexée par dossier. Colonne inconnue : 0 et avertissement QUERY.CRITERIA_INVALID ; filtre portant une autre table : QUERY.CRITERIA_IGNORED. |
POST |
/v2/compteabudget/count |
Comptage par critères complets (corps JSON { where:[…] }). |
POST |
/v2/compteabudget/recherche |
Recherche par critères complets - corps JSON au format QueryFilter : { "where":[{ "column":"CT_Num", "operator":"like", "value":"CL%" }, { "column":"CT_Intitule", "operator":"like", "value":"%dupont%", "connector":"OR" }], "orderBy":[{ "column":"CT_Num", "desc":false }], "limit":50, "offset":100 }. Opérateurs : = <> != < <= > >= like, not like, in, not in, is null, is not null, between (values pour in/between). Même réponse et mêmes avertissements que GET (QUERY.CRITERIA_INVALID, QUERY.CRITERIA_IGNORED). |
POST |
/v2/compteabudget/save |
Sauvegarde (upsert : création ou mise à jour selon la présence de la clé). |
Détail
GET /v2/compteabudget
Liste les éléments (GetAll(QueryFilter)) sur le ou les dossiers cible. Paramètres : targets (CSV), limit, offset (pagination SQL, tri cbMarq par défaut avec offset), sort (colonnes SQL, -Col = décroissant), where (tableau JSON de filtres [{column, operator, value}]). Réponse indexée par dossier (meta.dossiers) ; en pagination, meta.pagination.total = Count des filtres (somme des dossiers). Pour des critères riches, utiliser POST …/recherche. Colonne inconnue de la table de l'objet (filtre ou tri) : liste vide sur le dossier et avertissement QUERY.CRITERIA_INVALID dans meta.warnings ; critère portant une autre table : sans effet, avertissement QUERY.CRITERIA_IGNORED (statut 200 inchangé).
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
sort |
query | string |
non | - |
where |
query | string |
non | - |
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X GET "https://<votre-connecteur>/v2/compteabudget?sort=<sort>&where=<where>" \
-H "Authorization: Bearer <jeton>" \
-H "Accept: application/json"
POST /v2/compteabudget
Crée un élément (201). Corps = JSON partiel du DTO.
Corps de la requête (application/json)
Schéma CompteABudgetDto - 5 propriétés (détail : Schémas).
Écriture partielle : seules les propriétés présentes dans le corps sont écrites (voir Conventions).
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X POST "https://<votre-connecteur>/v2/compteabudget" \
-H "Authorization: Bearer <jeton>" \
-H "Content-Type: application/json" \
-d '{"idPlanAnalytique": 0, "numeroSection": "…", "sens": 0}'
PUT /v2/compteabudget
Modifie un élément existant (200). Corps = JSON partiel du DTO, clé comprise.
Corps de la requête (application/json)
Schéma CompteABudgetDto - 5 propriétés (détail : Schémas).
Écriture partielle : seules les propriétés présentes dans le corps sont écrites (voir Conventions).
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X PUT "https://<votre-connecteur>/v2/compteabudget" \
-H "Authorization: Bearer <jeton>" \
-H "Content-Type: application/json" \
-d '{"idPlanAnalytique": 0, "numeroSection": "…", "sens": 0}'
DELETE /v2/compteabudget
Supprime un élément (200). Corps = JSON identifiant l'élément (clé).
Corps de la requête (application/json)
Schéma CompteABudgetDto - 5 propriétés (détail : Schémas).
Écriture partielle : seules les propriétés présentes dans le corps sont écrites (voir Conventions).
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X DELETE "https://<votre-connecteur>/v2/compteabudget" \
-H "Authorization: Bearer <jeton>" \
-H "Content-Type: application/json" \
-d '{"idPlanAnalytique": 0, "numeroSection": "…", "sens": 0}'
GET /v2/compteabudget/count
Compte les éléments répondant aux filtres (Count(QueryFilter) - tri et pagination ignorés) : where en paramètre de requête. Réponse indexée par dossier. Colonne inconnue : 0 et avertissement QUERY.CRITERIA_INVALID ; filtre portant une autre table : QUERY.CRITERIA_IGNORED.
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
where |
query | string |
non | - |
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X GET "https://<votre-connecteur>/v2/compteabudget/count?where=<where>" \
-H "Authorization: Bearer <jeton>" \
-H "Accept: application/json"
POST /v2/compteabudget/count
Comptage par critères complets (corps JSON { where:[…] }).
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X POST "https://<votre-connecteur>/v2/compteabudget/count" \
-H "Authorization: Bearer <jeton>" \
-H "Accept: application/json"
POST /v2/compteabudget/recherche
Recherche par critères complets - corps JSON au format QueryFilter : { "where":[{ "column":"CT_Num", "operator":"like", "value":"CL%" }, { "column":"CT_Intitule", "operator":"like", "value":"%dupont%", "connector":"OR" }], "orderBy":[{ "column":"CT_Num", "desc":false }], "limit":50, "offset":100 }. Opérateurs : = <> != < <= > >= like, not like, in, not in, is null, is not null, between (values pour in/between). Même réponse et mêmes avertissements que GET (QUERY.CRITERIA_INVALID, QUERY.CRITERIA_IGNORED).
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X POST "https://<votre-connecteur>/v2/compteabudget/recherche" \
-H "Authorization: Bearer <jeton>" \
-H "Accept: application/json"
POST /v2/compteabudget/save
Sauvegarde (upsert : création ou mise à jour selon la présence de la clé).
Corps de la requête (application/json)
Schéma CompteABudgetDto - 5 propriétés (détail : Schémas).
Écriture partielle : seules les propriétés présentes dans le corps sont écrites (voir Conventions).
Réponses
| Code | Description | Schéma de data |
|---|---|---|
200 |
OK | - |
401 |
Unauthorized | - |
403 |
Forbidden | - |
Exemple
curl -s -X POST "https://<votre-connecteur>/v2/compteabudget/save" \
-H "Authorization: Bearer <jeton>" \
-H "Content-Type: application/json" \
-d '{"idPlanAnalytique": 0, "numeroSection": "…", "sens": 0}'
Schémas
Schémas résolus à un niveau : les propriétés qui référencent un autre schéma sont citées par leur nom, sans être dépliées.
CompteABudgetDto
CompteABudgetDto - 5 propriétés
| Propriété | Type | Notes |
|---|---|---|
idPlanAnalytique |
integer (int32) |
Plan analytique (N_Analytique). Obligatoire ; non modifiable. |
numeroSection |
string |
nullable, Section analytique de détail (CA_Num). Obligatoire ; non modifiable. |
sens |
integer (int32) |
Sens du budget (CA_BSens) : 0 Charge (défaut), 1 Produit. |
dotations |
tableau de BudgetDotationDto |
nullable, Dotations par série et période (lecture : non nulles ; écriture : seules les dotations transmises). |
sousBudgets |
tableau de CompteABudgetVentilationDto |
nullable, Sous-budget général : ventilation du budget sur des comptes généraux (F_COMPTEABUDGETG). Écriture : liste COMPLÈTE (remplace les ventilations ; absente = inchangées). |