## Change Origin Post-Quantum Encryption setting `client.OriginPostQuantumEncryption.Update(ctx, params) (*OriginPostQuantumEncryptionUpdateResponse, error)` **put** `/zones/{zone_id}/cache/origin_post_quantum_encryption` Instructs Cloudflare to use Post-Quantum (PQ) key agreement algorithms when connecting to your origin. Preferred instructs Cloudflare to opportunistically send a Post-Quantum keyshare in the first message to the origin (for fastest connections when the origin supports and prefers PQ), supported means that PQ algorithms are advertised but only used when requested by the origin, and off means that PQ algorithms are not advertised. ### Parameters - `params OriginPostQuantumEncryptionUpdateParams` - `ZoneID param.Field[string]` Path param: Identifier. - `Value param.Field[OriginPostQuantumEncryptionUpdateParamsValue]` Body param: Value of the Origin Post Quantum Encryption Setting. - `const OriginPostQuantumEncryptionUpdateParamsValuePreferred OriginPostQuantumEncryptionUpdateParamsValue = "preferred"` - `const OriginPostQuantumEncryptionUpdateParamsValueSupported OriginPostQuantumEncryptionUpdateParamsValue = "supported"` - `const OriginPostQuantumEncryptionUpdateParamsValueOff OriginPostQuantumEncryptionUpdateParamsValue = "off"` ### Returns - `type OriginPostQuantumEncryptionUpdateResponse struct{…}` - `ID OriginPostQuantumEncryptionUpdateResponseID` The identifier of the caching setting. - `const OriginPostQuantumEncryptionUpdateResponseIDOriginPqe OriginPostQuantumEncryptionUpdateResponseID = "origin_pqe"` - `Editable bool` Whether the setting is editable. - `Value OriginPostQuantumEncryptionUpdateResponseValue` Value of the Origin Post Quantum Encryption Setting. - `const OriginPostQuantumEncryptionUpdateResponseValuePreferred OriginPostQuantumEncryptionUpdateResponseValue = "preferred"` - `const OriginPostQuantumEncryptionUpdateResponseValueSupported OriginPostQuantumEncryptionUpdateResponseValue = "supported"` - `const OriginPostQuantumEncryptionUpdateResponseValueOff OriginPostQuantumEncryptionUpdateResponseValue = "off"` - `ModifiedOn Time` Last time this setting was modified. ### Example ```go package main import ( "context" "fmt" "github.com/cloudflare/cloudflare-go" "github.com/cloudflare/cloudflare-go/option" "github.com/cloudflare/cloudflare-go/origin_post_quantum_encryption" ) func main() { client := cloudflare.NewClient( option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"), ) originPostQuantumEncryption, err := client.OriginPostQuantumEncryption.Update(context.TODO(), origin_post_quantum_encryption.OriginPostQuantumEncryptionUpdateParams{ ZoneID: cloudflare.F("023e105f4ecef8ad9ca31a8372d0c353"), Value: cloudflare.F(origin_post_quantum_encryption.OriginPostQuantumEncryptionUpdateParamsValuePreferred), }) if err != nil { panic(err.Error()) } fmt.Printf("%+v\n", originPostQuantumEncryption.ID) } ``` #### 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" } } ], "success": true, "result": { "id": "origin_pqe", "editable": true, "value": "preferred", "modified_on": "2014-01-01T05:20:00.12345Z" } } ```