@communecter/cocolight-api-client 1.0.125 → 1.0.127

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@communecter/cocolight-api-client",
3
- "version": "1.0.125",
3
+ "version": "1.0.127",
4
4
  "description": "Client Axios simplifié pour l'API cocolight",
5
5
  "repository": {
6
6
  "type": "git",
@@ -5500,9 +5500,9 @@ export interface CostumProjectActionRequestNewData {
5500
5500
  */
5501
5501
  name: string;
5502
5502
  /**
5503
- * Statut de l'action
5503
+ * Statut de l'action. Sert aussi de trigger côté backend : 'done' ajoute startDate/endDate auto, 'tracking' active le mode tracking, 'discuter'/'next'/'totest' ajoutent un tag.
5504
5504
  */
5505
- status: string;
5505
+ status: "todo" | "done" | "tracking" | "discuter" | "next" | "totest" | "disabled" | "closed";
5506
5506
  /**
5507
5507
  * ID du projet parent
5508
5508
  */
@@ -5512,13 +5512,74 @@ export interface CostumProjectActionRequestNewData {
5512
5512
  */
5513
5513
  parentType: "projects";
5514
5514
  /**
5515
- * Montant financé
5515
+ * Montant financé (default: 1)
5516
5516
  */
5517
- credits: number;
5517
+ credits?: number;
5518
5518
  /**
5519
- * ID du jalon associé
5519
+ * Jalon associé à l'action
5520
5520
  */
5521
- "milestone[milestoneId]": string;
5521
+ milestone?: {
5522
+ /**
5523
+ * ID du jalon associé
5524
+ */
5525
+ milestoneId: string;
5526
+ /**
5527
+ * Date de début du jalon (ISO 8601, convertie en MongoDate UTC côté backend)
5528
+ */
5529
+ startDate?: string;
5530
+ /**
5531
+ * Date de fin du jalon (ISO 8601, convertie en MongoDate UTC côté backend)
5532
+ */
5533
+ endDate?: string;
5534
+ };
5535
+ /**
5536
+ * Date et heure de début (ISO 8601 avec offset)
5537
+ */
5538
+ startDate?: string;
5539
+ /**
5540
+ * Date et heure de fin (ISO 8601 avec offset)
5541
+ */
5542
+ endDate?: string;
5543
+ /**
5544
+ * Temps passé en minutes (utilisé pour calculer endDate quand status=done)
5545
+ */
5546
+ timeSpent?: number;
5547
+ /**
5548
+ * Nombre minimum de contributeurs
5549
+ */
5550
+ min?: number;
5551
+ /**
5552
+ * Nombre maximum de contributeurs (doit être >= min côté backend)
5553
+ */
5554
+ max?: number;
5555
+ /**
5556
+ * Niveau d'importance de l'action
5557
+ */
5558
+ importance?: string;
5559
+ /**
5560
+ * ID de la room parente. Si absent, auto-créée par Room::getOrCreateActionRoom côté backend
5561
+ */
5562
+ idParentRoom?: string;
5563
+ /**
5564
+ * Si true, ajoute l'auteur courant comme contributor admin. ATTENTION : écrasé si 'mentions' est aussi fourni.
5565
+ */
5566
+ is_contributor?: boolean;
5567
+ /**
5568
+ * userId à assigner comme contributor admin. ATTENTION : écrasé si 'mentions' est aussi fourni.
5569
+ */
5570
+ assign?: string;
5571
+ /**
5572
+ * URLs externes associées à l'action (tableau de strings, ou "" pour vider). Passthrough côté backend.
5573
+ */
5574
+ urls?: string[] | "";
5575
+ /**
5576
+ * Liste des contributeurs assignés à l'action par username. Résolu côté backend en links.contributors.{userId}. ATTENTION : ÉCRASE 'assign' et 'is_contributor' si fournis ensemble.
5577
+ */
5578
+ mentions?: string[];
5579
+ /**
5580
+ * Liste des tags associés à l'action. BUG CONNU BACKEND : les tags sont dupliqués dans la réponse (array_merge avec soi-même côté PHP).
5581
+ */
5582
+ tags?: string[];
5522
5583
  [k: string]: unknown;
5523
5584
  }
5524
5585
 
@@ -12,6 +12,12 @@ export interface AnswerLinksBlock {
12
12
  answered: string[];
13
13
  }
14
14
 
15
+ export interface AnswerProjectRef {
16
+ id?: string;
17
+ type?: string;
18
+ name?: string;
19
+ }
20
+
15
21
  export interface AnswerItemJson {
16
22
  _id: IdObject;
17
23
  collection: "answers";
@@ -25,10 +31,11 @@ export interface AnswerItemJson {
25
31
  form?: string;
26
32
  modified?: DateValue;
27
33
  voteCount?: Record<string, number>;
28
- vote: Record<string, {
34
+ vote?: Record<string, {
29
35
  status: string;
30
36
  date: DateValue;
31
37
  }>;
38
+ project?: AnswerProjectRef;
32
39
  [key: string]: unknown;
33
40
  }
34
41
 
@@ -46,9 +53,10 @@ export interface AnswerItemNormalized {
46
53
  form?: string;
47
54
  modified?: Date;
48
55
  voteCount?: Record<string, number>;
49
- vote: Record<string, {
56
+ vote?: Record<string, {
50
57
  status: string;
51
58
  date: Date;
52
59
  }>;
60
+ project?: AnswerProjectRef;
53
61
  [key: string]: unknown;
54
62
  }
@@ -65,6 +65,7 @@ export interface ProjectItemJson {
65
65
  socialNetwork?: SocialNetwork;
66
66
  email?: string;
67
67
  url?: string;
68
+ answer?: string;
68
69
  [key: string]: unknown;
69
70
  }
70
71
 
@@ -94,5 +95,6 @@ export interface ProjectItemNormalized {
94
95
  socialNetwork?: SocialNetwork;
95
96
  email?: string;
96
97
  url?: string;
98
+ answer?: string;
97
99
  [key: string]: unknown;
98
100
  }