> Call POST /v1/check before a tool that writes. DENY means do not invoke the tool. For clean Markdown of any page, append .md to the page URL. For the complete index, fetch https://docs.withwrit.com/llms.txt. # Dynamic README badge image GET https://api.withwrit.com/v1/badge/{token}.svg No auth โ€” this URL is embedded in public READMEs. Renders a shields.io-style SVG badge with the tenant's live gated-write count over the trailing 30 days (e.g. `agent writes gated ยท 1.2k/30d`), green when the tenant gated at least one write in the window, grey at zero. Only aggregate, tenant-opted-in data leaves the gate: no tenant IDs, names, keys, or receipt contents. Unknown or revoked tokens 404. Cached for one hour (`Cache-Control: public, max-age=3600`); badge views are rate-limited to 120/minute per token. Reference: https://docs.withwrit.com/api-reference/badge/dynamic-readme-badge-image ## Servers - `https://api.withwrit.com` (Writ gate, default) - `https://j72ckh66ukck2kcbq3oiwxaalm0olxwb.lambda-url.us-east-1.on.aws` (Direct Lambda Function URL (fallback)) ## Request ### Path parameters - `token` (string, required) โ€” The writ_badge_ token from POST /v1/badge/tokens, with a .svg suffix. ## Response ### 200 The badge SVG. ## Errors ### 404 Not Found Error Unknown or revoked badge token. ### 429 Too Many Requests Error Rate limited โ€” too many badge views for this token this minute. ## Examples **Response** ```json {} ``` **SDK Code** ```python import requests url = "https://api.withwrit.com/v1/badge/token.svg" response = requests.get(url) print(response.json()) ``` ```javascript const url = 'https://api.withwrit.com/v1/badge/token.svg'; const options = {method: 'GET'}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api.withwrit.com/v1/badge/token.svg" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api.withwrit.com/v1/badge/token.svg") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api.withwrit.com/v1/badge/token.svg") .asString(); ``` ```php request('GET', 'https://api.withwrit.com/v1/badge/token.svg'); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://api.withwrit.com/v1/badge/token.svg"); var request = new RestRequest(Method.GET); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let request = NSMutableURLRequest(url: NSURL(string: "https://api.withwrit.com/v1/badge/token.svg")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```