import { ApproveJoinGroupRequestsRequest as ApproveJoinGroupRequestsRequest$1, ApproveJoinGroupRequestsResponse as ApproveJoinGroupRequestsResponse$1, RejectJoinGroupRequestsRequest as RejectJoinGroupRequestsRequest$1, RejectJoinGroupRequestsResponse as RejectJoinGroupRequestsResponse$1, ListJoinGroupRequestsRequest as ListJoinGroupRequestsRequest$1, ListJoinGroupRequestsResponse as ListJoinGroupRequestsResponse$1, QueryJoinGroupRequestsRequest as QueryJoinGroupRequestsRequest$1, QueryJoinGroupRequestsResponse as QueryJoinGroupRequestsResponse$1 } from './index.typings.js'; import '@wix/sdk-types'; /** * To join a private group, a site member must submit a Join Request, which can be approved or rejected by an admin. * When the request is approved, the site member becomes a group member. */ interface JoinGroupRequest { /** * Member ID. See the Members API for more details. * @readonly * @format GUID */ siteMemberId?: string; /** * Contact ID. See the Contacts API for more details. * @readonly * @format GUID */ contactId?: string; /** Join group request status. */ status?: RequestStatusWithLiterals; /** Join group request details. */ requestDetails?: RequestDetails; } declare enum RequestStatus { /** Pending group request. */ PENDING = "PENDING", /** Approved group request. */ APPROVED = "APPROVED", /** Rejected group request. */ REJECTED = "REJECTED", /** Canceled group request. */ CANCELED = "CANCELED" } /** @enumType */ type RequestStatusWithLiterals = RequestStatus | 'PENDING' | 'APPROVED' | 'REJECTED' | 'CANCELED'; interface RequestDetails { /** * Reason the request has been rejected. * @maxLength 1000 */ rejectionReason?: string | null; } interface SocialGroupsEvent extends SocialGroupsEventPayloadOneOf { memberJoined?: MemberJoinedGroup; membersAdded?: MembersAddedToGroup; joinRequestsApproved?: JoinRequestsApproved; membersInvited?: MembersInvitedToGroup; } /** @oneof */ interface SocialGroupsEventPayloadOneOf { memberJoined?: MemberJoinedGroup; membersAdded?: MembersAddedToGroup; joinRequestsApproved?: JoinRequestsApproved; membersInvited?: MembersInvitedToGroup; } interface MemberJoinedGroup { /** @format GUID */ groupId?: string; /** @format GUID */ groupsInstanceId?: string; /** @format GUID */ siteMemberId?: string; } interface MembersAddedToGroup { /** @format GUID */ groupId?: string; /** @format GUID */ groupsInstanceId?: string; /** @format GUID */ whoAddedId?: string | null; /** @format GUID */ siteMemberIds?: string[]; /** * Used for Apes sticky experiment * @format GUID */ operationId?: string; } interface JoinRequestsApproved { /** @format GUID */ groupId?: string; /** @format GUID */ groupsInstanceId?: string; /** @format GUID */ siteMemberIds?: string[]; /** * Used for Apes sticky experiment * @format GUID */ operationId?: string; } interface MembersInvitedToGroup { /** @format GUID */ groupId?: string; /** @format GUID */ groupsInstanceId?: string; /** @format GUID */ siteMemberIds?: string[]; } interface GetJoinRequirementsRequest { /** * Group ID. * @format GUID */ groupId?: string; /** * Answers to membership questions. They can be empty, but submit join group request will fail if an answer to a required question is omitted. * @maxSize 50 */ membershipQuestionAnswers?: MembershipQuestionAnswer[]; autoInviteId?: string | null; } /** Answer to a membership question. */ interface MembershipQuestionAnswer { /** * Question ID. * @format GUID */ id?: string; /** * Answer text. * @maxLength 300 */ text?: string | null; } interface GetJoinRequirementsResponse { violation?: Violation; } interface PaidPlan { planId?: string; name?: string; startsAt?: Date | null; } declare enum ViolationType { NONE = "NONE", NOT_LOGGED_IN = "NOT_LOGGED_IN", ALREADY_JOINED = "ALREADY_JOINED", SECRET_GROUP = "SECRET_GROUP", EVENTS = "EVENTS", PRICING_PlANS = "PRICING_PlANS", MEMBERSHIP_QUESTIONS = "MEMBERSHIP_QUESTIONS", ADMIN_APPROVAL = "ADMIN_APPROVAL" } /** @enumType */ type ViolationTypeWithLiterals = ViolationType | 'NONE' | 'NOT_LOGGED_IN' | 'ALREADY_JOINED' | 'SECRET_GROUP' | 'EVENTS' | 'PRICING_PlANS' | 'MEMBERSHIP_QUESTIONS' | 'ADMIN_APPROVAL'; interface EventsViolationOptions { /** Events which allow user to join the group. */ eventIds?: string[]; } interface PricingPlanViolationOptions { installed?: boolean; /** Plan ids which allow user to join the group. */ requiredPlans?: PaidPlan[]; /** Plan ids which user have, but they don't allow to join group right now, because they start some time in the future. */ futurePlans?: PaidPlan[]; } interface MembershipQuestionViolationOptions { requiredQuestionIds?: string[]; } interface Violation extends ViolationViolationOptionsOneOf { eventsOptions?: EventsViolationOptions; pricingPlansOptions?: PricingPlanViolationOptions; membershipQuestionsOptions?: MembershipQuestionViolationOptions; violationType?: ViolationTypeWithLiterals; } /** @oneof */ interface ViolationViolationOptionsOneOf { eventsOptions?: EventsViolationOptions; pricingPlansOptions?: PricingPlanViolationOptions; membershipQuestionsOptions?: MembershipQuestionViolationOptions; } interface SubmitJoinGroupRequestRequest { /** * Relevant group. * @format GUID */ groupId?: string; /** * Answers to membership questions. They can be empty, but submit join group request will fail if an answer to a required question is omitted. * @maxSize 50 */ membershipQuestionAnswers?: MembershipQuestionAnswer[]; } interface SubmitJoinGroupRequestResponse { /** Submitted join group request. */ joinGroupRequest?: JoinGroupRequest; } interface CancelJoinGroupRequestRequest { /** * Relevant group. * @format GUID */ groupId?: string; } interface CancelJoinGroupRequestResponse { /** Cancelled join group request. */ joinGroupRequest?: JoinGroupRequest; } interface JoinGroupRequestCancelled { /** * Group ID for which join request was cancelled. * @format GUID */ groupId?: string; /** Cancelled join group request. */ joinGroupRequest?: JoinGroupRequest; } interface ApproveJoinGroupRequestsRequest { /** * ID of the group requested to join. * @format GUID */ groupId: string; /** * IDs of the site members to approve. * @format GUID * @maxSize 100 */ memberIds?: string[]; } declare enum ItemsToUpdate { /** Take into account only items which are listed in the request. */ BY_ID = "BY_ID", /** Update all items. */ ALL_ITEMS = "ALL_ITEMS" } /** @enumType */ type ItemsToUpdateWithLiterals = ItemsToUpdate | 'BY_ID' | 'ALL_ITEMS'; interface ApproveJoinGroupRequestsResponse { /** Approved join group requests. */ joinGroupRequests?: JoinGroupRequest[]; } interface JoinGroupRequestApproved { /** * Group ID for which join request was approved. * @format GUID */ groupId?: string; /** Approved join group request. */ joinGroupRequest?: JoinGroupRequest; } interface RejectJoinGroupRequestsRequest { /** * ID of the group requested to join. * @format GUID */ groupId: string; /** * Rejection info. * @maxSize 100 */ rejections?: Rejection[]; } interface Rejection { /** Member ID to reject. */ memberId?: string; /** * Rejection reason. Free text that will be displayed to the rejected site member. Limited to 1,000 characters. * @maxLength 1000 */ reason?: string | null; } interface RejectJoinGroupRequestsResponse { /** Rejected join group requests. */ joinGroupRequests?: JoinGroupRequest[]; } interface JoinGroupRequestRejected { /** * Group ID for which join request was rejected. * @format GUID */ groupId?: string; /** Rejected join group request. */ joinGroupRequest?: JoinGroupRequest; } interface ListJoinGroupRequestsRequest { /** * Group ID. * @format GUID */ groupId: string; /** * Maximum number of join group requests to retrieve. Defaults to 100. * @max 100 */ limit?: number | null; /** Number of join group requests to skip in the list. */ offset?: number | null; } declare enum OwnershipFilter { /** All items. */ ALL = "ALL", /** Items for the current site member. */ CURRENT_MEMBER = "CURRENT_MEMBER" } /** @enumType */ type OwnershipFilterWithLiterals = OwnershipFilter | 'ALL' | 'CURRENT_MEMBER'; interface ListJoinGroupRequestsResponse { /** Retrieved join group requests. */ joinGroupRequests?: JoinGroupRequest[]; metadata?: PagingMetadata; } 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; } interface QueryJoinGroupRequestsRequest { /** * Group ID. * @format GUID */ groupId: string; query?: Query; } 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[]; } interface Sorting { /** * Name of the field to sort by. * @maxLength 512 */ fieldName?: string; /** Sort order. */ order?: SortOrderWithLiterals; } declare enum SortOrder { ASC = "ASC", DESC = "DESC" } /** @enumType */ type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC'; interface Paging { /** Number of items to load. */ limit?: number | null; /** Number of items to skip in the current sort order. */ offset?: number | null; } interface QueryJoinGroupRequestsResponse { /** Join group requests. */ joinGroupRequests?: JoinGroupRequest[]; metadata?: PagingMetadata; } interface RejectAllJoinGroupRequestsRequest { } interface RejectAllJoinGroupRequestsResponse { /** Rejected join group requests. */ joinGroupRequests?: JoinGroupRequest[]; } interface ApproveAllJoinGroupRequestsRequest { } interface ApproveAllJoinGroupRequestsResponse { /** Rejected join group requests. */ joinGroupRequests?: JoinGroupRequest[]; } interface ListAllJoinGroupRequestsRequest { query?: Query; } interface ListAllJoinGroupRequestsResponse { /** Join group requests. */ joinGroupRequests?: JoinGroupRequest[]; metadata?: PagingMetadata; } interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; /** Event ID. With this ID you can easily spot duplicated events and ignore them. */ id?: string; /** * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities. * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`. */ entityFqdn?: string; /** * Event action name, placed at the top level to make it easier for users to dispatch messages. * For 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 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. * 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. */ entityEventSequence?: string | null; } /** @oneof */ interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } interface EntityCreatedEvent { entityAsJson?: string; /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */ restoreInfo?: RestoreInfo; } interface RestoreInfo { deletedDate?: Date | null; } 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; } interface EntityDeletedEvent { /** Entity that was deleted. */ deletedEntityAsJson?: string | null; } interface ActionEvent { bodyAsJson?: string; } interface MessageEnvelope { /** * App instance ID. * @format GUID */ instanceId?: string | null; /** * Event type. * @maxLength 150 */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; /** Details related to the account */ accountInfo?: AccountInfo; } interface IdentificationData extends IdentificationDataIdOneOf { /** * ID of a site visitor that has not logged in to the site. * @format GUID */ anonymousVisitorId?: string; /** * ID of a site visitor that has logged in to the site. * @format GUID */ memberId?: string; /** * ID of a Wix user (site owner, contributor, etc.). * @format GUID */ wixUserId?: string; /** * ID of an app. * @format GUID */ appId?: string; /** @readonly */ identityType?: WebhookIdentityTypeWithLiterals; } /** @oneof */ interface IdentificationDataIdOneOf { /** * ID of a site visitor that has not logged in to the site. * @format GUID */ anonymousVisitorId?: string; /** * ID of a site visitor that has logged in to the site. * @format GUID */ memberId?: string; /** * ID of a Wix user (site owner, contributor, etc.). * @format GUID */ wixUserId?: string; /** * ID of an app. * @format GUID */ appId?: string; } declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } /** @enumType */ type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP'; interface AccountInfo { /** * ID of the Wix account associated with the event. * @format GUID */ accountId?: string | null; /** * ID of the parent Wix account. Only included when accountId belongs to a child account. * @format GUID */ parentAccountId?: string | null; /** * ID of the Wix site associated with the event. Only included when the event is tied to a specific site. * @format GUID */ siteId?: string | null; } type __PublicMethodMetaInfo = { getUrl: (context: any) => string; httpMethod: K; path: string; pathParams: M; __requestType: T; __originalRequestType: S; __responseType: Q; __originalResponseType: R; }; declare function approveJoinGroupRequests(): __PublicMethodMetaInfo<'POST', { groupId: string; }, ApproveJoinGroupRequestsRequest$1, ApproveJoinGroupRequestsRequest, ApproveJoinGroupRequestsResponse$1, ApproveJoinGroupRequestsResponse>; declare function rejectJoinGroupRequests(): __PublicMethodMetaInfo<'POST', { groupId: string; }, RejectJoinGroupRequestsRequest$1, RejectJoinGroupRequestsRequest, RejectJoinGroupRequestsResponse$1, RejectJoinGroupRequestsResponse>; declare function listJoinGroupRequests(): __PublicMethodMetaInfo<'GET', { groupId: string; }, ListJoinGroupRequestsRequest$1, ListJoinGroupRequestsRequest, ListJoinGroupRequestsResponse$1, ListJoinGroupRequestsResponse>; declare function queryJoinGroupRequests(): __PublicMethodMetaInfo<'POST', { groupId: string; }, QueryJoinGroupRequestsRequest$1, QueryJoinGroupRequestsRequest, QueryJoinGroupRequestsResponse$1, QueryJoinGroupRequestsResponse>; export { type AccountInfo as AccountInfoOriginal, type ActionEvent as ActionEventOriginal, type ApproveAllJoinGroupRequestsRequest as ApproveAllJoinGroupRequestsRequestOriginal, type ApproveAllJoinGroupRequestsResponse as ApproveAllJoinGroupRequestsResponseOriginal, type ApproveJoinGroupRequestsRequest as ApproveJoinGroupRequestsRequestOriginal, type ApproveJoinGroupRequestsResponse as ApproveJoinGroupRequestsResponseOriginal, type CancelJoinGroupRequestRequest as CancelJoinGroupRequestRequestOriginal, type CancelJoinGroupRequestResponse as CancelJoinGroupRequestResponseOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type EventsViolationOptions as EventsViolationOptionsOriginal, type GetJoinRequirementsRequest as GetJoinRequirementsRequestOriginal, type GetJoinRequirementsResponse as GetJoinRequirementsResponseOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, ItemsToUpdate as ItemsToUpdateOriginal, type ItemsToUpdateWithLiterals as ItemsToUpdateWithLiteralsOriginal, type JoinGroupRequestApproved as JoinGroupRequestApprovedOriginal, type JoinGroupRequestCancelled as JoinGroupRequestCancelledOriginal, type JoinGroupRequest as JoinGroupRequestOriginal, type JoinGroupRequestRejected as JoinGroupRequestRejectedOriginal, type JoinRequestsApproved as JoinRequestsApprovedOriginal, type ListAllJoinGroupRequestsRequest as ListAllJoinGroupRequestsRequestOriginal, type ListAllJoinGroupRequestsResponse as ListAllJoinGroupRequestsResponseOriginal, type ListJoinGroupRequestsRequest as ListJoinGroupRequestsRequestOriginal, type ListJoinGroupRequestsResponse as ListJoinGroupRequestsResponseOriginal, type MemberJoinedGroup as MemberJoinedGroupOriginal, type MembersAddedToGroup as MembersAddedToGroupOriginal, type MembersInvitedToGroup as MembersInvitedToGroupOriginal, type MembershipQuestionAnswer as MembershipQuestionAnswerOriginal, type MembershipQuestionViolationOptions as MembershipQuestionViolationOptionsOriginal, type MessageEnvelope as MessageEnvelopeOriginal, OwnershipFilter as OwnershipFilterOriginal, type OwnershipFilterWithLiterals as OwnershipFilterWithLiteralsOriginal, type PagingMetadata as PagingMetadataOriginal, type Paging as PagingOriginal, type PaidPlan as PaidPlanOriginal, type PricingPlanViolationOptions as PricingPlanViolationOptionsOriginal, type QueryJoinGroupRequestsRequest as QueryJoinGroupRequestsRequestOriginal, type QueryJoinGroupRequestsResponse as QueryJoinGroupRequestsResponseOriginal, type Query as QueryOriginal, type RejectAllJoinGroupRequestsRequest as RejectAllJoinGroupRequestsRequestOriginal, type RejectAllJoinGroupRequestsResponse as RejectAllJoinGroupRequestsResponseOriginal, type RejectJoinGroupRequestsRequest as RejectJoinGroupRequestsRequestOriginal, type RejectJoinGroupRequestsResponse as RejectJoinGroupRequestsResponseOriginal, type Rejection as RejectionOriginal, type RequestDetails as RequestDetailsOriginal, RequestStatus as RequestStatusOriginal, type RequestStatusWithLiterals as RequestStatusWithLiteralsOriginal, type RestoreInfo as RestoreInfoOriginal, type SocialGroupsEvent as SocialGroupsEventOriginal, type SocialGroupsEventPayloadOneOf as SocialGroupsEventPayloadOneOfOriginal, SortOrder as SortOrderOriginal, type SortOrderWithLiterals as SortOrderWithLiteralsOriginal, type Sorting as SortingOriginal, type SubmitJoinGroupRequestRequest as SubmitJoinGroupRequestRequestOriginal, type SubmitJoinGroupRequestResponse as SubmitJoinGroupRequestResponseOriginal, type Violation as ViolationOriginal, ViolationType as ViolationTypeOriginal, type ViolationTypeWithLiterals as ViolationTypeWithLiteralsOriginal, type ViolationViolationOptionsOneOf as ViolationViolationOptionsOneOfOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, approveJoinGroupRequests, listJoinGroupRequests, queryJoinGroupRequests, rejectJoinGroupRequests };