GoogleApi.Compute.V1.Model.CorsPolicy (google_api_compute v0.37.0) View Source

The specification for allowing client side cross-origin requests. Please see W3C Recommendation for Cross Origin Resource Sharing

Attributes

  • allowCredentials (type: boolean(), default: nil) - In response to a preflight request, setting this to true indicates that the actual request can include user credentials. This translates to the Access-Control-Allow-Credentials header. Default is false.
  • allowHeaders (type: list(String.t), default: nil) - Specifies the content for the Access-Control-Allow-Headers header.
  • allowMethods (type: list(String.t), default: nil) - Specifies the content for the Access-Control-Allow-Methods header.
  • allowOriginRegexes (type: list(String.t), default: nil) - Specifies the regualar expression patterns that match allowed origins. For regular expression grammar please see github.com/google/re2/wiki/Syntax An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes.
  • allowOrigins (type: list(String.t), default: nil) - Specifies the list of origins that will be allowed to do CORS requests. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes.
  • disabled (type: boolean(), default: nil) - If true, specifies the CORS policy is disabled. The default value of false, which indicates that the CORS policy is in effect.
  • exposeHeaders (type: list(String.t), default: nil) - Specifies the content for the Access-Control-Expose-Headers header.
  • maxAge (type: integer(), default: nil) - Specifies how long results of a preflight request can be cached in seconds. This translates to the Access-Control-Max-Age header.

Link to this section Summary

Functions

Unwrap a decoded JSON object into its complex fields.

Link to this section Types

Specs

t() :: %GoogleApi.Compute.V1.Model.CorsPolicy{
  allowCredentials: boolean() | nil,
  allowHeaders: [String.t()] | nil,
  allowMethods: [String.t()] | nil,
  allowOriginRegexes: [String.t()] | nil,
  allowOrigins: [String.t()] | nil,
  disabled: boolean() | nil,
  exposeHeaders: [String.t()] | nil,
  maxAge: integer() | nil
}

Link to this section Functions

Specs

decode(struct(), keyword()) :: struct()

Unwrap a decoded JSON object into its complex fields.