InkeepBaseSettings

This interface is used to configure the base settings for the Inkeep widgets.

PropertyTypeDescription
apiKeystringRequired. The API key for your integration. Example: process.env.INKEEP_API_KEY.
integrationIdstringRequired. The identifier for the integration point. Example: process.env.INKEEP_INTEGRATION_ID.
organizationIdstringRequired. The identifier for your organization. Example: process.env.INKEEP_ORGANIZATION_ID.
organizationDisplayNamestringRequired. The display name for your organization. Example: "Inkeep".
primaryBrandColorstringRequired. The primary brand color. The UX will automatically derive a theme from this color. Example: "#26D6FF".
userIdstringUser ID for analytics. Default's to an auto-generated ID for the page or browser, depending on optOutAnalyticalCookies and optOutAllAnalytics.
userEmailstringUser email for analytics. Default undefined.
userNamestringUser name for analytics and showing initials in the UX. Default: undefined.
userCohortsstring[]Array of user cohorts to correlate to your own customer segmentation in analytics. Default: [].
userTokenstringCan be used to gate the search and chat service to authenticated users. See here.
userType"EXTERNAL" | "INTERNAL"Used as meta-data in analytics and error logging.
logEventCallback(event: InkeepCallbackEvent) => voidCallback function for logging events to integrate with your own analytics. Refer to Use your own analytics for details.
optOutAnalyticalCookiesbooleanOption to disable cookies used for tracking a user's Inkeep usage behavior across multiple browser sessions. Only same-domain cookies are used. Default: false.
optOutAllAnalyticsbooleanOption to disable all usage analytics, even anonymous ones. Default: false.
optOutFunctionalCookiesbooleanOption to disable cookies that are used for functionality. Default: false.
remoteErrorLogsLevelRemoteErrorLogsLevelThe level of remote error logging for Inkeep's monitoring service. Default: RemoteErrorLogsLevel.IdentifiableErrors.
consoleDebugLevelConsoleDebugLevelThe level of logging to your console. Default: ConsoleDebugLevel.Errors.
chatApiProxyDomainstringDomain for routing search and chat API calls through a proxy. Default: undefined. Example: myproxy.com.
analyticsApiProxyDomainstringDomain for routing analytics API calls through a proxy. Default: undefined. Example: myproxy.com.
env"DEVELOPMENT" | "PRODUCTION"Used as meta-data in analytics and error logging. Default is PRODUCTION. If set to DEVELOPMENT, the user conversations are not shown in the analytics dashboard.
tagsstring[]Associate questions together by tag for analytics.
appendQueryParamsToUrlsRecord<string, string>Optional query parameters to be added to documentation links. Useful for click tracking via UTM tags. Example: { utm_source: 'inkeep_widget' }.
themeUserThemeUse the theme configuration to configure colors, fonts, z-indexes and other properties of the widget. Learn more.
customIconsCustomIconsOptional icon overrides. Learn more.
colorModeColorModeControl the color mode of the widget. Learn more.
prismPrismLibPass in your own instance of the Prismjs library, we recommend doing this if you are using any plugins or doing any custom modifications to the instance of Prism in your application to avoid conflicts with the global Prism namespace. Note that you will need to import any additional languages you wish the syntax highlighter to support.

Example

import { type InkeepBaseSettings } from "@inkeep/uikit";

export const baseSettings: InkeepBaseSettings = {
  apiKey: process.env.INKEEP_API_KEY!,
  integrationId: process.env.INKEEP_INTEGRATION_ID!,
  organizationId: process.env.INKEEP_ORGANIZATION_ID!,
  organizationDisplayName: "Inkeep",
  primaryBrandColor: "#26D6FF",
  product: "Inkeep Product",
  productVersion: "1.0.0",
  userId: "user_id",
  userEmail: "user@example.com",
  userName: "John Doe",
  userCohorts: ["cohort1", "cohort2"],
  optOutAnalyticalCookies: false,
  optOutAllAnalytics: false,
  optOutFunctionalCookies: false,
  remoteErrorLogsLevel: RemoteErrorLogsLevel.AnonymousErrors,
  consoleDebugLevel: ConsoleDebugLevel.Errors,
  chatApiProxyDomain: "myproxy.com",
  env: "PRODUCTION",
};