@doist/comms-sdk 3.9.0 → 3.9.1
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.
|
@@ -164,16 +164,16 @@ export class UsersClient extends BaseClient {
|
|
|
164
164
|
return this.post(`${ENDPOINT_USERS}/update`, args, UserSchema);
|
|
165
165
|
}
|
|
166
166
|
/**
|
|
167
|
-
*
|
|
167
|
+
* Creates or partially updates the session user's shared status.
|
|
168
168
|
* The status belongs to the Todoist account, so it is shared with Todoist.
|
|
169
169
|
* Requires the `user:write` scope.
|
|
170
170
|
*
|
|
171
171
|
* @param args - The status to set.
|
|
172
|
-
* @param args.message - 1 to 80 characters once trimmed.
|
|
173
|
-
* @param args.emoji -
|
|
174
|
-
* @param args.activeUntil -
|
|
175
|
-
* @param args.effects -
|
|
176
|
-
*
|
|
172
|
+
* @param args.message - 1 to 80 characters once trimmed. Required when creating a status.
|
|
173
|
+
* @param args.emoji - Emoji to set; null removes it, omission preserves it.
|
|
174
|
+
* @param args.activeUntil - Future expiry (`Date` or ISO string); null removes it, omission preserves it.
|
|
175
|
+
* @param args.effects - Merge supplied effects. Omission or {} preserves effects; null clears all.
|
|
176
|
+
* An individual effect set to null is removed; {} preserves its configuration or enables defaults.
|
|
177
177
|
* @returns The updated user object.
|
|
178
178
|
*
|
|
179
179
|
* @example
|
|
@@ -160,16 +160,16 @@ export declare class UsersClient extends BaseClient {
|
|
|
160
160
|
*/
|
|
161
161
|
update(args: UpdateUserArgs): Promise<User>;
|
|
162
162
|
/**
|
|
163
|
-
*
|
|
163
|
+
* Creates or partially updates the session user's shared status.
|
|
164
164
|
* The status belongs to the Todoist account, so it is shared with Todoist.
|
|
165
165
|
* Requires the `user:write` scope.
|
|
166
166
|
*
|
|
167
167
|
* @param args - The status to set.
|
|
168
|
-
* @param args.message - 1 to 80 characters once trimmed.
|
|
169
|
-
* @param args.emoji -
|
|
170
|
-
* @param args.activeUntil -
|
|
171
|
-
* @param args.effects -
|
|
172
|
-
*
|
|
168
|
+
* @param args.message - 1 to 80 characters once trimmed. Required when creating a status.
|
|
169
|
+
* @param args.emoji - Emoji to set; null removes it, omission preserves it.
|
|
170
|
+
* @param args.activeUntil - Future expiry (`Date` or ISO string); null removes it, omission preserves it.
|
|
171
|
+
* @param args.effects - Merge supplied effects. Omission or {} preserves effects; null clears all.
|
|
172
|
+
* An individual effect set to null is removed; {} preserves its configuration or enables defaults.
|
|
173
173
|
* @returns The updated user object.
|
|
174
174
|
*
|
|
175
175
|
* @example
|
|
@@ -189,21 +189,23 @@ export type UpdateUserArgs = {
|
|
|
189
189
|
};
|
|
190
190
|
type StatusEffectArgs = {
|
|
191
191
|
scope?: {
|
|
192
|
-
mode
|
|
192
|
+
mode?: 'all';
|
|
193
193
|
};
|
|
194
194
|
};
|
|
195
|
+
/** Only supplied fields change. Null removes optional fields and effects. */
|
|
195
196
|
export type SetStatusArgs = {
|
|
196
|
-
/** 1 to 80 characters once trimmed. */
|
|
197
|
-
message
|
|
197
|
+
/** 1 to 80 characters once trimmed. Required when creating a status; omission preserves it. */
|
|
198
|
+
message?: string;
|
|
198
199
|
emoji?: string | null;
|
|
199
|
-
/**
|
|
200
|
+
/** Must be in the future; null removes expiry, omission preserves it. Dates are sent as ISO strings. */
|
|
200
201
|
activeUntil?: Date | string | null;
|
|
202
|
+
/** Supplied effects are merged; null clears all effects, omission or {} preserves them. */
|
|
201
203
|
effects?: {
|
|
202
|
-
/** Holds back Comms notifications
|
|
203
|
-
pauseNotifications?: StatusEffectArgs;
|
|
204
|
-
/**
|
|
205
|
-
pauseActivity?: StatusEffectArgs;
|
|
206
|
-
};
|
|
204
|
+
/** Holds back Comms notifications. Null removes it; {} preserves its configuration or enables it with defaults. */
|
|
205
|
+
pauseNotifications?: StatusEffectArgs | null;
|
|
206
|
+
/** Pauses Todoist Karma and streaks. Null removes it; {} preserves its configuration or enables it with defaults. */
|
|
207
|
+
pauseActivity?: StatusEffectArgs | null;
|
|
208
|
+
} | null;
|
|
207
209
|
};
|
|
208
210
|
type SearchArgsCommon = {
|
|
209
211
|
workspaceId: number;
|