public sealed class CreateContextRequest : IMessage<CreateContextRequest>, IEquatable<CreateContextRequest>, IDeepCloneable<CreateContextRequest>, IBufferMessage, IMessage
Reference documentation and code samples for the Google Cloud Dialogflow v2 API class CreateContextRequest.
The request message for
[Contexts.CreateContext][google.cloud.dialogflow.v2.Contexts.CreateContext].
Required. The session to create a context for.
Format: projects/<Project ID>/agent/sessions/<Session ID> or
projects/<Project ID>/agent/environments/<Environment ID>/users/<User
ID>/sessions/<Session ID>.
If Environment ID is not specified, we assume default 'draft'
environment. If User ID is not specified, we assume default '-' user.
Property Value
Type
Description
string
ParentAsSessionName
public SessionName ParentAsSessionName { get; set; }
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThis document provides reference documentation for the \u003ccode\u003eCreateContextRequest\u003c/code\u003e class within the Google Cloud Dialogflow v2 API, specifically for version 4.9.0.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eCreateContextRequest\u003c/code\u003e class is used to create a context in a Dialogflow session, requiring a specified context and session parent.\u003c/p\u003e\n"],["\u003cp\u003eThis page also lists the different versions of the \u003ccode\u003eCreateContextRequest\u003c/code\u003e available, going back to version 3.2.0, with the most current version being 4.26.0.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eCreateContextRequest\u003c/code\u003e class implements multiple interfaces, including \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e, and inherits from \u003ccode\u003eobject\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThere are two constructors available for \u003ccode\u003eCreateContextRequest\u003c/code\u003e, one that is parameterless and one that takes a \u003ccode\u003eCreateContextRequest\u003c/code\u003e object.\u003c/p\u003e\n"]]],[],null,[]]