--- title: "Validate VMC or CMC logo format (encoded)" source_url: https://dev.digicert.com/certcentral-apis/services-api/utilities/validate-vmc-or-cmc-logo-format-encoded.html api_method: PUT api_endpoint: "/services/v2/util/validate-vmc-encoded-logo" api_url: "https://www.digicert.com/services/v2/util/validate-vmc-encoded-logo" --- **PUT** `https://www.digicert.com/services/v2/util/validate-vmc-encoded-logo` Use this endpoint to check if the format of an SVG file is compatible with the requirements for Verified Mark Certificates (VMC) or a Common Mark Certificate (CMC). > **Info** > > This endpoint accepts compressed logo data, formatted as a base64-encoded string. To submit raw SVG data, use the [Validate VMC or CMC logo format (SVG)](https://dev.digicert.com/md/certcentral-apis/services-api/utilities/validate-vmc-or-cmc-logo-format-svg.md) endpoint. ## Request format To submit a request to the **Validate VMC or CMC logo format (encoded)** endpoint: - Set the `Content-Type` header to `application/json`. - Format the data for your SVG logo as a compressed, base64-encoded string. For example, in a bash shell, run this command: ```bash echo '' | gzip | base64 ``` - In the JSON payload, submit the string containing the encoded logo data as the value of the `logo` parameter. - Omit the custom header `X-DC-DEVKEY`. This operation does not require authentication with an API key. ## Response format If the logo format meets VMC or CMC requirements, the endpoint returns a status of **204 No Content**. If there is a formatting issue with the logo, the endpoint returns an error message with a status of **400 Bad Request**. The error message provides: - A brief description of the formatting issue. - The line and column number where you can find the problem when you open the file in a text editor. To learn more about formatting a logo for VMC or CMC, visit Getting Ready for BIMI: Prep Your Logo. To resolve issues with the SVG format of your logo: 1. Open the SVG file in a text editor. 2. Update the content at the locations displayed in the error messages. 3. Save the file. 4. Submit another request with your updated SVG data. ## Example requests and responses **cURL** ```bash curl --request PUT 'https://www.digicert.com/services/v2/util/validate-vmc-encoded-logo' \ --header 'Content-Type: application/json' \ --data-raw '{ "logo" : {{compressed_base64_encoded_svg_logo}} }' ``` **Python** ```python import requests import json url = "https://www.digicert.com/services/v2/util/validate-vmc-encoded-logo" payload = json.dumps({ "logo": {{compressed_base64_encoded_svg_logo}} }) headers = { 'Content-Type': 'application/json' } response = requests.request("PUT", url, headers=headers, data=payload) print(response.text) ``` **Go** ```go package main import ( "fmt" "strings" "net/http" "io/ioutil" ) func main() { url := "https://www.digicert.com/services/v2/util/validate-vmc-encoded-logo" method := "PUT" payload := strings.NewReader(`{ "logo" : {{compressed_base64_encoded_svg_logo}} }`) client := &http.Client { } req, err := http.NewRequest(method, url, payload) if err != nil { fmt.Println(err) return } req.Header.Add("Content-Type", "application/json") res, err := client.Do(req) if err != nil { fmt.Println(err) return } defer res.Body.Close() body, err := ioutil.ReadAll(res.Body) if err != nil { fmt.Println(err) return } fmt.Println(string(body)) } ``` **NodeJS** ```javascript var request = require('request'); var options = { 'method': 'PUT', 'url': 'https://www.digicert.com/services/v2/util/validate-vmc-encoded-logo', 'headers': { 'Content-Type': 'application/json' }, body: JSON.stringify({ "logo": {{compressed_base64_encoded_svg_logo}} }) }; request(options, function (error, response) { if (error) throw new Error(error); console.log(response.body); }); ``` **204 No Content** ```json // empty ``` **400 Bad Request** ```json { "errors": [ { "code": "invalid_vmc_logo", "message": "attribute \"overflow\" not allowed here at line 4:65" } ] } ``` ## Request parameters
Name Req/Opt Type Description
logo required string Compressed logo data, formatted as a base64-encoded string.