urembo-hub-api
    Preparing search index...
    Index

    Constructors

    Methods

    • Parameters

      Returns Promise<
          {
              user: { email: string; fullName: string; id: string; role: user_role };
          } & {
              createdAt: Date;
              id: string;
              isModerator: boolean;
              message: string;
              messageType: string;
              sessionId: string;
              userId: string;
          },
      >

    • Parameters

      • sessionId: string
      • productId: string
      • userId: string
      • userRole: string

      Returns Promise<
          {
              product: {
                  currency: string;
                  id: string;
                  imageUrl: string;
                  name: string;
                  price: Decimal;
                  stockQuantity: number;
              };
          } & {
              createdAt: Date;
              featuredAt: Date;
              id: string;
              isCurrentlyFeatured: boolean;
              isFeatured: boolean;
              position: number;
              productId: string;
              sessionId: string;
          },
      >

    • Parameters

      Returns Promise<
          {
              retailer: {
                  businessName: string;
                  email: string;
                  fullName: string;
                  id: string;
              };
          } & {
              actualEnd: Date;
              actualStart: Date;
              createdAt: Date;
              description: string;
              endedAt: Date;
              id: string;
              isActive: boolean;
              retailerId: string;
              scheduledAt: Date;
              startedAt: Date;
              status: string;
              streamUrl: string;
              thumbnailUrl: string;
              title: string;
              updatedAt: Date;
              vendorId: string;
              viewerCount: number;
          },
      >

    • Parameters

      • page: number = 1
      • limit: number = 10
      • Optionalstatus: string
      • OptionalretailerId: string
      • Optionalcategory: string

      Returns Promise<
          {
              pagination: {
                  limit: number;
                  page: number;
                  pages: number;
                  total: number;
              };
              sessions: (
                  {
                      _count: { messages: number; participants: number };
                      products: (
                          {
                              product: {
                                  currency: string;
                                  id: string;
                                  imageUrl: string;
                                  name: string;
                                  price: Decimal;
                                  stockQuantity: number;
                              };
                          } & {
                              createdAt: Date;
                              featuredAt: Date;
                              id: string;
                              isCurrentlyFeatured: boolean;
                              isFeatured: boolean;
                              position: number;
                              productId: string;
                              sessionId: string;
                          }
                      )[];
                      retailer: {
                          businessName: string;
                          email: string;
                          fullName: string;
                          id: string;
                      };
                  } & {
                      actualEnd: Date;
                      actualStart: Date;
                      createdAt: Date;
                      description: string;
                      endedAt: Date;
                      id: string;
                      isActive: boolean;
                      retailerId: string;
                      scheduledAt: Date;
                      startedAt: Date;
                      status: string;
                      streamUrl: string;
                      thumbnailUrl: string;
                      title: string;
                      updatedAt: Date;
                      vendorId: string;
                      viewerCount: number;
                  }
              )[];
          },
      >

    • Parameters

      • OptionaluserId: string
      • OptionaluserRole: string

      Returns Promise<
          {
              endedSessions: number;
              liveSessions: number;
              scheduledSessions: number;
              totalMessages: number;
              totalParticipants: number;
              totalSessions: number;
          },
      >

    • Parameters

      • id: string

      Returns Promise<
          {
              messages: (
                  {
                      user: {
                          email: string;
                          fullName: string;
                          id: string;
                          role: user_role;
                      };
                  } & {
                      createdAt: Date;
                      id: string;
                      isModerator: boolean;
                      message: string;
                      messageType: string;
                      sessionId: string;
                      userId: string;
                  }
              )[];
              participants: (
                  {
                      user: {
                          email: string;
                          fullName: string;
                          id: string;
                          role: user_role;
                      };
                  } & {
                      id: string;
                      isActive: boolean;
                      joinedAt: Date;
                      lastSeenAt: Date;
                      leftAt: Date;
                      sessionId: string;
                      userId: string;
                  }
              )[];
              products: (
                  {
                      product: {
                          currency: string;
                          id: string;
                          imageUrl: string;
                          name: string;
                          price: Decimal;
                          stockQuantity: number;
                      };
                  } & {
                      createdAt: Date;
                      featuredAt: Date;
                      id: string;
                      isCurrentlyFeatured: boolean;
                      isFeatured: boolean;
                      position: number;
                      productId: string;
                      sessionId: string;
                  }
              )[];
              retailer: {
                  businessName: string;
                  email: string;
                  fullName: string;
                  id: string;
              };
          } & {
              actualEnd: Date;
              actualStart: Date;
              createdAt: Date;
              description: string;
              endedAt: Date;
              id: string;
              isActive: boolean;
              retailerId: string;
              scheduledAt: Date;
              startedAt: Date;
              status: string;
              streamUrl: string;
              thumbnailUrl: string;
              title: string;
              updatedAt: Date;
              vendorId: string;
              viewerCount: number;
          },
      >

    • Parameters

      • sessionId: string
      • page: number = 1
      • limit: number = 50

      Returns Promise<
          {
              messages: (
                  {
                      user: {
                          email: string;
                          fullName: string;
                          id: string;
                          role: user_role;
                      };
                  } & {
                      createdAt: Date;
                      id: string;
                      isModerator: boolean;
                      message: string;
                      messageType: string;
                      sessionId: string;
                      userId: string;
                  }
              )[];
              pagination: { limit: number; page: number; pages: number; total: number };
          },
      >

    • Parameters

      • sessionId: string

      Returns Promise<
          (
              {
                  user: { email: string; fullName: string; id: string; role: user_role };
              } & {
                  id: string;
                  isActive: boolean;
                  joinedAt: Date;
                  lastSeenAt: Date;
                  leftAt: Date;
                  sessionId: string;
                  userId: string;
              }
          )[],
      >

    • Parameters

      • userId: string
      • userRole: string
      • page: number = 1
      • limit: number = 10

      Returns Promise<
          {
              pagination: {
                  limit: number;
                  page: number;
                  pages: number;
                  total: number;
              };
              sessions: (
                  {
                      _count: { messages: number; participants: number };
                      retailer: {
                          businessName: string;
                          email: string;
                          fullName: string;
                          id: string;
                      };
                  } & {
                      actualEnd: Date;
                      actualStart: Date;
                      createdAt: Date;
                      description: string;
                      endedAt: Date;
                      id: string;
                      isActive: boolean;
                      retailerId: string;
                      scheduledAt: Date;
                      startedAt: Date;
                      status: string;
                      streamUrl: string;
                      thumbnailUrl: string;
                      title: string;
                      updatedAt: Date;
                      vendorId: string;
                      viewerCount: number;
                  }
              )[];
          },
      >

    • Parameters

      • sessionId: string
      • userId: string

      Returns Promise<
          | {
              user: { email: string; fullName: string; id: string; role: user_role };
          } & {
              id: string;
              isActive: boolean;
              joinedAt: Date;
              lastSeenAt: Date;
              leftAt: Date;
              sessionId: string;
              userId: string;
          }
          | { message: string },
      >

    • Parameters

      • query: string
      • OptionaluserId: string
      • OptionaluserRole: string

      Returns Promise<
          (
              {
                  _count: { messages: number; participants: number };
                  retailer: {
                      businessName: string;
                      email: string;
                      fullName: string;
                      id: string;
                  };
              } & {
                  actualEnd: Date;
                  actualStart: Date;
                  createdAt: Date;
                  description: string;
                  endedAt: Date;
                  id: string;
                  isActive: boolean;
                  retailerId: string;
                  scheduledAt: Date;
                  startedAt: Date;
                  status: string;
                  streamUrl: string;
                  thumbnailUrl: string;
                  title: string;
                  updatedAt: Date;
                  vendorId: string;
                  viewerCount: number;
              }
          )[],
      >

    • Parameters

      Returns Promise<
          {
              products: (
                  {
                      product: {
                          currency: string;
                          id: string;
                          imageUrl: string;
                          name: string;
                          price: Decimal;
                          stockQuantity: number;
                      };
                  } & {
                      createdAt: Date;
                      featuredAt: Date;
                      id: string;
                      isCurrentlyFeatured: boolean;
                      isFeatured: boolean;
                      position: number;
                      productId: string;
                      sessionId: string;
                  }
              )[];
              retailer: {
                  businessName: string;
                  email: string;
                  fullName: string;
                  id: string;
              };
          } & {
              actualEnd: Date;
              actualStart: Date;
              createdAt: Date;
              description: string;
              endedAt: Date;
              id: string;
              isActive: boolean;
              retailerId: string;
              scheduledAt: Date;
              startedAt: Date;
              status: string;
              streamUrl: string;
              thumbnailUrl: string;
              title: string;
              updatedAt: Date;
              vendorId: string;
              viewerCount: number;
          },
      >