## Delete variants setting `client.Cache.Variants.Delete(ctx, body) (*VariantDeleteResponse, error)` **delete** `/zones/{zone_id}/cache/variants` Variant support enables caching variants of images with certain file extensions in addition to the original. This only applies when the origin server sends the 'Vary: Accept' response header. If the origin server sends 'Vary: Accept' but does not serve the variant requested, the response will not be cached. This will be indicated with BYPASS cache status in the response headers. ### Parameters - `body VariantDeleteParams` - `ZoneID param.Field[string]` Identifier. ### Returns - `type VariantDeleteResponse struct{…}` - `ID VariantDeleteResponseID` The identifier of the caching setting. - `const VariantDeleteResponseIDVariants VariantDeleteResponseID = "variants"` - `Editable bool` Whether the setting is editable. - `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/cache" "github.com/cloudflare/cloudflare-go/option" ) func main() { client := cloudflare.NewClient( option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"), ) variant, err := client.Cache.Variants.Delete(context.TODO(), cache.VariantDeleteParams{ ZoneID: cloudflare.F("023e105f4ecef8ad9ca31a8372d0c353"), }) if err != nil { panic(err.Error()) } fmt.Printf("%+v\n", variant.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": "variants", "editable": true, "modified_on": "2014-01-01T05:20:00.12345Z" } } ```