@cfxlabsinc/b2b-services
    Preparing search index...

    Class CustomerSlackBotInstallationService

    Index
    db: B2bDatabase
    • Get a slack installation by ID

      Parameters

      • args: {
            customerId: string;
            id: string[];
            tx?: PgAsyncTransaction<NodePgQueryResultHKT, EmptyRelations>;
        }

      Returns Promise<void>

    • Returns a URL that is suitable for including in an Add to Slack button. Its token signs who is installing, so the install is recorded as theirs.

      Parameters

      • claims: { customerId: string; userId?: string; visibility?: "ALL" | "INTERNAL" }
        • customerId: string
        • OptionaluserId?: string

          The dashboard user's id.

        • Optionalvisibility?: "ALL" | "INTERNAL"

          INTERNAL when the user's role in this customer is internal.

      Returns string

    • Get a slack installation by ID

      Parameters

      • args: {
            customerId: string;
            id: string;
            tx?: PgAsyncTransaction<NodePgQueryResultHKT, EmptyRelations>;
        }

      Returns Promise<{ ok: true; value: CustomerSlackBotInstallation | null }>

    • Search a slack installations

      Parameters

      • __namedParameters: {
            createdAt?: DbTimestampCriteria;
            customerId: string;
            ids?: string[];
            page?: number;
            pageSize?: number;
            slackBotInstallationIds?: string[];
            tx?: PgAsyncTransaction<NodePgQueryResultHKT, EmptyRelations>;
            updatedAt?: DbTimestampCriteria;
        }

      Returns Promise<
          {
              ok: true;
              value: {
                  hasNext: boolean;
                  items: CustomerSlackBotInstallation[];
                  total: number;
              };
          },
      >