export interface Group { /** * Group ID. * @readonly */ id?: string | null; /** A unique part of a group's URL, for example `https:/example.com/groups/slug`. */ slug?: string | null; /** Group privacy status. */ privacyStatus?: PrivacyStatus; /** Group name. */ name?: string | null; /** Group description in [DraftJS](https://draftjs.org) format. */ description?: string | null; /** Group teaser. */ teaser?: string | null; /** What group members are called, for example `Coworkers`, `Friends`, or `Students`. */ memberTitle?: string | null; /** Cover image. You cannot upload your own cover image. */ coverImage?: CoverImage; /** * Group specific settings. * * These settings can also be found in [a site's Dashboard](https://www.wix.com/my-account/site-selector/?buttonText=Select%20Site&title=Select%20a%20Site&autoSelectOnSingleSite=true&actionUrl=https:%2F%2Fwww.wix.com%2Fdashboard%2F%7B%7BmetaSiteId%7D%7D%2Fwix-groups/settings?). */ settings?: GroupSettings; /** * Total count of current group members. * @readonly */ membersCount?: number | null; /** * Group owner. * @readonly */ ownerId?: string | null; /** * Group creation date and time. * @readonly */ createdDate?: Date | null; /** * Date and time of the latest group update. * @readonly */ updatedDate?: Date | null; /** * Date and time of the most recent group activity, for example a post or comment. * @readonly */ lastActivityDate?: Date | null; } export declare enum Type { UNKNOWN = "UNKNOWN", ADMIN_APPROVAL = "ADMIN_APPROVAL", PAID_PLANS = "PAID_PLANS", EVENTS = "EVENTS" } export interface Events { eventIds?: string[]; } export interface Logo { /** Logo image ID (for internal use). */ mediaId?: string | null; /** Logo image width. */ width?: number | null; /** Logo image height. */ height?: number | null; } export interface GroupDetailsPosition { /** horizontal coordinate */ x?: number; /** vertical coordinate */ y?: number; } export interface Image { /** Image ID (for internal use). */ mediaId?: string | null; /** Image width. */ width?: number | null; /** Image height. */ height?: number | null; /** Indicates pre-configured/auto-generated images (from templates, client generated). */ preset?: boolean | null; } export interface Position { /** horizontal coordinate */ x?: number; /** vertical coordinate */ y?: number; } export declare enum AllowPolicy { UNKNOWN = "UNKNOWN", OWNER_AND_ADMINS = "OWNER_AND_ADMINS", OWNER = "OWNER", ALL_MEMBERS = "ALL_MEMBERS" } export interface OnboardingStepSettings { stepKey?: StepKey; visible?: boolean; } export declare enum StepKey { UNKNOWN = "UNKNOWN", CREATE_POST = "CREATE_POST", REACT_TO_POST = "REACT_TO_POST", INVITE_MEMBERS = "INVITE_MEMBERS" } export declare enum PrivacyStatus { /** Undefined group privacy status. */ UNKNOWN = "UNKNOWN", /** Anyone can see the group and its content. Anyone can join the group. */ PUBLIC = "PUBLIC", /** Anyone can see the group, but only members can see its content. New members must submit a `Join Group Request`. */ PRIVATE = "PRIVATE", /** Only admins and members can see the group. New members can only be added by other members. */ SECRET = "SECRET" } export interface AccessRestriction extends AccessRestrictionDataOneOf { events?: Events; type?: Type; } /** @oneof */ export interface AccessRestrictionDataOneOf { events?: Events; } export interface GroupDetails { /** Group logo. You cannot upload your own logo. */ logo?: Logo; /** What group members are called, for example `Coworkers`, `Friends`, or `Students`. */ membersTitle?: string | null; } /** Cover image. You cannot upload your own cover image. */ export interface CoverImage { /** Cover image. */ image?: Image; /** Position of the corner of the cover image (or logo). */ position?: Position; /** Position of the corner of the cover image (or logo) for mobile browser. */ mobilePosition?: Position; /** * Alternative text is typically a relatively short phrase that describes what the image depicts. * * The alternative text is used: * + If the browser cannot display the image. * + If the user is utilizing a screen reader. * + By search engines to understand what images are on your site. */ altText?: string | null; } export interface GroupSettings { /** * __Deprecated.__ Use `allowedToInviteMembers` instead. * Whether regular members are permitted to invite new members. * If `false`, only admins can invite members. Defaults to `true`. * @deprecated */ membersCanInvite?: boolean | null; /** * __Deprecated.__ Use `allowedToApproveJoinRequests` instead. * Whether all group members are permitted to approve join group requests. * If `false`, member approval is limited to the admins. * @deprecated */ membersCanApprove?: boolean | null; /** Whether a daily post about new members is enabled. */ welcomeMemberPostEnabled?: boolean | null; /** Whether an automatic post about changing the group details is enabled. */ groupDetailsChangedPostEnabled?: boolean | null; /** Whether all members can see the full member list. */ showMemberList?: boolean | null; /** Determines who can invite members to the group */ allowedToInviteMembers?: AllowPolicy; /** Determines who can approve member join requests to the group */ allowedToApproveJoinRequests?: AllowPolicy; } export interface Identity { /** Member ID of the group creator. See the Members API for more details. */ id?: string | null; identityType?: IdentityType; } export declare enum IdentityType { /** Wix user. */ USER = "USER", /** Wix member. */ MEMBER = "MEMBER" } export interface CreateGroupRequest { /** Group to create. */ group: Group; /** ID of the member who created the group, from the Members API. This member will automatically become an admin. */ creatorId?: string | null; /** Content type. */ contentType?: ContentType; } export declare enum ContentType { PLAIN_TEXT = "PLAIN_TEXT", DRAFTJS = "DRAFTJS", RICH_CONTENT = "RICH_CONTENT" } export interface CreateGroupResponse { /** Created group. */ group?: Group; } export interface UpdateGroupRequest { /** Group to update. */ group: Group; /** Content type. */ contentType?: ContentType; } export interface UpdateGroupResponse { /** Updated group. */ group?: Group; } export interface GroupCoverChanged { /** Old URL of group cover. */ oldUrl?: string | null; /** New URL of group cover. */ newUrl?: string | null; } export interface GroupDescriptionChanged { /** Group's old description. */ oldDescription?: string | null; /** Group's new description. */ newDescription?: string | null; } export interface DeleteGroupRequest { /** ID of the group to delete. */ groupId: string; } export interface DeleteGroupResponse { /** Deleted group. */ group?: Group; } export interface GetGroupRequest { /** ID of the group to retrieve. */ groupId: string; /** Content type. */ contentType?: ContentType; } export interface GetGroupResponse { /** Retrieved group. */ group?: Group; } export interface GetGroupBySlugRequest { /** Unique part of the group's URL. For example, if a group's URL is `https:/example.com/groups/{my-fitness-group}`, the slug is `my-fitness-group`. Case-sensitive. */ slug: string; autoInviteId?: string | null; /** Content type. */ contentType?: ContentType; } export interface GetGroupBySlugResponse { /** Retrieved group. */ group?: Group; } export interface GetGroupIdBySlugRequest { /** Unique part of the group's URL, for example `group-1` in `https:/example.com/groups/group-1`. Pass only the slug. Case-sensitive. */ slug?: string; autoInviteId?: string | null; } export interface GetGroupIdBySlugResponse { /** ID of the group that correspond to slug */ groupId?: string; /** Global feed permissions */ accessPermissions?: GlobalFeedPermissions; } export interface GlobalFeedPermissions { feedPermissions?: FeedPermissions; ownFeedItemPermissions?: FeedItemPermissions; allFeedItemPermissions?: FeedItemPermissions; activityFeedItemPermissions?: FeedItemPermissions; } export interface FeedPermissions { canViewPosts?: boolean; canCreatePosts?: boolean; canPinPosts?: boolean; canCreateTopic?: boolean; canFollowPosts?: boolean; canCreatePaidPosts?: boolean; canReadSettings?: boolean; canManageSettings?: boolean; } export interface FeedItemPermissions { canViewFullPost?: boolean; canAssignTopic?: boolean; canUnassignTopic?: boolean; /** bool canFollow = 3; // it's not related to context token */ canUpdate?: boolean; canDelete?: boolean; /** always true */ canShare?: boolean; canAddComment?: boolean; canReact?: boolean; canPin?: boolean; } export interface ListGroupsRequest { /** Number of items to load. Maximum `100`. */ limit?: number | null; /** Number of items to skip in the current sort order. */ offset?: number | null; /** Content type. */ contentType?: ContentType; } export interface ListGroupsResponse { /** Retrieved Groups. */ groups?: Group[]; /** Paging metadata. */ metadata?: PagingMetadata; } export interface PagingMetadata { /** Number of items returned in the response. */ count?: number | null; /** Offset that was requested. */ offset?: number | null; /** Total number of items that match the query. */ total?: number | null; /** Flag that indicates the server failed to calculate the `total` field. */ tooManyToCount?: boolean | null; } export interface ListGroupsByUserIdRequest { /** Content type. */ contentType?: ContentType; } export interface ListGroupsByUserIdResponse { groups?: GroupWithMsId[]; } /** Retrieved Groups by metasite id */ export interface GroupWithMsId { metaSiteId?: string; groups?: Group[]; } export interface QueryGroupsRequest { /** Query options. */ query?: Query; /** Content type. */ contentType?: ContentType; } export interface Query { /** * Filter object in the following format: * `"filter" : { * "fieldName1": "value1", * "fieldName2":{"$operator":"value2"} * }` * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains` */ filter?: any; /** * Sort object in the following format: * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` */ sort?: Sorting[]; /** Paging options to limit and skip the number of items. */ paging?: Paging; /** Array of projected fields. A list of specific field names to return. If `fieldsets` are also specified, the union of `fieldsets` and `fields` is returned. */ fields?: string[]; /** Array of named, predefined sets of projected fields. A array of predefined named sets of fields to be returned. Specifying multiple `fieldsets` will return the union of fields from all sets. If `fields` are also specified, the union of `fieldsets` and `fields` is returned. */ fieldsets?: string[]; } export interface Sorting { /** Name of the field to sort by. */ fieldName?: string; /** Sort order. */ order?: SortOrder; } export declare enum SortOrder { ASC = "ASC", DESC = "DESC" } export interface Paging { /** Number of items to load. */ limit?: number | null; /** Number of items to skip in the current sort order. */ offset?: number | null; } export interface QueryGroupsResponse { /** Retrieved groups. */ groups?: Group[]; /** Paging metadata. */ metadata?: PagingMetadata; } export interface QueryJoinedGroupsRequest { /** Query options. */ query?: Query; /** Content type. */ contentType?: ContentType; } export interface QueryJoinedGroupsResponse { /** Retrieved groups. */ groups?: Group[]; /** Paging metadata. */ metadata?: PagingMetadata; } export interface QueryGroupsByMembershipRequest { /** Query options. */ query?: Query; membershipStatus?: MembershipStatus; /** Filter groups by permissions. */ permissionsFilter?: GroupPermissions; /** Content type. */ contentType?: ContentType; } export declare enum MembershipStatus { NONE = "NONE", JOINED = "JOINED", PENDING = "PENDING" } export interface GroupPermissions { canCreatePosts?: boolean | null; } export interface QueryGroupsByMembershipResponse { /** Retrieved groups. */ groups?: Group[]; /** Paging metadata. */ metadata?: PagingMetadata; } export interface ListGroupIntegrationsDataRequest { groupIds?: string[]; } export interface ListGroupIntegrationsDataResponse { groupsIntegrationsData?: GroupIntegrationsData[]; } export interface GroupIntegrationsData { groupId?: string; feedItemsCount?: number; topicIds?: string[]; eventIds?: string[]; connectedPricingPlanIds?: string[]; onlineProgramIds?: string[]; } export interface GetGroupMembersGroupIdsRequest { /** ID of the group to retrieve members group ids. */ groupId?: string; } export interface GetGroupMembersGroupIdsResponse { /** All members group id */ allMembersGroupId?: string; /** Admins members group id */ adminMembersGroupId?: string; } export interface GetGroupBMFeaturesRequest { /** ID of the group to retrieve BM features. */ groupId?: string; } export interface GetGroupBMFeaturesResponse { level?: number; features?: BMFeatures; } export interface BMFeatures { bmFeatures?: BMFeaturesBMFeatures[]; } export declare enum BMFeaturesBMFeatures { BM_FEATURES_UNKNOWN = "BM_FEATURES_UNKNOWN", BM_FEATURES_GENERATE_TOPICS = "BM_FEATURES_GENERATE_TOPICS", BM_FEATURES_GENERATE_QUESTIONS = "BM_FEATURES_GENERATE_QUESTIONS" } export interface QueryJoinedGroupsWithMemberRequest { /** Query options. */ query?: Query; /** ID of the member to find common groups with */ memberId?: string; /** Content type. */ contentType?: ContentType; } export interface QueryJoinedGroupsWithMemberResponse { /** Retrieved groups. */ groups?: Group[]; /** Paging metadata. */ metadata?: PagingMetadata; } export interface GetPrivacyRequest { /** Group ids to list privacy for */ groupIds?: string[]; } export interface GetPrivacyResponse { /** Privacy statuses listed per group id */ privacyStatuses?: Record; } export interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; /** * Unique event ID. * Allows clients to ignore duplicate webhooks. */ id?: string; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ triggeredByAnonymizeRequest?: boolean | null; /** If present, indicates the action that triggered the event. */ originatedFrom?: string | null; /** * A sequence number defining the order of updates to the underlying entity. * For example, given that some entity was updated at 16:00 and than again at 16:01, * it is guaranteed that the sequence number of the second update is strictly higher than the first. * As the consumer, you can use this value to ensure that you handle messages in the correct order. * To do so, you will need to persist this number on your end, and compare the sequence number from the * message against the one you have stored. Given that the stored number is higher, you should ignore the message. */ entityEventSequence?: string | null; } /** @oneof */ export interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } export interface EntityCreatedEvent { entityAsJson?: string; /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */ restoreInfo?: RestoreInfo; } export interface RestoreInfo { deletedDate?: Date | null; } export interface EntityUpdatedEvent { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; } export interface EntityDeletedEvent { /** Entity that was deleted */ deletedEntityAsJson?: string | null; } export interface ActionEvent { bodyAsJson?: string; } export interface MessageEnvelope { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; } export interface IdentificationData extends IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; /** @readonly */ identityType?: WebhookIdentityType; } /** @oneof */ export interface IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; } export declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } interface EventsNonNullableFields { eventIds: string[]; } interface AccessRestrictionNonNullableFields { events?: EventsNonNullableFields; type: Type; } interface GroupDetailsPositionNonNullableFields { x: number; y: number; } interface GroupDetailsNonNullableFields { logoPosition?: GroupDetailsPositionNonNullableFields; mobileLogoPosition?: GroupDetailsPositionNonNullableFields; } interface PositionNonNullableFields { x: number; y: number; } interface CoverImageNonNullableFields { position?: PositionNonNullableFields; mobilePosition?: PositionNonNullableFields; } interface OnboardingStepSettingsNonNullableFields { stepKey: StepKey; visible: boolean; } interface GroupSettingsNonNullableFields { allowedToInviteMembers: AllowPolicy; allowedToApproveJoinRequests: AllowPolicy; allowedToAddMembers: AllowPolicy; allowedToCreatePosts: AllowPolicy; allowedToCommentPosts: AllowPolicy; onboardingStepsSettings: OnboardingStepSettingsNonNullableFields[]; allowedToCreateEvents: AllowPolicy; } interface IdentityNonNullableFields { identityType: IdentityType; } interface GroupNonNullableFields { privacyLevel: PrivacyStatus; privacyStatus: PrivacyStatus; accessRestriction?: AccessRestrictionNonNullableFields; details?: GroupDetailsNonNullableFields; coverImage?: CoverImageNonNullableFields; settings?: GroupSettingsNonNullableFields; createdBy?: IdentityNonNullableFields; } export interface CreateGroupResponseNonNullableFields { group?: GroupNonNullableFields; } export interface UpdateGroupResponseNonNullableFields { group?: GroupNonNullableFields; } export interface DeleteGroupResponseNonNullableFields { group?: GroupNonNullableFields; } export interface GetGroupResponseNonNullableFields { group?: GroupNonNullableFields; } export interface GetGroupBySlugResponseNonNullableFields { group?: GroupNonNullableFields; } export interface ListGroupsResponseNonNullableFields { groups: GroupNonNullableFields[]; } export interface QueryGroupsResponseNonNullableFields { groups: GroupNonNullableFields[]; } export {};