[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[[["\u003cp\u003eThis documentation provides details for the \u003ccode\u003eFunction\u003c/code\u003e class within the Google Cloud Functions v2beta API, specifically version 1.0.0-beta07.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eFunction\u003c/code\u003e class describes a Cloud Function which executes user-defined computations in response to events and includes configurations for the function and its triggers.\u003c/p\u003e\n"],["\u003cp\u003eThe class implements interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e, providing methods and properties for data manipulation and object management.\u003c/p\u003e\n"],["\u003cp\u003eKey properties of the \u003ccode\u003eFunction\u003c/code\u003e class include \u003ccode\u003eBuildConfig\u003c/code\u003e, \u003ccode\u003eServiceConfig\u003c/code\u003e, \u003ccode\u003eEventTrigger\u003c/code\u003e, and \u003ccode\u003eEnvironment\u003c/code\u003e, which detail the function's build, service deployment, event triggering, and environment, respectively.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eFunction\u003c/code\u003e class also includes read-only properties like \u003ccode\u003eCreateTime\u003c/code\u003e, \u003ccode\u003eUpdateTime\u003c/code\u003e, \u003ccode\u003eState\u003c/code\u003e, and \u003ccode\u003eUrl\u003c/code\u003e which help to keep track of the history, state and location of the deployed function.\u003c/p\u003e\n"]]],[],null,["# Cloud Functions v2beta API - Class Function (1.0.0-beta07)\n\nVersion latestkeyboard_arrow_down\n\n- [1.0.0-beta07 (latest)](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.Function)\n- [1.0.0-beta06](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/1.0.0-beta06/Google.Cloud.Functions.V2Beta.Function) \n\n public sealed class Function : IMessage\u003cFunction\u003e, IEquatable\u003cFunction\u003e, IDeepCloneable\u003cFunction\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Cloud Functions v2beta API class Function.\n\nDescribes a Cloud Function that contains user computation executed in\nresponse to an event. It encapsulates function and trigger configurations. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e Function \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[Function](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.Function), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Function](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.Function), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[Function](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.Function), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Functions.V2Beta](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta)\n\nAssembly\n--------\n\nGoogle.Cloud.Functions.V2Beta.dll\n\nConstructors\n------------\n\n### Function()\n\n public Function()\n\n### Function(Function)\n\n public Function(Function other)\n\nProperties\n----------\n\n### BuildConfig\n\n public BuildConfig BuildConfig { get; set; }\n\nDescribes the Build step of the function that builds a container from the\ngiven source.\n\n### CreateTime\n\n public Timestamp CreateTime { get; set; }\n\nOutput only. The create timestamp of a Cloud Function. This is only\napplicable to 2nd Gen functions.\n\n### Description\n\n public string Description { get; set; }\n\nUser-provided description of a function.\n\n### Environment\n\n public Environment Environment { get; set; }\n\nDescribe whether the function is 1st Gen or 2nd Gen.\n\n### EventTrigger\n\n public EventTrigger EventTrigger { get; set; }\n\nAn Eventarc trigger managed by Google Cloud Functions that fires events in\nresponse to a condition in another service.\n\n### FunctionName\n\n public FunctionName FunctionName { get; set; }\n\n[FunctionName](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.FunctionName)-typed view over the [Name](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.Function#Google_Cloud_Functions_V2Beta_Function_Name) resource name property.\n\n### KmsKeyName\n\n public string KmsKeyName { get; set; }\n\n\\[Preview\\] Resource name of a KMS crypto key (managed by the user) used to\nencrypt/decrypt function resources.\n\nIt must match the pattern\n`projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`.\n\n### KmsKeyNameAsCryptoKeyName\n\n public CryptoKeyName KmsKeyNameAsCryptoKeyName { get; set; }\n\n[CryptoKeyName](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.CryptoKeyName)-typed view over the [KmsKeyName](/dotnet/docs/reference/Google.Cloud.Functions.V2Beta/latest/Google.Cloud.Functions.V2Beta.Function#Google_Cloud_Functions_V2Beta_Function_KmsKeyName) resource name property.\n\n### Labels\n\n public MapField\u003cstring, string\u003e Labels { get; }\n\nLabels associated with this Cloud Function.\n\n### Name\n\n public string Name { get; set; }\n\nA user-defined name of the function. Function names must be unique\nglobally and match pattern `projects/*/locations/*/functions/*`\n\n### SatisfiesPzs\n\n public bool SatisfiesPzs { get; set; }\n\nOutput only. Reserved for future use.\n\n### ServiceConfig\n\n public ServiceConfig ServiceConfig { get; set; }\n\nDescribes the Service being deployed. Currently deploys services to Cloud\nRun (fully managed).\n\n### State\n\n public Function.Types.State State { get; set; }\n\nOutput only. State of the function.\n\n### StateMessages\n\n public RepeatedField\u003cStateMessage\u003e StateMessages { get; }\n\nOutput only. State Messages for this Cloud Function.\n\n### UpdateTime\n\n public Timestamp UpdateTime { get; set; }\n\nOutput only. The last update timestamp of a Cloud Function.\n\n### Url\n\n public string Url { get; set; }\n\nOutput only. The deployed url for the function."]]