@wix/auto_sdk_portfolio_project-items 1.0.48 → 1.0.49

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.
@@ -206,177 +206,6 @@ interface Link {
206
206
  */
207
207
  target?: string | null;
208
208
  }
209
- interface GenerateTokenForProjectItemsRequest {
210
- /**
211
- * Media ids of requested project items
212
- * @minSize 1
213
- * @maxLength 100
214
- */
215
- mediaIds: string[];
216
- }
217
- interface GenerateTokenForProjectItemsResponse {
218
- /** Generated media tokens for project items */
219
- mediaTokens?: ProjectItemMediaToken[];
220
- }
221
- interface ProjectItemMediaToken {
222
- /** Media id of project item */
223
- mediaId?: string;
224
- /** Generated media token for project item */
225
- mediaToken?: string;
226
- }
227
- interface DomainEvent extends DomainEventBodyOneOf {
228
- createdEvent?: EntityCreatedEvent;
229
- updatedEvent?: EntityUpdatedEvent;
230
- deletedEvent?: EntityDeletedEvent;
231
- actionEvent?: ActionEvent;
232
- /** Event ID. With this ID you can easily spot duplicated events and ignore them. */
233
- _id?: string;
234
- /**
235
- * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
236
- * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
237
- */
238
- entityFqdn?: string;
239
- /**
240
- * Event action name, placed at the top level to make it easier for users to dispatch messages.
241
- * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
242
- */
243
- slug?: string;
244
- /** ID of the entity associated with the event. */
245
- entityId?: string;
246
- /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
247
- eventTime?: Date | null;
248
- /**
249
- * Whether the event was triggered as a result of a privacy regulation application
250
- * (for example, GDPR).
251
- */
252
- triggeredByAnonymizeRequest?: boolean | null;
253
- /** If present, indicates the action that triggered the event. */
254
- originatedFrom?: string | null;
255
- /**
256
- * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.
257
- * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
258
- */
259
- entityEventSequence?: string | null;
260
- }
261
- /** @oneof */
262
- interface DomainEventBodyOneOf {
263
- createdEvent?: EntityCreatedEvent;
264
- updatedEvent?: EntityUpdatedEvent;
265
- deletedEvent?: EntityDeletedEvent;
266
- actionEvent?: ActionEvent;
267
- }
268
- interface EntityCreatedEvent {
269
- entity?: string;
270
- }
271
- interface RestoreInfo {
272
- deletedDate?: Date | null;
273
- }
274
- interface EntityUpdatedEvent {
275
- /**
276
- * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
277
- * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
278
- * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
279
- */
280
- currentEntity?: string;
281
- }
282
- interface EntityDeletedEvent {
283
- /** Entity that was deleted. */
284
- deletedEntity?: string | null;
285
- }
286
- interface ActionEvent {
287
- body?: string;
288
- }
289
- interface MessageEnvelope {
290
- /**
291
- * App instance ID.
292
- * @format GUID
293
- */
294
- instanceId?: string | null;
295
- /**
296
- * Event type.
297
- * @maxLength 150
298
- */
299
- eventType?: string;
300
- /** The identification type and identity data. */
301
- identity?: IdentificationData;
302
- /** Stringify payload. */
303
- data?: string;
304
- /** Details related to the account */
305
- accountInfo?: AccountInfo;
306
- }
307
- interface IdentificationData extends IdentificationDataIdOneOf {
308
- /**
309
- * ID of a site visitor that has not logged in to the site.
310
- * @format GUID
311
- */
312
- anonymousVisitorId?: string;
313
- /**
314
- * ID of a site visitor that has logged in to the site.
315
- * @format GUID
316
- */
317
- memberId?: string;
318
- /**
319
- * ID of a Wix user (site owner, contributor, etc.).
320
- * @format GUID
321
- */
322
- wixUserId?: string;
323
- /**
324
- * ID of an app.
325
- * @format GUID
326
- */
327
- appId?: string;
328
- /** @readonly */
329
- identityType?: WebhookIdentityTypeWithLiterals;
330
- }
331
- /** @oneof */
332
- interface IdentificationDataIdOneOf {
333
- /**
334
- * ID of a site visitor that has not logged in to the site.
335
- * @format GUID
336
- */
337
- anonymousVisitorId?: string;
338
- /**
339
- * ID of a site visitor that has logged in to the site.
340
- * @format GUID
341
- */
342
- memberId?: string;
343
- /**
344
- * ID of a Wix user (site owner, contributor, etc.).
345
- * @format GUID
346
- */
347
- wixUserId?: string;
348
- /**
349
- * ID of an app.
350
- * @format GUID
351
- */
352
- appId?: string;
353
- }
354
- declare enum WebhookIdentityType {
355
- UNKNOWN = "UNKNOWN",
356
- ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
357
- MEMBER = "MEMBER",
358
- WIX_USER = "WIX_USER",
359
- APP = "APP"
360
- }
361
- /** @enumType */
362
- type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
363
- interface AccountInfo {
364
- /**
365
- * ID of the Wix account associated with the event.
366
- * @format GUID
367
- */
368
- accountId?: string | null;
369
- /**
370
- * ID of the parent Wix account. Only included when accountId belongs to a child account.
371
- * @format GUID
372
- */
373
- parentAccountId?: string | null;
374
- /**
375
- * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
376
- * @format GUID
377
- */
378
- siteId?: string | null;
379
- }
380
209
  interface InvalidateCache extends InvalidateCacheGetByOneOf {
381
210
  /**
382
211
  * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!
@@ -930,6 +759,68 @@ interface CreateProjectGalleryResponse {
930
759
  */
931
760
  galleryId?: string;
932
761
  }
762
+ interface DomainEvent extends DomainEventBodyOneOf {
763
+ createdEvent?: EntityCreatedEvent;
764
+ updatedEvent?: EntityUpdatedEvent;
765
+ deletedEvent?: EntityDeletedEvent;
766
+ actionEvent?: ActionEvent;
767
+ /** Event ID. With this ID you can easily spot duplicated events and ignore them. */
768
+ _id?: string;
769
+ /**
770
+ * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
771
+ * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
772
+ */
773
+ entityFqdn?: string;
774
+ /**
775
+ * Event action name, placed at the top level to make it easier for users to dispatch messages.
776
+ * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
777
+ */
778
+ slug?: string;
779
+ /** ID of the entity associated with the event. */
780
+ entityId?: string;
781
+ /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
782
+ eventTime?: Date | null;
783
+ /**
784
+ * Whether the event was triggered as a result of a privacy regulation application
785
+ * (for example, GDPR).
786
+ */
787
+ triggeredByAnonymizeRequest?: boolean | null;
788
+ /** If present, indicates the action that triggered the event. */
789
+ originatedFrom?: string | null;
790
+ /**
791
+ * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.
792
+ * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
793
+ */
794
+ entityEventSequence?: string | null;
795
+ }
796
+ /** @oneof */
797
+ interface DomainEventBodyOneOf {
798
+ createdEvent?: EntityCreatedEvent;
799
+ updatedEvent?: EntityUpdatedEvent;
800
+ deletedEvent?: EntityDeletedEvent;
801
+ actionEvent?: ActionEvent;
802
+ }
803
+ interface EntityCreatedEvent {
804
+ entity?: string;
805
+ }
806
+ interface RestoreInfo {
807
+ deletedDate?: Date | null;
808
+ }
809
+ interface EntityUpdatedEvent {
810
+ /**
811
+ * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
812
+ * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
813
+ * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
814
+ */
815
+ currentEntity?: string;
816
+ }
817
+ interface EntityDeletedEvent {
818
+ /** Entity that was deleted. */
819
+ deletedEntity?: string | null;
820
+ }
821
+ interface ActionEvent {
822
+ body?: string;
823
+ }
933
824
  interface Empty {
934
825
  }
935
826
  interface DeletedProjectRestored {
@@ -962,6 +853,115 @@ interface DuplicateProjectItemsResponse {
962
853
  /** Bulk action metadata. */
963
854
  bulkActionMetadata?: BulkActionMetadata;
964
855
  }
856
+ interface MessageEnvelope {
857
+ /**
858
+ * App instance ID.
859
+ * @format GUID
860
+ */
861
+ instanceId?: string | null;
862
+ /**
863
+ * Event type.
864
+ * @maxLength 150
865
+ */
866
+ eventType?: string;
867
+ /** The identification type and identity data. */
868
+ identity?: IdentificationData;
869
+ /** Stringify payload. */
870
+ data?: string;
871
+ /** Details related to the account */
872
+ accountInfo?: AccountInfo;
873
+ }
874
+ interface IdentificationData extends IdentificationDataIdOneOf {
875
+ /**
876
+ * ID of a site visitor that has not logged in to the site.
877
+ * @format GUID
878
+ */
879
+ anonymousVisitorId?: string;
880
+ /**
881
+ * ID of a site visitor that has logged in to the site.
882
+ * @format GUID
883
+ */
884
+ memberId?: string;
885
+ /**
886
+ * ID of a Wix user (site owner, contributor, etc.).
887
+ * @format GUID
888
+ */
889
+ wixUserId?: string;
890
+ /**
891
+ * ID of an app.
892
+ * @format GUID
893
+ */
894
+ appId?: string;
895
+ /** @readonly */
896
+ identityType?: WebhookIdentityTypeWithLiterals;
897
+ }
898
+ /** @oneof */
899
+ interface IdentificationDataIdOneOf {
900
+ /**
901
+ * ID of a site visitor that has not logged in to the site.
902
+ * @format GUID
903
+ */
904
+ anonymousVisitorId?: string;
905
+ /**
906
+ * ID of a site visitor that has logged in to the site.
907
+ * @format GUID
908
+ */
909
+ memberId?: string;
910
+ /**
911
+ * ID of a Wix user (site owner, contributor, etc.).
912
+ * @format GUID
913
+ */
914
+ wixUserId?: string;
915
+ /**
916
+ * ID of an app.
917
+ * @format GUID
918
+ */
919
+ appId?: string;
920
+ }
921
+ declare enum WebhookIdentityType {
922
+ UNKNOWN = "UNKNOWN",
923
+ ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
924
+ MEMBER = "MEMBER",
925
+ WIX_USER = "WIX_USER",
926
+ APP = "APP"
927
+ }
928
+ /** @enumType */
929
+ type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
930
+ interface AccountInfo {
931
+ /**
932
+ * ID of the Wix account associated with the event.
933
+ * @format GUID
934
+ */
935
+ accountId?: string | null;
936
+ /**
937
+ * ID of the parent Wix account. Only included when accountId belongs to a child account.
938
+ * @format GUID
939
+ */
940
+ parentAccountId?: string | null;
941
+ /**
942
+ * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
943
+ * @format GUID
944
+ */
945
+ siteId?: string | null;
946
+ }
947
+ interface GenerateTokenForProjectItemsRequest {
948
+ /**
949
+ * Media ids of requested project items
950
+ * @minSize 1
951
+ * @maxLength 100
952
+ */
953
+ mediaIds: string[];
954
+ }
955
+ interface GenerateTokenForProjectItemsResponse {
956
+ /** Generated media tokens for project items */
957
+ mediaTokens?: ProjectItemMediaToken[];
958
+ }
959
+ interface ProjectItemMediaToken {
960
+ /** Media id of project item */
961
+ mediaId?: string;
962
+ /** Generated media token for project item */
963
+ mediaToken?: string;
964
+ }
965
965
  interface BaseEventMetadata {
966
966
  /**
967
967
  * App instance ID.
@@ -1058,16 +1058,6 @@ interface ProjectItemUpdatedEnvelope {
1058
1058
  * @slug updated
1059
1059
  */
1060
1060
  declare function onProjectItemUpdated(handler: (event: ProjectItemUpdatedEnvelope) => void | Promise<void>): void;
1061
- /**
1062
- * Generate media token for project items
1063
- * @param mediaIds - Media ids of requested project items
1064
- * @public
1065
- * @requiredField mediaIds
1066
- * @permissionId PORTFOLIO.PROJECT_ITEM_CREATE
1067
- * @applicableIdentity APP
1068
- * @fqn com.wixpress.portfolio.portfolioapp.MediaService.GenerateTokenForProjectItems
1069
- */
1070
- declare function generateTokenForProjectItems(mediaIds: string[]): Promise<NonNullablePaths<GenerateTokenForProjectItemsResponse, `mediaTokens` | `mediaTokens.${number}.mediaId` | `mediaTokens.${number}.mediaToken`, 4>>;
1071
1061
  /**
1072
1062
  * Creates a project item.
1073
1063
  * @param item - Project item to create.
@@ -1275,5 +1265,15 @@ interface DuplicateProjectItemsOptions {
1275
1265
  */
1276
1266
  targetProjectId: string;
1277
1267
  }
1268
+ /**
1269
+ * Generate media token for project items
1270
+ * @param mediaIds - Media ids of requested project items
1271
+ * @public
1272
+ * @requiredField mediaIds
1273
+ * @permissionId PORTFOLIO.PROJECT_ITEM_CREATE
1274
+ * @applicableIdentity APP
1275
+ * @fqn com.wixpress.portfolio.portfolioapp.MediaService.GenerateTokenForProjectItems
1276
+ */
1277
+ declare function generateTokenForProjectItems(mediaIds: string[]): Promise<NonNullablePaths<GenerateTokenForProjectItemsResponse, `mediaTokens` | `mediaTokens.${number}.mediaId` | `mediaTokens.${number}.mediaToken`, 4>>;
1278
1278
 
1279
1279
  export { type AccountInfo, type AccountInfoMetadata, type ActionEvent, type AddressLocation, type App, type ApplicationError, type BaseEventMetadata, type BulkActionMetadata, type BulkCreateProjectItemResult, type BulkCreateProjectItemsOptions, type BulkCreateProjectItemsRequest, type BulkCreateProjectItemsResponse, type BulkDeleteProjectItemResult, type BulkDeleteProjectItemsOptions, type BulkDeleteProjectItemsRequest, type BulkDeleteProjectItemsResponse, type BulkUpdateProjectItemResult, type BulkUpdateProjectItemsOptions, type BulkUpdateProjectItemsRequest, type BulkUpdateProjectItemsResponse, type CreateProjectGalleryRequest, type CreateProjectGalleryResponse, type CreateProjectItemRequest, type CreateProjectItemResponse, type CursorPaging, type Cursors, type CustomTag, type DeleteProjectItemRequest, type DeleteProjectItemResponse, type DeletedProjectRestored, type DomainEvent, type DomainEventBodyOneOf, type DuplicateProjectItemsOptions, type DuplicateProjectItemsRequest, type DuplicateProjectItemsResponse, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EventMetadata, type File, type GenerateTokenForProjectItemsRequest, type GenerateTokenForProjectItemsResponse, type GetProjectItemRequest, type GetProjectItemResponse, type IdentificationData, type IdentificationDataIdOneOf, type Image, ImageType, type ImageTypeWithLiterals, type InvalidateCache, type InvalidateCacheGetByOneOf, type Item, type ItemMetadata, type ItemMetadataOneOf, type Link, type ListProjectItemsOptions, type ListProjectItemsRequest, type ListProjectItemsResponse, type MaskedItem, type MessageEnvelope, type Page, type Pages, type Paging, type PagingMetadataV2, type Point, type ProjectItemCreatedEnvelope, type ProjectItemDeletedEnvelope, type ProjectItemMediaToken, type ProjectItemUpdatedEnvelope, type QueryProjectItemsRequest, type QueryProjectItemsResponse, type QueryV2, type QueryV2PagingMethodOneOf, type RestoreInfo, SortOrder, type SortOrderWithLiterals, type Sorting, type Tags, Type, type TypeWithLiterals, type URI, type URIs, type UnsharpMasking, type UpdateProjectItem, type UpdateProjectItemRequest, type UpdateProjectItemResponse, type Video, type VideoResolution, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, bulkCreateProjectItems, bulkDeleteProjectItems, bulkUpdateProjectItems, createProjectItem, deleteProjectItem, duplicateProjectItems, generateTokenForProjectItems, getProjectItem, listProjectItems, onProjectItemCreated, onProjectItemDeleted, onProjectItemUpdated, updateProjectItem };