@communecter/cocolight-api-client 1.0.84 → 1.0.86
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/dist/cocolight-api-client.browser.js +1 -1
- package/dist/cocolight-api-client.cjs +1 -1
- package/dist/cocolight-api-client.mjs.js +1 -1
- package/dist/cocolight-api-client.vite.mjs.js +1 -1
- package/dist/cocolight-api-client.vite.mjs.js.map +1 -1
- package/package.json +1 -1
- package/src/api/Badge.ts +1 -1
- package/src/api/BaseEntity.ts +29 -1
- package/src/api/EndpointApi.ts +1 -1
- package/src/api/EndpointApi.types.ts +15 -7
- package/src/api/Event.ts +1 -1
- package/src/api/Organization.ts +8 -4
- package/src/api/Poi.ts +1 -1
- package/src/api/Project.ts +7 -3
- package/src/api/User.ts +9 -0
- package/src/endpoints.module.ts +122 -156
- package/types/api/BaseEntity.d.ts +8 -1
- package/types/api/EndpointApi.d.ts +1 -1
- package/types/api/EndpointApi.types.d.ts +15 -7
- package/types/api/Organization.d.ts +6 -0
- package/types/api/Project.d.ts +6 -1
- package/types/api/User.d.ts +6 -0
- package/types/endpoints.module.d.ts +248 -5
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { UpdateSettingsData, UpdateBlockDescriptionData, UpdateBlockInfoData, UpdateBlockSocialData, UpdateBlockLocalityData, GetNewsData, GetGalleryData, GlobalAutocompleteCostumData, CostumEventRequestActorsData, CostumEventRequestSubeventsData, CostumEventRequestDatesData, CostumEventRequestElementEventData, CostumEventRequestCategoriesData, CostumEventRequestEventData, CostumEventRequestLinkTlToEventData, CostumEventRequestLoadContextTagData, GetOrganizationsAdminData, GetOrganizationsNoAdminData, GetProjectsAdminData, GetProjectsNoAdminData, GetPoisAdminData, GetPoisNoAdminData, GetSubscribersData, GetBadgesData, CoformAnswersSearchData, SearchMemberAutocompleteData } from "./EndpointApi.types.js";
|
|
1
|
+
import type { UpdateSettingsData, UpdateBlockDescriptionData, UpdateBlockInfoData, UpdateBlockSocialData, UpdateBlockLocalityData, GetNewsData, GetGalleryData, GlobalAutocompleteCostumData, CostumEventRequestActorsData, CostumEventRequestSubeventsData, CostumEventRequestDatesData, CostumEventRequestElementEventData, CostumEventRequestCategoriesData, CostumEventRequestEventData, CostumEventRequestLinkTlToEventData, CostumEventRequestLoadContextTagData, GetOrganizationsAdminData, GetOrganizationsNoAdminData, GetProjectsAdminData, GetProjectsNoAdminData, GetPoisAdminData, GetPoisNoAdminData, GetSubscribersData, GetBadgesData, CoformAnswersSearchData, SearchMemberAutocompleteData, GetEventsData } from "./EndpointApi.types.js";
|
|
2
2
|
import type { TransformsMap } from "../types/entities.js";
|
|
3
3
|
/**
|
|
4
4
|
* Types pour les méthodes d'entité (organization, project, poi, event, badge, news)
|
|
@@ -1038,6 +1038,13 @@ export declare class BaseEntity<TServerData = any> {
|
|
|
1038
1038
|
* @returns - Les données de réponse.
|
|
1039
1039
|
*/
|
|
1040
1040
|
getProjects(data?: Partial<GetProjectsAdminData | GetProjectsNoAdminData>): Promise<PaginatorPage<Project>>;
|
|
1041
|
+
/**
|
|
1042
|
+
* Récupérer les événements d'une entitée : liste des événements de l'entité ou elle est "organizer" ou "attendee".
|
|
1043
|
+
* Constant : GET_EVENTS
|
|
1044
|
+
* @param data - Paramètres (partiels) de recherche/pagination.
|
|
1045
|
+
* @returns - Les données de réponse.
|
|
1046
|
+
*/
|
|
1047
|
+
getEvents(data?: Partial<GetEventsData>): Promise<PaginatorPage<EventEntity>>;
|
|
1041
1048
|
/**
|
|
1042
1049
|
* Récupérer les POIs d'une entité : liste des POIs de l'entité ou elle est "parent".
|
|
1043
1050
|
* Constant : GET_POIS_NO_ADMIN / GET_POIS_ADMIN
|
|
@@ -357,7 +357,7 @@ export declare class EndpointApi {
|
|
|
357
357
|
*/
|
|
358
358
|
searchTags(data: SearchTagsData): Promise<any>;
|
|
359
359
|
/**
|
|
360
|
-
* Afficher les votes d'une
|
|
360
|
+
* Afficher les votes d'une actualité/commentaire : Récupère la liste des votes (like, love, etc.) sur une actualité/commentaire.
|
|
361
361
|
* Constant : SHOW_VOTE
|
|
362
362
|
* @param data - Données envoyées à l'API
|
|
363
363
|
* @returns Les données de réponse.
|
|
@@ -871,7 +871,7 @@ export interface ShowVoteData {
|
|
|
871
871
|
/**
|
|
872
872
|
* Type de l'élément
|
|
873
873
|
*/
|
|
874
|
-
type: "news";
|
|
874
|
+
type: "news" | "comments";
|
|
875
875
|
/**
|
|
876
876
|
* ID de l'élément dont on veut récupérer les votes
|
|
877
877
|
*/
|
|
@@ -3440,17 +3440,13 @@ export interface AssignBadgesData {
|
|
|
3440
3440
|
[k: string]: unknown;
|
|
3441
3441
|
}
|
|
3442
3442
|
export interface GetEventsData {
|
|
3443
|
-
searchType:
|
|
3443
|
+
searchType: "events"[];
|
|
3444
3444
|
indexMin: number;
|
|
3445
3445
|
indexStep: number;
|
|
3446
|
-
/**
|
|
3447
|
-
* Timestamp de début
|
|
3448
|
-
*/
|
|
3449
|
-
startDate: number;
|
|
3450
3446
|
/**
|
|
3451
3447
|
* Date de début (UTC)
|
|
3452
3448
|
*/
|
|
3453
|
-
startDateUTC
|
|
3449
|
+
startDateUTC?: string;
|
|
3454
3450
|
/**
|
|
3455
3451
|
* Date de fin (UTC)
|
|
3456
3452
|
*/
|
|
@@ -3478,6 +3474,18 @@ export interface GetEventsData {
|
|
|
3478
3474
|
count?: boolean;
|
|
3479
3475
|
countType?: unknown[];
|
|
3480
3476
|
fediverse: boolean;
|
|
3477
|
+
/**
|
|
3478
|
+
* Filtrer les événements récurrents (true/false)
|
|
3479
|
+
*/
|
|
3480
|
+
recurrency?: boolean;
|
|
3481
|
+
filters?: {
|
|
3482
|
+
$or?: Record<string, unknown>;
|
|
3483
|
+
/**
|
|
3484
|
+
* This interface was referenced by `undefined`'s JSON-Schema definition
|
|
3485
|
+
* via the `patternProperty` "^links\.attendees\.(?:[a-f0-9]{24}|@\w+)$".
|
|
3486
|
+
*/
|
|
3487
|
+
[k: string]: unknown;
|
|
3488
|
+
};
|
|
3481
3489
|
[k: string]: unknown;
|
|
3482
3490
|
}
|
|
3483
3491
|
export interface ShareEventsData {
|
|
@@ -88,6 +88,12 @@ export declare class Organization extends BaseEntity<OrganizationItemNormalized>
|
|
|
88
88
|
* Récupère les projets de l'organisation.
|
|
89
89
|
*/
|
|
90
90
|
getProjects(data?: Parameters<BaseEntity<OrganizationItemNormalized>["getProjects"]>[0]): Promise<PaginatorPage<import("./Project.js").Project>>;
|
|
91
|
+
/**
|
|
92
|
+
* {@inheritDoc BaseEntity#getEvents}
|
|
93
|
+
*
|
|
94
|
+
* Récupère les événements de l'organisation.
|
|
95
|
+
*/
|
|
96
|
+
getEvents(data?: Parameters<BaseEntity<OrganizationItemNormalized>["getEvents"]>[0]): Promise<PaginatorPage<import("./Event.js").Event>>;
|
|
91
97
|
/**
|
|
92
98
|
* {@inheritDoc BaseEntity#getPois}
|
|
93
99
|
*
|
package/types/api/Project.d.ts
CHANGED
|
@@ -31,7 +31,12 @@ export declare class Project extends BaseEntity<ProjectItemNormalized> {
|
|
|
31
31
|
* Récupère les projets du projet.
|
|
32
32
|
*/
|
|
33
33
|
getProjects(data?: Parameters<BaseEntity<ProjectItemNormalized>["getProjects"]>[0]): Promise<PaginatorPage<Project>>;
|
|
34
|
-
|
|
34
|
+
/**
|
|
35
|
+
* {@inheritDoc BaseEntity#getEvents}
|
|
36
|
+
*
|
|
37
|
+
* Récupère les événements d'un projet.
|
|
38
|
+
*/
|
|
39
|
+
getEvents(data?: Parameters<BaseEntity<ProjectItemNormalized>["getEvents"]>[0]): Promise<PaginatorPage<import("./Event.js").Event>>;
|
|
35
40
|
/**
|
|
36
41
|
* {@inheritDoc BaseEntity#getPois}
|
|
37
42
|
*
|
package/types/api/User.d.ts
CHANGED
|
@@ -169,6 +169,12 @@ export declare class User extends BaseEntity<UserItemNormalized> {
|
|
|
169
169
|
* Récupérer les projets d'un utilisateur : Récupère la liste des projets auxquels l'utilisateur contribue.
|
|
170
170
|
*/
|
|
171
171
|
getProjects(data?: Parameters<BaseEntity<UserItemNormalized>["getProjects"]>[0]): Promise<PaginatorPage<import("./Project.js").Project>>;
|
|
172
|
+
/**
|
|
173
|
+
* {@inheritDoc BaseEntity#getEvents}
|
|
174
|
+
*
|
|
175
|
+
* Récupère les événements d'un utilisateur.
|
|
176
|
+
*/
|
|
177
|
+
getEvents(data?: Parameters<BaseEntity<UserItemNormalized>["getEvents"]>[0]): Promise<PaginatorPage<import("./Event.js").Event>>;
|
|
172
178
|
/**
|
|
173
179
|
* {@inheritDoc BaseEntity#getPois}
|
|
174
180
|
*
|