@macro-inc/sdk 0.4.0 → 0.5.0
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/CALLS.md +82 -0
- package/README.md +176 -7
- package/dist/chunk-2IVGAIGQ.js +80 -0
- package/dist/{chunk-PTX2RV2N.js → chunk-3SW6QVDV.js} +33 -0
- package/dist/{chunk-XFA7NCJ5.js → chunk-GT5EUYOR.js} +13 -15
- package/dist/{chunk-ZLBDES7U.js → chunk-HIW6KU2I.js} +490 -4
- package/dist/{chunk-AZJUIUIV.js → chunk-J2VK3NOR.js} +56 -0
- package/dist/{chunk-PZPTJI6F.js → chunk-UVJLWLSJ.js} +41 -2
- package/dist/generated/agent-fold/index.d.ts +8 -6
- package/dist/generated/agent-harness/index.d.ts +1 -1
- package/dist/generated/agent-harness/index.js +1 -1
- package/dist/generated/agent-harness/sdk.gen.d.ts +17 -1
- package/dist/generated/agent-harness/types.gen.d.ts +188 -3
- package/dist/generated/auth/index.js +1 -1
- package/dist/generated/auth/sdk.gen.d.ts +13 -15
- package/dist/generated/auth/types.gen.d.ts +36 -17
- package/dist/generated/cognition/index.d.ts +1 -1
- package/dist/generated/cognition/index.js +1 -1
- package/dist/generated/cognition/sdk.gen.d.ts +38 -1
- package/dist/generated/cognition/types.gen.d.ts +473 -4
- package/dist/generated/connection/types.gen.d.ts +1 -1
- package/dist/generated/notification/index.d.ts +1 -1
- package/dist/generated/notification/types.gen.d.ts +36 -1
- package/dist/generated/scheduled-action/index.d.ts +1 -1
- package/dist/generated/scheduled-action/index.js +1 -1
- package/dist/generated/scheduled-action/sdk.gen.d.ts +17 -2
- package/dist/generated/scheduled-action/types.gen.d.ts +642 -104
- package/dist/generated/storage/index.d.ts +1 -1
- package/dist/generated/storage/index.js +1 -1
- package/dist/generated/storage/sdk.gen.d.ts +204 -5
- package/dist/generated/storage/types.gen.d.ts +3969 -374
- package/dist/src/calls/browser.d.ts +14 -0
- package/dist/src/calls/browser.js +102 -0
- package/dist/src/calls/common.d.ts +18 -0
- package/dist/src/calls/node.d.ts +24 -0
- package/dist/src/calls/node.js +145 -0
- package/dist/src/calls/telemetry.d.ts +5 -0
- package/dist/src/entities/account-managers/grant.d.ts +28 -5
- package/dist/src/entities/account-managers/namespace.d.ts +15 -3
- package/dist/src/entities/activity/entity.d.ts +7 -0
- package/dist/src/entities/activity/namespace.d.ts +58 -0
- package/dist/src/entities/activity/namespace.test.d.ts +1 -0
- package/dist/src/entities/agent-sessions/activity.d.ts +10 -2
- package/dist/src/entities/agent-sessions/agent-session.d.ts +193 -18
- package/dist/src/entities/agent-sessions/code-execution.d.ts +15 -3
- package/dist/src/entities/agent-sessions/conversation.d.ts +46 -9
- package/dist/src/entities/agent-sessions/namespace.d.ts +71 -16
- package/dist/src/entities/agent-sessions/origin.d.ts +1 -1
- package/dist/src/entities/agent-sessions/queued-action.d.ts +17 -3
- package/dist/src/entities/agent-sessions/review.d.ts +55 -4
- package/dist/src/entities/agent-sessions/tool-approval.d.ts +5 -1
- package/dist/src/entities/agents/agent.d.ts +98 -3
- package/dist/src/entities/agents/namespace.d.ts +52 -8
- package/dist/src/entities/ai/namespace.d.ts +9 -1
- package/dist/src/entities/api-keys/api-key.d.ts +6 -1
- package/dist/src/entities/api-keys/namespace.d.ts +15 -3
- package/dist/src/entities/bots/bot.d.ts +38 -6
- package/dist/src/entities/bots/namespace.d.ts +13 -1
- package/dist/src/entities/bots/token.d.ts +6 -1
- package/dist/src/entities/calendar/booking-link.d.ts +7 -1
- package/dist/src/entities/calendar/booking-namespace.d.ts +13 -0
- package/dist/src/entities/calendar/booking.d.ts +15 -0
- package/dist/src/entities/calendar/calendar.d.ts +7 -1
- package/dist/src/entities/calendar/event.d.ts +59 -9
- package/dist/src/entities/calendar/namespace.d.ts +88 -10
- package/dist/src/entities/calendar/replacement.d.ts +19 -3
- package/dist/src/entities/calls/call-record.d.ts +90 -14
- package/dist/src/entities/calls/connection.d.ts +7 -1
- package/dist/src/entities/calls/message.d.ts +27 -5
- package/dist/src/entities/calls/namespace.d.ts +15 -3
- package/dist/src/entities/canvases/canvas.d.ts +324 -0
- package/dist/src/entities/channels/access-request.d.ts +10 -2
- package/dist/src/entities/channels/activity.d.ts +20 -4
- package/dist/src/entities/channels/channel.d.ts +130 -23
- package/dist/src/entities/channels/labels.d.ts +41 -7
- package/dist/src/entities/channels/message.d.ts +41 -7
- package/dist/src/entities/channels/namespace.d.ts +28 -3
- package/dist/src/entities/channels/post.test.d.ts +1 -0
- package/dist/src/entities/channels/thread.d.ts +19 -3
- package/dist/src/entities/chats/chat.d.ts +56 -6
- package/dist/src/entities/chats/generation.d.ts +11 -2
- package/dist/src/entities/chats/namespace.d.ts +10 -2
- package/dist/src/entities/connected-apps/connected-app.d.ts +14 -1
- package/dist/src/entities/connected-apps/connector.d.ts +3 -0
- package/dist/src/entities/connected-apps/namespace.d.ts +16 -0
- package/dist/src/entities/crm/company.d.ts +63 -15
- package/dist/src/entities/crm/contact.d.ts +60 -13
- package/dist/src/entities/crm/namespace.d.ts +85 -11
- package/dist/src/entities/crm/pipeline-entry.d.ts +102 -0
- package/dist/src/entities/crm/pipeline.d.ts +271 -27
- package/dist/src/entities/crm/pipelines.d.ts +39 -2
- package/dist/src/entities/databases/column.d.ts +54 -7
- package/dist/src/entities/databases/database.d.ts +126 -12
- package/dist/src/entities/databases/namespace.d.ts +16 -4
- package/dist/src/entities/databases/row.d.ts +2 -0
- package/dist/src/entities/databases/saved-query.d.ts +145 -0
- package/dist/src/entities/databases/table.d.ts +64 -10
- package/dist/src/entities/databases/view.d.ts +27 -5
- package/dist/src/entities/databases/webhook.d.ts +8 -1
- package/dist/src/entities/documents/ai-edit.d.ts +2 -0
- package/dist/src/entities/documents/anchor.d.ts +12 -2
- package/dist/src/entities/documents/comment.d.ts +29 -5
- package/dist/src/entities/documents/document.d.ts +243 -20
- package/dist/src/entities/documents/markdown.d.ts +25 -0
- package/dist/src/entities/documents/namespace.d.ts +132 -13
- package/dist/src/entities/documents/skills.test.d.ts +1 -0
- package/dist/src/entities/documents/system-skill.d.ts +21 -1
- package/dist/src/entities/documents/text-comment.d.ts +41 -0
- package/dist/src/entities/documents/text-comment.test.d.ts +1 -0
- package/dist/src/entities/documents/version.d.ts +5 -1
- package/dist/src/entities/email/attachment.d.ts +3 -0
- package/dist/src/entities/email/draft.d.ts +61 -9
- package/dist/src/entities/email/filter.d.ts +12 -2
- package/dist/src/entities/email/label.d.ts +7 -1
- package/dist/src/entities/email/link.d.ts +5 -1
- package/dist/src/entities/email/message.d.ts +55 -8
- package/dist/src/entities/email/namespace.d.ts +127 -21
- package/dist/src/entities/email/thread.d.ts +99 -16
- package/dist/src/entities/entity-mentions/mention.d.ts +6 -1
- package/dist/src/entities/entity-mentions/namespace.d.ts +5 -1
- package/dist/src/entities/entity.d.ts +56 -6
- package/dist/src/entities/external-chat/chat.d.ts +62 -11
- package/dist/src/entities/external-chat/message.d.ts +1 -1
- package/dist/src/entities/external-chat/namespace.d.ts +5 -1
- package/dist/src/entities/external-chat/send.d.ts +10 -2
- package/dist/src/entities/favorites/namespace.d.ts +20 -3
- package/dist/src/entities/foreign/foreign-entity.d.ts +5 -1
- package/dist/src/entities/foreign/namespace.d.ts +4 -0
- package/dist/src/entities/forms/form.d.ts +71 -13
- package/dist/src/entities/forms/namespace.d.ts +10 -2
- package/dist/src/entities/forms/question.d.ts +35 -7
- package/dist/src/entities/forms/response.d.ts +25 -5
- package/dist/src/entities/forms/section.d.ts +15 -3
- package/dist/src/entities/github-pull-requests/namespace.d.ts +5 -1
- package/dist/src/entities/github-pull-requests/pull-request.d.ts +15 -3
- package/dist/src/entities/harnesses/harness.d.ts +51 -3
- package/dist/src/entities/harnesses/namespace.d.ts +53 -7
- package/dist/src/entities/harnesses/pairing.d.ts +12 -2
- package/dist/src/entities/images/image.d.ts +16 -5
- package/dist/src/entities/images/namespace.d.ts +8 -1
- package/dist/src/entities/initiatives/initiative.d.ts +117 -3
- package/dist/src/entities/initiatives/initiative.test.d.ts +1 -0
- package/dist/src/entities/initiatives/namespace.d.ts +69 -7
- package/dist/src/entities/me/namespace.d.ts +27 -2
- package/dist/src/entities/meetings/meeting.d.ts +45 -8
- package/dist/src/entities/meetings/namespace.d.ts +20 -4
- package/dist/src/entities/memory/namespace.d.ts +49 -0
- package/dist/src/entities/memory/namespace.test.d.ts +1 -0
- package/dist/src/entities/messages/discussion.d.ts +84 -0
- package/dist/src/entities/messages/thread.d.ts +19 -5
- package/dist/src/entities/notifications/namespace.d.ts +40 -7
- package/dist/src/entities/notifications/notification.d.ts +29 -5
- package/dist/src/entities/pins/namespace.d.ts +23 -4
- package/dist/src/entities/projects/namespace.d.ts +29 -0
- package/dist/src/entities/projects/project.d.ts +47 -6
- package/dist/src/entities/properties/namespace.d.ts +67 -11
- package/dist/src/entities/properties/namespace.test.d.ts +1 -0
- package/dist/src/entities/properties/property-definition.d.ts +30 -5
- package/dist/src/entities/properties/property-option.d.ts +14 -2
- package/dist/src/entities/referrals/namespace.d.ts +8 -1
- package/dist/src/entities/routines/namespace.d.ts +128 -7
- package/dist/src/entities/routines/routine.d.ts +111 -25
- package/dist/src/entities/saved-views/namespace.d.ts +57 -0
- package/dist/src/entities/saved-views/saved-view.d.ts +78 -0
- package/dist/src/entities/search/namespace.d.ts +5 -1
- package/dist/src/entities/sharing/access.d.ts +50 -9
- package/dist/src/entities/spreadsheets/spreadsheet.d.ts +201 -0
- package/dist/src/entities/tasks/namespace.d.ts +13 -1
- package/dist/src/entities/tasks/task.d.ts +7 -1
- package/dist/src/entities/teams/invite.d.ts +3 -0
- package/dist/src/entities/teams/namespace.d.ts +10 -2
- package/dist/src/entities/teams/team.d.ts +7 -0
- package/dist/src/entities/unfurls/namespace.d.ts +12 -2
- package/dist/src/entities/users/namespace.d.ts +19 -1
- package/dist/src/entities/users/profile-picture.d.ts +29 -0
- package/dist/src/entities/users/profile-picture.test.d.ts +1 -0
- package/dist/src/entities/users/user.d.ts +52 -1
- package/dist/src/entities/web/namespace.d.ts +6 -0
- package/dist/src/entities/webhooks/namespace.d.ts +5 -0
- package/dist/src/entities/webhooks/webhook.d.ts +47 -7
- package/dist/src/entities/whatsapp/account.d.ts +5 -1
- package/dist/src/entities/whatsapp/chat.d.ts +9 -1
- package/dist/src/entities/whatsapp/namespace.d.ts +7 -1
- package/dist/src/entities/workspace/namespace.d.ts +7 -1
- package/dist/src/entities/workspace/query.d.ts +5 -1
- package/dist/src/events/hydrate/user.d.ts +14 -0
- package/dist/src/events/receiver.d.ts +2 -0
- package/dist/src/events/types.d.ts +2 -1
- package/dist/src/macro.d.ts +33 -5
- package/dist/src/macro.js +15635 -10132
- package/dist/src/utils/lazy.d.ts +7 -1
- package/package.json +32 -5
- package/dist/src/entities/crm/comment.d.ts +0 -64
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { AttendeeResponseStatus, CalendarAttendeeInputBody, CalendarDeletionScopeParam, CalendarEvent as CalendarEventRecord, CalendarGuestInputBody, CalendarRsvpScopeParam, CalendarUpdateScopeParam, ConferenceChange, EventReminders, EventTime, EventTransparency, EventVisibility, GuestPolicy, OutOfOfficeProperties } from '../../../generated/calendar/types.gen';
|
|
2
2
|
import type { MacroClient } from '../../utils/client';
|
|
3
|
+
import type { Channel } from '../channels/channel';
|
|
3
4
|
import { MacroEntity } from '../entity';
|
|
4
5
|
import { Calendar } from './calendar';
|
|
5
6
|
import { CalendarReplacement } from './replacement';
|
|
@@ -140,7 +141,10 @@ export declare class CalendarEvent extends MacroEntity<CalendarEventRecord> {
|
|
|
140
141
|
/** The calendar the canonical source belongs to, when known. */
|
|
141
142
|
readonly calendar: () => Promise<Calendar | undefined>;
|
|
142
143
|
/** The full synced event record. Available on a seeded handle (from create /
|
|
143
|
-
* update / rsvp); a bare `byId` handle throws (no fetch-by-id endpoint).
|
|
144
|
+
* update / rsvp); a bare `byId` handle throws (no fetch-by-id endpoint).
|
|
145
|
+
*
|
|
146
|
+
* @readonly
|
|
147
|
+
*/
|
|
144
148
|
record(): Promise<CalendarEventRecord>;
|
|
145
149
|
/** Update the event and return a handle to its synced record.
|
|
146
150
|
*
|
|
@@ -155,7 +159,12 @@ export declare class CalendarEvent extends MacroEntity<CalendarEventRecord> {
|
|
|
155
159
|
* to a meeting the user organizes from one of the inboxes (add them from
|
|
156
160
|
* that copy and say why). Reminders belong to one copy, so set them on one
|
|
157
161
|
* copy and say which inbox you used. Without `inbox` the call is refused
|
|
158
|
-
* with `copy_choice_required`, listing each copy and the question to ask.
|
|
162
|
+
* with `copy_choice_required`, listing each copy and the question to ask.
|
|
163
|
+
*
|
|
164
|
+
* @destructive
|
|
165
|
+
* @openworld
|
|
166
|
+
* @idempotent
|
|
167
|
+
*/
|
|
159
168
|
update(options: UpdateEventOptions): Promise<CalendarEvent>;
|
|
160
169
|
/** Delete the event (or a scoped part of a recurring series) at its provider.
|
|
161
170
|
*
|
|
@@ -172,16 +181,28 @@ export declare class CalendarEvent extends MacroEntity<CalendarEventRecord> {
|
|
|
172
181
|
* Deleting a copy where they are a guest takes the meeting off that inbox's
|
|
173
182
|
* calendar: on Google it also declines the invitation and tells the
|
|
174
183
|
* organizer, while on Outlook the organizer is not told and still sees the
|
|
175
|
-
* invitation unanswered.
|
|
184
|
+
* invitation unanswered.
|
|
185
|
+
*
|
|
186
|
+
* @destructive
|
|
187
|
+
* @openworld
|
|
188
|
+
* @idempotent
|
|
189
|
+
*/
|
|
176
190
|
delete(options?: DeleteEventOptions): Promise<void>;
|
|
177
191
|
/** Preview an organizer replacement without cancelling or sending invitations.
|
|
178
|
-
* Review replacement.status() before explicitly calling replacement.confirm().
|
|
192
|
+
* Review replacement.status() before explicitly calling replacement.confirm().
|
|
193
|
+
*
|
|
194
|
+
* @write
|
|
195
|
+
*/
|
|
179
196
|
prepareReplacement(options: {
|
|
180
197
|
removeConference: boolean;
|
|
181
198
|
recurrenceId?: string;
|
|
182
199
|
calendar?: Calendar;
|
|
183
200
|
}): Promise<CalendarReplacement>;
|
|
184
|
-
/**
|
|
201
|
+
/**
|
|
202
|
+
* Open this calendar copy in its provider for actions unavailable through its API.
|
|
203
|
+
*
|
|
204
|
+
* @readonly
|
|
205
|
+
*/
|
|
185
206
|
providerUrl(options?: {
|
|
186
207
|
recurrenceId?: string;
|
|
187
208
|
calendar?: Calendar;
|
|
@@ -199,7 +220,12 @@ export declare class CalendarEvent extends MacroEntity<CalendarEventRecord> {
|
|
|
199
220
|
*
|
|
200
221
|
* The organizer may add guests, and so may a guest the organizer lets
|
|
201
222
|
* invite others (see {@link CalendarEvent.viewerCan}); Google emails the
|
|
202
|
-
* new guests.
|
|
223
|
+
* new guests.
|
|
224
|
+
*
|
|
225
|
+
* @destructive
|
|
226
|
+
* @openworld
|
|
227
|
+
* @idempotent
|
|
228
|
+
*/
|
|
203
229
|
inviteGuests(options: InviteGuestsOptions): Promise<CalendarEvent>;
|
|
204
230
|
/** Add a snapshot of an event shared with one of the requester's
|
|
205
231
|
* channels to one of their Google calendars, and return a handle to the
|
|
@@ -210,15 +236,39 @@ export declare class CalendarEvent extends MacroEntity<CalendarEventRecord> {
|
|
|
210
236
|
* their calendars, whichever calendar is named, so it cannot be added to
|
|
211
237
|
* another of their calendars either; with `join_request_open` while their
|
|
212
238
|
* request to join it is pending or accepted (the meeting then arrives as an
|
|
213
|
-
* invitation); and with `copy_refused` when Google will not import it.
|
|
239
|
+
* invitation); and with `copy_refused` when Google will not import it.
|
|
240
|
+
*
|
|
241
|
+
* @write
|
|
242
|
+
* @openworld
|
|
243
|
+
*/
|
|
214
244
|
addToCalendar(options?: {
|
|
215
245
|
calendar?: Calendar;
|
|
216
246
|
}): Promise<CalendarEvent>;
|
|
247
|
+
/** Share the event with a channel's current members, as posting it in the
|
|
248
|
+
* channel does: they can then preview it, export it with {@link ics}, add it
|
|
249
|
+
* to their calendar with {@link addToCalendar} and ask to join. The caller
|
|
250
|
+
* must be in the channel and hold the event on their own calendar; private
|
|
251
|
+
* and confidential events are refused with a 403. Sharing again changes
|
|
252
|
+
* nothing.
|
|
253
|
+
*
|
|
254
|
+
* @write
|
|
255
|
+
* @idempotent
|
|
256
|
+
*/
|
|
257
|
+
shareWithChannel(channel: Channel): Promise<void>;
|
|
217
258
|
/** The event as an iCalendar (`.ics`) document: its series, title,
|
|
218
259
|
* description, location and organizer, never its guests or join link.
|
|
219
260
|
* Available for the requester's own events and ones shared with a channel
|
|
220
|
-
* they belong to.
|
|
261
|
+
* they belong to.
|
|
262
|
+
*
|
|
263
|
+
* @readonly
|
|
264
|
+
*/
|
|
221
265
|
ics(): Promise<string>;
|
|
222
|
-
/**
|
|
266
|
+
/**
|
|
267
|
+
* Record the requester's RSVP and return a handle to the synced record.
|
|
268
|
+
*
|
|
269
|
+
* @destructive
|
|
270
|
+
* @openworld
|
|
271
|
+
* @idempotent
|
|
272
|
+
*/
|
|
223
273
|
rsvp(options: RsvpEventOptions): Promise<CalendarEvent>;
|
|
224
274
|
}
|
|
@@ -121,16 +121,29 @@ export type CalendarEventRole = 'organizer' | 'guest';
|
|
|
121
121
|
*/
|
|
122
122
|
export declare class CalendarNamespace {
|
|
123
123
|
private readonly client;
|
|
124
|
-
/**
|
|
124
|
+
/**
|
|
125
|
+
* Calendar availability settings, each referring to a typed calendar.
|
|
126
|
+
*
|
|
127
|
+
* @readonly
|
|
128
|
+
*/
|
|
125
129
|
availabilityCalendars(): Promise<{
|
|
126
130
|
calendar: Calendar;
|
|
127
131
|
name: string;
|
|
128
132
|
isPrimary: boolean;
|
|
129
133
|
contributesToAvailability: boolean;
|
|
130
134
|
}[]>;
|
|
131
|
-
/**
|
|
135
|
+
/**
|
|
136
|
+
* Current sharing preference for the team calendar.
|
|
137
|
+
*
|
|
138
|
+
* @readonly
|
|
139
|
+
*/
|
|
132
140
|
teamSharing(): Promise<TeamCalendarSharing>;
|
|
133
|
-
/**
|
|
141
|
+
/**
|
|
142
|
+
* Replace the team calendar sharing preference.
|
|
143
|
+
*
|
|
144
|
+
* @write
|
|
145
|
+
* @idempotent
|
|
146
|
+
*/
|
|
134
147
|
setTeamSharing(sharing: TeamCalendarSharing): Promise<TeamCalendarSharing>;
|
|
135
148
|
/** Occurrences on every calendar the user can see: their schedule is only
|
|
136
149
|
* `contributesToAvailability` rows and meetings they attend; call the rest
|
|
@@ -164,7 +177,10 @@ export declare class CalendarNamespace {
|
|
|
164
177
|
* `inbox` to its `update`, `inviteGuests` or `delete`; without it the call
|
|
165
178
|
* is refused with `copy_choice_required`, which names each copy's inbox and
|
|
166
179
|
* event and gives the question to ask. An occurrence whose calendar is no
|
|
167
|
-
* longer listed has no `inbox`; take it from that refusal.
|
|
180
|
+
* longer listed has no `inbox`; take it from that refusal.
|
|
181
|
+
*
|
|
182
|
+
* @readonly
|
|
183
|
+
*/
|
|
168
184
|
occurrences(options: Omit<ListOccurrencesData['query'], 'cursor'>): AsyncGenerator<{
|
|
169
185
|
event: CalendarEvent;
|
|
170
186
|
occurrence: import("../../../generated/storage").CalendarOccurrence;
|
|
@@ -173,7 +189,11 @@ export declare class CalendarNamespace {
|
|
|
173
189
|
inbox: string | undefined;
|
|
174
190
|
role: CalendarEventRole | undefined;
|
|
175
191
|
}, any, any>;
|
|
176
|
-
/**
|
|
192
|
+
/**
|
|
193
|
+
* A page of team availability, including its roster and continuation cursor.
|
|
194
|
+
*
|
|
195
|
+
* @readonly
|
|
196
|
+
*/
|
|
177
197
|
teamPage(options: NonNullable<ListTeamCalendarData['query']>): Promise<{
|
|
178
198
|
items: ({
|
|
179
199
|
owner: User;
|
|
@@ -196,7 +216,11 @@ export declare class CalendarNamespace {
|
|
|
196
216
|
}[];
|
|
197
217
|
nextCursor: string | undefined;
|
|
198
218
|
}>;
|
|
199
|
-
/**
|
|
219
|
+
/**
|
|
220
|
+
* Teammates' out-of-office occurrences in a bounded viewport. Check hasMore for truncation.
|
|
221
|
+
*
|
|
222
|
+
* @readonly
|
|
223
|
+
*/
|
|
200
224
|
teamOutOfOffice(options: NonNullable<ListTeamOutOfOfficeData['query']>): Promise<{
|
|
201
225
|
items: {
|
|
202
226
|
event: CalendarEvent;
|
|
@@ -210,18 +234,69 @@ export declare class CalendarNamespace {
|
|
|
210
234
|
/** Booking links, their settings, booked meetings and booking statistics. */
|
|
211
235
|
readonly booking: BookingNamespace;
|
|
212
236
|
constructor(client: MacroClient);
|
|
213
|
-
/**
|
|
237
|
+
/**
|
|
238
|
+
* When the user and their teammates are busy in a bounded UTC window (a day
|
|
239
|
+
* or a week is best, at most 370 days); `freeWindows` is present only when
|
|
240
|
+
* every person's data is complete, so never infer free time from missing
|
|
241
|
+
* busy blocks. Always includes the user; omit `members` for the whole team,
|
|
242
|
+
* or pass `[]` for only the user. Busy blocks carry no event titles, and
|
|
243
|
+
* working hours are not applied.
|
|
244
|
+
*
|
|
245
|
+
* @readonly
|
|
246
|
+
*/
|
|
247
|
+
teamAvailability(opts: {
|
|
248
|
+
/** Inclusive start, RFC 3339 UTC. */
|
|
249
|
+
start: string;
|
|
250
|
+
/** Exclusive end, RFC 3339 UTC; later than `start`. */
|
|
251
|
+
end: string;
|
|
252
|
+
/** At most 100 current teammates. */
|
|
253
|
+
members?: User[];
|
|
254
|
+
}): Promise<{
|
|
255
|
+
start: string;
|
|
256
|
+
end: string;
|
|
257
|
+
members: {
|
|
258
|
+
user: User;
|
|
259
|
+
busy: Array<import("../../../generated/storage").AvailabilityInterval>;
|
|
260
|
+
coverage: import("../../../generated/storage").AvailabilityCoverage;
|
|
261
|
+
unknownReasons: Array<import("../../../generated/storage").AvailabilityUnknownReason>;
|
|
262
|
+
}[];
|
|
263
|
+
freeWindows: import("../../../generated/storage").AvailabilityInterval[] | undefined;
|
|
264
|
+
/** Requested people who are not current teammates; nothing about them is disclosed. */
|
|
265
|
+
unknownUsers: User[];
|
|
266
|
+
complete: boolean;
|
|
267
|
+
summary: string;
|
|
268
|
+
}>;
|
|
269
|
+
/**
|
|
270
|
+
* The calendars the caller can see, some possibly not theirs, primaries and writable first.
|
|
271
|
+
*
|
|
272
|
+
* @readonly
|
|
273
|
+
*/
|
|
214
274
|
calendars(): Promise<Calendar[]>;
|
|
215
|
-
/**
|
|
275
|
+
/**
|
|
276
|
+
* A handle to a calendar by id. Detail loads on first access.
|
|
277
|
+
*
|
|
278
|
+
* @readonly
|
|
279
|
+
*/
|
|
216
280
|
calendar(id: string): Calendar;
|
|
217
|
-
/**
|
|
281
|
+
/**
|
|
282
|
+
* A handle to a calendar event by id, for driving mutations.
|
|
283
|
+
*
|
|
284
|
+
* @readonly
|
|
285
|
+
*/
|
|
218
286
|
event(id: string): CalendarEvent;
|
|
219
|
-
/**
|
|
287
|
+
/**
|
|
288
|
+
* Recover a saved replacement, including after its original event was retired.
|
|
289
|
+
*
|
|
290
|
+
* @readonly
|
|
291
|
+
*/
|
|
220
292
|
replacement(operationId: string): CalendarReplacement;
|
|
221
293
|
/**
|
|
222
294
|
* Create a calendar event and return a handle to its synced record; an
|
|
223
295
|
* agent's program is refused (403) and creates through a review or
|
|
224
296
|
* {@link createConfirmed} instead.
|
|
297
|
+
*
|
|
298
|
+
* @destructive
|
|
299
|
+
* @openworld
|
|
225
300
|
*/
|
|
226
301
|
createEvent(options: CreateEventOptions): Promise<CalendarEvent>;
|
|
227
302
|
/**
|
|
@@ -236,6 +311,9 @@ export declare class CalendarNamespace {
|
|
|
236
311
|
* out-of-office and guest policy, and the calendar to write to. The event
|
|
237
312
|
* is written to the provider at once and guests receive invitations; on an
|
|
238
313
|
* error, look for the event before creating it again.
|
|
314
|
+
*
|
|
315
|
+
* @destructive
|
|
316
|
+
* @openworld
|
|
239
317
|
*/
|
|
240
318
|
createConfirmed(options: ConfirmedEventOptions): Promise<CalendarEvent>;
|
|
241
319
|
}
|
|
@@ -5,11 +5,27 @@ export declare class CalendarReplacement {
|
|
|
5
5
|
private readonly client;
|
|
6
6
|
readonly id: string;
|
|
7
7
|
constructor(client: MacroClient, id: string);
|
|
8
|
-
/**
|
|
8
|
+
/** A handle to a replacement by its operation id. */
|
|
9
|
+
static byId(client: MacroClient, id: string): CalendarReplacement;
|
|
10
|
+
/**
|
|
11
|
+
* Read progress without initiating provider writes.
|
|
12
|
+
*
|
|
13
|
+
* @readonly
|
|
14
|
+
*/
|
|
9
15
|
status(): Promise<CalendarReplacementView>;
|
|
10
16
|
/** Confirm the reviewed cancellation and reinvitation, or resume that same operation.
|
|
11
|
-
* Present the preview and obtain the organizer's confirmation before the first call.
|
|
17
|
+
* Present the preview and obtain the organizer's confirmation before the first call.
|
|
18
|
+
*
|
|
19
|
+
* @destructive
|
|
20
|
+
* @openworld
|
|
21
|
+
* @idempotent
|
|
22
|
+
*/
|
|
12
23
|
confirm(): Promise<CalendarReplacementView>;
|
|
13
|
-
/**
|
|
24
|
+
/**
|
|
25
|
+
* Discard an unconfirmed preview. Confirmed operations must be recovered, not discarded.
|
|
26
|
+
*
|
|
27
|
+
* @destructive
|
|
28
|
+
* @idempotent
|
|
29
|
+
*/
|
|
14
30
|
discard(): Promise<void>;
|
|
15
31
|
}
|
|
@@ -6,6 +6,7 @@ import { FavoritableEntity } from '../entity';
|
|
|
6
6
|
import { Meeting } from '../meetings/meeting';
|
|
7
7
|
import { MessageThread, type TimelineOptions } from '../messages/thread';
|
|
8
8
|
import { EntityAccess } from '../sharing/access';
|
|
9
|
+
import { type SharePermissionOptions } from '../sharing/permissions';
|
|
9
10
|
import { User } from '../users/user';
|
|
10
11
|
import { CallConnection, type JoinOptions } from './connection';
|
|
11
12
|
import { CallMessage } from './message';
|
|
@@ -18,23 +19,53 @@ export declare class CallRecord extends FavoritableEntity<CallRecordDetail> {
|
|
|
18
19
|
private constructor();
|
|
19
20
|
/** Build a live call handle without fetching its archived detail. */
|
|
20
21
|
static fromLive(client: MacroClient, summary: LiveCallSummary): CallRecord;
|
|
21
|
-
/**
|
|
22
|
+
/**
|
|
23
|
+
* Join only while this call is live; never start a replacement call.
|
|
24
|
+
*
|
|
25
|
+
* @write
|
|
26
|
+
* @mcp-exclude Returns a live call room credential; MCP calls carry JSON only.
|
|
27
|
+
*/
|
|
22
28
|
join(opts?: JoinOptions): Promise<CallConnection>;
|
|
23
|
-
/**
|
|
29
|
+
/**
|
|
30
|
+
* Read the current ring state for this account.
|
|
31
|
+
*
|
|
32
|
+
* @readonly
|
|
33
|
+
*/
|
|
24
34
|
ringState(): Promise<RingStatus>;
|
|
25
|
-
/**
|
|
35
|
+
/**
|
|
36
|
+
* Read the connected room roster without joining.
|
|
37
|
+
*
|
|
38
|
+
* @readonly
|
|
39
|
+
*/
|
|
26
40
|
participants(): Promise<CallParticipant[]>;
|
|
27
|
-
/**
|
|
41
|
+
/**
|
|
42
|
+
* Decline this call's ring for the current account.
|
|
43
|
+
*
|
|
44
|
+
* @write
|
|
45
|
+
* @idempotent
|
|
46
|
+
*/
|
|
28
47
|
decline(): Promise<void>;
|
|
29
|
-
/**
|
|
48
|
+
/**
|
|
49
|
+
* Read the persistent discussion, which may be a channel thread.
|
|
50
|
+
*
|
|
51
|
+
* @readonly
|
|
52
|
+
*/
|
|
30
53
|
discussion(): Promise<MessageThread | Thread>;
|
|
31
54
|
/** Download recording bytes through the Macro host. */
|
|
32
55
|
readonly recording: {
|
|
33
56
|
bytes: () => Promise<Uint8Array>;
|
|
34
57
|
};
|
|
35
|
-
/**
|
|
58
|
+
/**
|
|
59
|
+
* A shared message thread scoped to this resource.
|
|
60
|
+
*
|
|
61
|
+
* @readonly
|
|
62
|
+
*/
|
|
36
63
|
messageThreadById(id: string): MessageThread;
|
|
37
|
-
/**
|
|
64
|
+
/**
|
|
65
|
+
* A mixed message and activity timeline page.
|
|
66
|
+
*
|
|
67
|
+
* @readonly
|
|
68
|
+
*/
|
|
38
69
|
timelinePage(selection?: TimelineOptions<CallMessage>): Promise<{
|
|
39
70
|
entries: ({
|
|
40
71
|
type: "activity";
|
|
@@ -57,16 +88,34 @@ export declare class CallRecord extends FavoritableEntity<CallRecordDetail> {
|
|
|
57
88
|
}>;
|
|
58
89
|
/** Access requests and direct user grants. */
|
|
59
90
|
readonly access: EntityAccess;
|
|
60
|
-
/**
|
|
91
|
+
/**
|
|
92
|
+
* Get or create a shareable meeting for this call.
|
|
93
|
+
*
|
|
94
|
+
* @write
|
|
95
|
+
* @idempotent
|
|
96
|
+
*/
|
|
61
97
|
meeting(): Promise<Meeting>;
|
|
62
|
-
/**
|
|
98
|
+
/**
|
|
99
|
+
* Update custom speaker assignments in the transcript.
|
|
100
|
+
*
|
|
101
|
+
* @write
|
|
102
|
+
* @idempotent
|
|
103
|
+
*/
|
|
63
104
|
editTranscript(assignments: EditCallTranscriptRequest['assignments']): Promise<void>;
|
|
64
|
-
/**
|
|
105
|
+
/**
|
|
106
|
+
* Toggle the server's share-with-team setting and return its new value.
|
|
107
|
+
*
|
|
108
|
+
* @write
|
|
109
|
+
*/
|
|
65
110
|
toggleTeamShare(): Promise<boolean>;
|
|
66
111
|
/** Favorites identify call records as `call`. */
|
|
67
112
|
readonly entityType = "call";
|
|
68
113
|
protected fetch(): Promise<CallRecordDetail>;
|
|
69
|
-
/**
|
|
114
|
+
/**
|
|
115
|
+
* The call's URL in the Macro web app; hand it to users as the link.
|
|
116
|
+
*
|
|
117
|
+
* @readonly
|
|
118
|
+
*/
|
|
70
119
|
webUrl(): string;
|
|
71
120
|
/** Identity, loaded detail and {@link webUrl}, so serialized handles carry their link. */
|
|
72
121
|
toJSON(): {
|
|
@@ -76,7 +125,11 @@ export declare class CallRecord extends FavoritableEntity<CallRecordDetail> {
|
|
|
76
125
|
};
|
|
77
126
|
/** A handle to a call record by id. Details load on first access. */
|
|
78
127
|
static byId(client: MacroClient, id: string): CallRecord;
|
|
79
|
-
/**
|
|
128
|
+
/**
|
|
129
|
+
* A message in this call's persistent chat. Fields load on first access.
|
|
130
|
+
*
|
|
131
|
+
* @readonly
|
|
132
|
+
*/
|
|
80
133
|
message(id: string): CallMessage;
|
|
81
134
|
/** The call's display name (user-supplied or AI-generated; unset while active). */
|
|
82
135
|
readonly name: () => Promise<string | undefined>;
|
|
@@ -124,16 +177,39 @@ export declare class CallRecord extends FavoritableEntity<CallRecordDetail> {
|
|
|
124
177
|
readonly recordingPreviewUrl: () => Promise<string | undefined>;
|
|
125
178
|
/** When the recording started, if it was recorded. */
|
|
126
179
|
readonly recordingStartedAt: () => Promise<string | undefined>;
|
|
127
|
-
/**
|
|
180
|
+
/**
|
|
181
|
+
* Rename the call or clear the custom name.
|
|
182
|
+
*
|
|
183
|
+
* @write
|
|
184
|
+
* @idempotent
|
|
185
|
+
*/
|
|
128
186
|
rename(name: string | null): Promise<void>;
|
|
129
187
|
/**
|
|
130
188
|
* Share the call with the creator's team (view access), or unshare it.
|
|
131
189
|
* While the call is live this sets the pending toggle any participant with
|
|
132
190
|
* edit access may change; once archived only the call's creator may change
|
|
133
191
|
* it and the API answers 403 otherwise.
|
|
192
|
+
*
|
|
193
|
+
* @write
|
|
194
|
+
* @idempotent
|
|
134
195
|
*/
|
|
135
196
|
setTeamShare(shared: boolean): Promise<void>;
|
|
136
|
-
/**
|
|
197
|
+
/**
|
|
198
|
+
* Change who can open the call: the link share and its access level, and
|
|
199
|
+
* channel grants. Omitted fields are left as they are; requires edit access
|
|
200
|
+
* (channel membership). `teamShareAccessLevel` only accepts `view` or `null`,
|
|
201
|
+
* and once the call is archived only its creator may change it.
|
|
202
|
+
*
|
|
203
|
+
* @write
|
|
204
|
+
* @idempotent
|
|
205
|
+
*/
|
|
206
|
+
updateSharePermissions(options: SharePermissionOptions): Promise<void>;
|
|
207
|
+
/**
|
|
208
|
+
* Delete the call record.
|
|
209
|
+
*
|
|
210
|
+
* @destructive
|
|
211
|
+
* @idempotent
|
|
212
|
+
*/
|
|
137
213
|
delete(): Promise<void>;
|
|
138
214
|
/** Search calls by name and transcript, most relevant first, auto-paginated. */
|
|
139
215
|
static search: (client: MacroClient, query: string, searchOpts?: import("../search/options").SearchOpts) => AsyncGenerator<CallRecord, any, any>;
|
|
@@ -21,7 +21,13 @@ export declare class CallConnection {
|
|
|
21
21
|
readonly started: boolean;
|
|
22
22
|
/** Construct a connection from the server's admission response. */
|
|
23
23
|
constructor(client: MacroClient, response: CallTokenResponse);
|
|
24
|
-
/**
|
|
24
|
+
/**
|
|
25
|
+
* Leave this exact call; safe to invoke after another call has started.
|
|
26
|
+
*
|
|
27
|
+
* @write
|
|
28
|
+
* @idempotent
|
|
29
|
+
* @mcp-exclude Acts on a live call connection, which only a join returns.
|
|
30
|
+
*/
|
|
25
31
|
leave(): Promise<{
|
|
26
32
|
callEnded: boolean;
|
|
27
33
|
}>;
|
|
@@ -20,14 +20,36 @@ export declare class CallMessage extends MacroEntity<MessageRecord> {
|
|
|
20
20
|
readonly createdAt: () => Promise<string>;
|
|
21
21
|
/** When the message was last updated. */
|
|
22
22
|
readonly updatedAt: () => Promise<string>;
|
|
23
|
-
/**
|
|
23
|
+
/**
|
|
24
|
+
* The call whose chat contains this message.
|
|
25
|
+
*
|
|
26
|
+
* @readonly
|
|
27
|
+
*/
|
|
24
28
|
call(): CallRecord;
|
|
25
|
-
/**
|
|
29
|
+
/**
|
|
30
|
+
* The user who sent this message.
|
|
31
|
+
*
|
|
32
|
+
* @readonly
|
|
33
|
+
*/
|
|
26
34
|
author(): Promise<User>;
|
|
27
|
-
/**
|
|
35
|
+
/**
|
|
36
|
+
* Reply in the call's canonical thread, including when this is a reply.
|
|
37
|
+
*
|
|
38
|
+
* @write
|
|
39
|
+
*/
|
|
28
40
|
reply(body: string | RichMessage): Promise<CallMessage>;
|
|
29
|
-
/**
|
|
41
|
+
/**
|
|
42
|
+
* Replace this message's body.
|
|
43
|
+
*
|
|
44
|
+
* @destructive
|
|
45
|
+
* @idempotent
|
|
46
|
+
*/
|
|
30
47
|
edit(body: string | RichMessage): Promise<this>;
|
|
31
|
-
/**
|
|
48
|
+
/**
|
|
49
|
+
* Delete this message, preserving the rest of the call's chat.
|
|
50
|
+
*
|
|
51
|
+
* @destructive
|
|
52
|
+
* @idempotent
|
|
53
|
+
*/
|
|
32
54
|
delete(): Promise<void>;
|
|
33
55
|
}
|
|
@@ -20,10 +20,22 @@ export declare class CallRecordNamespace {
|
|
|
20
20
|
constructor(client: MacroClient);
|
|
21
21
|
/** Get a lazy call handle; joining it never creates a call. */
|
|
22
22
|
byId(id: string): CallRecord;
|
|
23
|
-
/**
|
|
23
|
+
/**
|
|
24
|
+
* Search archived calls by name and transcript, not the live room roster.
|
|
25
|
+
*
|
|
26
|
+
* @readonly
|
|
27
|
+
*/
|
|
24
28
|
search(query: string, opts?: SearchOpts): AsyncGenerator<CallRecord>;
|
|
25
|
-
/**
|
|
29
|
+
/**
|
|
30
|
+
* List joinable live calls; use after an event stream reconnects.
|
|
31
|
+
*
|
|
32
|
+
* @readonly
|
|
33
|
+
*/
|
|
26
34
|
active(): Promise<CallRecord[]>;
|
|
27
|
-
/**
|
|
35
|
+
/**
|
|
36
|
+
* Preview these calls in input order; missing records are omitted.
|
|
37
|
+
*
|
|
38
|
+
* @readonly
|
|
39
|
+
*/
|
|
28
40
|
summaries(calls: CallRecord[]): Promise<CallSummary[]>;
|
|
29
41
|
}
|