/*! Copyright (c) 2019, XAPPmedia */ import { Playlist } from "stentor-media"; import { AbstractResponseBuilder, ActiveContext, CanFulfillIntentResult, Card, ListItem, OrderDescription, PaymentParameters, PlayableMedia, Response, ResponseBuilderProps, ResponseOutput, SimpleResponse, SuggestionTypes, UserDataType, UserDataValue } from "stentor-models"; import { MediaObject, Response as ActionsOnGoogleResponse, RichResponse } from "./index"; export interface ActionsOnGoogleBuilderProps extends ResponseBuilderProps { sessionId?: string; } /** * Build a response suitable for Actions on Google * * @deprecated - Instead of using channel specific response builders, we recommend using the generic ResponseBuilder and the channels translator * @class ActionsOnGoogleResponseBuilder * @extends {AbstractResponseBuilder} */ export declare class ActionsOnGoogleResponseBuilder extends AbstractResponseBuilder { private responseBody; private promptOutput; private repromptOutput; private suggestions; private permissionRequest; private permissionRequestTTSContext; private permissionNotificationIntent; private playables; private accountLinkingRequest; private accountLinkingRequestTTSContext; private surfaceChangeRequest; private surfaceChangeRequestTTSContext; private surfaceChangeRequestNotificationTitle; constructor(props: ActionsOnGoogleBuilderProps); respond(response: Response): this; say(response: string | ResponseOutput, append?: boolean): this; reprompt(response: string | ResponseOutput, append?: boolean): this; withCard(card: Card): this; withCarousel(items: ListItem[]): this; withList(items: ListItem[], title?: string): this; withDisplay(display: object): AbstractResponseBuilder; withSuggestions(suggestion: SuggestionTypes | SuggestionTypes[]): this; withActiveContext(context: ActiveContext | ActiveContext[]): this; /** * * @param {string} tts (Google is always string) * @returns {this} */ askForAccountLinking(response?: string): this; /** * * @param {string} tts (Google is always string) * @param {string} notificationLabel * @returns {this} */ askForSurfaceChange(response?: string, notificationLabel?: string): this; askForNotification(intentId: string): this; askForListAccess(response?: string): AbstractResponseBuilder; /** * * @param phoneNumber */ askForCallTransfer(phoneNumber: string): AbstractResponseBuilder; askForUserData(userDataType: UserDataType): Promise; askForHandoff(): this; play(playable: PlayableMedia, offset?: number): this; playPlaylist(playlist: Playlist | PlayableMedia[]): this; mediaQueueSize(): number; stop(): this; enqueue(next: PlayableMedia, current: PlayableMedia): this; build(): ActionsOnGoogleResponse; createRichResponse(): RichResponse; copyMediaObjects(): MediaObject[]; withCanFulfill(results: CanFulfillIntentResult): this; askTransactionRequirements(): AbstractResponseBuilder; askForDeliveryAddress(response?: string | SimpleResponse): AbstractResponseBuilder; askForTransactionDecision(paymentParameters: PaymentParameters, order: OrderDescription): AbstractResponseBuilder; askForOrderUpdate(response: string | SimpleResponse, order: OrderDescription): AbstractResponseBuilder; }