@linebundle-sdk/ts 1.0.0-rc.3 → 1.0.0-rc.5
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/esm/index.d.ts +14622 -3
- package/esm/index.js +7854 -2
- package/esm/index.js.map +1 -1
- package/package.json +4 -13
- package/tsup.config.ts +11 -0
- package/esm/client/client.gen.d.ts +0 -3
- package/esm/client/client.gen.d.ts.map +0 -1
- package/esm/client/client.gen.js +0 -236
- package/esm/client/client.gen.js.map +0 -1
- package/esm/client/index.d.ts +0 -9
- package/esm/client/index.d.ts.map +0 -1
- package/esm/client/index.js +0 -7
- package/esm/client/index.js.map +0 -1
- package/esm/client/types.gen.d.ts +0 -118
- package/esm/client/types.gen.d.ts.map +0 -1
- package/esm/client/types.gen.js +0 -3
- package/esm/client/types.gen.js.map +0 -1
- package/esm/client/utils.gen.d.ts +0 -34
- package/esm/client/utils.gen.d.ts.map +0 -1
- package/esm/client/utils.gen.js +0 -231
- package/esm/client/utils.gen.js.map +0 -1
- package/esm/client.gen.d.ts +0 -13
- package/esm/client.gen.d.ts.map +0 -1
- package/esm/client.gen.js +0 -4
- package/esm/client.gen.js.map +0 -1
- package/esm/core/auth.gen.d.ts +0 -19
- package/esm/core/auth.gen.d.ts.map +0 -1
- package/esm/core/auth.gen.js +0 -15
- package/esm/core/auth.gen.js.map +0 -1
- package/esm/core/bodySerializer.gen.d.ts +0 -26
- package/esm/core/bodySerializer.gen.d.ts.map +0 -1
- package/esm/core/bodySerializer.gen.js +0 -58
- package/esm/core/bodySerializer.gen.js.map +0 -1
- package/esm/core/params.gen.d.ts +0 -44
- package/esm/core/params.gen.d.ts.map +0 -1
- package/esm/core/params.gen.js +0 -101
- package/esm/core/params.gen.js.map +0 -1
- package/esm/core/pathSerializer.gen.d.ts +0 -34
- package/esm/core/pathSerializer.gen.d.ts.map +0 -1
- package/esm/core/pathSerializer.gen.js +0 -107
- package/esm/core/pathSerializer.gen.js.map +0 -1
- package/esm/core/queryKeySerializer.gen.d.ts +0 -19
- package/esm/core/queryKeySerializer.gen.d.ts.map +0 -1
- package/esm/core/queryKeySerializer.gen.js +0 -93
- package/esm/core/queryKeySerializer.gen.js.map +0 -1
- package/esm/core/serverSentEvents.gen.d.ts +0 -72
- package/esm/core/serverSentEvents.gen.d.ts.map +0 -1
- package/esm/core/serverSentEvents.gen.js +0 -134
- package/esm/core/serverSentEvents.gen.js.map +0 -1
- package/esm/core/types.gen.d.ts +0 -79
- package/esm/core/types.gen.d.ts.map +0 -1
- package/esm/core/types.gen.js +0 -3
- package/esm/core/types.gen.js.map +0 -1
- package/esm/core/utils.gen.d.ts +0 -20
- package/esm/core/utils.gen.d.ts.map +0 -1
- package/esm/core/utils.gen.js +0 -88
- package/esm/core/utils.gen.js.map +0 -1
- package/esm/index.d.ts.map +0 -1
- package/esm/sdk.gen.d.ts +0 -1854
- package/esm/sdk.gen.d.ts.map +0 -1
- package/esm/sdk.gen.js +0 -3875
- package/esm/sdk.gen.js.map +0 -1
- package/esm/types.gen.d.ts +0 -12463
- package/esm/types.gen.d.ts.map +0 -1
- package/esm/types.gen.js +0 -3
- package/esm/types.gen.js.map +0 -1
- package/esm/zod.gen.d.ts +0 -8634
- package/esm/zod.gen.d.ts.map +0 -1
- package/esm/zod.gen.js +0 -4430
- package/esm/zod.gen.js.map +0 -1
package/esm/sdk.gen.js
DELETED
|
@@ -1,3875 +0,0 @@
|
|
|
1
|
-
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
|
-
import { formDataBodySerializer } from './client';
|
|
3
|
-
import { client } from './client.gen';
|
|
4
|
-
import { zAiAgentCancelWorkflowData, zAiAgentCancelWorkflowResponse, zAiAgentCreateSessionData, zAiAgentCreateSessionResponse, zAiAgentGetSessionCostsData, zAiAgentGetSessionCostsResponse, zAiAgentGetSessionData, zAiAgentGetSessionResponse, zAiAgentListSessionsData, zAiAgentListSessionsResponse, zAiAgentListWorkflowsData, zAiAgentListWorkflowsResponse, zAiAgentSendMessage2Data, zAiAgentSendMessage2Response, zAiAgentSendMessageData, zAiAgentSendMessageResponse, zAiAgentsGetOrgCostsData, zAiAgentsGetOrgCostsResponse, zAiAgentStartWorkflowAsyncData, zAiAgentStartWorkflowAsyncResponse, zAiAgentStartWorkflowData, zAiAgentStartWorkflowResponse, zAIDeleteSessionData, zAIDeleteSessionResponse, zAiWorkflowsGetExecutionDetailsData, zAiWorkflowsGetExecutionDetailsResponse, zAnalyticGetDashboardData, zAnalyticGetDashboardResponse, zAnalyticGetTotalsData, zAnalyticGetTotalsResponse, zAuditLogsGetPermissionStatsData, zAuditLogsGetPermissionStatsResponse, zAuditLogsListPermissionsData, zAuditLogsListPermissionsResponse, zAuthContextsGetData, zAuthContextsGetResponse, zAutomationCronHealthCheckData, zAutomationCronTriggerScheduledData, zAutomationMetadataGetActionsData, zAutomationMetadataGetActionsResponse, zAutomationMetadataGetTaskData, zAutomationMetadataGetTaskResponse, zAutomationMetadataGetTasksData, zAutomationMetadataGetTasksResponse, zAutomationMetadataGetTriggersData, zAutomationMetadataGetTriggersResponse, zAutomationRulesCreateData, zAutomationRulesCreateResponse, zAutomationRulesDeleteData, zAutomationRulesDeleteResponse, zAutomationRulesExecuteData, zAutomationRulesExecuteResponse, zAutomationRulesGetConditionsData, zAutomationRulesGetConditionsResponse, zAutomationRulesGetData, zAutomationRulesGetExecutionsData, zAutomationRulesGetExecutionsResponse, zAutomationRulesGetMetadataData, zAutomationRulesGetMetadataResponse, zAutomationRulesGetResponse, zAutomationRulesListData, zAutomationRulesListResponse, zAutomationRulesPatchData, zAutomationRulesPatchResponse, zAutomationRulesUpdateData, zAutomationRulesUpdateResponse, zBookingCreateData, zBookingCreateResponse, zBookingsCheckAvailabilityData, zBookingsCheckAvailabilityResponse, zBookingsDeleteData, zBookingsDeleteResponse, zBookingsGetByIdData, zBookingsGetByIdResponse, zBookingsGetPlaceScheduleData, zBookingsGetPlaceScheduleResponse, zBookingsListData, zBookingsListResponse, zBookingsUpdateData, zBookingsUpdateResponse, zChatMessagesDeleteData, zChatMessagesDeleteResponse, zChatMessagesGetCountData, zChatMessagesGetCountResponse, zChatMessagesGetUnreadCountData, zChatMessagesGetUnreadCountResponse, zChatMessagesListData, zChatMessagesListResponse, zChatMessagesMarkReadData, zChatMessagesMarkReadResponse, zChatRoomsAddMemberData, zChatRoomsAddMemberResponse, zChatRoomsCreateDirectData, zChatRoomsCreateDirectResponse, zChatRoomsCreateGroupData, zChatRoomsCreateGroupResponse, zChatRoomsGetByIdData, zChatRoomsGetByIdResponse, zChatRoomsListData, zChatRoomsListMembersData, zChatRoomsListMembersResponse, zChatRoomsListResponse, zChatRoomsRemoveMemberData, zChatRoomsRemoveMemberResponse, zChatRoomsUpdateData, zChatRoomsUpdateResponse, zConnectWebSocketData, zContactsCreateData, zContactsCreateResponse, zContactsDeleteData, zContactsDeleteResponse, zContactsGetData, zContactsGetResponse, zContactsListData, zContactsListResponse, zContactsSearchData, zContactsSearchResponse, zContactsToggleFavoriteData, zContactsToggleFavoriteResponse, zContactsUpdateData, zContactsUpdateResponse, zCustomRolesAddPermissionData, zCustomRolesAssignToUserData, zCustomRolesCreateData, zCustomRolesCreateResponse, zCustomRolesGetData, zCustomRolesGetMyPermissionsData, zCustomRolesGetMyPermissionsResponse, zCustomRolesGetResponse, zCustomRolesListData, zCustomRolesListResponse, zCustomRolesRemovePermissionData, zCustomRolesRemovePermissionResponse, zCustomRolesRemoveUserRoleData, zCustomRolesRemoveUserRoleResponse, zCustomRolesSetPermissionsData, zCustomRolesUpdateData, zCustomRolesUpdateResponse, zEventAttendeesAddBulkData, zEventAttendeesAddBulkResponse, zEventAttendeesAddData, zEventAttendeesAddResponse, zEventAttendeesCheckInData, zEventAttendeesCheckInResponse, zEventAttendeesGetData, zEventAttendeesGetResponse, zEventAttendeesRemoveBulkData, zEventAttendeesRemoveBulkResponse, zEventAttendeesRemoveData, zEventAttendeesRemoveResponse, zEventAttendeesUpdateBulkStatusData, zEventAttendeesUpdateBulkStatusResponse, zEventAttendeesUpdateData, zEventAttendeesUpdateResponse, zEventCompareVersionsData, zEventDocumentsAddDocumentData, zEventDocumentsGetDocumentsData, zEventDocumentsGetDocumentsResponse, zEventDocumentsRemoveData, zEventDocumentsRemoveResponse, zEventGetData, zEventGetLatestVersionData, zEventGetLatestVersionResponse, zEventGetResponse, zEventGetSectionSettingsData, zEventGetSectionSettingsResponse, zEventGetVersionData, zEventGetVersionResponse, zEventLocationGetData, zEventLocationGetResponse, zEventLocationUpdateData, zEventLocationUpdateResponse, zEventsArchiveData, zEventsCreateData, zEventsCreateResponse, zEventsDeleteData, zEventsFilterAdvancedData, zEventsFilterAdvancedResponse, zEventsGetSectionContentData, zEventsGetSectionContentResponse, zEventsGetSectionIdentificationData, zEventsGetSectionIdentificationResponse, zEventsGetSettingsData, zEventsGetSettingsResponse, zEventsGetSocialFeedData, zEventsGetSocialFeedResponse, zEventsGetTimezonesData, zEventsGetTimezonesResponse, zEventsListBySpaceData, zEventsListBySpaceResponse, zEventsListCalendarData, zEventsListCalendarResponse, zEventsListData, zEventsListResponse, zEventsListVersionsData, zEventsPatchContentData, zEventsPatchContentResponse, zEventsPatchIdentificationData, zEventsPatchIdentificationResponse, zEventsPatchSettingsData, zEventsPatchSettingsResponse, zEventsPublishData, zEventsPublishVersionData, zEventsPublishWithNotificationsData, zEventsRollbackVersionData, zEventsRollbackVersionResponse, zEventsTransferData, zEventsTransferResponse, zEventsUpdateCoverData, zEventsUpdateCoverResponse, zEventTimelineCreateMilestoneData, zEventTimelineCreateMilestoneResponse, zEventTimelineGetData, zEventTimelineGetPublishedData, zEventTimelineGetPublishedResponse, zEventTimelineGetResponse, zEventTimelineLinkMilestoneData, zEventTimelineUnlinkData, zEventTimezonesValidateData, zEventTimezonesValidateResponse, zEventUnpublishVersionData, zEventUnpublishVersionResponse, zEventUpdateData, zEventUpdateResponse, zFeaturesGetData, zGetLatestPublicEventVersionData, zGetLatestPublicEventVersionResponse, zGetLatestPublicSpaceVersionData, zGetLatestPublicSpaceVersionResponse, zHandleUserCreatedApiV1IntegrationUserCreatedPostData, zHandleUserUpdatedApiV1IntegrationUserUpdatedPostData, zHealthCheckAutomationData, zHealthCheckData, zHealthNotificationsCheckData, zIntegrationHandleOrgRemovedData, zIntegrationUserHandleRemovedData, zMetricsGetData, zOrganizationsArchiveData, zOrganizationsArchiveResponse, zOrganizationsCreateData, zOrganizationsCreateInviteData, zOrganizationsCreateInviteResponse, zOrganizationsCreateResponse, zOrganizationsDeleteInviteData, zOrganizationsDeleteInviteResponse, zOrganizationsGetByIdData, zOrganizationsGetByIdResponse, zOrganizationsGetCurrentData, zOrganizationsGetCurrentResponse, zOrganizationsGetInvitesData, zOrganizationsGetInvitesResponse, zOrganizationsListData, zOrganizationsListResponse, zOrganizationsUpdateData, zOrganizationsUpdateResponse, zPermissionsGetData, zPermissionsGetResponse, zPermissionsListData, zPermissionsListResponse, zPlaceArchiveData, zPlacePublishData, zPlacesCreateData, zPlacesCreateResponse, zPlacesDeleteData, zPlacesGetData, zPlacesGetResponse, zPlacesListData, zPlacesListResponse, zPlacesUpdateData, zPlacesUpdateResponse, zRealtimeGetInfoData, zRolesDeleteData, zRolesDeleteResponse, zSentryTriggerErrorData, zSpaceArchiveData, zSpaceAssignUserToRoleData, zSpaceBulkUpdateParentData, zSpaceBulkUpdateParentResponse, zSpaceContactsAddBulkData, zSpaceContactsAddBulkResponse, zSpaceContactsAddData, zSpaceContactsAddResponse, zSpaceContactsBulkDeleteData, zSpaceContactsBulkDeleteResponse, zSpaceContactsCountData, zSpaceContactsCountResponse, zSpaceContactsGetContactsBySpaceData, zSpaceContactsGetContactsBySpaceResponse, zSpaceContactsGetData, zSpaceContactsGetResponse, zSpaceContactsGetSpacesByContactData, zSpaceContactsGetSpacesByContactResponse, zSpaceContactsRemoveData, zSpaceContactsRemoveResponse, zSpaceDocumentsAddData, zSpaceDocumentsGetData, zSpaceDocumentsGetResponse, zSpaceDocumentsRemoveData, zSpaceDocumentsRemoveResponse, zSpaceEventsAddData, zSpaceEventsAddResponse, zSpaceEventsBulkAddData, zSpaceEventsBulkAddResponse, zSpaceEventsBulkRemoveData, zSpaceEventsBulkRemoveResponse, zSpaceEventsCountData, zSpaceEventsCountResponse, zSpaceEventsGetByIdData, zSpaceEventsGetByIdResponse, zSpaceEventsGetData, zSpaceEventsGetEventSpacesData, zSpaceEventsGetEventSpacesResponse, zSpaceEventsGetResponse, zSpaceEventsRemoveEventData, zSpaceEventsRemoveEventResponse, zSpaceGetLatestVersionData, zSpaceGetLatestVersionResponse, zSpaceGetUserRolesData, zSpaceGetUserRolesResponse, zSpacePublishData, zSpaceRolesAssignPermissionData, zSpaceRolesCreateData, zSpaceRolesCreateResponse, zSpaceRolesDeleteData, zSpaceRolesDeleteResponse, zSpaceRolesGetData, zSpaceRolesGetResponse, zSpaceRolesListRolesData, zSpaceRolesListRolesResponse, zSpaceRolesRemovePermissionData, zSpaceRolesRemovePermissionResponse, zSpaceRolesUpdateRoleData, zSpaceRolesUpdateRoleResponse, zSpacesAddMemberData, zSpacesAddMemberResponse, zSpacesCompareVersionsData, zSpacesCompareVersionsResponse, zSpacesCreateSpaceData, zSpacesCreateSpaceResponse, zSpacesCreateWithParentData, zSpacesCreateWithParentResponse, zSpacesDeleteByIdData, zSpacesDetachParentData, zSpacesDetachParentResponse, zSpacesGetByIdData, zSpacesGetByIdResponse, zSpacesGetHierarchyData, zSpacesGetHierarchyResponse, zSpacesGetJoinableByUserData, zSpacesGetJoinableByUserResponse, zSpacesGetMembersData, zSpacesGetMembersResponse, zSpacesGetParentData, zSpacesGetParentResponse, zSpacesGetVersionData, zSpacesGetVersionResponse, zSpacesJoinData, zSpacesJoinResponse, zSpacesListChildrenData, zSpacesListChildrenResponse, zSpacesListData, zSpacesListResponse, zSpacesListVersionsData, zSpacesListVersionsResponse, zSpacesPublishVersionData, zSpacesPublishVersionResponse, zSpacesRemoveMemberData, zSpacesRemoveUserFromRoleData, zSpacesRemoveUserFromRoleResponse, zSpacesRollbackData, zSpacesRollbackResponse, zSpacesUnpublishData, zSpacesUnpublishResponse, zSpacesUpdateParentData, zSpacesUpdateParentResponse, zSpaceTestAuthData, zSpaceTransferData, zSpaceTransferResponse, zSpaceUpdateData, zSpaceUpdateMemberRoleData, zSpaceUpdateMemberRoleResponse, zSpaceUpdateResponse, zUserCreateAssistantData, zUserCreateAssistantResponse, zUserGetAssistantData, zUserGetAssistantResponse, zUserGetProfileData, zUserGetProfileResponse, zUserListData, zUserListResponse, zUsersDeleteAvatarData, zUsersDeleteAvatarResponse, zUsersGetAvatarByIdData, zUsersGetAvatarData, zUsersGetCurrentProfileData, zUsersGetCurrentProfileResponse, zUsersSearchData, zUsersSearchResponse, zUserUpdateProfileData, zUserUpdateProfileResponse, zUserUploadAvatarData, zUserUploadAvatarResponse } from './zod.gen';
|
|
5
|
-
class HeyApiClient {
|
|
6
|
-
constructor(args) {
|
|
7
|
-
this.client = args?.client ?? client;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
class HeyApiRegistry {
|
|
11
|
-
constructor() {
|
|
12
|
-
this.defaultKey = 'default';
|
|
13
|
-
this.instances = new Map();
|
|
14
|
-
}
|
|
15
|
-
get(key) {
|
|
16
|
-
const instance = this.instances.get(key ?? this.defaultKey);
|
|
17
|
-
if (!instance) {
|
|
18
|
-
throw new Error(`No SDK client found. Create one with "new Linebundle()" to fix this error.`);
|
|
19
|
-
}
|
|
20
|
-
return instance;
|
|
21
|
-
}
|
|
22
|
-
set(value, key) {
|
|
23
|
-
this.instances.set(key ?? this.defaultKey, value);
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
export class User extends HeyApiClient {
|
|
27
|
-
/**
|
|
28
|
-
* Get Assistant
|
|
29
|
-
*
|
|
30
|
-
* Get the current user's AI assistant if it exists.
|
|
31
|
-
*/
|
|
32
|
-
getAssistant(options) {
|
|
33
|
-
return (options?.client ?? this.client).get({
|
|
34
|
-
requestValidator: async (data) => await zUserGetAssistantData.parseAsync(data),
|
|
35
|
-
responseValidator: async (data) => await zUserGetAssistantResponse.parseAsync(data),
|
|
36
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
37
|
-
url: '/api/v1/user/assistant',
|
|
38
|
-
...options
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* Create Assistant
|
|
43
|
-
*
|
|
44
|
-
* Create a personal AI assistant for the current user.
|
|
45
|
-
*/
|
|
46
|
-
createAssistant(options) {
|
|
47
|
-
return (options?.client ?? this.client).post({
|
|
48
|
-
requestValidator: async (data) => await zUserCreateAssistantData.parseAsync(data),
|
|
49
|
-
responseValidator: async (data) => await zUserCreateAssistantResponse.parseAsync(data),
|
|
50
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
51
|
-
url: '/api/v1/user/assistant',
|
|
52
|
-
...options
|
|
53
|
-
});
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Get User List
|
|
57
|
-
*/
|
|
58
|
-
list(options) {
|
|
59
|
-
return (options?.client ?? this.client).get({
|
|
60
|
-
requestValidator: async (data) => await zUserListData.parseAsync(data),
|
|
61
|
-
responseValidator: async (data) => await zUserListResponse.parseAsync(data),
|
|
62
|
-
url: '/api/v1/user',
|
|
63
|
-
...options
|
|
64
|
-
});
|
|
65
|
-
}
|
|
66
|
-
/**
|
|
67
|
-
* Update Profile
|
|
68
|
-
*
|
|
69
|
-
* Update current user's profile.
|
|
70
|
-
*/
|
|
71
|
-
updateProfile(options) {
|
|
72
|
-
return (options.client ?? this.client).put({
|
|
73
|
-
requestValidator: async (data) => await zUserUpdateProfileData.parseAsync(data),
|
|
74
|
-
responseValidator: async (data) => await zUserUpdateProfileResponse.parseAsync(data),
|
|
75
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
76
|
-
url: '/api/v1/user/me',
|
|
77
|
-
...options,
|
|
78
|
-
headers: {
|
|
79
|
-
'Content-Type': 'application/json',
|
|
80
|
-
...options.headers
|
|
81
|
-
}
|
|
82
|
-
});
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* Get User Profile By Id
|
|
86
|
-
*
|
|
87
|
-
* Get public profile information for a specific user by ID.
|
|
88
|
-
*
|
|
89
|
-
* This endpoint allows authenticated users to view public profile information
|
|
90
|
-
* of any user in the system. Used for user discovery and profile viewing.
|
|
91
|
-
*
|
|
92
|
-
* Args:
|
|
93
|
-
* user_id: UUID string of the user whose profile to retrieve
|
|
94
|
-
*
|
|
95
|
-
* Returns:
|
|
96
|
-
* UserProfileResponse: Public profile information (excludes sensitive data like email)
|
|
97
|
-
*
|
|
98
|
-
* Raises:
|
|
99
|
-
* HTTPException: 400 for invalid UUID format, 404 for user not found, 500 for server errors
|
|
100
|
-
*/
|
|
101
|
-
getProfile(options) {
|
|
102
|
-
return (options.client ?? this.client).get({
|
|
103
|
-
requestValidator: async (data) => await zUserGetProfileData.parseAsync(data),
|
|
104
|
-
responseValidator: async (data) => await zUserGetProfileResponse.parseAsync(data),
|
|
105
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
106
|
-
url: '/api/v1/user/{user_id}',
|
|
107
|
-
...options
|
|
108
|
-
});
|
|
109
|
-
}
|
|
110
|
-
/**
|
|
111
|
-
* Upload Avatar
|
|
112
|
-
*
|
|
113
|
-
* Upload avatar for current user.
|
|
114
|
-
*/
|
|
115
|
-
uploadAvatar(options) {
|
|
116
|
-
return (options.client ?? this.client).post({
|
|
117
|
-
...formDataBodySerializer,
|
|
118
|
-
requestValidator: async (data) => await zUserUploadAvatarData.parseAsync(data),
|
|
119
|
-
responseValidator: async (data) => await zUserUploadAvatarResponse.parseAsync(data),
|
|
120
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
121
|
-
url: '/api/v1/user/me/avatar',
|
|
122
|
-
...options,
|
|
123
|
-
headers: {
|
|
124
|
-
'Content-Type': null,
|
|
125
|
-
...options.headers
|
|
126
|
-
}
|
|
127
|
-
});
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
export class Users extends HeyApiClient {
|
|
131
|
-
/**
|
|
132
|
-
* Search Users
|
|
133
|
-
*/
|
|
134
|
-
search(options) {
|
|
135
|
-
return (options?.client ?? this.client).get({
|
|
136
|
-
requestValidator: async (data) => await zUsersSearchData.parseAsync(data),
|
|
137
|
-
responseValidator: async (data) => await zUsersSearchResponse.parseAsync(data),
|
|
138
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
139
|
-
url: '/api/v1/user/search',
|
|
140
|
-
...options
|
|
141
|
-
});
|
|
142
|
-
}
|
|
143
|
-
/**
|
|
144
|
-
* Get Current User Profile
|
|
145
|
-
*
|
|
146
|
-
* Get current user's profile information.
|
|
147
|
-
*/
|
|
148
|
-
getCurrentProfile(options) {
|
|
149
|
-
return (options?.client ?? this.client).get({
|
|
150
|
-
requestValidator: async (data) => await zUsersGetCurrentProfileData.parseAsync(data),
|
|
151
|
-
responseValidator: async (data) => await zUsersGetCurrentProfileResponse.parseAsync(data),
|
|
152
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
153
|
-
url: '/api/v1/user/me',
|
|
154
|
-
...options
|
|
155
|
-
});
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
|
-
* Delete Avatar
|
|
159
|
-
*
|
|
160
|
-
* Delete current user's avatar.
|
|
161
|
-
*/
|
|
162
|
-
deleteAvatar(options) {
|
|
163
|
-
return (options?.client ?? this.client).delete({
|
|
164
|
-
requestValidator: async (data) => await zUsersDeleteAvatarData.parseAsync(data),
|
|
165
|
-
responseValidator: async (data) => await zUsersDeleteAvatarResponse.parseAsync(data),
|
|
166
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
167
|
-
url: '/api/v1/user/me/avatar',
|
|
168
|
-
...options
|
|
169
|
-
});
|
|
170
|
-
}
|
|
171
|
-
/**
|
|
172
|
-
* Get Avatar
|
|
173
|
-
*
|
|
174
|
-
* Get current user's avatar image.
|
|
175
|
-
*/
|
|
176
|
-
getAvatar(options) {
|
|
177
|
-
return (options?.client ?? this.client).get({
|
|
178
|
-
requestValidator: async (data) => await zUsersGetAvatarData.parseAsync(data),
|
|
179
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
180
|
-
url: '/api/v1/user/me/avatar',
|
|
181
|
-
...options
|
|
182
|
-
});
|
|
183
|
-
}
|
|
184
|
-
/**
|
|
185
|
-
* Get User Avatar
|
|
186
|
-
*
|
|
187
|
-
* Get user's avatar image (requires authentication).
|
|
188
|
-
*/
|
|
189
|
-
getAvatarById(options) {
|
|
190
|
-
return (options.client ?? this.client).get({
|
|
191
|
-
requestValidator: async (data) => await zUsersGetAvatarByIdData.parseAsync(data),
|
|
192
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
193
|
-
url: '/api/v1/user/avatar/{user_id}',
|
|
194
|
-
...options
|
|
195
|
-
});
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
export class AuthContexts extends HeyApiClient {
|
|
199
|
-
/**
|
|
200
|
-
* Get Auth Context
|
|
201
|
-
*
|
|
202
|
-
* Get the current authenticated user's context.
|
|
203
|
-
*
|
|
204
|
-
* Returns user profile information and a list of organizations they belong to.
|
|
205
|
-
* For M2M tokens (service accounts), returns minimal info with is_service_account=True.
|
|
206
|
-
*/
|
|
207
|
-
get(options) {
|
|
208
|
-
return (options?.client ?? this.client).get({
|
|
209
|
-
requestValidator: async (data) => await zAuthContextsGetData.parseAsync(data),
|
|
210
|
-
responseValidator: async (data) => await zAuthContextsGetResponse.parseAsync(data),
|
|
211
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
212
|
-
url: '/api/v1/auth/context',
|
|
213
|
-
...options
|
|
214
|
-
});
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
export class AuditLogs extends HeyApiClient {
|
|
218
|
-
/**
|
|
219
|
-
* List Permission Audit Logs
|
|
220
|
-
*
|
|
221
|
-
* List permission audit logs with filtering and pagination.
|
|
222
|
-
*
|
|
223
|
-
* Requires PERMISSION_READ permission.
|
|
224
|
-
*
|
|
225
|
-
* **Security**: Non-admin users can only view logs for their own organization.
|
|
226
|
-
* The org_id filter is automatically applied based on the user's permissions.
|
|
227
|
-
*
|
|
228
|
-
* **Query Parameters**:
|
|
229
|
-
* - user_id: Filter by specific user
|
|
230
|
-
* - org_id: Filter by organization (auto-scoped for non-admins)
|
|
231
|
-
* - permission_code: Filter by permission (e.g., "SPACE_MANAGE_MEMBERS")
|
|
232
|
-
* - result: Filter by result ("granted" or "denied")
|
|
233
|
-
* - start_date/end_date: Filter by date range
|
|
234
|
-
* - skip/limit: Pagination controls
|
|
235
|
-
*
|
|
236
|
-
* **Returns**: Paginated list of audit log entries with total count.
|
|
237
|
-
*/
|
|
238
|
-
listPermissions(options) {
|
|
239
|
-
return (options?.client ?? this.client).get({
|
|
240
|
-
requestValidator: async (data) => await zAuditLogsListPermissionsData.parseAsync(data),
|
|
241
|
-
responseValidator: async (data) => await zAuditLogsListPermissionsResponse.parseAsync(data),
|
|
242
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
243
|
-
url: '/api/v1/audit-logs/permissions',
|
|
244
|
-
...options
|
|
245
|
-
});
|
|
246
|
-
}
|
|
247
|
-
/**
|
|
248
|
-
* Get Permission Audit Stats
|
|
249
|
-
*
|
|
250
|
-
* Get aggregate statistics for permission audit logs.
|
|
251
|
-
*
|
|
252
|
-
* Requires PERMISSION_READ permission.
|
|
253
|
-
*
|
|
254
|
-
* **Security**: Non-admin users can only view stats for their own organization.
|
|
255
|
-
*
|
|
256
|
-
* **Returns**:
|
|
257
|
-
* - total_checks: Total number of permission checks
|
|
258
|
-
* - granted_count: Number of granted permissions
|
|
259
|
-
* - denied_count: Number of denied permissions
|
|
260
|
-
* - unique_users: Number of unique users who triggered checks
|
|
261
|
-
* - unique_permissions: Number of unique permissions checked
|
|
262
|
-
* - most_checked_permissions: Top 10 most frequently checked permissions
|
|
263
|
-
* - most_denied_permissions: Top 10 most frequently denied permissions
|
|
264
|
-
*/
|
|
265
|
-
getPermissionStats(options) {
|
|
266
|
-
return (options?.client ?? this.client).get({
|
|
267
|
-
requestValidator: async (data) => await zAuditLogsGetPermissionStatsData.parseAsync(data),
|
|
268
|
-
responseValidator: async (data) => await zAuditLogsGetPermissionStatsResponse.parseAsync(data),
|
|
269
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
270
|
-
url: '/api/v1/audit-logs/permissions/stats',
|
|
271
|
-
...options
|
|
272
|
-
});
|
|
273
|
-
}
|
|
274
|
-
}
|
|
275
|
-
export class Events extends HeyApiClient {
|
|
276
|
-
/**
|
|
277
|
-
* Get Event List
|
|
278
|
-
*
|
|
279
|
-
* Get events with advanced filtering capabilities.
|
|
280
|
-
*
|
|
281
|
-
* Supports multiple filtering strategies:
|
|
282
|
-
* - Legacy query parameters for backward compatibility
|
|
283
|
-
* - Individual advanced filter parameters
|
|
284
|
-
* - Complex JSON filter object for advanced use cases
|
|
285
|
-
*/
|
|
286
|
-
list(options) {
|
|
287
|
-
return (options?.client ?? this.client).get({
|
|
288
|
-
requestValidator: async (data) => await zEventsListData.parseAsync(data),
|
|
289
|
-
responseValidator: async (data) => await zEventsListResponse.parseAsync(data),
|
|
290
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
291
|
-
url: '/api/v1/event',
|
|
292
|
-
...options
|
|
293
|
-
});
|
|
294
|
-
}
|
|
295
|
-
/**
|
|
296
|
-
* Create Event
|
|
297
|
-
*/
|
|
298
|
-
create(options) {
|
|
299
|
-
return (options.client ?? this.client).post({
|
|
300
|
-
...formDataBodySerializer,
|
|
301
|
-
requestValidator: async (data) => await zEventsCreateData.parseAsync(data),
|
|
302
|
-
responseValidator: async (data) => await zEventsCreateResponse.parseAsync(data),
|
|
303
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
304
|
-
url: '/api/v1/event',
|
|
305
|
-
...options,
|
|
306
|
-
headers: {
|
|
307
|
-
'Content-Type': null,
|
|
308
|
-
...options.headers
|
|
309
|
-
}
|
|
310
|
-
});
|
|
311
|
-
}
|
|
312
|
-
/**
|
|
313
|
-
* Get Calendar Events
|
|
314
|
-
*
|
|
315
|
-
* Get events for calendar view.
|
|
316
|
-
*
|
|
317
|
-
* Requires start_date and end_date.
|
|
318
|
-
* Returns all events in the range (high limit) to avoid missing data.
|
|
319
|
-
* Supports all standard event filters.
|
|
320
|
-
*/
|
|
321
|
-
listCalendar(options) {
|
|
322
|
-
return (options.client ?? this.client).get({
|
|
323
|
-
requestValidator: async (data) => await zEventsListCalendarData.parseAsync(data),
|
|
324
|
-
responseValidator: async (data) => await zEventsListCalendarResponse.parseAsync(data),
|
|
325
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
326
|
-
url: '/api/v1/event/calendar',
|
|
327
|
-
...options
|
|
328
|
-
});
|
|
329
|
-
}
|
|
330
|
-
/**
|
|
331
|
-
* Get Social Feed
|
|
332
|
-
*
|
|
333
|
-
* Get the social feed of events for the current user.
|
|
334
|
-
*
|
|
335
|
-
* Events are ranked by:
|
|
336
|
-
* 1. User relationship (personal events > owned spaces > member spaces > others)
|
|
337
|
-
* 2. Temporal proximity to user's current time (events happening soon rank higher)
|
|
338
|
-
*/
|
|
339
|
-
getSocialFeed(options) {
|
|
340
|
-
return (options?.client ?? this.client).get({
|
|
341
|
-
requestValidator: async (data) => await zEventsGetSocialFeedData.parseAsync(data),
|
|
342
|
-
responseValidator: async (data) => await zEventsGetSocialFeedResponse.parseAsync(data),
|
|
343
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
344
|
-
url: '/api/v1/event/social/feed',
|
|
345
|
-
...options
|
|
346
|
-
});
|
|
347
|
-
}
|
|
348
|
-
/**
|
|
349
|
-
* Filter Events Advanced
|
|
350
|
-
*
|
|
351
|
-
* Advanced event filtering using POST method for complex filter objects.
|
|
352
|
-
*
|
|
353
|
-
* This endpoint is useful for complex filtering scenarios that exceed
|
|
354
|
-
* URL length limits or require complex nested conditions.
|
|
355
|
-
*/
|
|
356
|
-
filterAdvanced(options) {
|
|
357
|
-
return (options.client ?? this.client).post({
|
|
358
|
-
requestValidator: async (data) => await zEventsFilterAdvancedData.parseAsync(data),
|
|
359
|
-
responseValidator: async (data) => await zEventsFilterAdvancedResponse.parseAsync(data),
|
|
360
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
361
|
-
url: '/api/v1/event/filter',
|
|
362
|
-
...options,
|
|
363
|
-
headers: {
|
|
364
|
-
'Content-Type': 'application/json',
|
|
365
|
-
...options.headers
|
|
366
|
-
}
|
|
367
|
-
});
|
|
368
|
-
}
|
|
369
|
-
/**
|
|
370
|
-
* Get Events By Space
|
|
371
|
-
*/
|
|
372
|
-
listBySpace(options) {
|
|
373
|
-
return (options.client ?? this.client).get({
|
|
374
|
-
requestValidator: async (data) => await zEventsListBySpaceData.parseAsync(data),
|
|
375
|
-
responseValidator: async (data) => await zEventsListBySpaceResponse.parseAsync(data),
|
|
376
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
377
|
-
url: '/api/v1/event/space/{space_id}',
|
|
378
|
-
...options
|
|
379
|
-
});
|
|
380
|
-
}
|
|
381
|
-
/**
|
|
382
|
-
* Delete Event
|
|
383
|
-
*/
|
|
384
|
-
delete(options) {
|
|
385
|
-
return (options.client ?? this.client).delete({
|
|
386
|
-
requestValidator: async (data) => await zEventsDeleteData.parseAsync(data),
|
|
387
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
388
|
-
url: '/api/v1/event/{event_id}',
|
|
389
|
-
...options
|
|
390
|
-
});
|
|
391
|
-
}
|
|
392
|
-
/**
|
|
393
|
-
* Patch Event Identification
|
|
394
|
-
*
|
|
395
|
-
* Update event title and status (Identification info). API renamed from /header.
|
|
396
|
-
*/
|
|
397
|
-
patchIdentification(options) {
|
|
398
|
-
return (options.client ?? this.client).patch({
|
|
399
|
-
requestValidator: async (data) => await zEventsPatchIdentificationData.parseAsync(data),
|
|
400
|
-
responseValidator: async (data) => await zEventsPatchIdentificationResponse.parseAsync(data),
|
|
401
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
402
|
-
url: '/api/v1/event/{event_id}/identification',
|
|
403
|
-
...options,
|
|
404
|
-
headers: {
|
|
405
|
-
'Content-Type': 'application/json',
|
|
406
|
-
...options.headers
|
|
407
|
-
}
|
|
408
|
-
});
|
|
409
|
-
}
|
|
410
|
-
/**
|
|
411
|
-
* Get Section Identification
|
|
412
|
-
*/
|
|
413
|
-
getSectionIdentification(options) {
|
|
414
|
-
return (options.client ?? this.client).get({
|
|
415
|
-
requestValidator: async (data) => await zEventsGetSectionIdentificationData.parseAsync(data),
|
|
416
|
-
responseValidator: async (data) => await zEventsGetSectionIdentificationResponse.parseAsync(data),
|
|
417
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
418
|
-
url: '/api/v1/event/{event_id}/section/identification',
|
|
419
|
-
...options
|
|
420
|
-
});
|
|
421
|
-
}
|
|
422
|
-
/**
|
|
423
|
-
* Get Section Content
|
|
424
|
-
*/
|
|
425
|
-
getSectionContent(options) {
|
|
426
|
-
return (options.client ?? this.client).get({
|
|
427
|
-
requestValidator: async (data) => await zEventsGetSectionContentData.parseAsync(data),
|
|
428
|
-
responseValidator: async (data) => await zEventsGetSectionContentResponse.parseAsync(data),
|
|
429
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
430
|
-
url: '/api/v1/event/{event_id}/section/content',
|
|
431
|
-
...options
|
|
432
|
-
});
|
|
433
|
-
}
|
|
434
|
-
/**
|
|
435
|
-
* Patch Event Content
|
|
436
|
-
*
|
|
437
|
-
* Update event content (Description, Metadata, Theme).
|
|
438
|
-
*/
|
|
439
|
-
patchContent(options) {
|
|
440
|
-
return (options.client ?? this.client).patch({
|
|
441
|
-
requestValidator: async (data) => await zEventsPatchContentData.parseAsync(data),
|
|
442
|
-
responseValidator: async (data) => await zEventsPatchContentResponse.parseAsync(data),
|
|
443
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
444
|
-
url: '/api/v1/event/{event_id}/content',
|
|
445
|
-
...options,
|
|
446
|
-
headers: {
|
|
447
|
-
'Content-Type': 'application/json',
|
|
448
|
-
...options.headers
|
|
449
|
-
}
|
|
450
|
-
});
|
|
451
|
-
}
|
|
452
|
-
/**
|
|
453
|
-
* Get Event Settings
|
|
454
|
-
*
|
|
455
|
-
* Get dedicated event settings.
|
|
456
|
-
*/
|
|
457
|
-
getSettings(options) {
|
|
458
|
-
return (options.client ?? this.client).get({
|
|
459
|
-
requestValidator: async (data) => await zEventsGetSettingsData.parseAsync(data),
|
|
460
|
-
responseValidator: async (data) => await zEventsGetSettingsResponse.parseAsync(data),
|
|
461
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
462
|
-
url: '/api/v1/event/{event_id}/settings',
|
|
463
|
-
...options
|
|
464
|
-
});
|
|
465
|
-
}
|
|
466
|
-
/**
|
|
467
|
-
* Patch Event Settings
|
|
468
|
-
*
|
|
469
|
-
* Update event settings (Visibility, Access).
|
|
470
|
-
*/
|
|
471
|
-
patchSettings(options) {
|
|
472
|
-
return (options.client ?? this.client).patch({
|
|
473
|
-
requestValidator: async (data) => await zEventsPatchSettingsData.parseAsync(data),
|
|
474
|
-
responseValidator: async (data) => await zEventsPatchSettingsResponse.parseAsync(data),
|
|
475
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
476
|
-
url: '/api/v1/event/{event_id}/settings',
|
|
477
|
-
...options,
|
|
478
|
-
headers: {
|
|
479
|
-
'Content-Type': 'application/json',
|
|
480
|
-
...options.headers
|
|
481
|
-
}
|
|
482
|
-
});
|
|
483
|
-
}
|
|
484
|
-
/**
|
|
485
|
-
* Update Cover
|
|
486
|
-
*/
|
|
487
|
-
updateCover(options) {
|
|
488
|
-
return (options.client ?? this.client).patch({
|
|
489
|
-
...formDataBodySerializer,
|
|
490
|
-
requestValidator: async (data) => await zEventsUpdateCoverData.parseAsync(data),
|
|
491
|
-
responseValidator: async (data) => await zEventsUpdateCoverResponse.parseAsync(data),
|
|
492
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
493
|
-
url: '/api/v1/event/{event_id}/cover',
|
|
494
|
-
...options,
|
|
495
|
-
headers: {
|
|
496
|
-
'Content-Type': null,
|
|
497
|
-
...options.headers
|
|
498
|
-
}
|
|
499
|
-
});
|
|
500
|
-
}
|
|
501
|
-
/**
|
|
502
|
-
* Publish Event
|
|
503
|
-
*/
|
|
504
|
-
publish(options) {
|
|
505
|
-
return (options.client ?? this.client).patch({
|
|
506
|
-
requestValidator: async (data) => await zEventsPublishData.parseAsync(data),
|
|
507
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
508
|
-
url: '/api/v1/event/{event_id}/publish',
|
|
509
|
-
...options
|
|
510
|
-
});
|
|
511
|
-
}
|
|
512
|
-
/**
|
|
513
|
-
* Publish Event With Notifications
|
|
514
|
-
*/
|
|
515
|
-
publishWithNotifications(options) {
|
|
516
|
-
return (options.client ?? this.client).post({
|
|
517
|
-
requestValidator: async (data) => await zEventsPublishWithNotificationsData.parseAsync(data),
|
|
518
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
519
|
-
url: '/api/v1/event/{event_id}/publish-with-notifications',
|
|
520
|
-
...options,
|
|
521
|
-
headers: {
|
|
522
|
-
'Content-Type': 'application/json',
|
|
523
|
-
...options.headers
|
|
524
|
-
}
|
|
525
|
-
});
|
|
526
|
-
}
|
|
527
|
-
/**
|
|
528
|
-
* Archive Event
|
|
529
|
-
*/
|
|
530
|
-
archive(options) {
|
|
531
|
-
return (options.client ?? this.client).patch({
|
|
532
|
-
requestValidator: async (data) => await zEventsArchiveData.parseAsync(data),
|
|
533
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
534
|
-
url: '/api/v1/event/{event_id}/archive',
|
|
535
|
-
...options
|
|
536
|
-
});
|
|
537
|
-
}
|
|
538
|
-
/**
|
|
539
|
-
* Transfer Event
|
|
540
|
-
*
|
|
541
|
-
* Transfer a personal event to an organization.
|
|
542
|
-
*
|
|
543
|
-
* Requirements:
|
|
544
|
-
* - Event must be personal (org_id IS NULL)
|
|
545
|
-
* - Current user must be the creator
|
|
546
|
-
* - Current user must be owner or admin of target organization
|
|
547
|
-
*
|
|
548
|
-
* Returns:
|
|
549
|
-
* - 200: Transfer successful
|
|
550
|
-
* - 400: Validation error (event already org-scoped, etc.)
|
|
551
|
-
* - 403: Permission denied (not creator or not org admin)
|
|
552
|
-
* - 404: Event not found
|
|
553
|
-
*/
|
|
554
|
-
transfer(options) {
|
|
555
|
-
return (options.client ?? this.client).post({
|
|
556
|
-
requestValidator: async (data) => await zEventsTransferData.parseAsync(data),
|
|
557
|
-
responseValidator: async (data) => await zEventsTransferResponse.parseAsync(data),
|
|
558
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
559
|
-
url: '/api/v1/event/{event_id}/transfer',
|
|
560
|
-
...options,
|
|
561
|
-
headers: {
|
|
562
|
-
'Content-Type': 'application/json',
|
|
563
|
-
...options.headers
|
|
564
|
-
}
|
|
565
|
-
});
|
|
566
|
-
}
|
|
567
|
-
/**
|
|
568
|
-
* Publish Event Version
|
|
569
|
-
*
|
|
570
|
-
* Create an immutable published version of the event for recommendations
|
|
571
|
-
*/
|
|
572
|
-
publishVersion(options) {
|
|
573
|
-
return (options.client ?? this.client).post({
|
|
574
|
-
requestValidator: async (data) => await zEventsPublishVersionData.parseAsync(data),
|
|
575
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
576
|
-
url: '/api/v1/event/{event_id}/versions/publish',
|
|
577
|
-
...options
|
|
578
|
-
});
|
|
579
|
-
}
|
|
580
|
-
/**
|
|
581
|
-
* List Event Versions
|
|
582
|
-
*
|
|
583
|
-
* Get all published versions of an event
|
|
584
|
-
*/
|
|
585
|
-
listVersions(options) {
|
|
586
|
-
return (options.client ?? this.client).get({
|
|
587
|
-
requestValidator: async (data) => await zEventsListVersionsData.parseAsync(data),
|
|
588
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
589
|
-
url: '/api/v1/event/{event_id}/versions',
|
|
590
|
-
...options
|
|
591
|
-
});
|
|
592
|
-
}
|
|
593
|
-
/**
|
|
594
|
-
* Rollback Event to Version
|
|
595
|
-
*
|
|
596
|
-
* Restore event to a specific published version
|
|
597
|
-
*/
|
|
598
|
-
rollbackVersion(options) {
|
|
599
|
-
return (options.client ?? this.client).post({
|
|
600
|
-
requestValidator: async (data) => await zEventsRollbackVersionData.parseAsync(data),
|
|
601
|
-
responseValidator: async (data) => await zEventsRollbackVersionResponse.parseAsync(data),
|
|
602
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
603
|
-
url: '/api/v1/event/{event_id}/versions/rollback',
|
|
604
|
-
...options
|
|
605
|
-
});
|
|
606
|
-
}
|
|
607
|
-
/**
|
|
608
|
-
* Get Timezone Info
|
|
609
|
-
*
|
|
610
|
-
* Get timezone information for frontend validation and suggestions.
|
|
611
|
-
*
|
|
612
|
-
* Returns:
|
|
613
|
-
* Dictionary containing:
|
|
614
|
-
* - all_timezones: List of all valid IANA timezones
|
|
615
|
-
* - common_timezones: List of commonly used timezones for UI suggestions
|
|
616
|
-
* - count: Total number of supported timezones
|
|
617
|
-
*/
|
|
618
|
-
getTimezones(options) {
|
|
619
|
-
return (options?.client ?? this.client).get({
|
|
620
|
-
requestValidator: async (data) => await zEventsGetTimezonesData.parseAsync(data),
|
|
621
|
-
responseValidator: async (data) => await zEventsGetTimezonesResponse.parseAsync(data),
|
|
622
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
623
|
-
url: '/api/v1/event/timezones/',
|
|
624
|
-
...options
|
|
625
|
-
});
|
|
626
|
-
}
|
|
627
|
-
}
|
|
628
|
-
export class Event_ extends HeyApiClient {
|
|
629
|
-
/**
|
|
630
|
-
* Get Event By Id
|
|
631
|
-
*/
|
|
632
|
-
get(options) {
|
|
633
|
-
return (options.client ?? this.client).get({
|
|
634
|
-
requestValidator: async (data) => await zEventGetData.parseAsync(data),
|
|
635
|
-
responseValidator: async (data) => await zEventGetResponse.parseAsync(data),
|
|
636
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
637
|
-
url: '/api/v1/event/{event_id}',
|
|
638
|
-
...options
|
|
639
|
-
});
|
|
640
|
-
}
|
|
641
|
-
/**
|
|
642
|
-
* Update Event
|
|
643
|
-
*/
|
|
644
|
-
update(options) {
|
|
645
|
-
return (options.client ?? this.client).put({
|
|
646
|
-
requestValidator: async (data) => await zEventUpdateData.parseAsync(data),
|
|
647
|
-
responseValidator: async (data) => await zEventUpdateResponse.parseAsync(data),
|
|
648
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
649
|
-
url: '/api/v1/event/{event_id}',
|
|
650
|
-
...options,
|
|
651
|
-
headers: {
|
|
652
|
-
'Content-Type': 'application/json',
|
|
653
|
-
...options.headers
|
|
654
|
-
}
|
|
655
|
-
});
|
|
656
|
-
}
|
|
657
|
-
/**
|
|
658
|
-
* Get Section Settings
|
|
659
|
-
*/
|
|
660
|
-
getSectionSettings(options) {
|
|
661
|
-
return (options.client ?? this.client).get({
|
|
662
|
-
requestValidator: async (data) => await zEventGetSectionSettingsData.parseAsync(data),
|
|
663
|
-
responseValidator: async (data) => await zEventGetSectionSettingsResponse.parseAsync(data),
|
|
664
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
665
|
-
url: '/api/v1/event/{event_id}/section/settings',
|
|
666
|
-
...options
|
|
667
|
-
});
|
|
668
|
-
}
|
|
669
|
-
/**
|
|
670
|
-
* Unpublish Event (Mark as Draft)
|
|
671
|
-
*
|
|
672
|
-
* Mark event as draft (unpublished)
|
|
673
|
-
*/
|
|
674
|
-
unpublishVersion(options) {
|
|
675
|
-
return (options.client ?? this.client).post({
|
|
676
|
-
requestValidator: async (data) => await zEventUnpublishVersionData.parseAsync(data),
|
|
677
|
-
responseValidator: async (data) => await zEventUnpublishVersionResponse.parseAsync(data),
|
|
678
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
679
|
-
url: '/api/v1/event/{event_id}/versions/unpublish',
|
|
680
|
-
...options
|
|
681
|
-
});
|
|
682
|
-
}
|
|
683
|
-
/**
|
|
684
|
-
* Compare Event Versions
|
|
685
|
-
*
|
|
686
|
-
* Compare two versions and see what changed
|
|
687
|
-
*/
|
|
688
|
-
compareVersions(options) {
|
|
689
|
-
return (options.client ?? this.client).get({
|
|
690
|
-
requestValidator: async (data) => await zEventCompareVersionsData.parseAsync(data),
|
|
691
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
692
|
-
url: '/api/v1/event/{event_id}/versions/compare',
|
|
693
|
-
...options
|
|
694
|
-
});
|
|
695
|
-
}
|
|
696
|
-
/**
|
|
697
|
-
* Get Latest Event Version
|
|
698
|
-
*
|
|
699
|
-
* Get the most recent published version of an event
|
|
700
|
-
*/
|
|
701
|
-
getLatestVersion(options) {
|
|
702
|
-
return (options.client ?? this.client).get({
|
|
703
|
-
requestValidator: async (data) => await zEventGetLatestVersionData.parseAsync(data),
|
|
704
|
-
responseValidator: async (data) => await zEventGetLatestVersionResponse.parseAsync(data),
|
|
705
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
706
|
-
url: '/api/v1/event/{event_id}/versions/latest',
|
|
707
|
-
...options
|
|
708
|
-
});
|
|
709
|
-
}
|
|
710
|
-
/**
|
|
711
|
-
* Get Event Version
|
|
712
|
-
*
|
|
713
|
-
* Get specific published version of an event
|
|
714
|
-
*/
|
|
715
|
-
getVersion(options) {
|
|
716
|
-
return (options.client ?? this.client).get({
|
|
717
|
-
requestValidator: async (data) => await zEventGetVersionData.parseAsync(data),
|
|
718
|
-
responseValidator: async (data) => await zEventGetVersionResponse.parseAsync(data),
|
|
719
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
720
|
-
url: '/api/v1/event/{event_id}/versions/{transaction_id}',
|
|
721
|
-
...options
|
|
722
|
-
});
|
|
723
|
-
}
|
|
724
|
-
}
|
|
725
|
-
export class EventTimezones extends HeyApiClient {
|
|
726
|
-
/**
|
|
727
|
-
* Validate Timezone
|
|
728
|
-
*
|
|
729
|
-
* Validate a specific timezone string.
|
|
730
|
-
*
|
|
731
|
-
* Args:
|
|
732
|
-
* timezone: Timezone string to validate (query parameter)
|
|
733
|
-
*
|
|
734
|
-
* Returns:
|
|
735
|
-
* Dictionary containing:
|
|
736
|
-
* - valid: Boolean indicating if timezone is valid
|
|
737
|
-
* - timezone: The validated timezone string
|
|
738
|
-
* - suggestions: List of similar timezones if invalid (empty if valid)
|
|
739
|
-
*/
|
|
740
|
-
validate(options) {
|
|
741
|
-
return (options.client ?? this.client).get({
|
|
742
|
-
requestValidator: async (data) => await zEventTimezonesValidateData.parseAsync(data),
|
|
743
|
-
responseValidator: async (data) => await zEventTimezonesValidateResponse.parseAsync(data),
|
|
744
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
745
|
-
url: '/api/v1/event/timezones/validate',
|
|
746
|
-
...options
|
|
747
|
-
});
|
|
748
|
-
}
|
|
749
|
-
}
|
|
750
|
-
export class EventAttendees extends HeyApiClient {
|
|
751
|
-
/**
|
|
752
|
-
* Get Event Attendees
|
|
753
|
-
*
|
|
754
|
-
* Get all attendees for a specific event.
|
|
755
|
-
*
|
|
756
|
-
* Supports filtering by status and check-in status.
|
|
757
|
-
*/
|
|
758
|
-
get(options) {
|
|
759
|
-
return (options.client ?? this.client).get({
|
|
760
|
-
requestValidator: async (data) => await zEventAttendeesGetData.parseAsync(data),
|
|
761
|
-
responseValidator: async (data) => await zEventAttendeesGetResponse.parseAsync(data),
|
|
762
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
763
|
-
url: '/api/v1/events/{event_id}/attendees',
|
|
764
|
-
...options
|
|
765
|
-
});
|
|
766
|
-
}
|
|
767
|
-
/**
|
|
768
|
-
* Add Event Attendee
|
|
769
|
-
*
|
|
770
|
-
* Add a contact as an attendee to an event.
|
|
771
|
-
*
|
|
772
|
-
* The contact must belong to the user's contact list (personal or org).
|
|
773
|
-
*/
|
|
774
|
-
add(options) {
|
|
775
|
-
return (options.client ?? this.client).post({
|
|
776
|
-
requestValidator: async (data) => await zEventAttendeesAddData.parseAsync(data),
|
|
777
|
-
responseValidator: async (data) => await zEventAttendeesAddResponse.parseAsync(data),
|
|
778
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
779
|
-
url: '/api/v1/events/{event_id}/attendees',
|
|
780
|
-
...options,
|
|
781
|
-
headers: {
|
|
782
|
-
'Content-Type': 'application/json',
|
|
783
|
-
...options.headers
|
|
784
|
-
}
|
|
785
|
-
});
|
|
786
|
-
}
|
|
787
|
-
/**
|
|
788
|
-
* Remove Event Attendees Bulk
|
|
789
|
-
*
|
|
790
|
-
* Remove multiple attendees from an event.
|
|
791
|
-
*/
|
|
792
|
-
removeBulk(options) {
|
|
793
|
-
return (options.client ?? this.client).delete({
|
|
794
|
-
requestValidator: async (data) => await zEventAttendeesRemoveBulkData.parseAsync(data),
|
|
795
|
-
responseValidator: async (data) => await zEventAttendeesRemoveBulkResponse.parseAsync(data),
|
|
796
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
797
|
-
url: '/api/v1/events/{event_id}/attendees/bulk',
|
|
798
|
-
...options,
|
|
799
|
-
headers: {
|
|
800
|
-
'Content-Type': 'application/json',
|
|
801
|
-
...options.headers
|
|
802
|
-
}
|
|
803
|
-
});
|
|
804
|
-
}
|
|
805
|
-
/**
|
|
806
|
-
* Add Event Attendees Bulk
|
|
807
|
-
*
|
|
808
|
-
* Add multiple contacts as attendees to an event.
|
|
809
|
-
*
|
|
810
|
-
* All contacts must belong to the user's contact list.
|
|
811
|
-
*/
|
|
812
|
-
addBulk(options) {
|
|
813
|
-
return (options.client ?? this.client).post({
|
|
814
|
-
requestValidator: async (data) => await zEventAttendeesAddBulkData.parseAsync(data),
|
|
815
|
-
responseValidator: async (data) => await zEventAttendeesAddBulkResponse.parseAsync(data),
|
|
816
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
817
|
-
url: '/api/v1/events/{event_id}/attendees/bulk',
|
|
818
|
-
...options,
|
|
819
|
-
headers: {
|
|
820
|
-
'Content-Type': 'application/json',
|
|
821
|
-
...options.headers
|
|
822
|
-
}
|
|
823
|
-
});
|
|
824
|
-
}
|
|
825
|
-
/**
|
|
826
|
-
* Remove Event Attendee
|
|
827
|
-
*
|
|
828
|
-
* Remove an attendee from an event.
|
|
829
|
-
*/
|
|
830
|
-
remove(options) {
|
|
831
|
-
return (options.client ?? this.client).delete({
|
|
832
|
-
requestValidator: async (data) => await zEventAttendeesRemoveData.parseAsync(data),
|
|
833
|
-
responseValidator: async (data) => await zEventAttendeesRemoveResponse.parseAsync(data),
|
|
834
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
835
|
-
url: '/api/v1/events/{event_id}/attendees/{attendee_id}',
|
|
836
|
-
...options
|
|
837
|
-
});
|
|
838
|
-
}
|
|
839
|
-
/**
|
|
840
|
-
* Update Event Attendee
|
|
841
|
-
*
|
|
842
|
-
* Update an attendee's information (status, notes, check-in status).
|
|
843
|
-
*/
|
|
844
|
-
update(options) {
|
|
845
|
-
return (options.client ?? this.client).put({
|
|
846
|
-
requestValidator: async (data) => await zEventAttendeesUpdateData.parseAsync(data),
|
|
847
|
-
responseValidator: async (data) => await zEventAttendeesUpdateResponse.parseAsync(data),
|
|
848
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
849
|
-
url: '/api/v1/events/{event_id}/attendees/{attendee_id}',
|
|
850
|
-
...options,
|
|
851
|
-
headers: {
|
|
852
|
-
'Content-Type': 'application/json',
|
|
853
|
-
...options.headers
|
|
854
|
-
}
|
|
855
|
-
});
|
|
856
|
-
}
|
|
857
|
-
/**
|
|
858
|
-
* Check In Attendee
|
|
859
|
-
*
|
|
860
|
-
* Check in an attendee to the event.
|
|
861
|
-
*/
|
|
862
|
-
checkIn(options) {
|
|
863
|
-
return (options.client ?? this.client).post({
|
|
864
|
-
requestValidator: async (data) => await zEventAttendeesCheckInData.parseAsync(data),
|
|
865
|
-
responseValidator: async (data) => await zEventAttendeesCheckInResponse.parseAsync(data),
|
|
866
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
867
|
-
url: '/api/v1/events/{event_id}/attendees/{attendee_id}/check-in',
|
|
868
|
-
...options
|
|
869
|
-
});
|
|
870
|
-
}
|
|
871
|
-
/**
|
|
872
|
-
* Update Attendees Status Bulk
|
|
873
|
-
*
|
|
874
|
-
* Update status for multiple attendees at once.
|
|
875
|
-
*/
|
|
876
|
-
updateBulkStatus(options) {
|
|
877
|
-
return (options.client ?? this.client).patch({
|
|
878
|
-
requestValidator: async (data) => await zEventAttendeesUpdateBulkStatusData.parseAsync(data),
|
|
879
|
-
responseValidator: async (data) => await zEventAttendeesUpdateBulkStatusResponse.parseAsync(data),
|
|
880
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
881
|
-
url: '/api/v1/events/{event_id}/attendees/bulk/status',
|
|
882
|
-
...options,
|
|
883
|
-
headers: {
|
|
884
|
-
'Content-Type': 'application/json',
|
|
885
|
-
...options.headers
|
|
886
|
-
}
|
|
887
|
-
});
|
|
888
|
-
}
|
|
889
|
-
}
|
|
890
|
-
export class EventTimeline extends HeyApiClient {
|
|
891
|
-
/**
|
|
892
|
-
* Get event timeline
|
|
893
|
-
*
|
|
894
|
-
* Retrieve all milestones linked to a base event.
|
|
895
|
-
*/
|
|
896
|
-
get(options) {
|
|
897
|
-
return (options.client ?? this.client).get({
|
|
898
|
-
requestValidator: async (data) => await zEventTimelineGetData.parseAsync(data),
|
|
899
|
-
responseValidator: async (data) => await zEventTimelineGetResponse.parseAsync(data),
|
|
900
|
-
url: '/api/v1/event/{event_id}/timeline',
|
|
901
|
-
...options
|
|
902
|
-
});
|
|
903
|
-
}
|
|
904
|
-
/**
|
|
905
|
-
* Get published event timeline
|
|
906
|
-
*
|
|
907
|
-
* Retrieve published milestones for a base event's published version. Returns only milestones that were linked at publish time AND are themselves published.
|
|
908
|
-
*/
|
|
909
|
-
getPublished(options) {
|
|
910
|
-
return (options.client ?? this.client).get({
|
|
911
|
-
requestValidator: async (data) => await zEventTimelineGetPublishedData.parseAsync(data),
|
|
912
|
-
responseValidator: async (data) => await zEventTimelineGetPublishedResponse.parseAsync(data),
|
|
913
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
914
|
-
url: '/api/v1/event/{event_id}/timeline/published',
|
|
915
|
-
...options
|
|
916
|
-
});
|
|
917
|
-
}
|
|
918
|
-
/**
|
|
919
|
-
* Create and link milestone
|
|
920
|
-
*
|
|
921
|
-
* Create a new event and automatically link it as a milestone.
|
|
922
|
-
*/
|
|
923
|
-
createMilestone(options) {
|
|
924
|
-
return (options.client ?? this.client).post({
|
|
925
|
-
...formDataBodySerializer,
|
|
926
|
-
requestValidator: async (data) => await zEventTimelineCreateMilestoneData.parseAsync(data),
|
|
927
|
-
responseValidator: async (data) => await zEventTimelineCreateMilestoneResponse.parseAsync(data),
|
|
928
|
-
url: '/api/v1/event/{event_id}/timeline/milestones',
|
|
929
|
-
...options,
|
|
930
|
-
headers: {
|
|
931
|
-
'Content-Type': null,
|
|
932
|
-
...options.headers
|
|
933
|
-
}
|
|
934
|
-
});
|
|
935
|
-
}
|
|
936
|
-
/**
|
|
937
|
-
* Link existing event
|
|
938
|
-
*
|
|
939
|
-
* Link an existing event as a milestone to a base event.
|
|
940
|
-
*/
|
|
941
|
-
linkMilestone(options) {
|
|
942
|
-
return (options.client ?? this.client).post({
|
|
943
|
-
requestValidator: async (data) => await zEventTimelineLinkMilestoneData.parseAsync(data),
|
|
944
|
-
url: '/api/v1/event/{event_id}/timeline/link',
|
|
945
|
-
...options
|
|
946
|
-
});
|
|
947
|
-
}
|
|
948
|
-
/**
|
|
949
|
-
* Unlink milestone
|
|
950
|
-
*
|
|
951
|
-
* Remove a milestone link without deleting the event.
|
|
952
|
-
*/
|
|
953
|
-
unlink(options) {
|
|
954
|
-
return (options.client ?? this.client).delete({
|
|
955
|
-
requestValidator: async (data) => await zEventTimelineUnlinkData.parseAsync(data),
|
|
956
|
-
url: '/api/v1/event/{event_id}/timeline/{milestone_event_id}',
|
|
957
|
-
...options
|
|
958
|
-
});
|
|
959
|
-
}
|
|
960
|
-
}
|
|
961
|
-
export class EventDocuments extends HeyApiClient {
|
|
962
|
-
/**
|
|
963
|
-
* Remove Document From Event
|
|
964
|
-
*
|
|
965
|
-
* Remove a document from an event.
|
|
966
|
-
*/
|
|
967
|
-
remove(options) {
|
|
968
|
-
return (options.client ?? this.client).delete({
|
|
969
|
-
requestValidator: async (data) => await zEventDocumentsRemoveData.parseAsync(data),
|
|
970
|
-
responseValidator: async (data) => await zEventDocumentsRemoveResponse.parseAsync(data),
|
|
971
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
972
|
-
url: '/api/v1/events/{event_id}/documents/{document_id}',
|
|
973
|
-
...options
|
|
974
|
-
});
|
|
975
|
-
}
|
|
976
|
-
/**
|
|
977
|
-
* Add Document To Event
|
|
978
|
-
*
|
|
979
|
-
* Associate a document with an event.
|
|
980
|
-
*/
|
|
981
|
-
addDocument(options) {
|
|
982
|
-
return (options.client ?? this.client).post({
|
|
983
|
-
requestValidator: async (data) => await zEventDocumentsAddDocumentData.parseAsync(data),
|
|
984
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
985
|
-
url: '/api/v1/events/{event_id}/documents/{document_id}',
|
|
986
|
-
...options
|
|
987
|
-
});
|
|
988
|
-
}
|
|
989
|
-
/**
|
|
990
|
-
* Get Event Documents
|
|
991
|
-
*
|
|
992
|
-
* Get all documents for an event.
|
|
993
|
-
*/
|
|
994
|
-
getDocuments(options) {
|
|
995
|
-
return (options.client ?? this.client).get({
|
|
996
|
-
requestValidator: async (data) => await zEventDocumentsGetDocumentsData.parseAsync(data),
|
|
997
|
-
responseValidator: async (data) => await zEventDocumentsGetDocumentsResponse.parseAsync(data),
|
|
998
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
999
|
-
url: '/api/v1/events/{event_id}/documents',
|
|
1000
|
-
...options
|
|
1001
|
-
});
|
|
1002
|
-
}
|
|
1003
|
-
}
|
|
1004
|
-
export class EventLocation extends HeyApiClient {
|
|
1005
|
-
/**
|
|
1006
|
-
* Get Event Location
|
|
1007
|
-
*
|
|
1008
|
-
* Get the location details for an event.
|
|
1009
|
-
*/
|
|
1010
|
-
get(options) {
|
|
1011
|
-
return (options.client ?? this.client).get({
|
|
1012
|
-
requestValidator: async (data) => await zEventLocationGetData.parseAsync(data),
|
|
1013
|
-
responseValidator: async (data) => await zEventLocationGetResponse.parseAsync(data),
|
|
1014
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1015
|
-
url: '/api/v1/events/{event_id}/location',
|
|
1016
|
-
...options
|
|
1017
|
-
});
|
|
1018
|
-
}
|
|
1019
|
-
/**
|
|
1020
|
-
* Update Event Location
|
|
1021
|
-
*
|
|
1022
|
-
* Update the location details for an event.
|
|
1023
|
-
*/
|
|
1024
|
-
update(options) {
|
|
1025
|
-
return (options.client ?? this.client).put({
|
|
1026
|
-
requestValidator: async (data) => await zEventLocationUpdateData.parseAsync(data),
|
|
1027
|
-
responseValidator: async (data) => await zEventLocationUpdateResponse.parseAsync(data),
|
|
1028
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1029
|
-
url: '/api/v1/events/{event_id}/location',
|
|
1030
|
-
...options,
|
|
1031
|
-
headers: {
|
|
1032
|
-
'Content-Type': 'application/json',
|
|
1033
|
-
...options.headers
|
|
1034
|
-
}
|
|
1035
|
-
});
|
|
1036
|
-
}
|
|
1037
|
-
}
|
|
1038
|
-
export class Space extends HeyApiClient {
|
|
1039
|
-
/**
|
|
1040
|
-
* Test Auth
|
|
1041
|
-
*
|
|
1042
|
-
* Test endpoint to verify authentication
|
|
1043
|
-
*/
|
|
1044
|
-
testAuth(options) {
|
|
1045
|
-
return (options?.client ?? this.client).get({
|
|
1046
|
-
requestValidator: async (data) => await zSpaceTestAuthData.parseAsync(data),
|
|
1047
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1048
|
-
url: '/api/v1/space/test-auth',
|
|
1049
|
-
...options
|
|
1050
|
-
});
|
|
1051
|
-
}
|
|
1052
|
-
/**
|
|
1053
|
-
* Update Space
|
|
1054
|
-
*/
|
|
1055
|
-
update(options) {
|
|
1056
|
-
return (options.client ?? this.client).put({
|
|
1057
|
-
requestValidator: async (data) => await zSpaceUpdateData.parseAsync(data),
|
|
1058
|
-
responseValidator: async (data) => await zSpaceUpdateResponse.parseAsync(data),
|
|
1059
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1060
|
-
url: '/api/v1/space/{space_id}',
|
|
1061
|
-
...options,
|
|
1062
|
-
headers: {
|
|
1063
|
-
'Content-Type': 'application/json',
|
|
1064
|
-
...options.headers
|
|
1065
|
-
}
|
|
1066
|
-
});
|
|
1067
|
-
}
|
|
1068
|
-
/**
|
|
1069
|
-
* Publish Space
|
|
1070
|
-
*/
|
|
1071
|
-
publish(options) {
|
|
1072
|
-
return (options.client ?? this.client).patch({
|
|
1073
|
-
requestValidator: async (data) => await zSpacePublishData.parseAsync(data),
|
|
1074
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1075
|
-
url: '/api/v1/space/{space_id}/publish',
|
|
1076
|
-
...options
|
|
1077
|
-
});
|
|
1078
|
-
}
|
|
1079
|
-
/**
|
|
1080
|
-
* Archive Space
|
|
1081
|
-
*/
|
|
1082
|
-
archive(options) {
|
|
1083
|
-
return (options.client ?? this.client).patch({
|
|
1084
|
-
requestValidator: async (data) => await zSpaceArchiveData.parseAsync(data),
|
|
1085
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1086
|
-
url: '/api/v1/space/{space_id}/archive',
|
|
1087
|
-
...options
|
|
1088
|
-
});
|
|
1089
|
-
}
|
|
1090
|
-
/**
|
|
1091
|
-
* Update Space Member Role
|
|
1092
|
-
*
|
|
1093
|
-
* Update a space member's role
|
|
1094
|
-
*/
|
|
1095
|
-
updateMemberRole(options) {
|
|
1096
|
-
return (options.client ?? this.client).patch({
|
|
1097
|
-
requestValidator: async (data) => await zSpaceUpdateMemberRoleData.parseAsync(data),
|
|
1098
|
-
responseValidator: async (data) => await zSpaceUpdateMemberRoleResponse.parseAsync(data),
|
|
1099
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1100
|
-
url: '/api/v1/space/{space_id}/members/{user_id}',
|
|
1101
|
-
...options,
|
|
1102
|
-
headers: {
|
|
1103
|
-
'Content-Type': 'application/json',
|
|
1104
|
-
...options.headers
|
|
1105
|
-
}
|
|
1106
|
-
});
|
|
1107
|
-
}
|
|
1108
|
-
/**
|
|
1109
|
-
* Transfer Space
|
|
1110
|
-
*
|
|
1111
|
-
* Transfer a personal space to an organization.
|
|
1112
|
-
*
|
|
1113
|
-
* This endpoint allows the creator of a personal space to transfer ownership
|
|
1114
|
-
* to an organization they are a member of with owner or admin privileges.
|
|
1115
|
-
*
|
|
1116
|
-
* Requirements:
|
|
1117
|
-
* - Space must be personal (org_id IS NULL)
|
|
1118
|
-
* - Caller must be the space creator
|
|
1119
|
-
* - Caller must be owner or admin of the target organization
|
|
1120
|
-
*
|
|
1121
|
-
* Args:
|
|
1122
|
-
* space_id: ID of the space to transfer
|
|
1123
|
-
* request: Transfer request containing target_org_id
|
|
1124
|
-
*
|
|
1125
|
-
* Returns:
|
|
1126
|
-
* TransferSpaceResponse: Transfer status and metadata
|
|
1127
|
-
*
|
|
1128
|
-
* Raises:
|
|
1129
|
-
* HTTPException:
|
|
1130
|
-
* - 400: Invalid request (already org-scoped, not creator, etc.)
|
|
1131
|
-
* - 403: Permission denied (not org owner/admin)
|
|
1132
|
-
* - 404: Space or organization not found
|
|
1133
|
-
* - 500: Server error
|
|
1134
|
-
*/
|
|
1135
|
-
transfer(options) {
|
|
1136
|
-
return (options.client ?? this.client).post({
|
|
1137
|
-
requestValidator: async (data) => await zSpaceTransferData.parseAsync(data),
|
|
1138
|
-
responseValidator: async (data) => await zSpaceTransferResponse.parseAsync(data),
|
|
1139
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1140
|
-
url: '/api/v1/space/{space_id}/transfer',
|
|
1141
|
-
...options,
|
|
1142
|
-
headers: {
|
|
1143
|
-
'Content-Type': 'application/json',
|
|
1144
|
-
...options.headers
|
|
1145
|
-
}
|
|
1146
|
-
});
|
|
1147
|
-
}
|
|
1148
|
-
/**
|
|
1149
|
-
* Bulk Update Space Parent
|
|
1150
|
-
*
|
|
1151
|
-
* Bulk update parent relationship for multiple spaces
|
|
1152
|
-
*/
|
|
1153
|
-
bulkUpdateParent(options) {
|
|
1154
|
-
return (options.client ?? this.client).patch({
|
|
1155
|
-
requestValidator: async (data) => await zSpaceBulkUpdateParentData.parseAsync(data),
|
|
1156
|
-
responseValidator: async (data) => await zSpaceBulkUpdateParentResponse.parseAsync(data),
|
|
1157
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1158
|
-
url: '/api/v1/space/bulk-parent',
|
|
1159
|
-
...options,
|
|
1160
|
-
headers: {
|
|
1161
|
-
'Content-Type': 'application/json',
|
|
1162
|
-
...options.headers
|
|
1163
|
-
}
|
|
1164
|
-
});
|
|
1165
|
-
}
|
|
1166
|
-
/**
|
|
1167
|
-
* Get latest published space version
|
|
1168
|
-
*
|
|
1169
|
-
* Retrieve the most recent published version of a space
|
|
1170
|
-
*/
|
|
1171
|
-
getLatestVersion(options) {
|
|
1172
|
-
return (options.client ?? this.client).get({
|
|
1173
|
-
requestValidator: async (data) => await zSpaceGetLatestVersionData.parseAsync(data),
|
|
1174
|
-
responseValidator: async (data) => await zSpaceGetLatestVersionResponse.parseAsync(data),
|
|
1175
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1176
|
-
url: '/api/v1/space/{space_id}/versions/latest',
|
|
1177
|
-
...options
|
|
1178
|
-
});
|
|
1179
|
-
}
|
|
1180
|
-
/**
|
|
1181
|
-
* Get User Space Roles
|
|
1182
|
-
*
|
|
1183
|
-
* Get all space roles for a user in a specific space.
|
|
1184
|
-
*
|
|
1185
|
-
* Requires space read permissions.
|
|
1186
|
-
*/
|
|
1187
|
-
getUserRoles(options) {
|
|
1188
|
-
return (options.client ?? this.client).get({
|
|
1189
|
-
requestValidator: async (data) => await zSpaceGetUserRolesData.parseAsync(data),
|
|
1190
|
-
responseValidator: async (data) => await zSpaceGetUserRolesResponse.parseAsync(data),
|
|
1191
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1192
|
-
url: '/api/v1/space/spaces/{space_id}/members/{user_id}/roles',
|
|
1193
|
-
...options
|
|
1194
|
-
});
|
|
1195
|
-
}
|
|
1196
|
-
/**
|
|
1197
|
-
* Assign User To Space Role
|
|
1198
|
-
*
|
|
1199
|
-
* Assign a user to a space role.
|
|
1200
|
-
*
|
|
1201
|
-
* Requires space member management permissions.
|
|
1202
|
-
*/
|
|
1203
|
-
assignUserToRole(options) {
|
|
1204
|
-
return (options.client ?? this.client).post({
|
|
1205
|
-
requestValidator: async (data) => await zSpaceAssignUserToRoleData.parseAsync(data),
|
|
1206
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1207
|
-
url: '/api/v1/space/spaces/{space_id}/members/{user_id}/roles',
|
|
1208
|
-
...options
|
|
1209
|
-
});
|
|
1210
|
-
}
|
|
1211
|
-
}
|
|
1212
|
-
export class Spaces extends HeyApiClient {
|
|
1213
|
-
/**
|
|
1214
|
-
* Get Space List
|
|
1215
|
-
*/
|
|
1216
|
-
list(options) {
|
|
1217
|
-
return (options?.client ?? this.client).get({
|
|
1218
|
-
requestValidator: async (data) => await zSpacesListData.parseAsync(data),
|
|
1219
|
-
responseValidator: async (data) => await zSpacesListResponse.parseAsync(data),
|
|
1220
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1221
|
-
url: '/api/v1/space/',
|
|
1222
|
-
...options
|
|
1223
|
-
});
|
|
1224
|
-
}
|
|
1225
|
-
/**
|
|
1226
|
-
* Create Space
|
|
1227
|
-
*/
|
|
1228
|
-
createSpace(options) {
|
|
1229
|
-
return (options.client ?? this.client).post({
|
|
1230
|
-
requestValidator: async (data) => await zSpacesCreateSpaceData.parseAsync(data),
|
|
1231
|
-
responseValidator: async (data) => await zSpacesCreateSpaceResponse.parseAsync(data),
|
|
1232
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1233
|
-
url: '/api/v1/space/',
|
|
1234
|
-
...options,
|
|
1235
|
-
headers: {
|
|
1236
|
-
'Content-Type': 'application/json',
|
|
1237
|
-
...options.headers
|
|
1238
|
-
}
|
|
1239
|
-
});
|
|
1240
|
-
}
|
|
1241
|
-
/**
|
|
1242
|
-
* Delete Space
|
|
1243
|
-
*/
|
|
1244
|
-
deleteById(options) {
|
|
1245
|
-
return (options.client ?? this.client).delete({
|
|
1246
|
-
requestValidator: async (data) => await zSpacesDeleteByIdData.parseAsync(data),
|
|
1247
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1248
|
-
url: '/api/v1/space/{space_id}',
|
|
1249
|
-
...options
|
|
1250
|
-
});
|
|
1251
|
-
}
|
|
1252
|
-
/**
|
|
1253
|
-
* Get Space By Id
|
|
1254
|
-
*/
|
|
1255
|
-
getById(options) {
|
|
1256
|
-
return (options.client ?? this.client).get({
|
|
1257
|
-
requestValidator: async (data) => await zSpacesGetByIdData.parseAsync(data),
|
|
1258
|
-
responseValidator: async (data) => await zSpacesGetByIdResponse.parseAsync(data),
|
|
1259
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1260
|
-
url: '/api/v1/space/{space_id}',
|
|
1261
|
-
...options
|
|
1262
|
-
});
|
|
1263
|
-
}
|
|
1264
|
-
/**
|
|
1265
|
-
* Create Space With Parent
|
|
1266
|
-
*
|
|
1267
|
-
* Create a space with parent relationship and inheritance settings
|
|
1268
|
-
*/
|
|
1269
|
-
createWithParent(options) {
|
|
1270
|
-
return (options.client ?? this.client).post({
|
|
1271
|
-
requestValidator: async (data) => await zSpacesCreateWithParentData.parseAsync(data),
|
|
1272
|
-
responseValidator: async (data) => await zSpacesCreateWithParentResponse.parseAsync(data),
|
|
1273
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1274
|
-
url: '/api/v1/space/with-parent',
|
|
1275
|
-
...options,
|
|
1276
|
-
headers: {
|
|
1277
|
-
'Content-Type': 'application/json',
|
|
1278
|
-
...options.headers
|
|
1279
|
-
}
|
|
1280
|
-
});
|
|
1281
|
-
}
|
|
1282
|
-
/**
|
|
1283
|
-
* Publish space
|
|
1284
|
-
*
|
|
1285
|
-
* Publish current space state as immutable version for community discovery
|
|
1286
|
-
*/
|
|
1287
|
-
publishVersion(options) {
|
|
1288
|
-
return (options.client ?? this.client).post({
|
|
1289
|
-
requestValidator: async (data) => await zSpacesPublishVersionData.parseAsync(data),
|
|
1290
|
-
responseValidator: async (data) => await zSpacesPublishVersionResponse.parseAsync(data),
|
|
1291
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1292
|
-
url: '/api/v1/space/{space_id}/publish',
|
|
1293
|
-
...options
|
|
1294
|
-
});
|
|
1295
|
-
}
|
|
1296
|
-
/**
|
|
1297
|
-
* Get Space Members
|
|
1298
|
-
*
|
|
1299
|
-
* Get all members of a space
|
|
1300
|
-
*/
|
|
1301
|
-
getMembers(options) {
|
|
1302
|
-
return (options.client ?? this.client).get({
|
|
1303
|
-
requestValidator: async (data) => await zSpacesGetMembersData.parseAsync(data),
|
|
1304
|
-
responseValidator: async (data) => await zSpacesGetMembersResponse.parseAsync(data),
|
|
1305
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1306
|
-
url: '/api/v1/space/{space_id}/members',
|
|
1307
|
-
...options
|
|
1308
|
-
});
|
|
1309
|
-
}
|
|
1310
|
-
/**
|
|
1311
|
-
* Add Space Member
|
|
1312
|
-
*
|
|
1313
|
-
* Add a member to a space
|
|
1314
|
-
*/
|
|
1315
|
-
addMember(options) {
|
|
1316
|
-
return (options.client ?? this.client).post({
|
|
1317
|
-
requestValidator: async (data) => await zSpacesAddMemberData.parseAsync(data),
|
|
1318
|
-
responseValidator: async (data) => await zSpacesAddMemberResponse.parseAsync(data),
|
|
1319
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1320
|
-
url: '/api/v1/space/{space_id}/members',
|
|
1321
|
-
...options,
|
|
1322
|
-
headers: {
|
|
1323
|
-
'Content-Type': 'application/json',
|
|
1324
|
-
...options.headers
|
|
1325
|
-
}
|
|
1326
|
-
});
|
|
1327
|
-
}
|
|
1328
|
-
/**
|
|
1329
|
-
* Remove Space Member
|
|
1330
|
-
*
|
|
1331
|
-
* Remove a member from a space
|
|
1332
|
-
*/
|
|
1333
|
-
removeMember(options) {
|
|
1334
|
-
return (options.client ?? this.client).delete({
|
|
1335
|
-
requestValidator: async (data) => await zSpacesRemoveMemberData.parseAsync(data),
|
|
1336
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1337
|
-
url: '/api/v1/space/{space_id}/members/{user_id}',
|
|
1338
|
-
...options
|
|
1339
|
-
});
|
|
1340
|
-
}
|
|
1341
|
-
/**
|
|
1342
|
-
* Get Joinable Spaces By User
|
|
1343
|
-
*
|
|
1344
|
-
* Get spaces owned by a user that the current viewer can join.
|
|
1345
|
-
*
|
|
1346
|
-
* This endpoint returns spaces where the target user is an owner and the current
|
|
1347
|
-
* viewer has permission to join based on visibility rules:
|
|
1348
|
-
* - PUBLIC: Always visible to all users
|
|
1349
|
-
* - TENANT: Visible only to users in the same organization
|
|
1350
|
-
* - MEMBERS_ONLY: Excluded from joinable list (requires approval)
|
|
1351
|
-
*
|
|
1352
|
-
* Args:
|
|
1353
|
-
* user_id: UUID string of the user whose spaces to retrieve
|
|
1354
|
-
* limit: Maximum number of spaces to return (default: 10, max: 12)
|
|
1355
|
-
* prev: Previous ID for cursor-based pagination
|
|
1356
|
-
* sort_by: Field to sort by (default: "created_at")
|
|
1357
|
-
* sort_order: Sort order - "asc" or "desc" (default: "desc")
|
|
1358
|
-
*
|
|
1359
|
-
* Returns:
|
|
1360
|
-
* List[GetSpaceListResponseDTO]: List of joinable spaces
|
|
1361
|
-
*
|
|
1362
|
-
* Raises:
|
|
1363
|
-
* HTTPException: 401 for unauthorized access, 500 for server errors
|
|
1364
|
-
*/
|
|
1365
|
-
getJoinableByUser(options) {
|
|
1366
|
-
return (options.client ?? this.client).get({
|
|
1367
|
-
requestValidator: async (data) => await zSpacesGetJoinableByUserData.parseAsync(data),
|
|
1368
|
-
responseValidator: async (data) => await zSpacesGetJoinableByUserResponse.parseAsync(data),
|
|
1369
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1370
|
-
url: '/api/v1/space/by-user/{user_id}/joinable',
|
|
1371
|
-
...options
|
|
1372
|
-
});
|
|
1373
|
-
}
|
|
1374
|
-
/**
|
|
1375
|
-
* Join Space
|
|
1376
|
-
*
|
|
1377
|
-
* Self-join the current user to a space if permitted.
|
|
1378
|
-
*
|
|
1379
|
-
* This endpoint allows the current user to join a space based on visibility rules:
|
|
1380
|
-
* - PUBLIC: Anyone can join
|
|
1381
|
-
* - TENANT: Only users in the same organization can join
|
|
1382
|
-
* - MEMBERS_ONLY: Requires approval (returns 403)
|
|
1383
|
-
*
|
|
1384
|
-
* Args:
|
|
1385
|
-
* space_id: ID of the space to join
|
|
1386
|
-
*
|
|
1387
|
-
* Returns:
|
|
1388
|
-
* SpaceMemberResponse: Membership information after successful join
|
|
1389
|
-
*
|
|
1390
|
-
* Raises:
|
|
1391
|
-
* HTTPException:
|
|
1392
|
-
* - 404: Space not found
|
|
1393
|
-
* - 403: Permission denied (wrong tenant or members-only space)
|
|
1394
|
-
* - 409: Already a member
|
|
1395
|
-
* - 500: Server error
|
|
1396
|
-
*/
|
|
1397
|
-
join(options) {
|
|
1398
|
-
return (options.client ?? this.client).post({
|
|
1399
|
-
requestValidator: async (data) => await zSpacesJoinData.parseAsync(data),
|
|
1400
|
-
responseValidator: async (data) => await zSpacesJoinResponse.parseAsync(data),
|
|
1401
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1402
|
-
url: '/api/v1/space/{space_id}/join',
|
|
1403
|
-
...options
|
|
1404
|
-
});
|
|
1405
|
-
}
|
|
1406
|
-
/**
|
|
1407
|
-
* Get Space Children
|
|
1408
|
-
*
|
|
1409
|
-
* Get all child spaces of a given space
|
|
1410
|
-
*/
|
|
1411
|
-
listChildren(options) {
|
|
1412
|
-
return (options.client ?? this.client).get({
|
|
1413
|
-
requestValidator: async (data) => await zSpacesListChildrenData.parseAsync(data),
|
|
1414
|
-
responseValidator: async (data) => await zSpacesListChildrenResponse.parseAsync(data),
|
|
1415
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1416
|
-
url: '/api/v1/space/{space_id}/children',
|
|
1417
|
-
...options
|
|
1418
|
-
});
|
|
1419
|
-
}
|
|
1420
|
-
/**
|
|
1421
|
-
* Detach Space From Parent
|
|
1422
|
-
*
|
|
1423
|
-
* Detach a space from its parent, making it standalone
|
|
1424
|
-
*/
|
|
1425
|
-
detachParent(options) {
|
|
1426
|
-
return (options.client ?? this.client).delete({
|
|
1427
|
-
requestValidator: async (data) => await zSpacesDetachParentData.parseAsync(data),
|
|
1428
|
-
responseValidator: async (data) => await zSpacesDetachParentResponse.parseAsync(data),
|
|
1429
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1430
|
-
url: '/api/v1/space/{space_id}/parent',
|
|
1431
|
-
...options
|
|
1432
|
-
});
|
|
1433
|
-
}
|
|
1434
|
-
/**
|
|
1435
|
-
* Get Space Parent
|
|
1436
|
-
*
|
|
1437
|
-
* Get the parent space of a given space
|
|
1438
|
-
*/
|
|
1439
|
-
getParent(options) {
|
|
1440
|
-
return (options.client ?? this.client).get({
|
|
1441
|
-
requestValidator: async (data) => await zSpacesGetParentData.parseAsync(data),
|
|
1442
|
-
responseValidator: async (data) => await zSpacesGetParentResponse.parseAsync(data),
|
|
1443
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1444
|
-
url: '/api/v1/space/{space_id}/parent',
|
|
1445
|
-
...options
|
|
1446
|
-
});
|
|
1447
|
-
}
|
|
1448
|
-
/**
|
|
1449
|
-
* Update Space Parent
|
|
1450
|
-
*
|
|
1451
|
-
* Update the parent relationship of a space
|
|
1452
|
-
*/
|
|
1453
|
-
updateParent(options) {
|
|
1454
|
-
return (options.client ?? this.client).patch({
|
|
1455
|
-
requestValidator: async (data) => await zSpacesUpdateParentData.parseAsync(data),
|
|
1456
|
-
responseValidator: async (data) => await zSpacesUpdateParentResponse.parseAsync(data),
|
|
1457
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1458
|
-
url: '/api/v1/space/{space_id}/parent',
|
|
1459
|
-
...options,
|
|
1460
|
-
headers: {
|
|
1461
|
-
'Content-Type': 'application/json',
|
|
1462
|
-
...options.headers
|
|
1463
|
-
}
|
|
1464
|
-
});
|
|
1465
|
-
}
|
|
1466
|
-
/**
|
|
1467
|
-
* Get Space Hierarchy
|
|
1468
|
-
*
|
|
1469
|
-
* Get the full hierarchy tree starting from a given space
|
|
1470
|
-
*/
|
|
1471
|
-
getHierarchy(options) {
|
|
1472
|
-
return (options.client ?? this.client).get({
|
|
1473
|
-
requestValidator: async (data) => await zSpacesGetHierarchyData.parseAsync(data),
|
|
1474
|
-
responseValidator: async (data) => await zSpacesGetHierarchyResponse.parseAsync(data),
|
|
1475
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1476
|
-
url: '/api/v1/space/{space_id}/hierarchy',
|
|
1477
|
-
...options
|
|
1478
|
-
});
|
|
1479
|
-
}
|
|
1480
|
-
/**
|
|
1481
|
-
* Unpublish space
|
|
1482
|
-
*
|
|
1483
|
-
* Mark space as draft (unpublished), preserving version history
|
|
1484
|
-
*/
|
|
1485
|
-
unpublish(options) {
|
|
1486
|
-
return (options.client ?? this.client).post({
|
|
1487
|
-
requestValidator: async (data) => await zSpacesUnpublishData.parseAsync(data),
|
|
1488
|
-
responseValidator: async (data) => await zSpacesUnpublishResponse.parseAsync(data),
|
|
1489
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1490
|
-
url: '/api/v1/space/{space_id}/unpublish',
|
|
1491
|
-
...options
|
|
1492
|
-
});
|
|
1493
|
-
}
|
|
1494
|
-
/**
|
|
1495
|
-
* List space versions
|
|
1496
|
-
*
|
|
1497
|
-
* Get all published versions of a space
|
|
1498
|
-
*/
|
|
1499
|
-
listVersions(options) {
|
|
1500
|
-
return (options.client ?? this.client).get({
|
|
1501
|
-
requestValidator: async (data) => await zSpacesListVersionsData.parseAsync(data),
|
|
1502
|
-
responseValidator: async (data) => await zSpacesListVersionsResponse.parseAsync(data),
|
|
1503
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1504
|
-
url: '/api/v1/space/{space_id}/versions',
|
|
1505
|
-
...options
|
|
1506
|
-
});
|
|
1507
|
-
}
|
|
1508
|
-
/**
|
|
1509
|
-
* Get specific space version
|
|
1510
|
-
*
|
|
1511
|
-
* Retrieve a specific published version of a space
|
|
1512
|
-
*/
|
|
1513
|
-
getVersion(options) {
|
|
1514
|
-
return (options.client ?? this.client).get({
|
|
1515
|
-
requestValidator: async (data) => await zSpacesGetVersionData.parseAsync(data),
|
|
1516
|
-
responseValidator: async (data) => await zSpacesGetVersionResponse.parseAsync(data),
|
|
1517
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1518
|
-
url: '/api/v1/space/{space_id}/versions/{version_number}',
|
|
1519
|
-
...options
|
|
1520
|
-
});
|
|
1521
|
-
}
|
|
1522
|
-
/**
|
|
1523
|
-
* Compare space versions
|
|
1524
|
-
*
|
|
1525
|
-
* Compare two versions and see what changed
|
|
1526
|
-
*/
|
|
1527
|
-
compareVersions(options) {
|
|
1528
|
-
return (options.client ?? this.client).get({
|
|
1529
|
-
requestValidator: async (data) => await zSpacesCompareVersionsData.parseAsync(data),
|
|
1530
|
-
responseValidator: async (data) => await zSpacesCompareVersionsResponse.parseAsync(data),
|
|
1531
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1532
|
-
url: '/api/v1/space/{space_id}/versions/compare',
|
|
1533
|
-
...options
|
|
1534
|
-
});
|
|
1535
|
-
}
|
|
1536
|
-
/**
|
|
1537
|
-
* Rollback space to version
|
|
1538
|
-
*
|
|
1539
|
-
* Restore space to a specific published version
|
|
1540
|
-
*/
|
|
1541
|
-
rollback(options) {
|
|
1542
|
-
return (options.client ?? this.client).post({
|
|
1543
|
-
requestValidator: async (data) => await zSpacesRollbackData.parseAsync(data),
|
|
1544
|
-
responseValidator: async (data) => await zSpacesRollbackResponse.parseAsync(data),
|
|
1545
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1546
|
-
url: '/api/v1/space/{space_id}/rollback',
|
|
1547
|
-
...options,
|
|
1548
|
-
headers: {
|
|
1549
|
-
'Content-Type': 'application/json',
|
|
1550
|
-
...options.headers
|
|
1551
|
-
}
|
|
1552
|
-
});
|
|
1553
|
-
}
|
|
1554
|
-
/**
|
|
1555
|
-
* Remove User From Space Role
|
|
1556
|
-
*
|
|
1557
|
-
* Remove a user from a space role.
|
|
1558
|
-
*
|
|
1559
|
-
* Requires space member management permissions.
|
|
1560
|
-
*/
|
|
1561
|
-
removeUserFromRole(options) {
|
|
1562
|
-
return (options.client ?? this.client).delete({
|
|
1563
|
-
requestValidator: async (data) => await zSpacesRemoveUserFromRoleData.parseAsync(data),
|
|
1564
|
-
responseValidator: async (data) => await zSpacesRemoveUserFromRoleResponse.parseAsync(data),
|
|
1565
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1566
|
-
url: '/api/v1/space/spaces/{space_id}/members/{user_id}/roles/{space_role_id}',
|
|
1567
|
-
...options
|
|
1568
|
-
});
|
|
1569
|
-
}
|
|
1570
|
-
}
|
|
1571
|
-
export class SpaceRoles extends HeyApiClient {
|
|
1572
|
-
/**
|
|
1573
|
-
* List Space Roles
|
|
1574
|
-
*
|
|
1575
|
-
* List all roles for a space.
|
|
1576
|
-
*
|
|
1577
|
-
* Requires space read permissions.
|
|
1578
|
-
*/
|
|
1579
|
-
listRoles(options) {
|
|
1580
|
-
return (options.client ?? this.client).get({
|
|
1581
|
-
requestValidator: async (data) => await zSpaceRolesListRolesData.parseAsync(data),
|
|
1582
|
-
responseValidator: async (data) => await zSpaceRolesListRolesResponse.parseAsync(data),
|
|
1583
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1584
|
-
url: '/api/v1/space/spaces/{space_id}/roles/',
|
|
1585
|
-
...options
|
|
1586
|
-
});
|
|
1587
|
-
}
|
|
1588
|
-
/**
|
|
1589
|
-
* Create Space Role
|
|
1590
|
-
*
|
|
1591
|
-
* Create a new role for a space.
|
|
1592
|
-
*
|
|
1593
|
-
* Requires space management permissions.
|
|
1594
|
-
*/
|
|
1595
|
-
create(options) {
|
|
1596
|
-
return (options.client ?? this.client).post({
|
|
1597
|
-
requestValidator: async (data) => await zSpaceRolesCreateData.parseAsync(data),
|
|
1598
|
-
responseValidator: async (data) => await zSpaceRolesCreateResponse.parseAsync(data),
|
|
1599
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1600
|
-
url: '/api/v1/space/spaces/{space_id}/roles/',
|
|
1601
|
-
...options,
|
|
1602
|
-
headers: {
|
|
1603
|
-
'Content-Type': 'application/json',
|
|
1604
|
-
...options.headers
|
|
1605
|
-
}
|
|
1606
|
-
});
|
|
1607
|
-
}
|
|
1608
|
-
/**
|
|
1609
|
-
* Delete Space Role
|
|
1610
|
-
*
|
|
1611
|
-
* Delete a space role.
|
|
1612
|
-
*
|
|
1613
|
-
* Requires space management permissions.
|
|
1614
|
-
*/
|
|
1615
|
-
delete(options) {
|
|
1616
|
-
return (options.client ?? this.client).delete({
|
|
1617
|
-
requestValidator: async (data) => await zSpaceRolesDeleteData.parseAsync(data),
|
|
1618
|
-
responseValidator: async (data) => await zSpaceRolesDeleteResponse.parseAsync(data),
|
|
1619
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1620
|
-
url: '/api/v1/space/spaces/{space_id}/roles/{role_id}',
|
|
1621
|
-
...options
|
|
1622
|
-
});
|
|
1623
|
-
}
|
|
1624
|
-
/**
|
|
1625
|
-
* Get Space Role
|
|
1626
|
-
*
|
|
1627
|
-
* Get a specific space role by ID.
|
|
1628
|
-
*
|
|
1629
|
-
* Requires space read permissions.
|
|
1630
|
-
*/
|
|
1631
|
-
get(options) {
|
|
1632
|
-
return (options.client ?? this.client).get({
|
|
1633
|
-
requestValidator: async (data) => await zSpaceRolesGetData.parseAsync(data),
|
|
1634
|
-
responseValidator: async (data) => await zSpaceRolesGetResponse.parseAsync(data),
|
|
1635
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1636
|
-
url: '/api/v1/space/spaces/{space_id}/roles/{role_id}',
|
|
1637
|
-
...options
|
|
1638
|
-
});
|
|
1639
|
-
}
|
|
1640
|
-
/**
|
|
1641
|
-
* Update Space Role
|
|
1642
|
-
*
|
|
1643
|
-
* Update a space role.
|
|
1644
|
-
*
|
|
1645
|
-
* Requires space management permissions.
|
|
1646
|
-
*/
|
|
1647
|
-
updateRole(options) {
|
|
1648
|
-
return (options.client ?? this.client).put({
|
|
1649
|
-
requestValidator: async (data) => await zSpaceRolesUpdateRoleData.parseAsync(data),
|
|
1650
|
-
responseValidator: async (data) => await zSpaceRolesUpdateRoleResponse.parseAsync(data),
|
|
1651
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1652
|
-
url: '/api/v1/space/spaces/{space_id}/roles/{role_id}',
|
|
1653
|
-
...options,
|
|
1654
|
-
headers: {
|
|
1655
|
-
'Content-Type': 'application/json',
|
|
1656
|
-
...options.headers
|
|
1657
|
-
}
|
|
1658
|
-
});
|
|
1659
|
-
}
|
|
1660
|
-
/**
|
|
1661
|
-
* Assign Permission To Space Role
|
|
1662
|
-
*
|
|
1663
|
-
* Assign a permission to a space role.
|
|
1664
|
-
*
|
|
1665
|
-
* Requires space management permissions.
|
|
1666
|
-
*/
|
|
1667
|
-
assignPermission(options) {
|
|
1668
|
-
return (options.client ?? this.client).post({
|
|
1669
|
-
requestValidator: async (data) => await zSpaceRolesAssignPermissionData.parseAsync(data),
|
|
1670
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1671
|
-
url: '/api/v1/space/spaces/{space_id}/roles/{role_id}/permissions',
|
|
1672
|
-
...options,
|
|
1673
|
-
headers: {
|
|
1674
|
-
'Content-Type': 'application/json',
|
|
1675
|
-
...options.headers
|
|
1676
|
-
}
|
|
1677
|
-
});
|
|
1678
|
-
}
|
|
1679
|
-
/**
|
|
1680
|
-
* Remove Permission From Space Role
|
|
1681
|
-
*
|
|
1682
|
-
* Remove a permission from a space role.
|
|
1683
|
-
*
|
|
1684
|
-
* Requires space management permissions.
|
|
1685
|
-
*/
|
|
1686
|
-
removePermission(options) {
|
|
1687
|
-
return (options.client ?? this.client).delete({
|
|
1688
|
-
requestValidator: async (data) => await zSpaceRolesRemovePermissionData.parseAsync(data),
|
|
1689
|
-
responseValidator: async (data) => await zSpaceRolesRemovePermissionResponse.parseAsync(data),
|
|
1690
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1691
|
-
url: '/api/v1/space/spaces/{space_id}/roles/{role_id}/permissions/{permission_id}',
|
|
1692
|
-
...options
|
|
1693
|
-
});
|
|
1694
|
-
}
|
|
1695
|
-
}
|
|
1696
|
-
export class SpaceContacts extends HeyApiClient {
|
|
1697
|
-
/**
|
|
1698
|
-
* Get Space Contacts
|
|
1699
|
-
*
|
|
1700
|
-
* Get all contacts for a specific space.
|
|
1701
|
-
*
|
|
1702
|
-
* Args:
|
|
1703
|
-
* space_id: Space ID
|
|
1704
|
-
* limit: Maximum number of contacts to return
|
|
1705
|
-
* offset: Number of contacts to skip
|
|
1706
|
-
* current_user: Current authenticated user
|
|
1707
|
-
* tenant_ctx: Tenant context
|
|
1708
|
-
* service: Space contact service
|
|
1709
|
-
*
|
|
1710
|
-
* Returns:
|
|
1711
|
-
* List of space contacts with total count
|
|
1712
|
-
*/
|
|
1713
|
-
getContactsBySpace(options) {
|
|
1714
|
-
return (options.client ?? this.client).get({
|
|
1715
|
-
requestValidator: async (data) => await zSpaceContactsGetContactsBySpaceData.parseAsync(data),
|
|
1716
|
-
responseValidator: async (data) => await zSpaceContactsGetContactsBySpaceResponse.parseAsync(data),
|
|
1717
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1718
|
-
url: '/api/v1/spaces/{space_id}/contacts',
|
|
1719
|
-
...options
|
|
1720
|
-
});
|
|
1721
|
-
}
|
|
1722
|
-
/**
|
|
1723
|
-
* Add Contact To Space
|
|
1724
|
-
*
|
|
1725
|
-
* Add a contact to a space.
|
|
1726
|
-
*
|
|
1727
|
-
* Args:
|
|
1728
|
-
* space_id: Space ID
|
|
1729
|
-
* request: Space contact creation request
|
|
1730
|
-
* current_user: Current authenticated user
|
|
1731
|
-
* tenant_ctx: Tenant context
|
|
1732
|
-
* service: Space contact service
|
|
1733
|
-
*
|
|
1734
|
-
* Returns:
|
|
1735
|
-
* Created space contact
|
|
1736
|
-
*/
|
|
1737
|
-
add(options) {
|
|
1738
|
-
return (options.client ?? this.client).post({
|
|
1739
|
-
requestValidator: async (data) => await zSpaceContactsAddData.parseAsync(data),
|
|
1740
|
-
responseValidator: async (data) => await zSpaceContactsAddResponse.parseAsync(data),
|
|
1741
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1742
|
-
url: '/api/v1/spaces/{space_id}/contacts',
|
|
1743
|
-
...options,
|
|
1744
|
-
headers: {
|
|
1745
|
-
'Content-Type': 'application/json',
|
|
1746
|
-
...options.headers
|
|
1747
|
-
}
|
|
1748
|
-
});
|
|
1749
|
-
}
|
|
1750
|
-
/**
|
|
1751
|
-
* Get Contact Spaces
|
|
1752
|
-
*
|
|
1753
|
-
* Get all spaces for a specific contact.
|
|
1754
|
-
*
|
|
1755
|
-
* Args:
|
|
1756
|
-
* contact_id: Contact ID
|
|
1757
|
-
* limit: Maximum number of spaces to return
|
|
1758
|
-
* offset: Number of spaces to skip
|
|
1759
|
-
* current_user: Current authenticated user
|
|
1760
|
-
* tenant_ctx: Tenant context
|
|
1761
|
-
* service: Space contact service
|
|
1762
|
-
*
|
|
1763
|
-
* Returns:
|
|
1764
|
-
* List of space contacts
|
|
1765
|
-
*/
|
|
1766
|
-
getSpacesByContact(options) {
|
|
1767
|
-
return (options.client ?? this.client).get({
|
|
1768
|
-
requestValidator: async (data) => await zSpaceContactsGetSpacesByContactData.parseAsync(data),
|
|
1769
|
-
responseValidator: async (data) => await zSpaceContactsGetSpacesByContactResponse.parseAsync(data),
|
|
1770
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1771
|
-
url: '/api/v1/contacts/{contact_id}/spaces',
|
|
1772
|
-
...options
|
|
1773
|
-
});
|
|
1774
|
-
}
|
|
1775
|
-
/**
|
|
1776
|
-
* Remove Contact From Space
|
|
1777
|
-
*
|
|
1778
|
-
* Remove a contact from a space.
|
|
1779
|
-
*
|
|
1780
|
-
* Args:
|
|
1781
|
-
* space_contact_id: Space contact relationship ID
|
|
1782
|
-
* current_user: Current authenticated user
|
|
1783
|
-
* tenant_ctx: Tenant context
|
|
1784
|
-
* service: Space contact service
|
|
1785
|
-
*
|
|
1786
|
-
* Returns:
|
|
1787
|
-
* Success message
|
|
1788
|
-
*/
|
|
1789
|
-
remove(options) {
|
|
1790
|
-
return (options.client ?? this.client).delete({
|
|
1791
|
-
requestValidator: async (data) => await zSpaceContactsRemoveData.parseAsync(data),
|
|
1792
|
-
responseValidator: async (data) => await zSpaceContactsRemoveResponse.parseAsync(data),
|
|
1793
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1794
|
-
url: '/api/v1/space-contacts/{space_contact_id}',
|
|
1795
|
-
...options
|
|
1796
|
-
});
|
|
1797
|
-
}
|
|
1798
|
-
/**
|
|
1799
|
-
* Get Space Contact
|
|
1800
|
-
*
|
|
1801
|
-
* Get space contact by ID.
|
|
1802
|
-
*
|
|
1803
|
-
* Args:
|
|
1804
|
-
* space_contact_id: Space contact relationship ID
|
|
1805
|
-
* current_user: Current authenticated user
|
|
1806
|
-
* tenant_ctx: Tenant context
|
|
1807
|
-
* service: Space contact service
|
|
1808
|
-
*
|
|
1809
|
-
* Returns:
|
|
1810
|
-
* Space contact details
|
|
1811
|
-
*/
|
|
1812
|
-
get(options) {
|
|
1813
|
-
return (options.client ?? this.client).get({
|
|
1814
|
-
requestValidator: async (data) => await zSpaceContactsGetData.parseAsync(data),
|
|
1815
|
-
responseValidator: async (data) => await zSpaceContactsGetResponse.parseAsync(data),
|
|
1816
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1817
|
-
url: '/api/v1/space-contacts/{space_contact_id}',
|
|
1818
|
-
...options
|
|
1819
|
-
});
|
|
1820
|
-
}
|
|
1821
|
-
/**
|
|
1822
|
-
* Bulk Remove Contacts From Space
|
|
1823
|
-
*
|
|
1824
|
-
* Bulk remove contacts from a space.
|
|
1825
|
-
*
|
|
1826
|
-
* Args:
|
|
1827
|
-
* space_id: Space ID
|
|
1828
|
-
* contact_ids: List of contact IDs to remove
|
|
1829
|
-
* current_user: Current authenticated user
|
|
1830
|
-
* tenant_ctx: Tenant context
|
|
1831
|
-
* service: Space contact service
|
|
1832
|
-
*
|
|
1833
|
-
* Returns:
|
|
1834
|
-
* Number of contacts removed
|
|
1835
|
-
*/
|
|
1836
|
-
bulkDelete(options) {
|
|
1837
|
-
return (options.client ?? this.client).delete({
|
|
1838
|
-
requestValidator: async (data) => await zSpaceContactsBulkDeleteData.parseAsync(data),
|
|
1839
|
-
responseValidator: async (data) => await zSpaceContactsBulkDeleteResponse.parseAsync(data),
|
|
1840
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1841
|
-
url: '/api/v1/spaces/{space_id}/contacts/bulk',
|
|
1842
|
-
...options,
|
|
1843
|
-
headers: {
|
|
1844
|
-
'Content-Type': 'application/json',
|
|
1845
|
-
...options.headers
|
|
1846
|
-
}
|
|
1847
|
-
});
|
|
1848
|
-
}
|
|
1849
|
-
/**
|
|
1850
|
-
* Bulk Add Contacts To Space
|
|
1851
|
-
*
|
|
1852
|
-
* Add multiple contacts to a space.
|
|
1853
|
-
*
|
|
1854
|
-
* Args:
|
|
1855
|
-
* space_id: Space ID
|
|
1856
|
-
* contact_ids: List of contact IDs to add
|
|
1857
|
-
* current_user: Current authenticated user
|
|
1858
|
-
* tenant_ctx: Tenant context
|
|
1859
|
-
* service: Space contact service
|
|
1860
|
-
*
|
|
1861
|
-
* Returns:
|
|
1862
|
-
* List of created space contacts
|
|
1863
|
-
*/
|
|
1864
|
-
addBulk(options) {
|
|
1865
|
-
return (options.client ?? this.client).post({
|
|
1866
|
-
requestValidator: async (data) => await zSpaceContactsAddBulkData.parseAsync(data),
|
|
1867
|
-
responseValidator: async (data) => await zSpaceContactsAddBulkResponse.parseAsync(data),
|
|
1868
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1869
|
-
url: '/api/v1/spaces/{space_id}/contacts/bulk',
|
|
1870
|
-
...options,
|
|
1871
|
-
headers: {
|
|
1872
|
-
'Content-Type': 'application/json',
|
|
1873
|
-
...options.headers
|
|
1874
|
-
}
|
|
1875
|
-
});
|
|
1876
|
-
}
|
|
1877
|
-
/**
|
|
1878
|
-
* Count Space Contacts
|
|
1879
|
-
*
|
|
1880
|
-
* Count contacts in a space.
|
|
1881
|
-
*
|
|
1882
|
-
* Args:
|
|
1883
|
-
* space_id: Space ID
|
|
1884
|
-
* current_user: Current authenticated user
|
|
1885
|
-
* tenant_ctx: Tenant context
|
|
1886
|
-
* service: Space contact service
|
|
1887
|
-
*
|
|
1888
|
-
* Returns:
|
|
1889
|
-
* Number of contacts in space
|
|
1890
|
-
*/
|
|
1891
|
-
count(options) {
|
|
1892
|
-
return (options.client ?? this.client).get({
|
|
1893
|
-
requestValidator: async (data) => await zSpaceContactsCountData.parseAsync(data),
|
|
1894
|
-
responseValidator: async (data) => await zSpaceContactsCountResponse.parseAsync(data),
|
|
1895
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1896
|
-
url: '/api/v1/spaces/{space_id}/contacts/count',
|
|
1897
|
-
...options
|
|
1898
|
-
});
|
|
1899
|
-
}
|
|
1900
|
-
}
|
|
1901
|
-
export class SpaceEvents extends HeyApiClient {
|
|
1902
|
-
/**
|
|
1903
|
-
* Get Space Events
|
|
1904
|
-
*
|
|
1905
|
-
* Get all events for a specific space.
|
|
1906
|
-
*
|
|
1907
|
-
* Args:
|
|
1908
|
-
* space_id: Space ID
|
|
1909
|
-
* limit: Maximum number of events to return
|
|
1910
|
-
* offset: Number of events to skip
|
|
1911
|
-
* current_user: Current authenticated user
|
|
1912
|
-
* tenant_ctx: Tenant context
|
|
1913
|
-
* service: Space event service
|
|
1914
|
-
*
|
|
1915
|
-
* Returns:
|
|
1916
|
-
* List of space events with total count
|
|
1917
|
-
*/
|
|
1918
|
-
get(options) {
|
|
1919
|
-
return (options.client ?? this.client).get({
|
|
1920
|
-
requestValidator: async (data) => await zSpaceEventsGetData.parseAsync(data),
|
|
1921
|
-
responseValidator: async (data) => await zSpaceEventsGetResponse.parseAsync(data),
|
|
1922
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1923
|
-
url: '/api/v1/spaces/{space_id}/events',
|
|
1924
|
-
...options
|
|
1925
|
-
});
|
|
1926
|
-
}
|
|
1927
|
-
/**
|
|
1928
|
-
* Add Event To Space
|
|
1929
|
-
*
|
|
1930
|
-
* Add an event to a space.
|
|
1931
|
-
*
|
|
1932
|
-
* Args:
|
|
1933
|
-
* space_id: Space ID
|
|
1934
|
-
* request: Space event creation request
|
|
1935
|
-
* current_user: Current authenticated user
|
|
1936
|
-
* tenant_ctx: Tenant context
|
|
1937
|
-
* service: Space event service
|
|
1938
|
-
*
|
|
1939
|
-
* Returns:
|
|
1940
|
-
* Created space event
|
|
1941
|
-
*/
|
|
1942
|
-
add(options) {
|
|
1943
|
-
return (options.client ?? this.client).post({
|
|
1944
|
-
requestValidator: async (data) => await zSpaceEventsAddData.parseAsync(data),
|
|
1945
|
-
responseValidator: async (data) => await zSpaceEventsAddResponse.parseAsync(data),
|
|
1946
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1947
|
-
url: '/api/v1/spaces/{space_id}/events',
|
|
1948
|
-
...options,
|
|
1949
|
-
headers: {
|
|
1950
|
-
'Content-Type': 'application/json',
|
|
1951
|
-
...options.headers
|
|
1952
|
-
}
|
|
1953
|
-
});
|
|
1954
|
-
}
|
|
1955
|
-
/**
|
|
1956
|
-
* Get Event Spaces
|
|
1957
|
-
*
|
|
1958
|
-
* Get all spaces for a specific event.
|
|
1959
|
-
*
|
|
1960
|
-
* Args:
|
|
1961
|
-
* event_id: Event ID
|
|
1962
|
-
* limit: Maximum number of spaces to return
|
|
1963
|
-
* offset: Number of spaces to skip
|
|
1964
|
-
* current_user: Current authenticated user
|
|
1965
|
-
* tenant_ctx: Tenant context
|
|
1966
|
-
* service: Space event service
|
|
1967
|
-
*
|
|
1968
|
-
* Returns:
|
|
1969
|
-
* List of space events
|
|
1970
|
-
*/
|
|
1971
|
-
getEventSpaces(options) {
|
|
1972
|
-
return (options.client ?? this.client).get({
|
|
1973
|
-
requestValidator: async (data) => await zSpaceEventsGetEventSpacesData.parseAsync(data),
|
|
1974
|
-
responseValidator: async (data) => await zSpaceEventsGetEventSpacesResponse.parseAsync(data),
|
|
1975
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1976
|
-
url: '/api/v1/events/{event_id}/spaces',
|
|
1977
|
-
...options
|
|
1978
|
-
});
|
|
1979
|
-
}
|
|
1980
|
-
/**
|
|
1981
|
-
* Remove Event From Space
|
|
1982
|
-
*
|
|
1983
|
-
* Remove an event from a space.
|
|
1984
|
-
*
|
|
1985
|
-
* Args:
|
|
1986
|
-
* space_event_id: Space event relationship ID
|
|
1987
|
-
* current_user: Current authenticated user
|
|
1988
|
-
* tenant_ctx: Tenant context
|
|
1989
|
-
* service: Space event service
|
|
1990
|
-
*
|
|
1991
|
-
* Returns:
|
|
1992
|
-
* Success message
|
|
1993
|
-
*/
|
|
1994
|
-
removeEvent(options) {
|
|
1995
|
-
return (options.client ?? this.client).delete({
|
|
1996
|
-
requestValidator: async (data) => await zSpaceEventsRemoveEventData.parseAsync(data),
|
|
1997
|
-
responseValidator: async (data) => await zSpaceEventsRemoveEventResponse.parseAsync(data),
|
|
1998
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
1999
|
-
url: '/api/v1/space-events/{space_event_id}',
|
|
2000
|
-
...options
|
|
2001
|
-
});
|
|
2002
|
-
}
|
|
2003
|
-
/**
|
|
2004
|
-
* Get Space Event
|
|
2005
|
-
*
|
|
2006
|
-
* Get space event by ID.
|
|
2007
|
-
*
|
|
2008
|
-
* Args:
|
|
2009
|
-
* space_event_id: Space event relationship ID
|
|
2010
|
-
* current_user: Current authenticated user
|
|
2011
|
-
* tenant_ctx: Tenant context
|
|
2012
|
-
* service: Space event service
|
|
2013
|
-
*
|
|
2014
|
-
* Returns:
|
|
2015
|
-
* Space event details
|
|
2016
|
-
*/
|
|
2017
|
-
getById(options) {
|
|
2018
|
-
return (options.client ?? this.client).get({
|
|
2019
|
-
requestValidator: async (data) => await zSpaceEventsGetByIdData.parseAsync(data),
|
|
2020
|
-
responseValidator: async (data) => await zSpaceEventsGetByIdResponse.parseAsync(data),
|
|
2021
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2022
|
-
url: '/api/v1/space-events/{space_event_id}',
|
|
2023
|
-
...options
|
|
2024
|
-
});
|
|
2025
|
-
}
|
|
2026
|
-
/**
|
|
2027
|
-
* Bulk Remove Events From Space
|
|
2028
|
-
*
|
|
2029
|
-
* Bulk remove events from a space.
|
|
2030
|
-
*
|
|
2031
|
-
* Args:
|
|
2032
|
-
* space_id: Space ID
|
|
2033
|
-
* event_ids: List of event IDs to remove
|
|
2034
|
-
* current_user: Current authenticated user
|
|
2035
|
-
* tenant_ctx: Tenant context
|
|
2036
|
-
* service: Space event service
|
|
2037
|
-
*
|
|
2038
|
-
* Returns:
|
|
2039
|
-
* Number of events removed
|
|
2040
|
-
*/
|
|
2041
|
-
bulkRemove(options) {
|
|
2042
|
-
return (options.client ?? this.client).delete({
|
|
2043
|
-
requestValidator: async (data) => await zSpaceEventsBulkRemoveData.parseAsync(data),
|
|
2044
|
-
responseValidator: async (data) => await zSpaceEventsBulkRemoveResponse.parseAsync(data),
|
|
2045
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2046
|
-
url: '/api/v1/spaces/{space_id}/events/bulk',
|
|
2047
|
-
...options
|
|
2048
|
-
});
|
|
2049
|
-
}
|
|
2050
|
-
/**
|
|
2051
|
-
* Bulk Add Events To Space
|
|
2052
|
-
*
|
|
2053
|
-
* Add multiple events to a space.
|
|
2054
|
-
*
|
|
2055
|
-
* Args:
|
|
2056
|
-
* space_id: Space ID
|
|
2057
|
-
* event_ids: List of event IDs to add
|
|
2058
|
-
* current_user: Current authenticated user
|
|
2059
|
-
* tenant_ctx: Tenant context
|
|
2060
|
-
* service: Space event service
|
|
2061
|
-
*
|
|
2062
|
-
* Returns:
|
|
2063
|
-
* List of created space events
|
|
2064
|
-
*/
|
|
2065
|
-
bulkAdd(options) {
|
|
2066
|
-
return (options.client ?? this.client).post({
|
|
2067
|
-
requestValidator: async (data) => await zSpaceEventsBulkAddData.parseAsync(data),
|
|
2068
|
-
responseValidator: async (data) => await zSpaceEventsBulkAddResponse.parseAsync(data),
|
|
2069
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2070
|
-
url: '/api/v1/spaces/{space_id}/events/bulk',
|
|
2071
|
-
...options,
|
|
2072
|
-
headers: {
|
|
2073
|
-
'Content-Type': 'application/json',
|
|
2074
|
-
...options.headers
|
|
2075
|
-
}
|
|
2076
|
-
});
|
|
2077
|
-
}
|
|
2078
|
-
/**
|
|
2079
|
-
* Count Space Events
|
|
2080
|
-
*
|
|
2081
|
-
* Count events in a space.
|
|
2082
|
-
*
|
|
2083
|
-
* Args:
|
|
2084
|
-
* space_id: Space ID
|
|
2085
|
-
* current_user: Current authenticated user
|
|
2086
|
-
* tenant_ctx: Tenant context
|
|
2087
|
-
* service: Space event service
|
|
2088
|
-
*
|
|
2089
|
-
* Returns:
|
|
2090
|
-
* Number of events in space
|
|
2091
|
-
*/
|
|
2092
|
-
count(options) {
|
|
2093
|
-
return (options.client ?? this.client).get({
|
|
2094
|
-
requestValidator: async (data) => await zSpaceEventsCountData.parseAsync(data),
|
|
2095
|
-
responseValidator: async (data) => await zSpaceEventsCountResponse.parseAsync(data),
|
|
2096
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2097
|
-
url: '/api/v1/spaces/{space_id}/events/count',
|
|
2098
|
-
...options
|
|
2099
|
-
});
|
|
2100
|
-
}
|
|
2101
|
-
}
|
|
2102
|
-
export class SpaceDocuments extends HeyApiClient {
|
|
2103
|
-
/**
|
|
2104
|
-
* Remove Document From Space
|
|
2105
|
-
*
|
|
2106
|
-
* Remove a document from a space.
|
|
2107
|
-
*/
|
|
2108
|
-
remove(options) {
|
|
2109
|
-
return (options.client ?? this.client).delete({
|
|
2110
|
-
requestValidator: async (data) => await zSpaceDocumentsRemoveData.parseAsync(data),
|
|
2111
|
-
responseValidator: async (data) => await zSpaceDocumentsRemoveResponse.parseAsync(data),
|
|
2112
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2113
|
-
url: '/api/v1/spaces/{space_id}/documents/{document_id}',
|
|
2114
|
-
...options
|
|
2115
|
-
});
|
|
2116
|
-
}
|
|
2117
|
-
/**
|
|
2118
|
-
* Add Document To Space
|
|
2119
|
-
*
|
|
2120
|
-
* Associate a document with a space.
|
|
2121
|
-
*/
|
|
2122
|
-
add(options) {
|
|
2123
|
-
return (options.client ?? this.client).post({
|
|
2124
|
-
requestValidator: async (data) => await zSpaceDocumentsAddData.parseAsync(data),
|
|
2125
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2126
|
-
url: '/api/v1/spaces/{space_id}/documents/{document_id}',
|
|
2127
|
-
...options
|
|
2128
|
-
});
|
|
2129
|
-
}
|
|
2130
|
-
/**
|
|
2131
|
-
* Get Space Documents
|
|
2132
|
-
*
|
|
2133
|
-
* Get all documents for a space.
|
|
2134
|
-
*/
|
|
2135
|
-
get(options) {
|
|
2136
|
-
return (options.client ?? this.client).get({
|
|
2137
|
-
requestValidator: async (data) => await zSpaceDocumentsGetData.parseAsync(data),
|
|
2138
|
-
responseValidator: async (data) => await zSpaceDocumentsGetResponse.parseAsync(data),
|
|
2139
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2140
|
-
url: '/api/v1/spaces/{space_id}/documents',
|
|
2141
|
-
...options
|
|
2142
|
-
});
|
|
2143
|
-
}
|
|
2144
|
-
}
|
|
2145
|
-
export class Places extends HeyApiClient {
|
|
2146
|
-
/**
|
|
2147
|
-
* Get Place List
|
|
2148
|
-
*/
|
|
2149
|
-
list(options) {
|
|
2150
|
-
return (options?.client ?? this.client).get({
|
|
2151
|
-
requestValidator: async (data) => await zPlacesListData.parseAsync(data),
|
|
2152
|
-
responseValidator: async (data) => await zPlacesListResponse.parseAsync(data),
|
|
2153
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2154
|
-
url: '/api/v1/place',
|
|
2155
|
-
...options
|
|
2156
|
-
});
|
|
2157
|
-
}
|
|
2158
|
-
/**
|
|
2159
|
-
* Create Place
|
|
2160
|
-
*/
|
|
2161
|
-
create(options) {
|
|
2162
|
-
return (options.client ?? this.client).post({
|
|
2163
|
-
requestValidator: async (data) => await zPlacesCreateData.parseAsync(data),
|
|
2164
|
-
responseValidator: async (data) => await zPlacesCreateResponse.parseAsync(data),
|
|
2165
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2166
|
-
url: '/api/v1/place',
|
|
2167
|
-
...options,
|
|
2168
|
-
headers: {
|
|
2169
|
-
'Content-Type': 'application/json',
|
|
2170
|
-
...options.headers
|
|
2171
|
-
}
|
|
2172
|
-
});
|
|
2173
|
-
}
|
|
2174
|
-
/**
|
|
2175
|
-
* Delete Place
|
|
2176
|
-
*/
|
|
2177
|
-
delete(options) {
|
|
2178
|
-
return (options.client ?? this.client).delete({
|
|
2179
|
-
requestValidator: async (data) => await zPlacesDeleteData.parseAsync(data),
|
|
2180
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2181
|
-
url: '/api/v1/place/{place_id}',
|
|
2182
|
-
...options
|
|
2183
|
-
});
|
|
2184
|
-
}
|
|
2185
|
-
/**
|
|
2186
|
-
* Get Place By Id
|
|
2187
|
-
*/
|
|
2188
|
-
get(options) {
|
|
2189
|
-
return (options.client ?? this.client).get({
|
|
2190
|
-
requestValidator: async (data) => await zPlacesGetData.parseAsync(data),
|
|
2191
|
-
responseValidator: async (data) => await zPlacesGetResponse.parseAsync(data),
|
|
2192
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2193
|
-
url: '/api/v1/place/{place_id}',
|
|
2194
|
-
...options
|
|
2195
|
-
});
|
|
2196
|
-
}
|
|
2197
|
-
/**
|
|
2198
|
-
* Update Place
|
|
2199
|
-
*/
|
|
2200
|
-
update(options) {
|
|
2201
|
-
return (options.client ?? this.client).put({
|
|
2202
|
-
requestValidator: async (data) => await zPlacesUpdateData.parseAsync(data),
|
|
2203
|
-
responseValidator: async (data) => await zPlacesUpdateResponse.parseAsync(data),
|
|
2204
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2205
|
-
url: '/api/v1/place/{place_id}',
|
|
2206
|
-
...options,
|
|
2207
|
-
headers: {
|
|
2208
|
-
'Content-Type': 'application/json',
|
|
2209
|
-
...options.headers
|
|
2210
|
-
}
|
|
2211
|
-
});
|
|
2212
|
-
}
|
|
2213
|
-
}
|
|
2214
|
-
export class Place extends HeyApiClient {
|
|
2215
|
-
/**
|
|
2216
|
-
* Publish Place
|
|
2217
|
-
*/
|
|
2218
|
-
publish(options) {
|
|
2219
|
-
return (options.client ?? this.client).patch({
|
|
2220
|
-
requestValidator: async (data) => await zPlacePublishData.parseAsync(data),
|
|
2221
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2222
|
-
url: '/api/v1/place/{place_id}/publish',
|
|
2223
|
-
...options
|
|
2224
|
-
});
|
|
2225
|
-
}
|
|
2226
|
-
/**
|
|
2227
|
-
* Archive Place
|
|
2228
|
-
*/
|
|
2229
|
-
archive(options) {
|
|
2230
|
-
return (options.client ?? this.client).patch({
|
|
2231
|
-
requestValidator: async (data) => await zPlaceArchiveData.parseAsync(data),
|
|
2232
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2233
|
-
url: '/api/v1/place/{place_id}/archive',
|
|
2234
|
-
...options
|
|
2235
|
-
});
|
|
2236
|
-
}
|
|
2237
|
-
}
|
|
2238
|
-
export class Analytic extends HeyApiClient {
|
|
2239
|
-
/**
|
|
2240
|
-
* Get Analytic Totals
|
|
2241
|
-
*/
|
|
2242
|
-
getTotals(options) {
|
|
2243
|
-
return (options?.client ?? this.client).get({
|
|
2244
|
-
requestValidator: async (data) => await zAnalyticGetTotalsData.parseAsync(data),
|
|
2245
|
-
responseValidator: async (data) => await zAnalyticGetTotalsResponse.parseAsync(data),
|
|
2246
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2247
|
-
url: '/api/v1/analytic/counts',
|
|
2248
|
-
...options
|
|
2249
|
-
});
|
|
2250
|
-
}
|
|
2251
|
-
/**
|
|
2252
|
-
* Get Dashboard Analytics
|
|
2253
|
-
*/
|
|
2254
|
-
getDashboard(options) {
|
|
2255
|
-
return (options?.client ?? this.client).get({
|
|
2256
|
-
requestValidator: async (data) => await zAnalyticGetDashboardData.parseAsync(data),
|
|
2257
|
-
responseValidator: async (data) => await zAnalyticGetDashboardResponse.parseAsync(data),
|
|
2258
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2259
|
-
url: '/api/v1/analytic/dashboard',
|
|
2260
|
-
...options
|
|
2261
|
-
});
|
|
2262
|
-
}
|
|
2263
|
-
}
|
|
2264
|
-
export class Organizations extends HeyApiClient {
|
|
2265
|
-
/**
|
|
2266
|
-
* List Organizations
|
|
2267
|
-
*
|
|
2268
|
-
* List all organizations the current user belongs to.
|
|
2269
|
-
*/
|
|
2270
|
-
list(options) {
|
|
2271
|
-
return (options?.client ?? this.client).get({
|
|
2272
|
-
requestValidator: async (data) => await zOrganizationsListData.parseAsync(data),
|
|
2273
|
-
responseValidator: async (data) => await zOrganizationsListResponse.parseAsync(data),
|
|
2274
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2275
|
-
url: '/api/v1/organizations',
|
|
2276
|
-
...options
|
|
2277
|
-
});
|
|
2278
|
-
}
|
|
2279
|
-
/**
|
|
2280
|
-
* Create Organization
|
|
2281
|
-
*
|
|
2282
|
-
* Create a new organization.
|
|
2283
|
-
*/
|
|
2284
|
-
create(options) {
|
|
2285
|
-
return (options.client ?? this.client).post({
|
|
2286
|
-
requestValidator: async (data) => await zOrganizationsCreateData.parseAsync(data),
|
|
2287
|
-
responseValidator: async (data) => await zOrganizationsCreateResponse.parseAsync(data),
|
|
2288
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2289
|
-
url: '/api/v1/organizations',
|
|
2290
|
-
...options,
|
|
2291
|
-
headers: {
|
|
2292
|
-
'Content-Type': 'application/json',
|
|
2293
|
-
...options.headers
|
|
2294
|
-
}
|
|
2295
|
-
});
|
|
2296
|
-
}
|
|
2297
|
-
/**
|
|
2298
|
-
* Get Current Organization
|
|
2299
|
-
*
|
|
2300
|
-
* Get the current organization from JWT claims.
|
|
2301
|
-
* Returns the org that the user is currently authenticated for.
|
|
2302
|
-
*/
|
|
2303
|
-
getCurrent(options) {
|
|
2304
|
-
return (options?.client ?? this.client).get({
|
|
2305
|
-
requestValidator: async (data) => await zOrganizationsGetCurrentData.parseAsync(data),
|
|
2306
|
-
responseValidator: async (data) => await zOrganizationsGetCurrentResponse.parseAsync(data),
|
|
2307
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2308
|
-
url: '/api/v1/organizations/me',
|
|
2309
|
-
...options
|
|
2310
|
-
});
|
|
2311
|
-
}
|
|
2312
|
-
/**
|
|
2313
|
-
* Get Organization Invites Endpoint
|
|
2314
|
-
*
|
|
2315
|
-
* Get all pending invitations for an organization.
|
|
2316
|
-
*/
|
|
2317
|
-
getInvites(options) {
|
|
2318
|
-
return (options.client ?? this.client).get({
|
|
2319
|
-
requestValidator: async (data) => await zOrganizationsGetInvitesData.parseAsync(data),
|
|
2320
|
-
responseValidator: async (data) => await zOrganizationsGetInvitesResponse.parseAsync(data),
|
|
2321
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2322
|
-
url: '/api/v1/organizations/{org_id}/invites',
|
|
2323
|
-
...options
|
|
2324
|
-
});
|
|
2325
|
-
}
|
|
2326
|
-
/**
|
|
2327
|
-
* Create Invite
|
|
2328
|
-
*
|
|
2329
|
-
* Create an invite to the organization. Requires owner or admin role.
|
|
2330
|
-
*/
|
|
2331
|
-
createInvite(options) {
|
|
2332
|
-
return (options.client ?? this.client).post({
|
|
2333
|
-
requestValidator: async (data) => await zOrganizationsCreateInviteData.parseAsync(data),
|
|
2334
|
-
responseValidator: async (data) => await zOrganizationsCreateInviteResponse.parseAsync(data),
|
|
2335
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2336
|
-
url: '/api/v1/organizations/{org_id}/invites',
|
|
2337
|
-
...options,
|
|
2338
|
-
headers: {
|
|
2339
|
-
'Content-Type': 'application/json',
|
|
2340
|
-
...options.headers
|
|
2341
|
-
}
|
|
2342
|
-
});
|
|
2343
|
-
}
|
|
2344
|
-
/**
|
|
2345
|
-
* Delete Invite
|
|
2346
|
-
*
|
|
2347
|
-
* Delete/rescind an organization invite. Requires owner or admin role.
|
|
2348
|
-
*/
|
|
2349
|
-
deleteInvite(options) {
|
|
2350
|
-
return (options.client ?? this.client).delete({
|
|
2351
|
-
requestValidator: async (data) => await zOrganizationsDeleteInviteData.parseAsync(data),
|
|
2352
|
-
responseValidator: async (data) => await zOrganizationsDeleteInviteResponse.parseAsync(data),
|
|
2353
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2354
|
-
url: '/api/v1/organizations/{org_id}/invites/{invite_id}',
|
|
2355
|
-
...options
|
|
2356
|
-
});
|
|
2357
|
-
}
|
|
2358
|
-
/**
|
|
2359
|
-
* Archive Organization Endpoint
|
|
2360
|
-
*
|
|
2361
|
-
* Archive an organization (soft delete). Requires owner role only.
|
|
2362
|
-
*/
|
|
2363
|
-
archive(options) {
|
|
2364
|
-
return (options.client ?? this.client).delete({
|
|
2365
|
-
requestValidator: async (data) => await zOrganizationsArchiveData.parseAsync(data),
|
|
2366
|
-
responseValidator: async (data) => await zOrganizationsArchiveResponse.parseAsync(data),
|
|
2367
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2368
|
-
url: '/api/v1/organizations/{org_id}',
|
|
2369
|
-
...options
|
|
2370
|
-
});
|
|
2371
|
-
}
|
|
2372
|
-
/**
|
|
2373
|
-
* Get Organization By Id
|
|
2374
|
-
*
|
|
2375
|
-
* Get a single organization by ID.
|
|
2376
|
-
*/
|
|
2377
|
-
getById(options) {
|
|
2378
|
-
return (options.client ?? this.client).get({
|
|
2379
|
-
requestValidator: async (data) => await zOrganizationsGetByIdData.parseAsync(data),
|
|
2380
|
-
responseValidator: async (data) => await zOrganizationsGetByIdResponse.parseAsync(data),
|
|
2381
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2382
|
-
url: '/api/v1/organizations/{org_id}',
|
|
2383
|
-
...options
|
|
2384
|
-
});
|
|
2385
|
-
}
|
|
2386
|
-
/**
|
|
2387
|
-
* Update Organization
|
|
2388
|
-
*
|
|
2389
|
-
* Update an organization. Requires owner or admin role.
|
|
2390
|
-
*/
|
|
2391
|
-
update(options) {
|
|
2392
|
-
return (options.client ?? this.client).put({
|
|
2393
|
-
requestValidator: async (data) => await zOrganizationsUpdateData.parseAsync(data),
|
|
2394
|
-
responseValidator: async (data) => await zOrganizationsUpdateResponse.parseAsync(data),
|
|
2395
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2396
|
-
url: '/api/v1/organizations/{org_id}',
|
|
2397
|
-
...options,
|
|
2398
|
-
headers: {
|
|
2399
|
-
'Content-Type': 'application/json',
|
|
2400
|
-
...options.headers
|
|
2401
|
-
}
|
|
2402
|
-
});
|
|
2403
|
-
}
|
|
2404
|
-
}
|
|
2405
|
-
export class CustomRoles extends HeyApiClient {
|
|
2406
|
-
/**
|
|
2407
|
-
* List Roles Endpoint
|
|
2408
|
-
*
|
|
2409
|
-
* List all custom roles for an organization.
|
|
2410
|
-
*/
|
|
2411
|
-
list(options) {
|
|
2412
|
-
return (options?.client ?? this.client).get({
|
|
2413
|
-
requestValidator: async (data) => await zCustomRolesListData.parseAsync(data),
|
|
2414
|
-
responseValidator: async (data) => await zCustomRolesListResponse.parseAsync(data),
|
|
2415
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2416
|
-
url: '/api/v1/roles',
|
|
2417
|
-
...options
|
|
2418
|
-
});
|
|
2419
|
-
}
|
|
2420
|
-
/**
|
|
2421
|
-
* Create Role Endpoint
|
|
2422
|
-
*
|
|
2423
|
-
* Create a new custom role.
|
|
2424
|
-
*/
|
|
2425
|
-
create(options) {
|
|
2426
|
-
return (options.client ?? this.client).post({
|
|
2427
|
-
requestValidator: async (data) => await zCustomRolesCreateData.parseAsync(data),
|
|
2428
|
-
responseValidator: async (data) => await zCustomRolesCreateResponse.parseAsync(data),
|
|
2429
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2430
|
-
url: '/api/v1/roles',
|
|
2431
|
-
...options,
|
|
2432
|
-
headers: {
|
|
2433
|
-
'Content-Type': 'application/json',
|
|
2434
|
-
...options.headers
|
|
2435
|
-
}
|
|
2436
|
-
});
|
|
2437
|
-
}
|
|
2438
|
-
/**
|
|
2439
|
-
* Get Role Endpoint
|
|
2440
|
-
*
|
|
2441
|
-
* Get a single custom role by ID.
|
|
2442
|
-
*/
|
|
2443
|
-
get(options) {
|
|
2444
|
-
return (options.client ?? this.client).get({
|
|
2445
|
-
requestValidator: async (data) => await zCustomRolesGetData.parseAsync(data),
|
|
2446
|
-
responseValidator: async (data) => await zCustomRolesGetResponse.parseAsync(data),
|
|
2447
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2448
|
-
url: '/api/v1/roles/{role_id}',
|
|
2449
|
-
...options
|
|
2450
|
-
});
|
|
2451
|
-
}
|
|
2452
|
-
/**
|
|
2453
|
-
* Update Role Endpoint
|
|
2454
|
-
*
|
|
2455
|
-
* Update an existing custom role.
|
|
2456
|
-
*/
|
|
2457
|
-
update(options) {
|
|
2458
|
-
return (options.client ?? this.client).put({
|
|
2459
|
-
requestValidator: async (data) => await zCustomRolesUpdateData.parseAsync(data),
|
|
2460
|
-
responseValidator: async (data) => await zCustomRolesUpdateResponse.parseAsync(data),
|
|
2461
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2462
|
-
url: '/api/v1/roles/{role_id}',
|
|
2463
|
-
...options,
|
|
2464
|
-
headers: {
|
|
2465
|
-
'Content-Type': 'application/json',
|
|
2466
|
-
...options.headers
|
|
2467
|
-
}
|
|
2468
|
-
});
|
|
2469
|
-
}
|
|
2470
|
-
/**
|
|
2471
|
-
* Add Permission Endpoint
|
|
2472
|
-
*
|
|
2473
|
-
* Add a permission to a role.
|
|
2474
|
-
*/
|
|
2475
|
-
addPermission(options) {
|
|
2476
|
-
return (options.client ?? this.client).post({
|
|
2477
|
-
requestValidator: async (data) => await zCustomRolesAddPermissionData.parseAsync(data),
|
|
2478
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2479
|
-
url: '/api/v1/roles/{role_id}/permissions',
|
|
2480
|
-
...options,
|
|
2481
|
-
headers: {
|
|
2482
|
-
'Content-Type': 'application/json',
|
|
2483
|
-
...options.headers
|
|
2484
|
-
}
|
|
2485
|
-
});
|
|
2486
|
-
}
|
|
2487
|
-
/**
|
|
2488
|
-
* Set Permissions Endpoint
|
|
2489
|
-
*
|
|
2490
|
-
* Set all permissions for a role (replaces existing).
|
|
2491
|
-
*/
|
|
2492
|
-
setPermissions(options) {
|
|
2493
|
-
return (options.client ?? this.client).put({
|
|
2494
|
-
requestValidator: async (data) => await zCustomRolesSetPermissionsData.parseAsync(data),
|
|
2495
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2496
|
-
url: '/api/v1/roles/{role_id}/permissions',
|
|
2497
|
-
...options,
|
|
2498
|
-
headers: {
|
|
2499
|
-
'Content-Type': 'application/json',
|
|
2500
|
-
...options.headers
|
|
2501
|
-
}
|
|
2502
|
-
});
|
|
2503
|
-
}
|
|
2504
|
-
/**
|
|
2505
|
-
* Remove Permission Endpoint
|
|
2506
|
-
*
|
|
2507
|
-
* Remove a permission from a role.
|
|
2508
|
-
*/
|
|
2509
|
-
removePermission(options) {
|
|
2510
|
-
return (options.client ?? this.client).delete({
|
|
2511
|
-
requestValidator: async (data) => await zCustomRolesRemovePermissionData.parseAsync(data),
|
|
2512
|
-
responseValidator: async (data) => await zCustomRolesRemovePermissionResponse.parseAsync(data),
|
|
2513
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2514
|
-
url: '/api/v1/roles/{role_id}/permissions/{permission_code}',
|
|
2515
|
-
...options
|
|
2516
|
-
});
|
|
2517
|
-
}
|
|
2518
|
-
/**
|
|
2519
|
-
* Get My Permissions Endpoint
|
|
2520
|
-
*
|
|
2521
|
-
* Get current user's effective permissions.
|
|
2522
|
-
*
|
|
2523
|
-
* This returns the permissions from the JWT token claims, augmented with
|
|
2524
|
-
* any custom role permissions from the database.
|
|
2525
|
-
*/
|
|
2526
|
-
getMyPermissions(options) {
|
|
2527
|
-
return (options?.client ?? this.client).get({
|
|
2528
|
-
requestValidator: async (data) => await zCustomRolesGetMyPermissionsData.parseAsync(data),
|
|
2529
|
-
responseValidator: async (data) => await zCustomRolesGetMyPermissionsResponse.parseAsync(data),
|
|
2530
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2531
|
-
url: '/api/v1/roles/me/permissions',
|
|
2532
|
-
...options
|
|
2533
|
-
});
|
|
2534
|
-
}
|
|
2535
|
-
/**
|
|
2536
|
-
* Assign Role To User Endpoint
|
|
2537
|
-
*
|
|
2538
|
-
* Assign a role to a user.
|
|
2539
|
-
*/
|
|
2540
|
-
assignToUser(options) {
|
|
2541
|
-
return (options.client ?? this.client).post({
|
|
2542
|
-
requestValidator: async (data) => await zCustomRolesAssignToUserData.parseAsync(data),
|
|
2543
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2544
|
-
url: '/api/v1/roles/users/{user_id}/roles',
|
|
2545
|
-
...options
|
|
2546
|
-
});
|
|
2547
|
-
}
|
|
2548
|
-
/**
|
|
2549
|
-
* Remove Role From User Endpoint
|
|
2550
|
-
*
|
|
2551
|
-
* Remove a role from a user.
|
|
2552
|
-
*/
|
|
2553
|
-
removeUserRole(options) {
|
|
2554
|
-
return (options.client ?? this.client).delete({
|
|
2555
|
-
requestValidator: async (data) => await zCustomRolesRemoveUserRoleData.parseAsync(data),
|
|
2556
|
-
responseValidator: async (data) => await zCustomRolesRemoveUserRoleResponse.parseAsync(data),
|
|
2557
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2558
|
-
url: '/api/v1/roles/users/{user_id}/roles/{role_id}',
|
|
2559
|
-
...options
|
|
2560
|
-
});
|
|
2561
|
-
}
|
|
2562
|
-
}
|
|
2563
|
-
export class Roles extends HeyApiClient {
|
|
2564
|
-
/**
|
|
2565
|
-
* Delete Role Endpoint
|
|
2566
|
-
*
|
|
2567
|
-
* Delete a custom role.
|
|
2568
|
-
*/
|
|
2569
|
-
delete(options) {
|
|
2570
|
-
return (options.client ?? this.client).delete({
|
|
2571
|
-
requestValidator: async (data) => await zRolesDeleteData.parseAsync(data),
|
|
2572
|
-
responseValidator: async (data) => await zRolesDeleteResponse.parseAsync(data),
|
|
2573
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2574
|
-
url: '/api/v1/roles/{role_id}',
|
|
2575
|
-
...options
|
|
2576
|
-
});
|
|
2577
|
-
}
|
|
2578
|
-
}
|
|
2579
|
-
export class Permissions extends HeyApiClient {
|
|
2580
|
-
/**
|
|
2581
|
-
* List Permissions Endpoint
|
|
2582
|
-
*
|
|
2583
|
-
* List all available permissions in the system.
|
|
2584
|
-
*/
|
|
2585
|
-
list(options) {
|
|
2586
|
-
return (options?.client ?? this.client).get({
|
|
2587
|
-
requestValidator: async (data) => await zPermissionsListData.parseAsync(data),
|
|
2588
|
-
responseValidator: async (data) => await zPermissionsListResponse.parseAsync(data),
|
|
2589
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2590
|
-
url: '/api/v1/permissions',
|
|
2591
|
-
...options
|
|
2592
|
-
});
|
|
2593
|
-
}
|
|
2594
|
-
/**
|
|
2595
|
-
* Get Permission Endpoint
|
|
2596
|
-
*
|
|
2597
|
-
* Get a specific permission by code.
|
|
2598
|
-
*/
|
|
2599
|
-
get(options) {
|
|
2600
|
-
return (options.client ?? this.client).get({
|
|
2601
|
-
requestValidator: async (data) => await zPermissionsGetData.parseAsync(data),
|
|
2602
|
-
responseValidator: async (data) => await zPermissionsGetResponse.parseAsync(data),
|
|
2603
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2604
|
-
url: '/api/v1/permissions/{permission_code}',
|
|
2605
|
-
...options
|
|
2606
|
-
});
|
|
2607
|
-
}
|
|
2608
|
-
}
|
|
2609
|
-
export class Bookings extends HeyApiClient {
|
|
2610
|
-
/**
|
|
2611
|
-
* Get Bookings
|
|
2612
|
-
*
|
|
2613
|
-
* Get bookings with optional filters
|
|
2614
|
-
*/
|
|
2615
|
-
list(options) {
|
|
2616
|
-
return (options?.client ?? this.client).get({
|
|
2617
|
-
requestValidator: async (data) => await zBookingsListData.parseAsync(data),
|
|
2618
|
-
responseValidator: async (data) => await zBookingsListResponse.parseAsync(data),
|
|
2619
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2620
|
-
url: '/api/v1/booking',
|
|
2621
|
-
...options
|
|
2622
|
-
});
|
|
2623
|
-
}
|
|
2624
|
-
/**
|
|
2625
|
-
* Delete Booking
|
|
2626
|
-
*
|
|
2627
|
-
* Delete a booking
|
|
2628
|
-
*/
|
|
2629
|
-
delete(options) {
|
|
2630
|
-
return (options.client ?? this.client).delete({
|
|
2631
|
-
requestValidator: async (data) => await zBookingsDeleteData.parseAsync(data),
|
|
2632
|
-
responseValidator: async (data) => await zBookingsDeleteResponse.parseAsync(data),
|
|
2633
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2634
|
-
url: '/api/v1/booking/{booking_id}',
|
|
2635
|
-
...options
|
|
2636
|
-
});
|
|
2637
|
-
}
|
|
2638
|
-
/**
|
|
2639
|
-
* Get Booking By Id
|
|
2640
|
-
*
|
|
2641
|
-
* Get booking by ID
|
|
2642
|
-
*/
|
|
2643
|
-
getById(options) {
|
|
2644
|
-
return (options.client ?? this.client).get({
|
|
2645
|
-
requestValidator: async (data) => await zBookingsGetByIdData.parseAsync(data),
|
|
2646
|
-
responseValidator: async (data) => await zBookingsGetByIdResponse.parseAsync(data),
|
|
2647
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2648
|
-
url: '/api/v1/booking/{booking_id}',
|
|
2649
|
-
...options
|
|
2650
|
-
});
|
|
2651
|
-
}
|
|
2652
|
-
/**
|
|
2653
|
-
* Update Booking
|
|
2654
|
-
*
|
|
2655
|
-
* Update an existing booking
|
|
2656
|
-
*/
|
|
2657
|
-
update(options) {
|
|
2658
|
-
return (options.client ?? this.client).put({
|
|
2659
|
-
requestValidator: async (data) => await zBookingsUpdateData.parseAsync(data),
|
|
2660
|
-
responseValidator: async (data) => await zBookingsUpdateResponse.parseAsync(data),
|
|
2661
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2662
|
-
url: '/api/v1/booking/{booking_id}',
|
|
2663
|
-
...options,
|
|
2664
|
-
headers: {
|
|
2665
|
-
'Content-Type': 'application/json',
|
|
2666
|
-
...options.headers
|
|
2667
|
-
}
|
|
2668
|
-
});
|
|
2669
|
-
}
|
|
2670
|
-
/**
|
|
2671
|
-
* Check Availability
|
|
2672
|
-
*
|
|
2673
|
-
* Check if a place is available for booking
|
|
2674
|
-
*/
|
|
2675
|
-
checkAvailability(options) {
|
|
2676
|
-
return (options.client ?? this.client).post({
|
|
2677
|
-
requestValidator: async (data) => await zBookingsCheckAvailabilityData.parseAsync(data),
|
|
2678
|
-
responseValidator: async (data) => await zBookingsCheckAvailabilityResponse.parseAsync(data),
|
|
2679
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2680
|
-
url: '/api/v1/booking/check-availability',
|
|
2681
|
-
...options,
|
|
2682
|
-
headers: {
|
|
2683
|
-
'Content-Type': 'application/json',
|
|
2684
|
-
...options.headers
|
|
2685
|
-
}
|
|
2686
|
-
});
|
|
2687
|
-
}
|
|
2688
|
-
/**
|
|
2689
|
-
* Get Place Schedule
|
|
2690
|
-
*
|
|
2691
|
-
* Get the schedule of bookings for a place in a date range
|
|
2692
|
-
*/
|
|
2693
|
-
getPlaceSchedule(options) {
|
|
2694
|
-
return (options.client ?? this.client).get({
|
|
2695
|
-
requestValidator: async (data) => await zBookingsGetPlaceScheduleData.parseAsync(data),
|
|
2696
|
-
responseValidator: async (data) => await zBookingsGetPlaceScheduleResponse.parseAsync(data),
|
|
2697
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2698
|
-
url: '/api/v1/booking/places/{place_id}/schedule',
|
|
2699
|
-
...options
|
|
2700
|
-
});
|
|
2701
|
-
}
|
|
2702
|
-
}
|
|
2703
|
-
export class Booking extends HeyApiClient {
|
|
2704
|
-
/**
|
|
2705
|
-
* Create Booking
|
|
2706
|
-
*
|
|
2707
|
-
* Create a new booking
|
|
2708
|
-
*/
|
|
2709
|
-
create(options) {
|
|
2710
|
-
return (options.client ?? this.client).post({
|
|
2711
|
-
requestValidator: async (data) => await zBookingCreateData.parseAsync(data),
|
|
2712
|
-
responseValidator: async (data) => await zBookingCreateResponse.parseAsync(data),
|
|
2713
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2714
|
-
url: '/api/v1/booking',
|
|
2715
|
-
...options,
|
|
2716
|
-
headers: {
|
|
2717
|
-
'Content-Type': 'application/json',
|
|
2718
|
-
...options.headers
|
|
2719
|
-
}
|
|
2720
|
-
});
|
|
2721
|
-
}
|
|
2722
|
-
}
|
|
2723
|
-
export class ChatRooms extends HeyApiClient {
|
|
2724
|
-
/**
|
|
2725
|
-
* Create Direct Room
|
|
2726
|
-
*/
|
|
2727
|
-
createDirect(options) {
|
|
2728
|
-
return (options.client ?? this.client).post({
|
|
2729
|
-
requestValidator: async (data) => await zChatRoomsCreateDirectData.parseAsync(data),
|
|
2730
|
-
responseValidator: async (data) => await zChatRoomsCreateDirectResponse.parseAsync(data),
|
|
2731
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2732
|
-
url: '/api/v1/chat/rooms/direct',
|
|
2733
|
-
...options,
|
|
2734
|
-
headers: {
|
|
2735
|
-
'Content-Type': 'application/json',
|
|
2736
|
-
...options.headers
|
|
2737
|
-
}
|
|
2738
|
-
});
|
|
2739
|
-
}
|
|
2740
|
-
/**
|
|
2741
|
-
* Create Group Room
|
|
2742
|
-
*/
|
|
2743
|
-
createGroup(options) {
|
|
2744
|
-
return (options.client ?? this.client).post({
|
|
2745
|
-
requestValidator: async (data) => await zChatRoomsCreateGroupData.parseAsync(data),
|
|
2746
|
-
responseValidator: async (data) => await zChatRoomsCreateGroupResponse.parseAsync(data),
|
|
2747
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2748
|
-
url: '/api/v1/chat/rooms/group',
|
|
2749
|
-
...options,
|
|
2750
|
-
headers: {
|
|
2751
|
-
'Content-Type': 'application/json',
|
|
2752
|
-
...options.headers
|
|
2753
|
-
}
|
|
2754
|
-
});
|
|
2755
|
-
}
|
|
2756
|
-
/**
|
|
2757
|
-
* List User Rooms
|
|
2758
|
-
*/
|
|
2759
|
-
list(options) {
|
|
2760
|
-
return (options?.client ?? this.client).get({
|
|
2761
|
-
requestValidator: async (data) => await zChatRoomsListData.parseAsync(data),
|
|
2762
|
-
responseValidator: async (data) => await zChatRoomsListResponse.parseAsync(data),
|
|
2763
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2764
|
-
url: '/api/v1/chat/rooms/',
|
|
2765
|
-
...options
|
|
2766
|
-
});
|
|
2767
|
-
}
|
|
2768
|
-
/**
|
|
2769
|
-
* Get Room By Id
|
|
2770
|
-
*/
|
|
2771
|
-
getById(options) {
|
|
2772
|
-
return (options.client ?? this.client).get({
|
|
2773
|
-
requestValidator: async (data) => await zChatRoomsGetByIdData.parseAsync(data),
|
|
2774
|
-
responseValidator: async (data) => await zChatRoomsGetByIdResponse.parseAsync(data),
|
|
2775
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2776
|
-
url: '/api/v1/chat/rooms/{room_id}',
|
|
2777
|
-
...options
|
|
2778
|
-
});
|
|
2779
|
-
}
|
|
2780
|
-
/**
|
|
2781
|
-
* Update Room
|
|
2782
|
-
*/
|
|
2783
|
-
update(options) {
|
|
2784
|
-
return (options.client ?? this.client).patch({
|
|
2785
|
-
requestValidator: async (data) => await zChatRoomsUpdateData.parseAsync(data),
|
|
2786
|
-
responseValidator: async (data) => await zChatRoomsUpdateResponse.parseAsync(data),
|
|
2787
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2788
|
-
url: '/api/v1/chat/rooms/{room_id}',
|
|
2789
|
-
...options,
|
|
2790
|
-
headers: {
|
|
2791
|
-
'Content-Type': 'application/json',
|
|
2792
|
-
...options.headers
|
|
2793
|
-
}
|
|
2794
|
-
});
|
|
2795
|
-
}
|
|
2796
|
-
/**
|
|
2797
|
-
* List Room Members
|
|
2798
|
-
*/
|
|
2799
|
-
listMembers(options) {
|
|
2800
|
-
return (options.client ?? this.client).get({
|
|
2801
|
-
requestValidator: async (data) => await zChatRoomsListMembersData.parseAsync(data),
|
|
2802
|
-
responseValidator: async (data) => await zChatRoomsListMembersResponse.parseAsync(data),
|
|
2803
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2804
|
-
url: '/api/v1/chat/rooms/{room_id}/members',
|
|
2805
|
-
...options
|
|
2806
|
-
});
|
|
2807
|
-
}
|
|
2808
|
-
/**
|
|
2809
|
-
* Add Member To Room
|
|
2810
|
-
*/
|
|
2811
|
-
addMember(options) {
|
|
2812
|
-
return (options.client ?? this.client).post({
|
|
2813
|
-
requestValidator: async (data) => await zChatRoomsAddMemberData.parseAsync(data),
|
|
2814
|
-
responseValidator: async (data) => await zChatRoomsAddMemberResponse.parseAsync(data),
|
|
2815
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2816
|
-
url: '/api/v1/chat/rooms/{room_id}/members',
|
|
2817
|
-
...options,
|
|
2818
|
-
headers: {
|
|
2819
|
-
'Content-Type': 'application/json',
|
|
2820
|
-
...options.headers
|
|
2821
|
-
}
|
|
2822
|
-
});
|
|
2823
|
-
}
|
|
2824
|
-
/**
|
|
2825
|
-
* Remove Member From Room
|
|
2826
|
-
*/
|
|
2827
|
-
removeMember(options) {
|
|
2828
|
-
return (options.client ?? this.client).delete({
|
|
2829
|
-
requestValidator: async (data) => await zChatRoomsRemoveMemberData.parseAsync(data),
|
|
2830
|
-
responseValidator: async (data) => await zChatRoomsRemoveMemberResponse.parseAsync(data),
|
|
2831
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2832
|
-
url: '/api/v1/chat/rooms/{room_id}/members/{user_id}',
|
|
2833
|
-
...options
|
|
2834
|
-
});
|
|
2835
|
-
}
|
|
2836
|
-
}
|
|
2837
|
-
export class ChatMessages extends HeyApiClient {
|
|
2838
|
-
/**
|
|
2839
|
-
* List Messages
|
|
2840
|
-
*/
|
|
2841
|
-
list(options) {
|
|
2842
|
-
return (options.client ?? this.client).get({
|
|
2843
|
-
requestValidator: async (data) => await zChatMessagesListData.parseAsync(data),
|
|
2844
|
-
responseValidator: async (data) => await zChatMessagesListResponse.parseAsync(data),
|
|
2845
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2846
|
-
url: '/api/v1/chat/{room_id}/messages/',
|
|
2847
|
-
...options
|
|
2848
|
-
});
|
|
2849
|
-
}
|
|
2850
|
-
/**
|
|
2851
|
-
* Delete Message
|
|
2852
|
-
*/
|
|
2853
|
-
delete(options) {
|
|
2854
|
-
return (options.client ?? this.client).delete({
|
|
2855
|
-
requestValidator: async (data) => await zChatMessagesDeleteData.parseAsync(data),
|
|
2856
|
-
responseValidator: async (data) => await zChatMessagesDeleteResponse.parseAsync(data),
|
|
2857
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2858
|
-
url: '/api/v1/chat/messages/{message_id}',
|
|
2859
|
-
...options
|
|
2860
|
-
});
|
|
2861
|
-
}
|
|
2862
|
-
/**
|
|
2863
|
-
* Get Message Count
|
|
2864
|
-
*/
|
|
2865
|
-
getCount(options) {
|
|
2866
|
-
return (options.client ?? this.client).get({
|
|
2867
|
-
requestValidator: async (data) => await zChatMessagesGetCountData.parseAsync(data),
|
|
2868
|
-
responseValidator: async (data) => await zChatMessagesGetCountResponse.parseAsync(data),
|
|
2869
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2870
|
-
url: '/api/v1/chat/{room_id}/messages/count',
|
|
2871
|
-
...options
|
|
2872
|
-
});
|
|
2873
|
-
}
|
|
2874
|
-
/**
|
|
2875
|
-
* Mark Messages As Read
|
|
2876
|
-
*/
|
|
2877
|
-
markRead(options) {
|
|
2878
|
-
return (options.client ?? this.client).patch({
|
|
2879
|
-
requestValidator: async (data) => await zChatMessagesMarkReadData.parseAsync(data),
|
|
2880
|
-
responseValidator: async (data) => await zChatMessagesMarkReadResponse.parseAsync(data),
|
|
2881
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2882
|
-
url: '/api/v1/chat/{room_id}/read',
|
|
2883
|
-
...options
|
|
2884
|
-
});
|
|
2885
|
-
}
|
|
2886
|
-
/**
|
|
2887
|
-
* Get Unread Count
|
|
2888
|
-
*/
|
|
2889
|
-
getUnreadCount(options) {
|
|
2890
|
-
return (options.client ?? this.client).get({
|
|
2891
|
-
requestValidator: async (data) => await zChatMessagesGetUnreadCountData.parseAsync(data),
|
|
2892
|
-
responseValidator: async (data) => await zChatMessagesGetUnreadCountResponse.parseAsync(data),
|
|
2893
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2894
|
-
url: '/api/v1/chat/{room_id}/unread-count',
|
|
2895
|
-
...options
|
|
2896
|
-
});
|
|
2897
|
-
}
|
|
2898
|
-
}
|
|
2899
|
-
export class AiAgent extends HeyApiClient {
|
|
2900
|
-
/**
|
|
2901
|
-
* Send Message
|
|
2902
|
-
*/
|
|
2903
|
-
sendMessage(options) {
|
|
2904
|
-
return (options.client ?? this.client).post({
|
|
2905
|
-
requestValidator: async (data) => await zAiAgentSendMessageData.parseAsync(data),
|
|
2906
|
-
responseValidator: async (data) => await zAiAgentSendMessageResponse.parseAsync(data),
|
|
2907
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2908
|
-
url: '/api/v1/chat/{room_id}/messages/',
|
|
2909
|
-
...options,
|
|
2910
|
-
headers: {
|
|
2911
|
-
'Content-Type': 'application/json',
|
|
2912
|
-
...options.headers
|
|
2913
|
-
}
|
|
2914
|
-
});
|
|
2915
|
-
}
|
|
2916
|
-
/**
|
|
2917
|
-
* Create a new AI agent session
|
|
2918
|
-
*
|
|
2919
|
-
* Create a new conversation session with an AI agent. The session persists across multiple messages and maintains context.
|
|
2920
|
-
*/
|
|
2921
|
-
createSession(options) {
|
|
2922
|
-
return (options.client ?? this.client).post({
|
|
2923
|
-
requestValidator: async (data) => await zAiAgentCreateSessionData.parseAsync(data),
|
|
2924
|
-
responseValidator: async (data) => await zAiAgentCreateSessionResponse.parseAsync(data),
|
|
2925
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2926
|
-
url: '/api/v1/ai/sessions',
|
|
2927
|
-
...options,
|
|
2928
|
-
headers: {
|
|
2929
|
-
'Content-Type': 'application/json',
|
|
2930
|
-
...options.headers
|
|
2931
|
-
}
|
|
2932
|
-
});
|
|
2933
|
-
}
|
|
2934
|
-
/**
|
|
2935
|
-
* Send a message to an AI agent session
|
|
2936
|
-
*
|
|
2937
|
-
* Send a user message to an existing AI agent session and receive a response. The conversation context is maintained across messages.
|
|
2938
|
-
*/
|
|
2939
|
-
sendMessage2(options) {
|
|
2940
|
-
return (options.client ?? this.client).post({
|
|
2941
|
-
requestValidator: async (data) => await zAiAgentSendMessage2Data.parseAsync(data),
|
|
2942
|
-
responseValidator: async (data) => await zAiAgentSendMessage2Response.parseAsync(data),
|
|
2943
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2944
|
-
url: '/api/v1/ai/sessions/{session_id}/messages',
|
|
2945
|
-
...options,
|
|
2946
|
-
headers: {
|
|
2947
|
-
'Content-Type': 'application/json',
|
|
2948
|
-
...options.headers
|
|
2949
|
-
}
|
|
2950
|
-
});
|
|
2951
|
-
}
|
|
2952
|
-
}
|
|
2953
|
-
export class AiAgent2 extends HeyApiClient {
|
|
2954
|
-
/**
|
|
2955
|
-
* List AI agent sessions
|
|
2956
|
-
*
|
|
2957
|
-
* Retrieve a list of AI agent sessions for the current user. Supports filtering by agent type and status.
|
|
2958
|
-
*/
|
|
2959
|
-
listSessions(options) {
|
|
2960
|
-
return (options?.client ?? this.client).get({
|
|
2961
|
-
requestValidator: async (data) => await zAiAgentListSessionsData.parseAsync(data),
|
|
2962
|
-
responseValidator: async (data) => await zAiAgentListSessionsResponse.parseAsync(data),
|
|
2963
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2964
|
-
url: '/api/v1/ai/sessions',
|
|
2965
|
-
...options
|
|
2966
|
-
});
|
|
2967
|
-
}
|
|
2968
|
-
/**
|
|
2969
|
-
* Get AI agent session details
|
|
2970
|
-
*
|
|
2971
|
-
* Retrieve detailed information about a specific AI agent session.
|
|
2972
|
-
*/
|
|
2973
|
-
getSession(options) {
|
|
2974
|
-
return (options.client ?? this.client).get({
|
|
2975
|
-
requestValidator: async (data) => await zAiAgentGetSessionData.parseAsync(data),
|
|
2976
|
-
responseValidator: async (data) => await zAiAgentGetSessionResponse.parseAsync(data),
|
|
2977
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2978
|
-
url: '/api/v1/ai/sessions/{session_id}',
|
|
2979
|
-
...options
|
|
2980
|
-
});
|
|
2981
|
-
}
|
|
2982
|
-
/**
|
|
2983
|
-
* Get session cost breakdown
|
|
2984
|
-
*
|
|
2985
|
-
* Retrieve token usage and cost information for a specific AI agent session.
|
|
2986
|
-
*/
|
|
2987
|
-
getSessionCosts(options) {
|
|
2988
|
-
return (options.client ?? this.client).get({
|
|
2989
|
-
requestValidator: async (data) => await zAiAgentGetSessionCostsData.parseAsync(data),
|
|
2990
|
-
responseValidator: async (data) => await zAiAgentGetSessionCostsResponse.parseAsync(data),
|
|
2991
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
2992
|
-
url: '/api/v1/ai/sessions/{session_id}/costs',
|
|
2993
|
-
...options
|
|
2994
|
-
});
|
|
2995
|
-
}
|
|
2996
|
-
/**
|
|
2997
|
-
* List workflow executions
|
|
2998
|
-
*
|
|
2999
|
-
* Retrieve a list of workflow executions for the current user. Supports filtering by workflow type and status.
|
|
3000
|
-
*/
|
|
3001
|
-
listWorkflows(options) {
|
|
3002
|
-
return (options?.client ?? this.client).get({
|
|
3003
|
-
requestValidator: async (data) => await zAiAgentListWorkflowsData.parseAsync(data),
|
|
3004
|
-
responseValidator: async (data) => await zAiAgentListWorkflowsResponse.parseAsync(data),
|
|
3005
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3006
|
-
url: '/api/v1/ai/workflows',
|
|
3007
|
-
...options
|
|
3008
|
-
});
|
|
3009
|
-
}
|
|
3010
|
-
/**
|
|
3011
|
-
* Start a multi-agent workflow
|
|
3012
|
-
*
|
|
3013
|
-
* Execute a multi-agent workflow with specified parameters. Returns immediately with execution status; poll for completion.
|
|
3014
|
-
*/
|
|
3015
|
-
startWorkflow(options) {
|
|
3016
|
-
return (options.client ?? this.client).post({
|
|
3017
|
-
requestValidator: async (data) => await zAiAgentStartWorkflowData.parseAsync(data),
|
|
3018
|
-
responseValidator: async (data) => await zAiAgentStartWorkflowResponse.parseAsync(data),
|
|
3019
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3020
|
-
url: '/api/v1/ai/workflows',
|
|
3021
|
-
...options,
|
|
3022
|
-
headers: {
|
|
3023
|
-
'Content-Type': 'application/json',
|
|
3024
|
-
...options.headers
|
|
3025
|
-
}
|
|
3026
|
-
});
|
|
3027
|
-
}
|
|
3028
|
-
/**
|
|
3029
|
-
* Start a multi-agent workflow (async)
|
|
3030
|
-
*
|
|
3031
|
-
* Queue a multi-agent workflow for asynchronous execution. Returns immediately with execution_id and task_id. Poll GET /workflows/{execution_id} for status updates.
|
|
3032
|
-
*/
|
|
3033
|
-
startWorkflowAsync(options) {
|
|
3034
|
-
return (options.client ?? this.client).post({
|
|
3035
|
-
requestValidator: async (data) => await zAiAgentStartWorkflowAsyncData.parseAsync(data),
|
|
3036
|
-
responseValidator: async (data) => await zAiAgentStartWorkflowAsyncResponse.parseAsync(data),
|
|
3037
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3038
|
-
url: '/api/v1/ai/workflows/async',
|
|
3039
|
-
...options,
|
|
3040
|
-
headers: {
|
|
3041
|
-
'Content-Type': 'application/json',
|
|
3042
|
-
...options.headers
|
|
3043
|
-
}
|
|
3044
|
-
});
|
|
3045
|
-
}
|
|
3046
|
-
/**
|
|
3047
|
-
* Cancel a running workflow
|
|
3048
|
-
*
|
|
3049
|
-
* Cancel a pending or running workflow execution. Cannot cancel completed, failed, or already cancelled workflows.
|
|
3050
|
-
*/
|
|
3051
|
-
cancelWorkflow(options) {
|
|
3052
|
-
return (options.client ?? this.client).post({
|
|
3053
|
-
requestValidator: async (data) => await zAiAgentCancelWorkflowData.parseAsync(data),
|
|
3054
|
-
responseValidator: async (data) => await zAiAgentCancelWorkflowResponse.parseAsync(data),
|
|
3055
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3056
|
-
url: '/api/v1/ai/workflows/{execution_id}/cancel',
|
|
3057
|
-
...options
|
|
3058
|
-
});
|
|
3059
|
-
}
|
|
3060
|
-
}
|
|
3061
|
-
export class AI extends HeyApiClient {
|
|
3062
|
-
/**
|
|
3063
|
-
* Delete AI agent session
|
|
3064
|
-
*
|
|
3065
|
-
* Mark an AI agent session as deleted. The session and its conversation history will be soft-deleted.
|
|
3066
|
-
*/
|
|
3067
|
-
deleteSession(options) {
|
|
3068
|
-
return (options.client ?? this.client).delete({
|
|
3069
|
-
requestValidator: async (data) => await zAIDeleteSessionData.parseAsync(data),
|
|
3070
|
-
responseValidator: async (data) => await zAIDeleteSessionResponse.parseAsync(data),
|
|
3071
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3072
|
-
url: '/api/v1/ai/sessions/{session_id}',
|
|
3073
|
-
...options
|
|
3074
|
-
});
|
|
3075
|
-
}
|
|
3076
|
-
}
|
|
3077
|
-
export class AiAgents extends HeyApiClient {
|
|
3078
|
-
/**
|
|
3079
|
-
* Get organization-wide cost summary
|
|
3080
|
-
*
|
|
3081
|
-
* Retrieve aggregated cost and token usage across all AI agent sessions for the current organization. Requires organization context (not available in personal mode).
|
|
3082
|
-
*/
|
|
3083
|
-
getOrgCosts(options) {
|
|
3084
|
-
return (options?.client ?? this.client).get({
|
|
3085
|
-
requestValidator: async (data) => await zAiAgentsGetOrgCostsData.parseAsync(data),
|
|
3086
|
-
responseValidator: async (data) => await zAiAgentsGetOrgCostsResponse.parseAsync(data),
|
|
3087
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3088
|
-
url: '/api/v1/ai/costs',
|
|
3089
|
-
...options
|
|
3090
|
-
});
|
|
3091
|
-
}
|
|
3092
|
-
}
|
|
3093
|
-
export class AiWorkflows extends HeyApiClient {
|
|
3094
|
-
/**
|
|
3095
|
-
* Get workflow execution details
|
|
3096
|
-
*
|
|
3097
|
-
* Retrieve detailed information about a workflow execution, including status and results.
|
|
3098
|
-
*/
|
|
3099
|
-
getExecutionDetails(options) {
|
|
3100
|
-
return (options.client ?? this.client).get({
|
|
3101
|
-
requestValidator: async (data) => await zAiWorkflowsGetExecutionDetailsData.parseAsync(data),
|
|
3102
|
-
responseValidator: async (data) => await zAiWorkflowsGetExecutionDetailsResponse.parseAsync(data),
|
|
3103
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3104
|
-
url: '/api/v1/ai/workflows/{execution_id}',
|
|
3105
|
-
...options
|
|
3106
|
-
});
|
|
3107
|
-
}
|
|
3108
|
-
}
|
|
3109
|
-
export class Contacts extends HeyApiClient {
|
|
3110
|
-
/**
|
|
3111
|
-
* List Contacts
|
|
3112
|
-
*
|
|
3113
|
-
* List all contacts for the current user with tenant isolation.
|
|
3114
|
-
*/
|
|
3115
|
-
list(options) {
|
|
3116
|
-
return (options?.client ?? this.client).get({
|
|
3117
|
-
requestValidator: async (data) => await zContactsListData.parseAsync(data),
|
|
3118
|
-
responseValidator: async (data) => await zContactsListResponse.parseAsync(data),
|
|
3119
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3120
|
-
url: '/api/v1/contacts',
|
|
3121
|
-
...options
|
|
3122
|
-
});
|
|
3123
|
-
}
|
|
3124
|
-
/**
|
|
3125
|
-
* Create Contact
|
|
3126
|
-
*
|
|
3127
|
-
* Create a new contact.
|
|
3128
|
-
*/
|
|
3129
|
-
create(options) {
|
|
3130
|
-
return (options.client ?? this.client).post({
|
|
3131
|
-
requestValidator: async (data) => await zContactsCreateData.parseAsync(data),
|
|
3132
|
-
responseValidator: async (data) => await zContactsCreateResponse.parseAsync(data),
|
|
3133
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3134
|
-
url: '/api/v1/contacts',
|
|
3135
|
-
...options,
|
|
3136
|
-
headers: {
|
|
3137
|
-
'Content-Type': 'application/json',
|
|
3138
|
-
...options.headers
|
|
3139
|
-
}
|
|
3140
|
-
});
|
|
3141
|
-
}
|
|
3142
|
-
/**
|
|
3143
|
-
* Search Contacts
|
|
3144
|
-
*
|
|
3145
|
-
* Search contacts by query string with tenant isolation.
|
|
3146
|
-
*/
|
|
3147
|
-
search(options) {
|
|
3148
|
-
return (options.client ?? this.client).get({
|
|
3149
|
-
requestValidator: async (data) => await zContactsSearchData.parseAsync(data),
|
|
3150
|
-
responseValidator: async (data) => await zContactsSearchResponse.parseAsync(data),
|
|
3151
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3152
|
-
url: '/api/v1/contacts/search',
|
|
3153
|
-
...options
|
|
3154
|
-
});
|
|
3155
|
-
}
|
|
3156
|
-
/**
|
|
3157
|
-
* Delete Contact
|
|
3158
|
-
*
|
|
3159
|
-
* Delete a contact.
|
|
3160
|
-
*/
|
|
3161
|
-
delete(options) {
|
|
3162
|
-
return (options.client ?? this.client).delete({
|
|
3163
|
-
requestValidator: async (data) => await zContactsDeleteData.parseAsync(data),
|
|
3164
|
-
responseValidator: async (data) => await zContactsDeleteResponse.parseAsync(data),
|
|
3165
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3166
|
-
url: '/api/v1/contacts/{contact_id}',
|
|
3167
|
-
...options
|
|
3168
|
-
});
|
|
3169
|
-
}
|
|
3170
|
-
/**
|
|
3171
|
-
* Get Contact
|
|
3172
|
-
*
|
|
3173
|
-
* Get a specific contact by ID.
|
|
3174
|
-
*/
|
|
3175
|
-
get(options) {
|
|
3176
|
-
return (options.client ?? this.client).get({
|
|
3177
|
-
requestValidator: async (data) => await zContactsGetData.parseAsync(data),
|
|
3178
|
-
responseValidator: async (data) => await zContactsGetResponse.parseAsync(data),
|
|
3179
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3180
|
-
url: '/api/v1/contacts/{contact_id}',
|
|
3181
|
-
...options
|
|
3182
|
-
});
|
|
3183
|
-
}
|
|
3184
|
-
/**
|
|
3185
|
-
* Update Contact
|
|
3186
|
-
*
|
|
3187
|
-
* Update a contact.
|
|
3188
|
-
*/
|
|
3189
|
-
update(options) {
|
|
3190
|
-
return (options.client ?? this.client).put({
|
|
3191
|
-
requestValidator: async (data) => await zContactsUpdateData.parseAsync(data),
|
|
3192
|
-
responseValidator: async (data) => await zContactsUpdateResponse.parseAsync(data),
|
|
3193
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3194
|
-
url: '/api/v1/contacts/{contact_id}',
|
|
3195
|
-
...options,
|
|
3196
|
-
headers: {
|
|
3197
|
-
'Content-Type': 'application/json',
|
|
3198
|
-
...options.headers
|
|
3199
|
-
}
|
|
3200
|
-
});
|
|
3201
|
-
}
|
|
3202
|
-
/**
|
|
3203
|
-
* Toggle Favorite
|
|
3204
|
-
*
|
|
3205
|
-
* Toggle contact favorite status.
|
|
3206
|
-
*/
|
|
3207
|
-
toggleFavorite(options) {
|
|
3208
|
-
return (options.client ?? this.client).patch({
|
|
3209
|
-
requestValidator: async (data) => await zContactsToggleFavoriteData.parseAsync(data),
|
|
3210
|
-
responseValidator: async (data) => await zContactsToggleFavoriteResponse.parseAsync(data),
|
|
3211
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3212
|
-
url: '/api/v1/contacts/{contact_id}/favorite',
|
|
3213
|
-
...options,
|
|
3214
|
-
headers: {
|
|
3215
|
-
'Content-Type': 'application/json',
|
|
3216
|
-
...options.headers
|
|
3217
|
-
}
|
|
3218
|
-
});
|
|
3219
|
-
}
|
|
3220
|
-
}
|
|
3221
|
-
export class AutomationRules extends HeyApiClient {
|
|
3222
|
-
/**
|
|
3223
|
-
* Get all metadata
|
|
3224
|
-
*
|
|
3225
|
-
* Get combined metadata for triggers, conditions, and actions in a single request
|
|
3226
|
-
*/
|
|
3227
|
-
getMetadata(options) {
|
|
3228
|
-
return (options?.client ?? this.client).get({
|
|
3229
|
-
requestValidator: async (data) => await zAutomationRulesGetMetadataData.parseAsync(data),
|
|
3230
|
-
responseValidator: async (data) => await zAutomationRulesGetMetadataResponse.parseAsync(data),
|
|
3231
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3232
|
-
url: '/api/v1/automation/metadata',
|
|
3233
|
-
...options
|
|
3234
|
-
});
|
|
3235
|
-
}
|
|
3236
|
-
/**
|
|
3237
|
-
* Get condition metadata
|
|
3238
|
-
*
|
|
3239
|
-
* Get metadata for all available condition types
|
|
3240
|
-
*/
|
|
3241
|
-
getConditions(options) {
|
|
3242
|
-
return (options?.client ?? this.client).get({
|
|
3243
|
-
requestValidator: async (data) => await zAutomationRulesGetConditionsData.parseAsync(data),
|
|
3244
|
-
responseValidator: async (data) => await zAutomationRulesGetConditionsResponse.parseAsync(data),
|
|
3245
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3246
|
-
url: '/api/v1/automation/metadata/conditions',
|
|
3247
|
-
...options
|
|
3248
|
-
});
|
|
3249
|
-
}
|
|
3250
|
-
/**
|
|
3251
|
-
* List Rules
|
|
3252
|
-
*
|
|
3253
|
-
* List automation rules.
|
|
3254
|
-
*
|
|
3255
|
-
* RLS automatically filters:
|
|
3256
|
-
* - Personal mode: only user's own rules
|
|
3257
|
-
* - Organization mode: all org rules
|
|
3258
|
-
*/
|
|
3259
|
-
list(options) {
|
|
3260
|
-
return (options?.client ?? this.client).get({
|
|
3261
|
-
requestValidator: async (data) => await zAutomationRulesListData.parseAsync(data),
|
|
3262
|
-
responseValidator: async (data) => await zAutomationRulesListResponse.parseAsync(data),
|
|
3263
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3264
|
-
url: '/api/v1/automation/rules',
|
|
3265
|
-
...options
|
|
3266
|
-
});
|
|
3267
|
-
}
|
|
3268
|
-
/**
|
|
3269
|
-
* Create Rule
|
|
3270
|
-
*
|
|
3271
|
-
* Create new automation rule.
|
|
3272
|
-
*
|
|
3273
|
-
* Supports dual-scope:
|
|
3274
|
-
* - Personal mode: org_id=None, creator_id=current_user.id
|
|
3275
|
-
* - Organization mode: org_id=tenant_ctx.org_id, creator_id=current_user.id
|
|
3276
|
-
*/
|
|
3277
|
-
create(options) {
|
|
3278
|
-
return (options.client ?? this.client).post({
|
|
3279
|
-
requestValidator: async (data) => await zAutomationRulesCreateData.parseAsync(data),
|
|
3280
|
-
responseValidator: async (data) => await zAutomationRulesCreateResponse.parseAsync(data),
|
|
3281
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3282
|
-
url: '/api/v1/automation/rules',
|
|
3283
|
-
...options,
|
|
3284
|
-
headers: {
|
|
3285
|
-
'Content-Type': 'application/json',
|
|
3286
|
-
...options.headers
|
|
3287
|
-
}
|
|
3288
|
-
});
|
|
3289
|
-
}
|
|
3290
|
-
/**
|
|
3291
|
-
* Delete Rule
|
|
3292
|
-
*
|
|
3293
|
-
* Delete automation rule.
|
|
3294
|
-
*/
|
|
3295
|
-
delete(options) {
|
|
3296
|
-
return (options.client ?? this.client).delete({
|
|
3297
|
-
requestValidator: async (data) => await zAutomationRulesDeleteData.parseAsync(data),
|
|
3298
|
-
responseValidator: async (data) => await zAutomationRulesDeleteResponse.parseAsync(data),
|
|
3299
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3300
|
-
url: '/api/v1/automation/rules/{rule_id}',
|
|
3301
|
-
...options
|
|
3302
|
-
});
|
|
3303
|
-
}
|
|
3304
|
-
/**
|
|
3305
|
-
* Get Rule
|
|
3306
|
-
*
|
|
3307
|
-
* Get automation rule by ID.
|
|
3308
|
-
*/
|
|
3309
|
-
get(options) {
|
|
3310
|
-
return (options.client ?? this.client).get({
|
|
3311
|
-
requestValidator: async (data) => await zAutomationRulesGetData.parseAsync(data),
|
|
3312
|
-
responseValidator: async (data) => await zAutomationRulesGetResponse.parseAsync(data),
|
|
3313
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3314
|
-
url: '/api/v1/automation/rules/{rule_id}',
|
|
3315
|
-
...options
|
|
3316
|
-
});
|
|
3317
|
-
}
|
|
3318
|
-
/**
|
|
3319
|
-
* Patch Rule
|
|
3320
|
-
*
|
|
3321
|
-
* Partially update automation rule (PATCH).
|
|
3322
|
-
*/
|
|
3323
|
-
patch(options) {
|
|
3324
|
-
return (options.client ?? this.client).patch({
|
|
3325
|
-
requestValidator: async (data) => await zAutomationRulesPatchData.parseAsync(data),
|
|
3326
|
-
responseValidator: async (data) => await zAutomationRulesPatchResponse.parseAsync(data),
|
|
3327
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3328
|
-
url: '/api/v1/automation/rules/{rule_id}',
|
|
3329
|
-
...options,
|
|
3330
|
-
headers: {
|
|
3331
|
-
'Content-Type': 'application/json',
|
|
3332
|
-
...options.headers
|
|
3333
|
-
}
|
|
3334
|
-
});
|
|
3335
|
-
}
|
|
3336
|
-
/**
|
|
3337
|
-
* Update Rule
|
|
3338
|
-
*
|
|
3339
|
-
* Update automation rule.
|
|
3340
|
-
*/
|
|
3341
|
-
update(options) {
|
|
3342
|
-
return (options.client ?? this.client).put({
|
|
3343
|
-
requestValidator: async (data) => await zAutomationRulesUpdateData.parseAsync(data),
|
|
3344
|
-
responseValidator: async (data) => await zAutomationRulesUpdateResponse.parseAsync(data),
|
|
3345
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3346
|
-
url: '/api/v1/automation/rules/{rule_id}',
|
|
3347
|
-
...options,
|
|
3348
|
-
headers: {
|
|
3349
|
-
'Content-Type': 'application/json',
|
|
3350
|
-
...options.headers
|
|
3351
|
-
}
|
|
3352
|
-
});
|
|
3353
|
-
}
|
|
3354
|
-
/**
|
|
3355
|
-
* Execute Rule
|
|
3356
|
-
*
|
|
3357
|
-
* Manually execute automation rule.
|
|
3358
|
-
*/
|
|
3359
|
-
execute(options) {
|
|
3360
|
-
return (options.client ?? this.client).post({
|
|
3361
|
-
requestValidator: async (data) => await zAutomationRulesExecuteData.parseAsync(data),
|
|
3362
|
-
responseValidator: async (data) => await zAutomationRulesExecuteResponse.parseAsync(data),
|
|
3363
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3364
|
-
url: '/api/v1/automation/rules/{rule_id}/execute',
|
|
3365
|
-
...options,
|
|
3366
|
-
headers: {
|
|
3367
|
-
'Content-Type': 'application/json',
|
|
3368
|
-
...options.headers
|
|
3369
|
-
}
|
|
3370
|
-
});
|
|
3371
|
-
}
|
|
3372
|
-
/**
|
|
3373
|
-
* Get Rule Executions
|
|
3374
|
-
*
|
|
3375
|
-
* Get execution history for a specific automation rule.
|
|
3376
|
-
*
|
|
3377
|
-
* Returns list of past executions with their status, results, and errors.
|
|
3378
|
-
*/
|
|
3379
|
-
getExecutions(options) {
|
|
3380
|
-
return (options.client ?? this.client).get({
|
|
3381
|
-
requestValidator: async (data) => await zAutomationRulesGetExecutionsData.parseAsync(data),
|
|
3382
|
-
responseValidator: async (data) => await zAutomationRulesGetExecutionsResponse.parseAsync(data),
|
|
3383
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3384
|
-
url: '/api/v1/automation/rules/{rule_id}/executions',
|
|
3385
|
-
...options
|
|
3386
|
-
});
|
|
3387
|
-
}
|
|
3388
|
-
}
|
|
3389
|
-
export class AutomationMetadata extends HeyApiClient {
|
|
3390
|
-
/**
|
|
3391
|
-
* Get trigger metadata
|
|
3392
|
-
*
|
|
3393
|
-
* Get metadata for all available trigger types
|
|
3394
|
-
*/
|
|
3395
|
-
getTriggers(options) {
|
|
3396
|
-
return (options?.client ?? this.client).get({
|
|
3397
|
-
requestValidator: async (data) => await zAutomationMetadataGetTriggersData.parseAsync(data),
|
|
3398
|
-
responseValidator: async (data) => await zAutomationMetadataGetTriggersResponse.parseAsync(data),
|
|
3399
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3400
|
-
url: '/api/v1/automation/metadata/triggers',
|
|
3401
|
-
...options
|
|
3402
|
-
});
|
|
3403
|
-
}
|
|
3404
|
-
/**
|
|
3405
|
-
* Get action metadata
|
|
3406
|
-
*
|
|
3407
|
-
* Get metadata for all available action types
|
|
3408
|
-
*/
|
|
3409
|
-
getActions(options) {
|
|
3410
|
-
return (options?.client ?? this.client).get({
|
|
3411
|
-
requestValidator: async (data) => await zAutomationMetadataGetActionsData.parseAsync(data),
|
|
3412
|
-
responseValidator: async (data) => await zAutomationMetadataGetActionsResponse.parseAsync(data),
|
|
3413
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3414
|
-
url: '/api/v1/automation/metadata/actions',
|
|
3415
|
-
...options
|
|
3416
|
-
});
|
|
3417
|
-
}
|
|
3418
|
-
/**
|
|
3419
|
-
* Get task metadata
|
|
3420
|
-
*
|
|
3421
|
-
* Get metadata for a specific task type
|
|
3422
|
-
*/
|
|
3423
|
-
getTask(options) {
|
|
3424
|
-
return (options.client ?? this.client).get({
|
|
3425
|
-
requestValidator: async (data) => await zAutomationMetadataGetTaskData.parseAsync(data),
|
|
3426
|
-
responseValidator: async (data) => await zAutomationMetadataGetTaskResponse.parseAsync(data),
|
|
3427
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3428
|
-
url: '/api/v1/automation/metadata/tasks/{task_type}',
|
|
3429
|
-
...options
|
|
3430
|
-
});
|
|
3431
|
-
}
|
|
3432
|
-
/**
|
|
3433
|
-
* Get all task metadata
|
|
3434
|
-
*
|
|
3435
|
-
* Get metadata for all registered tasks, optionally filtered by category or tags
|
|
3436
|
-
*/
|
|
3437
|
-
getTasks(options) {
|
|
3438
|
-
return (options?.client ?? this.client).get({
|
|
3439
|
-
requestValidator: async (data) => await zAutomationMetadataGetTasksData.parseAsync(data),
|
|
3440
|
-
responseValidator: async (data) => await zAutomationMetadataGetTasksResponse.parseAsync(data),
|
|
3441
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3442
|
-
url: '/api/v1/automation/metadata/tasks',
|
|
3443
|
-
...options
|
|
3444
|
-
});
|
|
3445
|
-
}
|
|
3446
|
-
}
|
|
3447
|
-
export class AutomationCron extends HeyApiClient {
|
|
3448
|
-
/**
|
|
3449
|
-
* Trigger Scheduled Automation
|
|
3450
|
-
*
|
|
3451
|
-
* Trigger execution of all scheduled automation rules.
|
|
3452
|
-
*
|
|
3453
|
-
* This endpoint is designed to be called by external cron services like:
|
|
3454
|
-
* - cron-job.org (free tier)
|
|
3455
|
-
* - GitHub Actions (free for public repos)
|
|
3456
|
-
* - EasyCron
|
|
3457
|
-
* - Any service that can make HTTP POST requests on a schedule
|
|
3458
|
-
*
|
|
3459
|
-
* **Security:**
|
|
3460
|
-
* - Requires API key in X-Automation-Key header
|
|
3461
|
-
* - Set AUTOMATION_API_KEY in Railway environment variables
|
|
3462
|
-
*
|
|
3463
|
-
* **Setup:**
|
|
3464
|
-
* 1. Add AUTOMATION_API_KEY to Railway env vars (e.g., generate with: openssl rand -hex 32)
|
|
3465
|
-
* 2. Configure external cron to POST to this endpoint every 15 minutes
|
|
3466
|
-
* 3. Include X-Automation-Key: <your-key> header
|
|
3467
|
-
*
|
|
3468
|
-
* **Example cron-job.org setup:**
|
|
3469
|
-
* - URL: https://your-app.railway.app/api/v1/automation/cron/trigger-scheduled
|
|
3470
|
-
* - Method: POST
|
|
3471
|
-
* - Schedule: *15 * * * * (every 15 minutes)
|
|
3472
|
-
* - Custom Header: X-Automation-Key: your-secret-key-here
|
|
3473
|
-
*
|
|
3474
|
-
* **Returns:**
|
|
3475
|
-
* - 200 OK: Automation triggered successfully
|
|
3476
|
-
* - 401 Unauthorized: Invalid or missing API key
|
|
3477
|
-
* - 500 Internal Server Error: Execution failed
|
|
3478
|
-
*/
|
|
3479
|
-
triggerScheduled(options) {
|
|
3480
|
-
return (options.client ?? this.client).post({
|
|
3481
|
-
requestValidator: async (data) => await zAutomationCronTriggerScheduledData.parseAsync(data),
|
|
3482
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3483
|
-
url: '/api/v1/automation/api/v1/automation/cron/trigger-scheduled',
|
|
3484
|
-
...options
|
|
3485
|
-
});
|
|
3486
|
-
}
|
|
3487
|
-
/**
|
|
3488
|
-
* Cron Health Check
|
|
3489
|
-
*
|
|
3490
|
-
* Health check endpoint for external cron services.
|
|
3491
|
-
*
|
|
3492
|
-
* Some cron services (like cron-job.org) verify the endpoint is reachable
|
|
3493
|
-
* before enabling the job. This endpoint confirms the automation cron
|
|
3494
|
-
* endpoint is accessible.
|
|
3495
|
-
*/
|
|
3496
|
-
healthCheck(options) {
|
|
3497
|
-
return (options?.client ?? this.client).get({
|
|
3498
|
-
requestValidator: async (data) => await zAutomationCronHealthCheckData.parseAsync(data),
|
|
3499
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3500
|
-
url: '/api/v1/automation/api/v1/automation/cron/health',
|
|
3501
|
-
...options
|
|
3502
|
-
});
|
|
3503
|
-
}
|
|
3504
|
-
}
|
|
3505
|
-
export class Health extends HeyApiClient {
|
|
3506
|
-
/**
|
|
3507
|
-
* Automation Health Check
|
|
3508
|
-
*
|
|
3509
|
-
* Health check for automation system.
|
|
3510
|
-
*
|
|
3511
|
-
* Checks:
|
|
3512
|
-
* - API availability
|
|
3513
|
-
* - Prefect server connection
|
|
3514
|
-
* - Task registry
|
|
3515
|
-
* - Celery Beat (indirectly via task registry)
|
|
3516
|
-
*/
|
|
3517
|
-
checkAutomation(options) {
|
|
3518
|
-
return (options?.client ?? this.client).get({
|
|
3519
|
-
requestValidator: async (data) => await zHealthCheckAutomationData.parseAsync(data),
|
|
3520
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3521
|
-
url: '/api/v1/automation/health',
|
|
3522
|
-
...options
|
|
3523
|
-
});
|
|
3524
|
-
}
|
|
3525
|
-
/**
|
|
3526
|
-
* Health Check
|
|
3527
|
-
*
|
|
3528
|
-
* Health endpoint.
|
|
3529
|
-
*
|
|
3530
|
-
* - Default (`/health` or `/health?shallow=true`) is **liveness**: fast, no external deps.
|
|
3531
|
-
* - Optional (`/health?deep=true` or `/health?shallow=false`) performs **readiness** checks.
|
|
3532
|
-
*
|
|
3533
|
-
* Readiness only treats DB + Redis as critical. Other checks are informational/skipped.
|
|
3534
|
-
*/
|
|
3535
|
-
check(options) {
|
|
3536
|
-
return (options?.client ?? this.client).get({
|
|
3537
|
-
requestValidator: async (data) => await zHealthCheckData.parseAsync(data),
|
|
3538
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3539
|
-
url: '/health',
|
|
3540
|
-
...options
|
|
3541
|
-
});
|
|
3542
|
-
}
|
|
3543
|
-
}
|
|
3544
|
-
export class Integration extends HeyApiClient {
|
|
3545
|
-
/**
|
|
3546
|
-
* Webhook from Zitadel for organization removal
|
|
3547
|
-
*
|
|
3548
|
-
* Receives an authenticated JWT webhook payload from a Zitadel Action
|
|
3549
|
-
* when an organization is removed.
|
|
3550
|
-
*/
|
|
3551
|
-
handleOrgRemoved(options) {
|
|
3552
|
-
return (options?.client ?? this.client).post({
|
|
3553
|
-
requestValidator: async (data) => await zIntegrationHandleOrgRemovedData.parseAsync(data),
|
|
3554
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3555
|
-
url: '/api/v1/integration/org-removed',
|
|
3556
|
-
...options
|
|
3557
|
-
});
|
|
3558
|
-
}
|
|
3559
|
-
}
|
|
3560
|
-
export class IntegrationUser extends HeyApiClient {
|
|
3561
|
-
/**
|
|
3562
|
-
* Webhook from Zitadel for user removal
|
|
3563
|
-
*
|
|
3564
|
-
* Receives an authenticated JWT webhook payload from a Zitadel Action
|
|
3565
|
-
* when a user is removed.
|
|
3566
|
-
*/
|
|
3567
|
-
handleRemoved(options) {
|
|
3568
|
-
return (options?.client ?? this.client).post({
|
|
3569
|
-
requestValidator: async (data) => await zIntegrationUserHandleRemovedData.parseAsync(data),
|
|
3570
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3571
|
-
url: '/api/v1/integration/user-removed',
|
|
3572
|
-
...options
|
|
3573
|
-
});
|
|
3574
|
-
}
|
|
3575
|
-
}
|
|
3576
|
-
export class Sentry extends HeyApiClient {
|
|
3577
|
-
/**
|
|
3578
|
-
* Trigger Sentry Error
|
|
3579
|
-
*
|
|
3580
|
-
* Test endpoint to verify Sentry integration.
|
|
3581
|
-
* This endpoint intentionally raises an error to test error tracking.
|
|
3582
|
-
*/
|
|
3583
|
-
triggerError(options) {
|
|
3584
|
-
return (options?.client ?? this.client).get({
|
|
3585
|
-
requestValidator: async (data) => await zSentryTriggerErrorData.parseAsync(data),
|
|
3586
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3587
|
-
url: '/sentry-debug',
|
|
3588
|
-
...options
|
|
3589
|
-
});
|
|
3590
|
-
}
|
|
3591
|
-
}
|
|
3592
|
-
export class HealthNotifications extends HeyApiClient {
|
|
3593
|
-
/**
|
|
3594
|
-
* Notification Health Check
|
|
3595
|
-
*
|
|
3596
|
-
* Health check endpoint for notification services configuration.
|
|
3597
|
-
*/
|
|
3598
|
-
check(options) {
|
|
3599
|
-
return (options?.client ?? this.client).get({
|
|
3600
|
-
requestValidator: async (data) => await zHealthNotificationsCheckData.parseAsync(data),
|
|
3601
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3602
|
-
url: '/health/notifications',
|
|
3603
|
-
...options
|
|
3604
|
-
});
|
|
3605
|
-
}
|
|
3606
|
-
}
|
|
3607
|
-
export class Metrics extends HeyApiClient {
|
|
3608
|
-
/**
|
|
3609
|
-
* Metrics
|
|
3610
|
-
*
|
|
3611
|
-
* Prometheus metrics endpoint for monitoring.
|
|
3612
|
-
*/
|
|
3613
|
-
get(options) {
|
|
3614
|
-
return (options?.client ?? this.client).get({
|
|
3615
|
-
requestValidator: async (data) => await zMetricsGetData.parseAsync(data),
|
|
3616
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3617
|
-
url: '/metrics',
|
|
3618
|
-
...options
|
|
3619
|
-
});
|
|
3620
|
-
}
|
|
3621
|
-
}
|
|
3622
|
-
export class Features extends HeyApiClient {
|
|
3623
|
-
/**
|
|
3624
|
-
* Get Feature Flags
|
|
3625
|
-
*
|
|
3626
|
-
* Get current feature flag status for frontend clients.
|
|
3627
|
-
*/
|
|
3628
|
-
get(options) {
|
|
3629
|
-
return (options?.client ?? this.client).get({
|
|
3630
|
-
requestValidator: async (data) => await zFeaturesGetData.parseAsync(data),
|
|
3631
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3632
|
-
url: '/config/features',
|
|
3633
|
-
...options
|
|
3634
|
-
});
|
|
3635
|
-
}
|
|
3636
|
-
}
|
|
3637
|
-
export class Realtime extends HeyApiClient {
|
|
3638
|
-
/**
|
|
3639
|
-
* Realtime WebSocket protocol info
|
|
3640
|
-
*
|
|
3641
|
-
* Get WebSocket protocol information.
|
|
3642
|
-
*
|
|
3643
|
-
* Returns documentation about the WebSocket endpoint including:
|
|
3644
|
-
* - Connection endpoint
|
|
3645
|
-
* - Authentication requirements
|
|
3646
|
-
* - Protocol details
|
|
3647
|
-
* - ACK message format
|
|
3648
|
-
*
|
|
3649
|
-
* Returns:
|
|
3650
|
-
* dict: WebSocket protocol information
|
|
3651
|
-
*/
|
|
3652
|
-
getInfo(options) {
|
|
3653
|
-
return (options?.client ?? this.client).get({
|
|
3654
|
-
requestValidator: async (data) => await zRealtimeGetInfoData.parseAsync(data),
|
|
3655
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3656
|
-
url: '/realtime-info',
|
|
3657
|
-
...options
|
|
3658
|
-
});
|
|
3659
|
-
}
|
|
3660
|
-
}
|
|
3661
|
-
export class Linebundle extends HeyApiClient {
|
|
3662
|
-
constructor(args) {
|
|
3663
|
-
super(args);
|
|
3664
|
-
Linebundle.__registry.set(this, args?.key);
|
|
3665
|
-
}
|
|
3666
|
-
/**
|
|
3667
|
-
* Webhook from Zitadel for user creation
|
|
3668
|
-
*
|
|
3669
|
-
* Receives an authenticated JWT webhook payload from a Zitadel Action
|
|
3670
|
-
* when a new human user is created (admin-created or self-registered).
|
|
3671
|
-
*/
|
|
3672
|
-
handleUserCreatedApiV1IntegrationUserCreatedPost(options) {
|
|
3673
|
-
return (options?.client ?? this.client).post({
|
|
3674
|
-
requestValidator: async (data) => await zHandleUserCreatedApiV1IntegrationUserCreatedPostData.parseAsync(data),
|
|
3675
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3676
|
-
url: '/api/v1/integration/user-created',
|
|
3677
|
-
...options
|
|
3678
|
-
});
|
|
3679
|
-
}
|
|
3680
|
-
/**
|
|
3681
|
-
* Webhook from Zitadel for user profile update
|
|
3682
|
-
*
|
|
3683
|
-
* Receives an authenticated JWT webhook payload from a Zitadel Action
|
|
3684
|
-
* when a user's profile is updated (name, email, etc.).
|
|
3685
|
-
*/
|
|
3686
|
-
handleUserUpdatedApiV1IntegrationUserUpdatedPost(options) {
|
|
3687
|
-
return (options?.client ?? this.client).post({
|
|
3688
|
-
requestValidator: async (data) => await zHandleUserUpdatedApiV1IntegrationUserUpdatedPostData.parseAsync(data),
|
|
3689
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3690
|
-
url: '/api/v1/integration/user-updated',
|
|
3691
|
-
...options
|
|
3692
|
-
});
|
|
3693
|
-
}
|
|
3694
|
-
/**
|
|
3695
|
-
* Get Latest Event Version (Public Access)
|
|
3696
|
-
*
|
|
3697
|
-
* Get the most recent published version of an event. Supports unauthenticated access for PUBLIC events.
|
|
3698
|
-
*/
|
|
3699
|
-
getLatestPublicEventVersion(options) {
|
|
3700
|
-
return (options.client ?? this.client).get({
|
|
3701
|
-
requestValidator: async (data) => await zGetLatestPublicEventVersionData.parseAsync(data),
|
|
3702
|
-
responseValidator: async (data) => await zGetLatestPublicEventVersionResponse.parseAsync(data),
|
|
3703
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3704
|
-
url: '/api/v1/public/event/{event_id}/versions/latest',
|
|
3705
|
-
...options
|
|
3706
|
-
});
|
|
3707
|
-
}
|
|
3708
|
-
/**
|
|
3709
|
-
* Get Latest Published Version
|
|
3710
|
-
*
|
|
3711
|
-
* Get the latest published version of a space.
|
|
3712
|
-
* Public access permitted.
|
|
3713
|
-
*/
|
|
3714
|
-
getLatestPublicSpaceVersion(options) {
|
|
3715
|
-
return (options.client ?? this.client).get({
|
|
3716
|
-
requestValidator: async (data) => await zGetLatestPublicSpaceVersionData.parseAsync(data),
|
|
3717
|
-
responseValidator: async (data) => await zGetLatestPublicSpaceVersionResponse.parseAsync(data),
|
|
3718
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3719
|
-
url: '/api/v1/public/space/{space_id}/versions/latest',
|
|
3720
|
-
...options
|
|
3721
|
-
});
|
|
3722
|
-
}
|
|
3723
|
-
/**
|
|
3724
|
-
* Establish realtime WebSocket connection (upgrade)
|
|
3725
|
-
*
|
|
3726
|
-
* Upgrades to WebSocket at this path (subprotocol: json).
|
|
3727
|
-
*
|
|
3728
|
-
* Requires valid authenticated user & tenant context. Server sends single ACK then may push events.
|
|
3729
|
-
*/
|
|
3730
|
-
connectWebSocket(options) {
|
|
3731
|
-
return (options?.client ?? this.client).get({
|
|
3732
|
-
requestValidator: async (data) => await zConnectWebSocketData.parseAsync(data),
|
|
3733
|
-
security: [{ scheme: 'bearer', type: 'http' }],
|
|
3734
|
-
url: '/ws',
|
|
3735
|
-
...options
|
|
3736
|
-
});
|
|
3737
|
-
}
|
|
3738
|
-
get user() {
|
|
3739
|
-
return this._user ?? (this._user = new User({ client: this.client }));
|
|
3740
|
-
}
|
|
3741
|
-
get users() {
|
|
3742
|
-
return this._users ?? (this._users = new Users({ client: this.client }));
|
|
3743
|
-
}
|
|
3744
|
-
get authContexts() {
|
|
3745
|
-
return this._authContexts ?? (this._authContexts = new AuthContexts({ client: this.client }));
|
|
3746
|
-
}
|
|
3747
|
-
get auditLogs() {
|
|
3748
|
-
return this._auditLogs ?? (this._auditLogs = new AuditLogs({ client: this.client }));
|
|
3749
|
-
}
|
|
3750
|
-
get events() {
|
|
3751
|
-
return this._events ?? (this._events = new Events({ client: this.client }));
|
|
3752
|
-
}
|
|
3753
|
-
get event() {
|
|
3754
|
-
return this._event ?? (this._event = new Event_({ client: this.client }));
|
|
3755
|
-
}
|
|
3756
|
-
get eventTimezones() {
|
|
3757
|
-
return this._eventTimezones ?? (this._eventTimezones = new EventTimezones({ client: this.client }));
|
|
3758
|
-
}
|
|
3759
|
-
get eventAttendees() {
|
|
3760
|
-
return this._eventAttendees ?? (this._eventAttendees = new EventAttendees({ client: this.client }));
|
|
3761
|
-
}
|
|
3762
|
-
get eventTimeline() {
|
|
3763
|
-
return this._eventTimeline ?? (this._eventTimeline = new EventTimeline({ client: this.client }));
|
|
3764
|
-
}
|
|
3765
|
-
get eventDocuments() {
|
|
3766
|
-
return this._eventDocuments ?? (this._eventDocuments = new EventDocuments({ client: this.client }));
|
|
3767
|
-
}
|
|
3768
|
-
get eventLocation() {
|
|
3769
|
-
return this._eventLocation ?? (this._eventLocation = new EventLocation({ client: this.client }));
|
|
3770
|
-
}
|
|
3771
|
-
get space() {
|
|
3772
|
-
return this._space ?? (this._space = new Space({ client: this.client }));
|
|
3773
|
-
}
|
|
3774
|
-
get spaces() {
|
|
3775
|
-
return this._spaces ?? (this._spaces = new Spaces({ client: this.client }));
|
|
3776
|
-
}
|
|
3777
|
-
get spaceRoles() {
|
|
3778
|
-
return this._spaceRoles ?? (this._spaceRoles = new SpaceRoles({ client: this.client }));
|
|
3779
|
-
}
|
|
3780
|
-
get spaceContacts() {
|
|
3781
|
-
return this._spaceContacts ?? (this._spaceContacts = new SpaceContacts({ client: this.client }));
|
|
3782
|
-
}
|
|
3783
|
-
get spaceEvents() {
|
|
3784
|
-
return this._spaceEvents ?? (this._spaceEvents = new SpaceEvents({ client: this.client }));
|
|
3785
|
-
}
|
|
3786
|
-
get spaceDocuments() {
|
|
3787
|
-
return this._spaceDocuments ?? (this._spaceDocuments = new SpaceDocuments({ client: this.client }));
|
|
3788
|
-
}
|
|
3789
|
-
get places() {
|
|
3790
|
-
return this._places ?? (this._places = new Places({ client: this.client }));
|
|
3791
|
-
}
|
|
3792
|
-
get place() {
|
|
3793
|
-
return this._place ?? (this._place = new Place({ client: this.client }));
|
|
3794
|
-
}
|
|
3795
|
-
get analytic() {
|
|
3796
|
-
return this._analytic ?? (this._analytic = new Analytic({ client: this.client }));
|
|
3797
|
-
}
|
|
3798
|
-
get organizations() {
|
|
3799
|
-
return this._organizations ?? (this._organizations = new Organizations({ client: this.client }));
|
|
3800
|
-
}
|
|
3801
|
-
get customRoles() {
|
|
3802
|
-
return this._customRoles ?? (this._customRoles = new CustomRoles({ client: this.client }));
|
|
3803
|
-
}
|
|
3804
|
-
get roles() {
|
|
3805
|
-
return this._roles ?? (this._roles = new Roles({ client: this.client }));
|
|
3806
|
-
}
|
|
3807
|
-
get permissions() {
|
|
3808
|
-
return this._permissions ?? (this._permissions = new Permissions({ client: this.client }));
|
|
3809
|
-
}
|
|
3810
|
-
get bookings() {
|
|
3811
|
-
return this._bookings ?? (this._bookings = new Bookings({ client: this.client }));
|
|
3812
|
-
}
|
|
3813
|
-
get booking() {
|
|
3814
|
-
return this._booking ?? (this._booking = new Booking({ client: this.client }));
|
|
3815
|
-
}
|
|
3816
|
-
get chatRooms() {
|
|
3817
|
-
return this._chatRooms ?? (this._chatRooms = new ChatRooms({ client: this.client }));
|
|
3818
|
-
}
|
|
3819
|
-
get chatMessages() {
|
|
3820
|
-
return this._chatMessages ?? (this._chatMessages = new ChatMessages({ client: this.client }));
|
|
3821
|
-
}
|
|
3822
|
-
get aiAgent() {
|
|
3823
|
-
return this._aiAgent ?? (this._aiAgent = new AiAgent({ client: this.client }));
|
|
3824
|
-
}
|
|
3825
|
-
get aiAgent2() {
|
|
3826
|
-
return this._aiAgent2 ?? (this._aiAgent2 = new AiAgent2({ client: this.client }));
|
|
3827
|
-
}
|
|
3828
|
-
get ai() {
|
|
3829
|
-
return this._ai ?? (this._ai = new AI({ client: this.client }));
|
|
3830
|
-
}
|
|
3831
|
-
get aiAgents() {
|
|
3832
|
-
return this._aiAgents ?? (this._aiAgents = new AiAgents({ client: this.client }));
|
|
3833
|
-
}
|
|
3834
|
-
get aiWorkflows() {
|
|
3835
|
-
return this._aiWorkflows ?? (this._aiWorkflows = new AiWorkflows({ client: this.client }));
|
|
3836
|
-
}
|
|
3837
|
-
get contacts() {
|
|
3838
|
-
return this._contacts ?? (this._contacts = new Contacts({ client: this.client }));
|
|
3839
|
-
}
|
|
3840
|
-
get automationRules() {
|
|
3841
|
-
return this._automationRules ?? (this._automationRules = new AutomationRules({ client: this.client }));
|
|
3842
|
-
}
|
|
3843
|
-
get automationMetadata() {
|
|
3844
|
-
return this._automationMetadata ?? (this._automationMetadata = new AutomationMetadata({ client: this.client }));
|
|
3845
|
-
}
|
|
3846
|
-
get automationCron() {
|
|
3847
|
-
return this._automationCron ?? (this._automationCron = new AutomationCron({ client: this.client }));
|
|
3848
|
-
}
|
|
3849
|
-
get health() {
|
|
3850
|
-
return this._health ?? (this._health = new Health({ client: this.client }));
|
|
3851
|
-
}
|
|
3852
|
-
get integration() {
|
|
3853
|
-
return this._integration ?? (this._integration = new Integration({ client: this.client }));
|
|
3854
|
-
}
|
|
3855
|
-
get integrationUser() {
|
|
3856
|
-
return this._integrationUser ?? (this._integrationUser = new IntegrationUser({ client: this.client }));
|
|
3857
|
-
}
|
|
3858
|
-
get sentry() {
|
|
3859
|
-
return this._sentry ?? (this._sentry = new Sentry({ client: this.client }));
|
|
3860
|
-
}
|
|
3861
|
-
get healthNotifications() {
|
|
3862
|
-
return this._healthNotifications ?? (this._healthNotifications = new HealthNotifications({ client: this.client }));
|
|
3863
|
-
}
|
|
3864
|
-
get metrics() {
|
|
3865
|
-
return this._metrics ?? (this._metrics = new Metrics({ client: this.client }));
|
|
3866
|
-
}
|
|
3867
|
-
get features() {
|
|
3868
|
-
return this._features ?? (this._features = new Features({ client: this.client }));
|
|
3869
|
-
}
|
|
3870
|
-
get realtime() {
|
|
3871
|
-
return this._realtime ?? (this._realtime = new Realtime({ client: this.client }));
|
|
3872
|
-
}
|
|
3873
|
-
}
|
|
3874
|
-
Linebundle.__registry = new HeyApiRegistry();
|
|
3875
|
-
//# sourceMappingURL=sdk.gen.js.map
|