public interface

ChatKnowledgeArticlePreviewDataProvider

com.salesforce.android.chat.ui.ChatKnowledgeArticlePreviewDataProvider

Class Overview

Interface for providing a knowledge article's title and summary to a hyperlink preview rendered in the chat feed.

To provide data for an article preview, implement this interface and pass the instance to the ChatUI client using the knowledgeArticlePreviewDataProvider(ChatKnowledgeArticlePreviewDataProvider) builder.

An implementation of this interface should query the knowledge base using the Knowledge API and providing the articleIdOrTitle value.

Summary

Public Methods
abstract boolean onPreviewDataRequested(String articleIdOrTitle, ChatKnowledgeArticlePreviewDataHelper onPreviewDataReceived)
Retrieves the article's title and summary given the articleIdOrTitle.

Public Methods

public abstract boolean onPreviewDataRequested (String articleIdOrTitle, ChatKnowledgeArticlePreviewDataHelper onPreviewDataReceived)

Retrieves the article's title and summary given the articleIdOrTitle.

Parameters
articleIdOrTitle The 18 character articleId or article title.
onPreviewDataReceived The callback used to return the article's title and summary for use in generating the hyperlink preview.
Returns
  • If data provider was invoked or not.