## Update configuration properties `client.APIGateway.Configurations.Update(ctx, params) (*Configuration, error)` **put** `/zones/{zone_id}/api_gateway/configuration` Updates API Shield configuration settings for a zone. Can modify validation strictness, enforcement mode, and other global settings. ### Parameters - `params ConfigurationUpdateParams` - `ZoneID param.Field[string]` Path param: Identifier. - `Configuration param.Field[Configuration]` Body param - `Normalize param.Field[bool]` Query param: Ensures that the configuration is written or retrieved in normalized fashion ### Returns - `type Configuration struct{…}` - `AuthIDCharacteristics []ConfigurationAuthIDCharacteristic` - `type ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristic struct{…}` Auth ID Characteristic - `Name string` The name of the characteristic field, i.e., the header or cookie name. - `Type ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicType` The type of characteristic. - `const ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicTypeHeader ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicType = "header"` - `const ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicTypeCookie ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicType = "cookie"` - `type ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicJWTClaim struct{…}` Auth ID Characteristic extracted from JWT Token Claims - `Name string` Claim location expressed as `$(token_config_id):$(json_path)`, where `token_config_id` is the ID of the token configuration used in validating the JWT, and `json_path` is a RFC 9535 JSONPath (https://goessner.net/articles/JsonPath/, https://www.rfc-editor.org/rfc/rfc9535.html). The JSONPath expression may be in dot or bracket notation, may only specify literal keys or array indexes, and must return a singleton value, which will be interpreted as a string. - `Type ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicJWTClaimType` The type of characteristic. - `const ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicJWTClaimTypeJWT ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicJWTClaimType = "jwt"` ### Example ```go package main import ( "context" "fmt" "github.com/cloudflare/cloudflare-go" "github.com/cloudflare/cloudflare-go/api_gateway" "github.com/cloudflare/cloudflare-go/option" ) func main() { client := cloudflare.NewClient( option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"), ) configuration, err := client.APIGateway.Configurations.Update(context.TODO(), api_gateway.ConfigurationUpdateParams{ ZoneID: cloudflare.F("023e105f4ecef8ad9ca31a8372d0c353"), Configuration: api_gateway.ConfigurationParam{ AuthIDCharacteristics: cloudflare.F([]api_gateway.ConfigurationAuthIDCharacteristicsUnionParam{api_gateway.ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicParam{ Name: cloudflare.F("authorization"), Type: cloudflare.F(api_gateway.ConfigurationAuthIDCharacteristicsAPIShieldAuthIDCharacteristicTypeHeader), }}), }, }) if err != nil { panic(err.Error()) } fmt.Printf("%+v\n", configuration.AuthIDCharacteristics) } ``` #### Response ```json { "errors": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "messages": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "result": { "auth_id_characteristics": [ { "name": "authorization", "type": "header" } ] }, "success": true } ```