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

    Interact with entities, in admin contexts, where no distinction between identity vs organization is required.

    Index

    Constructors

    Properties

    identityAdminQueryService: IdentityAdminQueryService
    organizationAdminQueryService: OrganizationAdminQueryService

    Methods

    • Parameters

      • args: {
            createdAt?: DbTimestampCriteria;
            customerIds?: string[];
            ids?: string[];
            orderBy?: DbOrderByCriterion<
                | Omit<
                    PgTableWithColumns<
                        {
                            columns: {
                                countryOfResidence: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                createdAt: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                customerId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                data: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    { $type: ... },
                                >;
                                deletedAt: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                email: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                externalId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                id: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                name: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    { $type: ... },
                                >;
                                phone: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                referenceId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                status: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    { $type: ... },
                                >;
                                updatedAt: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                uuid: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                verification: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    { $type: ... },
                                >;
                            };
                            dialect: "pg";
                            name: "identity";
                            schema: "b2b";
                        },
                    >,
                    "enableRLS",
                >
                | Omit<
                    PgTableWithColumns<
                        {
                            columns: {
                                countryOfIncorporation: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                createdAt: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                customerId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                data: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    { $type: ... },
                                >;
                                description: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                entityType: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                externalId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                id: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                name: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                referenceId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                status: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    { $type: ... },
                                >;
                                taxId: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                updatedAt: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                                uuid: PgColumn<
                                    {
                                        baseColumn: ...;
                                        columnType: ...;
                                        data: ...;
                                        dataType: ...;
                                        driverParam: ...;
                                        enumValues: ...;
                                        generated: ...;
                                        hasDefault: ...;
                                        hasRuntimeDefault: ...;
                                        identity: ...;
                                        isAutoincrement: ...;
                                        isPrimaryKey: ...;
                                        name: ...;
                                        notNull: ...;
                                        tableName: ...;
                                    },
                                    {},
                                    {},
                                >;
                            };
                            dialect: "pg";
                            name: "organization";
                            schema: "b2b";
                        },
                    >,
                    "enableRLS",
                >,
                "createdAt"
                | "updatedAt",
            >[];
            page?: number;
            pageSize?: number;
            updatedAt?: DbTimestampCriteria;
        }
        • OptionalcreatedAt?: DbTimestampCriteria
        • OptionalcustomerIds?: string[]
        • Optionalids?: string[]

          Fetch multiple ids

        • OptionalorderBy?: DbOrderByCriterion<
              | Omit<
                  PgTableWithColumns<
                      {
                          columns: {
                              countryOfResidence: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              createdAt: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              customerId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              data: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  { $type: ... },
                              >;
                              deletedAt: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              email: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              externalId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              id: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              name: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  { $type: ... },
                              >;
                              phone: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              referenceId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              status: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  { $type: ... },
                              >;
                              updatedAt: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              uuid: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              verification: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  { $type: ... },
                              >;
                          };
                          dialect: "pg";
                          name: "identity";
                          schema: "b2b";
                      },
                  >,
                  "enableRLS",
              >
              | Omit<
                  PgTableWithColumns<
                      {
                          columns: {
                              countryOfIncorporation: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              createdAt: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              customerId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              data: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  { $type: ... },
                              >;
                              description: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              entityType: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              externalId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              id: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              name: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              referenceId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              status: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  { $type: ... },
                              >;
                              taxId: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              updatedAt: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                              uuid: PgColumn<
                                  {
                                      baseColumn: ...;
                                      columnType: ...;
                                      data: ...;
                                      dataType: ...;
                                      driverParam: ...;
                                      enumValues: ...;
                                      generated: ...;
                                      hasDefault: ...;
                                      hasRuntimeDefault: ...;
                                      identity: ...;
                                      isAutoincrement: ...;
                                      isPrimaryKey: ...;
                                      name: ...;
                                      notNull: ...;
                                      tableName: ...;
                                  },
                                  {},
                                  {},
                              >;
                          };
                          dialect: "pg";
                          name: "organization";
                          schema: "b2b";
                      },
                  >,
                  "enableRLS",
              >,
              "createdAt"
              | "updatedAt",
          >[]
        • Optionalpage?: number

          Defaults to 1

        • OptionalpageSize?: number

          Defaults to 50

        • OptionalupdatedAt?: DbTimestampCriteria

      Returns Promise<
          {
              ok: true;
              value: {
                  hasNext: boolean;
                  items: (
                      (
                          | { type: "IDENTITY" } & {
                              amlVerification?: {
                                  id: string;
                                  status: (...) | (...) | (...) | (...);
                              };
                              capabilities: (
                                  | "TRANSACT"
                                  | "MANAGE_PAYMENT_INSTRUMENT"
                                  | "MANAGE_LEDGER_ACCOUNT"
                                  | "MANAGE_DEPOSIT_MEMO"
                              )[];
                              countryOfResidence: string;
                              createdAt: Date;
                              customerVerification?: { id: string };
                              dateOfBirth?: string;
                              deletedAt?: Date;
                              email: string;
                              id: string;
                              identityDocumentVerification?: {
                                  id: string;
                                  status: (...) | (...) | (...) | (...);
                              };
                              name?: {
                                  firstName: string;
                                  lastName: string;
                                  middleName?: (...)
                                  | (...);
                              };
                              phone: string;
                              referenceId?: string;
                              status: | "ACTIVE"
                              | "DISABLED"
                              | "PENDING_VERIFICATION"
                              | "REVIEW"
                              | "BLOCKED"
                              | "DELETED";
                              updatedAt: Date;
                              uuid: string;
                              verificationProfileId?: string;
                          }
                          | { type: "ORGANIZATION" } & {
                              address?: {
                                  city: string;
                                  countryCode: string;
                                  line1: string;
                                  line2?: (...) | (...);
                                  postalCode: string;
                                  regionCode?: (...) | (...);
                              };
                              capabilities: (
                                  | "TRANSACT"
                                  | "MANAGE_PAYMENT_INSTRUMENT"
                                  | "MANAGE_LEDGER_ACCOUNT"
                                  | "MANAGE_DEPOSIT_MEMO"
                              )[];
                              countryOfIncorporation: string;
                              createdAt: Date;
                              description?: string;
                              email?: string;
                              id: string;
                              legalEntityType: string;
                              name: string;
                              phone?: E164Phone | undefined;
                              referenceId?: string;
                              status: "ACTIVE"
                              | "DISABLED"
                              | "PENDING_VERIFICATION";
                              taxId: string;
                              updatedAt: Date;
                              uuid: string;
                              verificationData?: {
                                  status: (...) | (...) | (...) | (...);
                                  verificationSessionId: string;
                                  verificationTemplateId: string;
                              };
                              verificationProfileId?: string;
                              websiteUrl?: string;
                          }
                      ) & { customerId: string }
                  )[];
              };
          },
      >