{"openapi":"3.1.0","info":{"title":"Spearhead API","version":"0.2.0","description":"Read-only, non-custodial private-market valuation intelligence API. methodology_version=v0.2.0, dataset_version=2026-06-14. Every data response carries a meta object with data_mode, provenance, methodology_version, dataset_version, as_of, and disclaimer.","contact":{"name":"Spearhead API","url":"https://pegasusthreesixty.com/developers"},"license":{"name":"Commercial - see terms","url":"https://pegasusthreesixty.com/legal/terms"},"termsOfService":"https://pegasusthreesixty.com/legal/terms"},"servers":[{"url":"https://api.pegasusthreesixty.com","description":"production"}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-Key"}},"schemas":{"ProblemDetail":{"type":"object","required":["type","title","status","detail","instance","code","request_id"],"properties":{"type":{"type":"string"},"title":{"type":"string"},"status":{"type":"integer"},"detail":{"type":"string"},"instance":{"type":"string"},"code":{"type":"string"},"request_id":{"type":"string"}}},"Meta":{"type":"object","required":["data_mode","provenance","methodology_version","dataset_version","as_of","disclaimer"],"properties":{"data_mode":{"type":"string","enum":["illustrative","live"]},"provenance":{"type":"string","enum":["backtest","live"]},"methodology_version":{"type":"string"},"dataset_version":{"type":"string"},"as_of":{"type":"string"},"disclaimer":{"type":"string"}}},"CompaniesResponse":{"type":"object","required":["meta","companies","page"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"companies":{"type":"array","items":{"$ref":"#/components/schemas/CompanyListItem"}},"page":{"$ref":"#/components/schemas/PageInfo"},"universe_note":{"type":"string"}}},"CompanyProfileResponse":{"type":"object","required":["meta","slug","name"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"slug":{"type":"string"},"name":{"type":"string"},"latest_mark":{"$ref":"#/components/schemas/MarkPoint"},"observations":{"type":"array","items":{"type":"object"}}}},"MarkSeriesResponse":{"type":"object","required":["meta","slug","coverage","series"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"slug":{"type":"string"},"coverage":{"type":"integer","enum":[80,95]},"series":{"type":"array","items":{"$ref":"#/components/schemas/MarkSeriesPoint"}},"events":{"type":"array","items":{"type":"object"}}}},"MarkEventsResponse":{"type":"object","required":["meta","slug","events"],"properties":{"meta":{"$ref":"#/components/schemas/Meta"},"slug":{"type":"string"},"events":{"type":"array","items":{"type":"object"}}}},"SignedResolutionResponse":{"type":"object","required":["slug","value_usd","signature"],"properties":{"slug":{"type":"string"},"value_usd":{"type":"number"},"band_80":{"type":"object"},"band_95":{"type":"object"},"signature":{"type":"string"}}},"UsageResponse":{"type":"object","required":["tier","rate_per_min","limits"],"properties":{"tier":{"type":"string"},"rate_per_min":{"type":"integer"},"limits":{"type":"object"},"scopes":{"type":"array","items":{"type":"string"}}}},"CompanyListItem":{"type":"object","properties":{"slug":{"type":"string"},"name":{"type":"string"},"sector":{"type":"string"},"status":{"type":"string","enum":["private","ipo_completed"]},"latest_mark":{"$ref":"#/components/schemas/MarkPoint"},"delta_30d_pct":{"type":"number","nullable":true}}},"MarkPoint":{"type":"object","properties":{"as_of_date":{"type":"string"},"value_usd":{"type":"number"},"lower_usd":{"type":"number"},"upper_usd":{"type":"number"},"confidence":{"type":"number"}}},"MarkSeriesPoint":{"type":"object","properties":{"date":{"type":"string"},"mark_usd":{"type":"number"},"lower_usd":{"type":"number"},"upper_usd":{"type":"number"}}},"PageInfo":{"type":"object","properties":{"limit":{"type":"integer"},"next_cursor":{"type":"string","nullable":true},"has_more":{"type":"boolean"}}}}},"security":[{"ApiKeyAuth":[]}],"paths":{"/v1/companies":{"get":{"tags":["commercial"],"operationId":"listCompanies","summary":"List the visible company universe","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":200,"default":50}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string","description":"Opaque pagination cursor from a prior response."}},{"name":"sector","in":"query","required":false,"schema":{"type":"string"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["private","ipo_completed"]}},{"name":"sort","in":"query","required":false,"schema":{"type":"string","description":"One of slug, name, value_usd, delta_30d_pct. Prefix - for descending."}},{"name":"If-None-Match","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-ID","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompaniesResponse"}}}},"304":{"description":"Not modified"},"401":{"description":"Authentication required or failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"403":{"description":"Tier not entitled","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"404":{"description":"Resource not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"422":{"description":"Request validation failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}},"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}},"Retry-After":{"schema":{"type":"integer"},"description":"Seconds until retry."}}}},"x-codeSamples":[{"lang":"curl","label":"curl","source":"curl -sS \"https://api.pegasusthreesixty.com/v1/companies?limit=50&sort=-value_usd\" \\\n  -H \"X-API-Key: $SPEARHEAD_API_KEY\" | jq '.meta, .'"},{"lang":"python","label":"Python","source":"import os, requests\n\nr = requests.get(\n    \"https://api.pegasusthreesixty.com/v1/companies?limit=50&sort=-value_usd\",\n    headers={\"X-API-Key\": os.environ[\"SPEARHEAD_API_KEY\"]},\n    timeout=10,\n)\nr.raise_for_status()\nbody = r.json()\nmeta = body[\"meta\"]  # read provenance before trusting a number\nassert meta[\"data_mode\"] in (\"illustrative\", \"live\")\nprint(meta, body)"},{"lang":"javascript","label":"JavaScript","source":"const res = await fetch(\"https://api.pegasusthreesixty.com/v1/companies?limit=50&sort=-value_usd\", {\n  headers: { \"X-API-Key\": process.env.SPEARHEAD_API_KEY },\n});\nif (!res.ok) throw new Error(`HTTP ${res.status}`);\nconst body = await res.json();\nconst { meta } = body;\nconsole.log(meta, body);"},{"lang":"go","label":"Go","source":"req, _ := http.NewRequest(\"GET\", \"https://api.pegasusthreesixty.com/v1/companies?limit=50&sort=-value_usd\", nil)\nreq.Header.Set(\"X-API-Key\", os.Getenv(\"SPEARHEAD_API_KEY\"))\nresp, err := http.DefaultClient.Do(req)\nif err != nil { panic(err) }\ndefer resp.Body.Close()"}]}},"/v1/companies/{slug}":{"get":{"tags":["commercial"],"operationId":"getCompany","summary":"Company valuation profile","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}},{"name":"If-None-Match","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-ID","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyProfileResponse"}}}},"304":{"description":"Not modified"},"401":{"description":"Authentication required or failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"403":{"description":"Tier not entitled","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"404":{"description":"Resource not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"422":{"description":"Request validation failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}},"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}},"Retry-After":{"schema":{"type":"integer"},"description":"Seconds until retry."}}}},"x-codeSamples":[{"lang":"curl","label":"curl","source":"curl -sS \"https://api.pegasusthreesixty.com/v1/companies/coreweave\" \\\n  -H \"X-API-Key: $SPEARHEAD_API_KEY\" | jq '.meta, .'"},{"lang":"python","label":"Python","source":"import os, requests\n\nr = requests.get(\n    \"https://api.pegasusthreesixty.com/v1/companies/coreweave\",\n    headers={\"X-API-Key\": os.environ[\"SPEARHEAD_API_KEY\"]},\n    timeout=10,\n)\nr.raise_for_status()\nbody = r.json()\nmeta = body[\"meta\"]  # read provenance before trusting a number\nassert meta[\"data_mode\"] in (\"illustrative\", \"live\")\nprint(meta, body)"},{"lang":"javascript","label":"JavaScript","source":"const res = await fetch(\"https://api.pegasusthreesixty.com/v1/companies/coreweave\", {\n  headers: { \"X-API-Key\": process.env.SPEARHEAD_API_KEY },\n});\nif (!res.ok) throw new Error(`HTTP ${res.status}`);\nconst body = await res.json();\nconst { meta } = body;\nconsole.log(meta, body);"},{"lang":"go","label":"Go","source":"req, _ := http.NewRequest(\"GET\", \"https://api.pegasusthreesixty.com/v1/companies/coreweave\", nil)\nreq.Header.Set(\"X-API-Key\", os.Getenv(\"SPEARHEAD_API_KEY\"))\nresp, err := http.DefaultClient.Do(req)\nif err != nil { panic(err) }\ndefer resp.Body.Close()"}]}},"/v1/companies/{slug}/marks":{"get":{"tags":["commercial"],"operationId":"getMarkSeries","summary":"Mark time series with intervals","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}},{"name":"coverage","in":"query","required":false,"schema":{"type":"integer","enum":[80,95]}},{"name":"If-None-Match","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-ID","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkSeriesResponse"}}}},"304":{"description":"Not modified"},"401":{"description":"Authentication required or failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"403":{"description":"Tier not entitled","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"404":{"description":"Resource not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"422":{"description":"Request validation failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}},"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}},"Retry-After":{"schema":{"type":"integer"},"description":"Seconds until retry."}}}},"x-codeSamples":[{"lang":"curl","label":"curl","source":"curl -sS \"https://api.pegasusthreesixty.com/v1/companies/coreweave/marks?coverage=80\" \\\n  -H \"X-API-Key: $SPEARHEAD_API_KEY\" | jq '.meta, .'"},{"lang":"python","label":"Python","source":"import os, requests\n\nr = requests.get(\n    \"https://api.pegasusthreesixty.com/v1/companies/coreweave/marks?coverage=80\",\n    headers={\"X-API-Key\": os.environ[\"SPEARHEAD_API_KEY\"]},\n    timeout=10,\n)\nr.raise_for_status()\nbody = r.json()\nmeta = body[\"meta\"]  # read provenance before trusting a number\nassert meta[\"data_mode\"] in (\"illustrative\", \"live\")\nprint(meta, body)"},{"lang":"javascript","label":"JavaScript","source":"const res = await fetch(\"https://api.pegasusthreesixty.com/v1/companies/coreweave/marks?coverage=80\", {\n  headers: { \"X-API-Key\": process.env.SPEARHEAD_API_KEY },\n});\nif (!res.ok) throw new Error(`HTTP ${res.status}`);\nconst body = await res.json();\nconst { meta } = body;\nconsole.log(meta, body);"},{"lang":"go","label":"Go","source":"req, _ := http.NewRequest(\"GET\", \"https://api.pegasusthreesixty.com/v1/companies/coreweave/marks?coverage=80\", nil)\nreq.Header.Set(\"X-API-Key\", os.Getenv(\"SPEARHEAD_API_KEY\"))\nresp, err := http.DefaultClient.Do(req)\nif err != nil { panic(err) }\ndefer resp.Body.Close()"}]}},"/v1/companies/{slug}/events":{"get":{"tags":["commercial"],"operationId":"getMarkEvents","summary":"Mark-event audit trail","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}},{"name":"If-None-Match","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-ID","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarkEventsResponse"}}}},"304":{"description":"Not modified"},"401":{"description":"Authentication required or failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"403":{"description":"Tier not entitled","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"404":{"description":"Resource not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"422":{"description":"Request validation failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}},"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}},"Retry-After":{"schema":{"type":"integer"},"description":"Seconds until retry."}}}},"x-codeSamples":[{"lang":"curl","label":"curl","source":"curl -sS \"https://api.pegasusthreesixty.com/v1/companies/coreweave/events\" \\\n  -H \"X-API-Key: $SPEARHEAD_API_KEY\" | jq '.meta, .'"},{"lang":"python","label":"Python","source":"import os, requests\n\nr = requests.get(\n    \"https://api.pegasusthreesixty.com/v1/companies/coreweave/events\",\n    headers={\"X-API-Key\": os.environ[\"SPEARHEAD_API_KEY\"]},\n    timeout=10,\n)\nr.raise_for_status()\nbody = r.json()\nmeta = body[\"meta\"]  # read provenance before trusting a number\nassert meta[\"data_mode\"] in (\"illustrative\", \"live\")\nprint(meta, body)"},{"lang":"javascript","label":"JavaScript","source":"const res = await fetch(\"https://api.pegasusthreesixty.com/v1/companies/coreweave/events\", {\n  headers: { \"X-API-Key\": process.env.SPEARHEAD_API_KEY },\n});\nif (!res.ok) throw new Error(`HTTP ${res.status}`);\nconst body = await res.json();\nconst { meta } = body;\nconsole.log(meta, body);"},{"lang":"go","label":"Go","source":"req, _ := http.NewRequest(\"GET\", \"https://api.pegasusthreesixty.com/v1/companies/coreweave/events\", nil)\nreq.Header.Set(\"X-API-Key\", os.Getenv(\"SPEARHEAD_API_KEY\"))\nresp, err := http.DefaultClient.Do(req)\nif err != nil { panic(err) }\ndefer resp.Body.Close()"}]}},"/v1/companies/{slug}/resolution":{"get":{"tags":["commercial"],"operationId":"getResolution","summary":"Signed resolution record","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}},{"name":"If-None-Match","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-ID","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignedResolutionResponse"}}}},"304":{"description":"Not modified"},"401":{"description":"Authentication required or failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"403":{"description":"Tier not entitled","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"404":{"description":"Resource not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"422":{"description":"Request validation failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}},"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}},"Retry-After":{"schema":{"type":"integer"},"description":"Seconds until retry."}}}},"x-codeSamples":[{"lang":"curl","label":"curl","source":"curl -sS \"https://api.pegasusthreesixty.com/v1/companies/coreweave/resolution\" \\\n  -H \"X-API-Key: $SPEARHEAD_API_KEY\" | jq '.meta, .'"},{"lang":"python","label":"Python","source":"import os, requests\n\nr = requests.get(\n    \"https://api.pegasusthreesixty.com/v1/companies/coreweave/resolution\",\n    headers={\"X-API-Key\": os.environ[\"SPEARHEAD_API_KEY\"]},\n    timeout=10,\n)\nr.raise_for_status()\nbody = r.json()\nmeta = body[\"meta\"]  # read provenance before trusting a number\nassert meta[\"data_mode\"] in (\"illustrative\", \"live\")\nprint(meta, body)"},{"lang":"javascript","label":"JavaScript","source":"const res = await fetch(\"https://api.pegasusthreesixty.com/v1/companies/coreweave/resolution\", {\n  headers: { \"X-API-Key\": process.env.SPEARHEAD_API_KEY },\n});\nif (!res.ok) throw new Error(`HTTP ${res.status}`);\nconst body = await res.json();\nconst { meta } = body;\nconsole.log(meta, body);"},{"lang":"go","label":"Go","source":"req, _ := http.NewRequest(\"GET\", \"https://api.pegasusthreesixty.com/v1/companies/coreweave/resolution\", nil)\nreq.Header.Set(\"X-API-Key\", os.Getenv(\"SPEARHEAD_API_KEY\"))\nresp, err := http.DefaultClient.Do(req)\nif err != nil { panic(err) }\ndefer resp.Body.Close()"}]}},"/v1/usage":{"get":{"tags":["commercial"],"operationId":"getUsage","summary":"Caller tier, limits, rate budget, and scopes","parameters":[{"name":"If-None-Match","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-ID","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsageResponse"}}}},"304":{"description":"Not modified"},"401":{"description":"Authentication required or failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"403":{"description":"Tier not entitled","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"404":{"description":"Resource not found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"422":{"description":"Request validation failed","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}}},"429":{"description":"Rate limit exceeded","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetail"}}},"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"}},"X-RateLimit-Remaining":{"schema":{"type":"integer"}},"X-RateLimit-Reset":{"schema":{"type":"integer"}},"RateLimit":{"schema":{"type":"string"}},"RateLimit-Policy":{"schema":{"type":"string"}},"ETag":{"schema":{"type":"string"}},"X-Request-ID":{"schema":{"type":"string"}},"Retry-After":{"schema":{"type":"integer"},"description":"Seconds until retry."}}}},"x-codeSamples":[{"lang":"curl","label":"curl","source":"curl -sS \"https://api.pegasusthreesixty.com/v1/usage\" \\\n  -H \"X-API-Key: $SPEARHEAD_API_KEY\" | jq '.meta, .'"},{"lang":"python","label":"Python","source":"import os, requests\n\nr = requests.get(\n    \"https://api.pegasusthreesixty.com/v1/usage\",\n    headers={\"X-API-Key\": os.environ[\"SPEARHEAD_API_KEY\"]},\n    timeout=10,\n)\nr.raise_for_status()\nbody = r.json()\nmeta = body[\"meta\"]  # read provenance before trusting a number\nassert meta[\"data_mode\"] in (\"illustrative\", \"live\")\nprint(meta, body)"},{"lang":"javascript","label":"JavaScript","source":"const res = await fetch(\"https://api.pegasusthreesixty.com/v1/usage\", {\n  headers: { \"X-API-Key\": process.env.SPEARHEAD_API_KEY },\n});\nif (!res.ok) throw new Error(`HTTP ${res.status}`);\nconst body = await res.json();\nconst { meta } = body;\nconsole.log(meta, body);"},{"lang":"go","label":"Go","source":"req, _ := http.NewRequest(\"GET\", \"https://api.pegasusthreesixty.com/v1/usage\", nil)\nreq.Header.Set(\"X-API-Key\", os.Getenv(\"SPEARHEAD_API_KEY\"))\nresp, err := http.DefaultClient.Do(req)\nif err != nil { panic(err) }\ndefer resp.Body.Close()"}]}}}}