public sealed class ServerKeyRestrictions : IMessage<ServerKeyRestrictions>, IEquatable<ServerKeyRestrictions>, IDeepCloneable<ServerKeyRestrictions>, IBufferMessage, IMessage
Reference documentation and code samples for the API Keys v2 API class ServerKeyRestrictions.
The IP addresses of callers that are allowed to use the key.
[[["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 page provides reference documentation for the \u003ccode\u003eServerKeyRestrictions\u003c/code\u003e class within the Google Cloud API Keys v2 API, specifically for version 1.1.0.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eServerKeyRestrictions\u003c/code\u003e class defines a mechanism to restrict API key usage to specific IP addresses, by implementing various interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe class includes a constructor that initializes the instance either with no parameters or by cloning another \u003ccode\u003eServerKeyRestrictions\u003c/code\u003e object.\u003c/p\u003e\n"],["\u003cp\u003eIt also features an \u003ccode\u003eAllowedIps\u003c/code\u003e property, which is a \u003ccode\u003eRepeatedField<string>\u003c/code\u003e allowing the specification of multiple IP addresses that are authorized to use the key.\u003c/p\u003e\n"],["\u003cp\u003eThe class inherits from the base \u003ccode\u003eObject\u003c/code\u003e class, and has access to its methods, like \u003ccode\u003eGetHashCode\u003c/code\u003e, \u003ccode\u003eGetType\u003c/code\u003e, \u003ccode\u003eMemberwiseClone\u003c/code\u003e, and \u003ccode\u003eToString\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,[]]