@ix-xs/metamob.api 3.0.21 → 3.0.23

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/README.md CHANGED
@@ -1,6 +1,6 @@
1
- # ![Metamob](https://beta.metamob.fr/img/pierre_dame_small.png) [Metamob](https://beta.metamob.fr)
1
+ # ![Metamob](https://metamob.fr/img/pierre_dame_small.png) [Metamob](https://metamob.fr)
2
2
 
3
- <img align=right src="https://beta.metamob.fr/img/ocre.png">
3
+ <img align=right src="https://metamob.fr/img/ocre.png">
4
4
  <div>
5
5
  <div>
6
6
  <h3>Complétez votre quête du Dofus Ocre</h3>
@@ -126,11 +126,18 @@ Toutes les requêtes retournent un objet JSON **normalisé** avec une structure
126
126
  status: 200,
127
127
  statusText: "OK",
128
128
  data: [
129
- { id: 1, name: "Brial", community: "France", ... },
130
- { id: 2, name: "Rafal", community: "France", ... },
129
+ {
130
+ username: "player1",
131
+ avatar: {
132
+ id: 123,
133
+ name: { fr: "Tofu", en: "Tofu", es: "Tofu" },
134
+ image: "tofu.png"
135
+ },
136
+ last_active: "2026-01-27 14:22:00"
137
+ }
131
138
  ],
132
139
  pagination: {
133
- total: 20,
140
+ total: 5,
134
141
  limit: 20,
135
142
  offset: 0
136
143
  }
@@ -303,28 +310,28 @@ getServers(options?: { server_name?: string })
303
310
 
304
311
  #### Serveurs disponibles
305
312
 
306
- | France | World |
307
- | ---------- | ---------- |
308
- | Brial | Brial |
309
- | Rafal | Rafal |
310
- | Salar | Salar |
311
- | Kourial | Kourial |
312
- | Dakal | Dakal |
313
- | Mikhal | Mikhal |
314
- | Imagiro | Imagiro |
315
- | Hell Mina | Hell Mina |
316
- | Tylezia | Tylezia |
317
- | Orukam | Orukam |
318
- | Tal Kasha | Tal Kasha |
319
- | Draconiros | Draconiros |
320
- | Ombre | Ombre |
321
- | Fallanster | Fallanster |
322
- | Boune | Boune |
323
- | Allisteria | Allisteria |
324
- | Blair | Blair |
325
- | Kelerog | Kelerog |
326
- | Talok | Talok |
327
- | Tiliwan | Tiliwan |
313
+ | Serveur | Communauté | Version |
314
+ | --- | --- | --- |
315
+ | Brial | World | Dofus (Unity) |
316
+ | Rafal | World | Dofus (Unity) |
317
+ | Salar | World | Dofus (Unity) |
318
+ | Kourial | World | Dofus (Unity) |
319
+ | Dakal | World | Dofus (Unity) |
320
+ | Mikhal | World | Dofus (Unity) |
321
+ | Imagiro | France | Dofus (Unity) |
322
+ | Hell Mina | France | Dofus (Unity) |
323
+ | Tylezia | France | Dofus (Unity) |
324
+ | Orukam | France | Dofus (Unity) |
325
+ | Tal Kasha | World | Dofus (Unity) |
326
+ | Draconiros | World | Dofus (Unity) |
327
+ | Ombre | World | Dofus (Unity) |
328
+ | Fallanster | World | Dofus Retro (1.29) |
329
+ | Boune | World | Dofus Retro (1.29)
330
+ | Allisteria | World | Dofus Retro (1.29) |
331
+ | Blair | World | Dofus Touch |
332
+ | Kelerog | France | Dofus Touch
333
+ | Talok | World | Dofus Touch |
334
+ | Tiliwan | France | Dofus Touch |
328
335
 
329
336
  #### Exemples
330
337
 
@@ -360,26 +367,6 @@ if (response.ok) {
360
367
  }
361
368
  ```
362
369
 
363
- **Grouper par communauté**
364
-
365
- ```javascript
366
- const response = await client.getServers();
367
-
368
- if (response.ok) {
369
- const byRegion = response.data.reduce((acc, server) => {
370
- if (!acc[server.community]) acc[server.community] = [];
371
- acc[server.community].push(server.name);
372
- return acc;
373
- }, {});
374
-
375
- console.log(byRegion);
376
- // {
377
- // France: ["Brial", "Rafal", ...],
378
- // World: ["Brial", "Rafal", ...]
379
- // }
380
- }
381
- ```
382
-
383
370
  ---
384
371
 
385
372
  ### Types de monstres
@@ -655,7 +642,6 @@ getUser(username: string)
655
642
  * @property {string} username - Nom d'utilisateur
656
643
  * @property {string} bio - Biographie de l'utilisateur
657
644
  * @property {UserAvatar} avatar - Avatar utilisateur
658
- * @property {string} created_at - Date de création du compte (ISO 8601)
659
645
  * @property {string} last_active - Dernière activité (ISO 8601)
660
646
  */
661
647
  ```
@@ -676,7 +662,6 @@ console.log(`
676
662
  ${user.username}
677
663
  Avatar: ${user.avatar.name.fr}
678
664
  Bio: ${user.bio || "Pas de bio"}
679
- Compte créé: ${new Date(user.created_at).toLocaleDateString("fr-FR")}
680
665
  Dernière activité: ${new Date(user.last_active).toLocaleDateString("fr-FR")}
681
666
  `);
682
667
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ix-xs/metamob.api",
3
- "version": "3.0.21",
3
+ "version": "3.0.23",
4
4
  "description": "API Metamob Javascript",
5
5
  "keywords": [
6
6
  "API",
package/src/MetamobAPI.js CHANGED
@@ -141,6 +141,8 @@ module.exports = class MetamobAPI {
141
141
  }
142
142
 
143
143
  this.#api_key = api_key;
144
+
145
+ this.cache = cache;
144
146
  }
145
147
 
146
148
  /**
@@ -842,7 +844,6 @@ module.exports = class MetamobAPI {
842
844
  * @property {string} username
843
845
  * @property {string} bio
844
846
  * @property {UserAvatar} avatar
845
- * @property {string} created_at
846
847
  * @property {string} last_active
847
848
 
848
849
  * @param {string} username