Contexts

google.cloud.dialogflow.v2. Contexts

Represents a Contexts

Constructor

new Contexts(rpcImpl, requestDelimitedopt, responseDelimitedopt)

Constructs a new Contexts service.

Parameters:
Name Type Attributes Default Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean <optional>
false

Whether requests are length-delimited

responseDelimited boolean <optional>
false

Whether responses are length-delimited

Extends

  • $protobuf.rpc.Service

Methods

(static) create(rpcImpl, requestDelimitedopt, responseDelimitedopt) → {Contexts}

Creates new Contexts service using the specified rpc implementation.

Parameters:
Name Type Attributes Default Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean <optional>
false

Whether requests are length-delimited

responseDelimited boolean <optional>
false

Whether responses are length-delimited

createContext(request, callback) → {undefined}

Calls CreateContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.ICreateContextRequest

CreateContextRequest message or plain object

callback google.cloud.dialogflow.v2.Contexts.CreateContextCallback

Node-style callback called with the error, if any, and Context

createContext(request) → {Promise.<google.cloud.dialogflow.v2.Context>}

Calls CreateContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.ICreateContextRequest

CreateContextRequest message or plain object

deleteAllContexts(request, callback) → {undefined}

Calls DeleteAllContexts.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IDeleteAllContextsRequest

DeleteAllContextsRequest message or plain object

callback google.cloud.dialogflow.v2.Contexts.DeleteAllContextsCallback

Node-style callback called with the error, if any, and Empty

deleteAllContexts(request) → {Promise.<google.protobuf.Empty>}

Calls DeleteAllContexts.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IDeleteAllContextsRequest

DeleteAllContextsRequest message or plain object

deleteContext(request, callback) → {undefined}

Calls DeleteContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IDeleteContextRequest

DeleteContextRequest message or plain object

callback google.cloud.dialogflow.v2.Contexts.DeleteContextCallback

Node-style callback called with the error, if any, and Empty

deleteContext(request) → {Promise.<google.protobuf.Empty>}

Calls DeleteContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IDeleteContextRequest

DeleteContextRequest message or plain object

getContext(request, callback) → {undefined}

Calls GetContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IGetContextRequest

GetContextRequest message or plain object

callback google.cloud.dialogflow.v2.Contexts.GetContextCallback

Node-style callback called with the error, if any, and Context

getContext(request) → {Promise.<google.cloud.dialogflow.v2.Context>}

Calls GetContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IGetContextRequest

GetContextRequest message or plain object

listContexts(request, callback) → {undefined}

Calls ListContexts.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IListContextsRequest

ListContextsRequest message or plain object

callback google.cloud.dialogflow.v2.Contexts.ListContextsCallback

Node-style callback called with the error, if any, and ListContextsResponse

listContexts(request) → {Promise.<google.cloud.dialogflow.v2.ListContextsResponse>}

Calls ListContexts.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IListContextsRequest

ListContextsRequest message or plain object

updateContext(request, callback) → {undefined}

Calls UpdateContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IUpdateContextRequest

UpdateContextRequest message or plain object

callback google.cloud.dialogflow.v2.Contexts.UpdateContextCallback

Node-style callback called with the error, if any, and Context

updateContext(request) → {Promise.<google.cloud.dialogflow.v2.Context>}

Calls UpdateContext.

Parameters:
Name Type Description
request google.cloud.dialogflow.v2.IUpdateContextRequest

UpdateContextRequest message or plain object

Type Definitions

CreateContextCallback(error, responseopt)

Callback as used by google.cloud.dialogflow.v2.Contexts#createContext.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.v2.Context <optional>

Context

DeleteAllContextsCallback(error, responseopt)

Callback as used by google.cloud.dialogflow.v2.Contexts#deleteAllContexts.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

DeleteContextCallback(error, responseopt)

Callback as used by google.cloud.dialogflow.v2.Contexts#deleteContext.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.protobuf.Empty <optional>

Empty

GetContextCallback(error, responseopt)

Callback as used by google.cloud.dialogflow.v2.Contexts#getContext.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.v2.Context <optional>

Context

ListContextsCallback(error, responseopt)

Callback as used by google.cloud.dialogflow.v2.Contexts#listContexts.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.v2.ListContextsResponse <optional>

ListContextsResponse

UpdateContextCallback(error, responseopt)

Callback as used by google.cloud.dialogflow.v2.Contexts#updateContext.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.v2.Context <optional>

Context