{"openapi":"3.1.0","info":{"version":"1.0.0","title":"Ops.Tools API","description":"Call the Ops.Tools API from your own code; every charged call uses your workspace's Ops.Tools credits.\n\n**Authentication.** Create an API key in your workspace (Settings → API keys) and send it as the `x-api-key` header. A `read` key lists and reads; a `write` key also makes changes, like a workspace member; an `admin` key can do everything its owner can. Every call acts on the workspace of the key. Guide: https://api.ops.tools/developers/auth.md\n\n**Errors.** Failures answer `{ \"error\": \"UPPER_SNAKE_CODE\", \"message\": \"...\" }` with the HTTP status; validation errors add `issues`. `402 INSUFFICIENT_CREDITS` means the credits are used up; `429` means slow down (see the `ratelimit-*` headers).\n\n**Ids** are UUIDv7 strings; times are ISO 8601 UTC.\n\n## AI Agents (MCP)\n\nThis API is also available as a hosted [MCP](https://modelcontextprotocol.io) server for AI agents at `https://mcp.ops.tools/mcp` — Streamable HTTP (JSON-RPC 2.0), authenticated with the same `x-api-key` header and scoped to the key's workspace. API catalog: `https://api.ops.tools/.well-known/api-catalog`."},"servers":[{"url":"https://api.ops.tools","description":"Ops.Tools"}],"components":{"schemas":{"BadRequestError":{"type":"object","properties":{"error":{"type":"string","example":"VALIDATION_ERROR","description":"Error code identifier"},"message":{"type":"string","example":"Invalid request parameters","description":"Human-readable error message"}},"required":["error","message"]},"UnauthorizedError":{"type":"object","properties":{"error":{"type":"string","example":"AUTHENTICATION_REQUIRED","description":"Error code"},"message":{"type":"string","example":"Authentication token is required","description":"Error message"}},"required":["error","message"]},"ForbiddenError":{"type":"object","properties":{"error":{"type":"string","example":"ACCESS_DENIED","description":"Error code"},"message":{"type":"string","example":"You do not have permission to perform this action","description":"Error message"}},"required":["error","message"]},"NotFoundError":{"type":"object","properties":{"error":{"type":"string","example":"NOT_FOUND","description":"Error code"},"message":{"type":"string","example":"The requested resource was not found","description":"Error message"}},"required":["error","message"]},"TooManyRequestsError":{"type":"object","properties":{"error":{"type":"string","example":"RATE_LIMIT_EXCEEDED","description":"Error code"},"message":{"type":"string","example":"Too many requests, please try again later","description":"Error message"}},"required":["error","message"]},"InternalServerError":{"type":"object","properties":{"error":{"type":"string","example":"INTERNAL_SERVER_ERROR","description":"Error code"},"message":{"type":"string","example":"An unexpected error occurred","description":"Error message"}},"required":["error","message"]},"ServiceUnavailableError":{"type":"object","properties":{"error":{"type":"string","example":"AUTHENTICATION_UNAVAILABLE","description":"Error code"},"message":{"type":"string","example":"Service temporarily unavailable","description":"Error message"}},"required":["error","message"]},"PaginationMeta":{"type":"object","properties":{"page":{"type":"integer","minimum":1},"limit":{"type":"integer","minimum":1,"maximum":200},"total":{"type":"integer","minimum":0},"totalPages":{"type":"integer","minimum":0},"hasNext":{"type":"boolean"},"hasPrev":{"type":"boolean"}},"required":["page","limit","total","totalPages","hasNext","hasPrev"]},"WalletBrandDomain":{"type":"string","enum":["any.xyz","phone-check.app","email-check.app","ip-info.app","ops.tools","currency-exchange.app"],"description":"Brand domain of the wallet (each product brand keeps its own credits, plans and Stripe customer)","example":"phone-check.app"},"CreditUsageDailyListResponse":{"type":"object","properties":{"daily":{"type":"array","items":{"$ref":"#/components/schemas/CreditUsageDailyModel"}},"pagination":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["daily","pagination"]},"CreditUsageDailyModel":{"type":"object","properties":{"_id":{"type":"string","format":"uuid","example":"018f6b1c-7e2a-7000-9d3e-4a5b6c7d8e9f","description":"UUID v7 identifier (36-character string)"},"workspaceId":{"type":"string","format":"uuid","example":"018f6b1c-7e2a-7000-9d3e-4a5b6c7d8e9f","description":"UUID v7 identifier (36-character string)"},"brandDomain":{"$ref":"#/components/schemas/WalletBrandDomain"},"userId":{"type":"string","format":"uuid","example":"018f6b1c-7e2a-7000-9d3e-4a5b6c7d8e9f","description":"UUID v7 identifier (36-character string)"},"service":{"type":"string","description":"Product service that consumed credits (e.g., \"phone-details\", \"email-check-details\")","example":"phone-details"},"date":{"type":"string","description":"Date in YYYY-MM-DD format","example":"2026-01-20"},"creditsUsed":{"type":"number","description":"Total credits consumed on this date","example":150},"requestCount":{"type":"number","description":"Number of requests made on this date","example":25},"metadata":{"type":"object","additionalProperties":{}},"systemUpdatedAt":{"type":"string","format":"date-time","example":"2025-01-01T12:00:00.000Z","description":"When the platform last changed this record on its own (a job, a sweep, a webhook, a sync); absent when it never has."}},"required":["_id","workspaceId","brandDomain","userId","service","date","creditsUsed","requestCount"]},"CreditUsageBreakdownResponse":{"type":"object","properties":{"workspaceId":{"type":"string","format":"uuid","example":"018f6b1c-7e2a-7000-9d3e-4a5b6c7d8e9f","description":"UUID v7 identifier (36-character string)"},"groupBy":{"type":"array","items":{"type":"string","enum":["date","user","api-key","service"]}},"totals":{"type":"object","properties":{"credits":{"type":"number","description":"Credits consumed in this slice."},"requests":{"type":"number","description":"Charged requests in this slice."}},"required":["credits","requests"]},"groups":{"type":"array","items":{"type":"object","properties":{"date":{"type":["string","null"],"description":"Usage day (YYYY-MM-DD, UTC).","example":"2026-07-01"},"userId":{"type":["string","null"],"format":"uuid","description":"Workspace member the usage attributes to (null when not grouped by user)."},"apiKeyId":{"type":["string","null"],"format":"uuid","description":"API key that made the calls (null for signed-in calls, or when not grouped by API key)."},"service":{"type":["string","null"],"description":"Product service that consumed credits.","example":"phone-details"},"credits":{"type":"number","description":"Credits consumed in this slice."},"requests":{"type":"number","description":"Charged requests in this slice."}},"required":["date","userId","apiKeyId","service","credits","requests"]}}},"required":["workspaceId","groupBy","totals","groups"]},"InsufficientCreditsError":{"type":"object","properties":{"error":{"type":"string","enum":["INSUFFICIENT_CREDITS"],"description":"Error code"},"message":{"type":"string","example":"No credits left: add credits or a plan under Billing","description":"Error message"}},"required":["error","message"]},"OpsDnsLookupResponse":{"type":"object","properties":{"success":{"type":"boolean","description":"The resolvers answered (no data counts as success, with no records).","example":true},"address":{"type":"string","description":"The host looked up.","example":"example.com"},"type":{"type":"string","enum":["A","AAAA","CNAME","MX","NAPTR","NS","PTR","SOA","SRV","TXT","ANY"],"example":"MX"},"records":{"type":"array","items":{},"description":"The records in the resolver's shape for the type (A/AAAA `{ address, family }`, MX `{ priority, exchange }`, TXT string arrays, SOA one object, …).","example":[{"priority":10,"exchange":"mail.example.com"}]},"error":{"type":"object","properties":{"code":{"type":"string","example":"ENOTFOUND"},"message":{"type":"string"}},"required":["code"],"description":"The resolver's failure."}},"required":["success","address","type"]},"OpsWhoisResponse":{"type":"object","properties":{"domain":{"type":"string","description":"The domain looked up.","example":"example.com"},"whoisText":{"type":"string","description":"The registry's WHOIS answer; `Lookup failed` when the registry did not answer."},"whoisJson":{"type":"object","properties":{"domainName":{"type":"string"},"isAvailable":{"type":"boolean","description":"The registry answered that the domain is not registered."},"isValid":{"type":"boolean","description":"`false` when no answer could be read."},"registryDomainId":{"type":"string"},"registrarWhoisServer":{"type":"string"},"registrar":{"type":"string"},"registrarUrl":{"type":"string"},"registrarIanaId":{"type":"string"},"registrarAbuseContactEmail":{"type":"string"},"registrarAbuseContactPhone":{"type":"string"},"updatedDate":{"type":["string","null"],"description":"ISO 8601 UTC."},"creationDate":{"type":["string","null"],"description":"ISO 8601 UTC."},"expirationDate":{"type":["string","null"],"description":"ISO 8601 UTC."},"status":{"type":"array","items":{"type":"string"}},"dnssec":{"type":"string"},"nameServers":{"type":"array","items":{"type":"string"}}},"description":"The answer read into fields (with `parseWhoisToJson`)."}},"required":["domain","whoisText"]},"OpsSslCheckResponse":{"type":"object","properties":{"domain":{"type":"string","example":"example.com"},"port":{"type":"number","example":443},"certificate":{"$ref":"#/components/schemas/SslCertificate"},"protocols":{"type":"array","items":{"type":"string"},"example":["TLSv1.2","TLSv1.3"]},"cipherSuite":{"type":"string","description":"Cipher suite the handshake agreed.","example":"TLS_AES_128_GCM_SHA256"}},"required":["domain","port","certificate"]},"SslCertificate":{"type":"object","properties":{"subject":{"type":"string","description":"Common name (or organization) the certificate is for.","example":"example.com"},"issuer":{"type":"string","description":"Issuing organization and country.","example":"Let's Encrypt, US"},"validFrom":{"type":"string","description":"ISO 8601 UTC.","example":"2026-10-01T00:00:00.000Z"},"validTo":{"type":"string","description":"ISO 8601 UTC.","example":"2026-12-30T23:59:59.000Z"},"daysRemaining":{"type":"number","example":34},"isValid":{"type":"boolean","description":"Today is within the validity window."},"isExpired":{"type":"boolean"},"isSelfSigned":{"type":"boolean"},"serialNumber":{"type":"string"},"fingerprint":{"type":"string","description":"SHA-1 fingerprint."},"keySize":{"type":"number","description":"Key size, bits.","example":2048},"subjectAltNames":{"type":"array","items":{"type":"string"},"description":"DNS names the certificate covers.","example":["example.com","www.example.com"]}},"required":["subject","issuer","validFrom","validTo","daysRemaining","isValid","isExpired","isSelfSigned"],"description":"The certificate presented; `Unknown` and invalid when the server did not complete a handshake."},"OpsHttpAnalyzeResponse":{"type":"object","properties":{"url":{"type":"string","description":"The URL analyzed.","example":"https://example.com/"},"finalUrl":{"type":"string","description":"Where the redirects ended.","example":"https://www.example.com/"},"statusCode":{"type":"number","description":"HTTP status of the final response; 0 when the URL could not be fetched.","example":200},"timestamp":{"type":"string","description":"When it was analyzed (ISO 8601 UTC).","example":"2026-11-26T19:05:04.158Z"},"scanDurationMs":{"type":"number","example":142},"redirectChain":{"type":"array","items":{"type":"string"},"description":"The URL asked for, when it redirected.","example":["https://example.com/"]},"rawHeaders":{"type":"object","additionalProperties":{"type":"string"},"description":"The final response headers, lowercased."},"analysis":{"$ref":"#/components/schemas/HttpAnalysis"},"summary":{"type":"object","properties":{"overallGrade":{"type":"string","example":"C"},"keyRecommendations":{"type":"array","items":{"type":"string"}}},"required":["overallGrade","keyRecommendations"]},"error":{"type":"string","description":"Why the URL could not be fetched.","example":"Failed to fetch URL"}},"required":["url","finalUrl","statusCode","timestamp","scanDurationMs","rawHeaders","analysis","summary"]},"HttpAnalysis":{"type":"object","properties":{"security":{"type":"object","properties":{"grade":{"type":"string","description":"A+ … F from the security headers.","example":"B"},"score":{"type":"number","description":"0..100.","example":81},"headers":{"type":"object","additionalProperties":{"$ref":"#/components/schemas/HttpHeaderAnalysis"},"description":"Each security header (HSTS, CSP, X-Frame-Options, …) by name."},"missingHeaders":{"type":"array","items":{"type":"string"}},"issues":{"type":"array","items":{"type":"string"}}},"required":["grade","score","headers","missingHeaders","issues"]},"performance":{"type":"object","properties":{"score":{"type":"number","description":"0..100.","example":85},"insights":{"type":"object","properties":{"caching":{"type":"object","properties":{"cacheControl":{"$ref":"#/components/schemas/HttpHeaderAnalysis"},"expires":{"$ref":"#/components/schemas/HttpHeaderAnalysis"},"etag":{"type":"object","properties":{"present":{"type":"boolean"},"status":{"type":"string","enum":["good","warning","missing"]}},"required":["present","status"]}}},"compression":{"type":"object","properties":{"contentEncoding":{"type":"object","properties":{"present":{"type":"boolean"},"value":{"type":"string"},"status":{"type":"string","enum":["good","warning","missing"]},"recommendation":{"type":"string"}},"required":["present","status"]}}},"other":{"type":"object","properties":{"keepAlive":{"type":"boolean"},"protocol":{"type":"string"},"recommendation":{"type":"string"}},"required":["keepAlive"]}},"required":["caching","compression","other"]},"issues":{"type":"array","items":{"type":"string"}}},"required":["score","insights","issues"]},"general":{"type":"object","properties":{"serverInfo":{"type":"object","properties":{"server":{"type":"string"},"status":{"type":"string","enum":["good","warning"]},"recommendation":{"type":"string"}},"required":["status"]},"contentType":{"type":"string"},"cors":{"type":"object","properties":{"allowOrigin":{"type":"string"},"status":{"type":"string","enum":["good","warning","missing"]},"recommendation":{"type":"string"}}},"cookies":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"secure":{"type":"boolean"},"httpOnly":{"type":"boolean"},"sameSite":{"type":"string","enum":["Strict","Lax","None"]},"status":{"type":"string","enum":["good","warning"]}},"required":["name","secure","httpOnly","status"]},"description":"Each `set-cookie` and its flags."}},"required":["serverInfo"]}},"required":["security","performance","general"]},"HttpHeaderAnalysis":{"type":"object","properties":{"present":{"type":"boolean"},"value":{"type":"string"},"status":{"type":"string","enum":["good","warning","missing","bad"]},"recommendation":{"type":"string"}},"required":["present","status"]},"OpsPortScanResponse":{"type":"object","properties":{"target":{"type":"string","description":"The host or IPv4 address scanned.","example":"example.com"},"ip":{"type":"string","description":"The address the scan connected to.","example":"93.184.215.14"},"scanId":{"type":"string","example":"ps-1795719905374-05e454"},"timestamp":{"type":"string","description":"When it was scanned (ISO 8601 UTC).","example":"2026-11-26T19:05:05.374Z"},"scanDurationMs":{"type":"number","example":41},"ports":{"type":"array","items":{"$ref":"#/components/schemas/OpsPortScanPort"}},"summary":{"type":"object","properties":{"totalScanned":{"type":"number"},"open":{"type":"number"},"closed":{"type":"number"},"filtered":{"type":"number"}},"required":["totalScanned","open","closed","filtered"]},"error":{"type":"string","description":"Why nothing was scanned.","example":"Failed to resolve hostname or IP"}},"required":["target","scanId","timestamp","scanDurationMs","ports","summary"]},"OpsPortScanPort":{"type":"object","properties":{"port":{"type":"number","example":443},"protocol":{"type":"string","enum":["tcp","udp"]},"state":{"type":"string","enum":["open","closed","filtered"],"description":"`filtered`: no answer within the timeout."},"service":{"type":"string","description":"Usual service of the port.","example":"https"},"banner":{"type":"string"},"tlsVersion":{"type":"string","example":"TLSv1.3"},"cipherSuite":{"type":"string","example":"TLS_AES_256_GCM_SHA384"},"certificate":{"type":"object","properties":{"subject":{"type":"string"},"issuer":{"type":"string"},"expires":{"type":"string"},"valid":{"type":"boolean"}},"required":["subject","issuer","expires","valid"],"description":"The certificate an open HTTPS port presents."},"responseTimeMs":{"type":"number"}},"required":["port","protocol","state","service"]},"OpsEmailAuthResponse":{"type":"object","properties":{"domain":{"type":"string","example":"example.com"},"spf":{"type":"object","properties":{"exists":{"type":"boolean"},"record":{"type":"object","properties":{"version":{"type":"string","enum":["spf1"]},"raw":{"type":"string","example":"v=spf1 include:_spf.google.com -all"},"mechanisms":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"`include`, `a`, `mx`, `ip4`, `ip6`, `ptr`, `exists` or `all`.","example":"include"},"qualifier":{"type":"string","description":"`+` pass, `-` fail, `~` soft fail, `?` neutral.","example":"+"},"value":{"type":"string","example":"_spf.google.com"}},"required":["type","qualifier"]}},"all":{"type":"string","description":"The closing `all` with its qualifier.","example":"-all"},"redirect":{"type":"string","description":"The `redirect=` domain."},"includeCount":{"type":"number","example":1},"lookupCount":{"type":"number","description":"DNS lookups an evaluation makes, includes followed (more than 10 is a permanent error).","example":4}},"required":["version","raw","mechanisms","includeCount","lookupCount"]},"errors":{"type":"array","items":{"type":"string"},"description":"What makes the record fail or weak; empty when it is fine.","example":[]}},"required":["exists","errors"],"description":"The `v=spf1` TXT record of the domain."},"dmarc":{"type":"object","properties":{"exists":{"type":"boolean"},"record":{"type":"object","properties":{"version":{"type":"string","enum":["DMARC1"]},"raw":{"type":"string","example":"v=DMARC1; p=reject; rua=mailto:dmarc@example.com"},"policy":{"type":"string","enum":["none","quarantine","reject"]},"subdomainPolicy":{"type":"string","enum":["none","quarantine","reject"],"description":"`sp`, else the policy."},"percentage":{"type":"number","description":"`pct`: the share of mail the policy applies to.","example":100},"rua":{"type":"array","items":{"type":"string"},"description":"Aggregate report addresses.","example":["dmarc@example.com"]},"ruf":{"type":"array","items":{"type":"string"},"description":"Forensic report addresses."},"adkim":{"type":"string","enum":["relaxed","strict"],"description":"DKIM alignment."},"aspf":{"type":"string","enum":["relaxed","strict"],"description":"SPF alignment."}},"required":["version","raw","percentage","rua","ruf","adkim","aspf"]},"errors":{"type":"array","items":{"type":"string"},"description":"What makes the record fail or weak; empty when it is fine.","example":[]}},"required":["exists","errors"],"description":"The `v=DMARC1` TXT record at `_dmarc.<domain>`."},"dkim":{"type":"object","properties":{"records":{"type":"array","items":{"type":"object","properties":{"selector":{"type":"string","example":"google"},"version":{"type":"string","example":"DKIM1"},"keyType":{"type":"string","example":"rsa"},"publicKey":{"type":"string","description":"The base64 key (`p=`); empty when revoked."},"revoked":{"type":"boolean","description":"`p=` is empty: the key was withdrawn."}},"required":["selector","version","keyType","publicKey","revoked"]}},"selectors":{"type":"array","items":{"type":"string"},"description":"Every selector checked: the common ones and `dkimSelectors`."},"errors":{"type":"array","items":{"type":"string"},"description":"What makes the record fail or weak; empty when it is fine.","example":[]}},"required":["records","selectors","errors"],"description":"The DKIM keys at `<selector>._domainkey.<domain>`."},"overallScore":{"type":"number","description":"0..100: SPF 30, DMARC 40, DKIM 30.","example":100},"grade":{"type":"string","description":"A+ … F from the score.","example":"A+"},"recommendations":{"type":"array","items":{"type":"string"},"description":"What to change, most important first."},"scanDurationMs":{"type":"number","example":120}},"required":["domain","spf","dmarc","dkim","overallScore","grade","recommendations","scanDurationMs"]}},"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-api-key","description":"API Key authentication using the `x-api-key` header."}}},"paths":{"/credit-usage/daily/list":{"get":{"summary":"List the credits used per day","description":"List the credits the request brand's wallets used per day.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"integer","exclusiveMinimum":0,"default":1,"example":1,"description":"Page number for pagination"},"required":false,"description":"Page number for pagination","name":"page","in":"query"},{"schema":{"type":"integer","exclusiveMinimum":0,"maximum":1000,"default":20,"example":200,"description":"Number of rows per page (max 1000, `CREDIT_USAGE_DAILY_LIST_MAX_LIMIT`): 90 days of usage in one request"},"required":false,"description":"Number of rows per page (max 1000, `CREDIT_USAGE_DAILY_LIST_MAX_LIMIT`): 90 days of usage in one request","name":"limit","in":"query"},{"schema":{"type":"string","description":"Filter by specific daily credit usage row IDs (comma-separated UUID v7)","example":"018f6b1c-7e2a-7000-9d3e-4a5b6c7d8e8f,018f6b1c-7e2a-7000-9d3e-4a5b6c7d8e8f"},"required":false,"description":"Filter by specific daily credit usage row IDs (comma-separated UUID v7)","name":"ids","in":"query"},{"schema":{"type":"string","format":"uuid","example":"018f6b1c-7e2a-7000-9d3e-000000000011","description":"Filter by specific workspace ID"},"required":false,"description":"Filter by specific workspace ID","name":"workspaceId","in":"query"},{"schema":{"type":"string","example":"phone-details","description":"Filter by service name (exact match)"},"required":false,"description":"Filter by service name (exact match)","name":"service","in":"query"},{"schema":{"type":"string","example":"2026-01-01","description":"Filter records from this date onwards (YYYY-MM-DD format)"},"required":false,"description":"Filter records from this date onwards (YYYY-MM-DD format)","name":"dateFrom","in":"query"},{"schema":{"type":"string","example":"2026-01-31","description":"Filter records up to this date (YYYY-MM-DD format)"},"required":false,"description":"Filter records up to this date (YYYY-MM-DD format)","name":"dateTo","in":"query"},{"schema":{"type":"string","enum":["date","creditsUsed","requestCount"],"default":"date","example":"date","description":"Field to sort by. Rows carry no timestamps, so the newest day first is the default."},"required":false,"description":"Field to sort by. Rows carry no timestamps, so the newest day first is the default.","name":"sortBy","in":"query"},{"schema":{"type":"string","enum":["asc","desc"],"default":"desc","example":"desc","description":"Sort order"},"required":false,"description":"Sort order","name":"sortOrder","in":"query"}],"responses":{"200":{"description":"Credit usage records retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditUsageDailyListResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/credit-usage/breakdown":{"get":{"summary":"Get credit usage breakdown","description":"Credits the request brand's wallet used in a date range, grouped by date, member, API key or service.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uuid","example":"018f6b1c-7e2a-7000-9d3e-000000000011","description":"Workspace to report usage for (required)."},"required":true,"description":"Workspace to report usage for (required).","name":"workspaceId","in":"query"},{"schema":{"type":"string","description":"From this day (inclusive, YYYY-MM-DD).","example":"2026-07-01"},"required":false,"description":"From this day (inclusive, YYYY-MM-DD).","name":"dateFrom","in":"query"},{"schema":{"type":"string","description":"To this day (inclusive, YYYY-MM-DD).","example":"2026-07-31"},"required":false,"description":"To this day (inclusive, YYYY-MM-DD).","name":"dateTo","in":"query"},{"schema":{"type":"string","default":["service"],"description":"Dimensions to group usage by (comma-separated subset of date / user / api-key / service).","example":"api-key,service"},"required":false,"description":"Dimensions to group usage by (comma-separated subset of date / user / api-key / service).","name":"groupBy","in":"query"}],"responses":{"200":{"description":"Credits used by the request brand wallet, grouped by the requested dimension(s), highest-credit first.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditUsageBreakdownResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/ops/dns-lookup":{"get":{"summary":"Look up DNS records","description":"Resolve the `type` records (A, AAAA, CNAME, MX, NAPTR, NS, PTR, SOA, SRV, TXT, ANY) of the host in `address` through public resolvers; costs 1 credit, and an internal name (`localhost`, a single label, `.local`, `.internal`, a private reverse zone) answers 400 `TARGET_NOT_PUBLIC` for free.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","minLength":1,"maxLength":2048,"description":"Domain or URL whose host to resolve.","example":"example.com"},"required":true,"description":"Domain or URL whose host to resolve.","name":"address","in":"query"},{"schema":{"type":"string","enum":["A","AAAA","CNAME","MX","NAPTR","NS","PTR","SOA","SRV","TXT","ANY"],"default":"A","description":"Record type.","example":"MX"},"required":false,"description":"Record type.","name":"type","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Read fresh instead of the cached answer."},"required":false,"description":"Read fresh instead of the cached answer.","name":"skipCache","in":"query"},{"schema":{"type":["integer","null"],"minimum":0,"maximum":180,"default":180,"description":"How long the answer may be cached, seconds (up to the configured cache time).","example":180},"required":false,"description":"How long the answer may be cached, seconds (up to the configured cache time).","name":"cacheTimeSeconds","in":"query"}],"responses":{"200":{"description":"The records resolved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpsDnsLookupResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"402":{"description":"The API key's workspace has no credits left on this brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsufficientCreditsError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/ops/whois":{"get":{"summary":"Look up WHOIS registration data","description":"Fetch the registry's WHOIS answer for `domain` (registrar, dates, name servers, statuses; read into fields with `parseWhoisToJson`); costs 1 credit, and an IP address or an internal name answers 400 `INVALID_DOMAIN` for free.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","minLength":1,"description":"Domain (or a URL of it).","example":"example.com"},"required":true,"description":"Domain (or a URL of it).","name":"domain","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Also read the answer into fields (`whoisJson`)."},"required":false,"description":"Also read the answer into fields (`whoisJson`).","name":"parseWhoisToJson","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Read fresh instead of the cached answer."},"required":false,"description":"Read fresh instead of the cached answer.","name":"skipCache","in":"query"},{"schema":{"type":["integer","null"],"minimum":0,"maximum":300,"default":300,"description":"How long the answer may be cached, seconds (up to the configured cache time).","example":300},"required":false,"description":"How long the answer may be cached, seconds (up to the configured cache time).","name":"cacheTimeSeconds","in":"query"}],"responses":{"200":{"description":"The WHOIS answer","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpsWhoisResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"402":{"description":"The API key's workspace has no credits left on this brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsufficientCreditsError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/ops/ssl-check":{"get":{"summary":"Check a domain's TLS certificate","description":"Read the TLS certificate `domain` presents on `port` (public addresses only): validity, days remaining, issuer, names and key; costs 1 credit, and a private target answers 400 `TARGET_NOT_PUBLIC`, a domain that does not resolve 400 `TARGET_UNRESOLVED`, both for free.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","minLength":1,"maxLength":253,"pattern":"^(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\\.)+[a-z0-9][a-z0-9-]{0,61}[a-z0-9]$/i","description":"Domain name; it must resolve to a public address.","example":"example.com"},"required":true,"description":"Domain name; it must resolve to a public address.","name":"domain","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":65535,"default":443,"description":"TLS port.","example":443},"required":false,"description":"TLS port.","name":"port","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Read fresh instead of the cached answer."},"required":false,"description":"Read fresh instead of the cached answer.","name":"skipCache","in":"query"}],"responses":{"200":{"description":"The certificate checked","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpsSslCheckResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"402":{"description":"The API key's workspace has no credits left on this brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsufficientCreditsError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/ops/http-analyze":{"get":{"summary":"Analyze a URL's HTTP response","description":"Fetch `url` (public addresses only) and grade its security headers, caching, compression, cookies and CORS; costs 1 credit, and a private target answers 400 `TARGET_NOT_PUBLIC` for free.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","format":"uri","description":"The http(s) URL to analyze; it must resolve to a public address.","example":"https://example.com"},"required":true,"description":"The http(s) URL to analyze; it must resolve to a public address.","name":"url","in":"query"},{"schema":{"type":"boolean","default":true,"description":"Follow redirects (each hop must be public too)."},"required":false,"description":"Follow redirects (each hop must be public too).","name":"followRedirects","in":"query"},{"schema":{"type":"integer","minimum":1000,"maximum":60000,"description":"Request timeout, milliseconds.","example":10000},"required":false,"description":"Request timeout, milliseconds.","name":"timeout","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Read fresh instead of the cached answer."},"required":false,"description":"Read fresh instead of the cached answer.","name":"skipCache","in":"query"}],"responses":{"200":{"description":"The response analyzed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpsHttpAnalyzeResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"402":{"description":"The API key's workspace has no credits left on this brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsufficientCreditsError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/ops/port-scan":{"get":{"summary":"Scan TCP ports of a host","description":"Scan `ports` of `target` (public addresses only; scan only hosts you may test) and report each as open, closed or filtered with its TLS details; costs 1 credit, and a private target answers 400 `TARGET_NOT_PUBLIC` for free.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","minLength":1,"maxLength":253,"pattern":"^([a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,}|(\\d{1,3}\\.){3}\\d{1,3}$","description":"Hostname or IPv4 address; it must resolve to a public address.","example":"example.com"},"required":true,"description":"Hostname or IPv4 address; it must resolve to a public address.","name":"target","in":"query"},{"schema":{"type":"string","description":"Ports to scan, comma-separated: at most 20 distinct ports (repeats count once); 80 and 443 when omitted.","example":"80,443"},"required":false,"description":"Ports to scan, comma-separated: at most 20 distinct ports (repeats count once); 80 and 443 when omitted.","name":"ports","in":"query"},{"schema":{"type":"integer","minimum":500,"maximum":30000,"default":2500,"description":"Per-port timeout, milliseconds.","example":2500},"required":false,"description":"Per-port timeout, milliseconds.","name":"timeout","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Read fresh instead of the cached answer."},"required":false,"description":"Read fresh instead of the cached answer.","name":"skipCache","in":"query"}],"responses":{"200":{"description":"The ports scanned","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpsPortScanResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"402":{"description":"The API key's workspace has no credits left on this brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsufficientCreditsError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}},"/ops/email-auth":{"get":{"summary":"Grade a domain's email authentication","description":"Read the SPF (with its 10-lookup limit), DMARC and DKIM records of `domain` (the common DKIM selectors plus `dkimSelectors`) and grade them A+ to F with recommendations; costs 1 credit, and an internal name answers 400 `TARGET_NOT_PUBLIC` for free.","security":[{"ApiKeyAuth":[]}],"parameters":[{"schema":{"type":"string","minLength":1,"maxLength":253,"pattern":"^(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\\.)+[a-z0-9][a-z0-9-]{0,61}[a-z0-9]$/i","description":"The domain mail is sent from.","example":"example.com"},"required":true,"description":"The domain mail is sent from.","name":"domain","in":"query"},{"schema":{"type":"string","description":"DKIM selectors to check besides the common ones (comma-separated, 10 at most).","example":"google,s2048"},"required":false,"description":"DKIM selectors to check besides the common ones (comma-separated, 10 at most).","name":"dkimSelectors","in":"query"},{"schema":{"type":"boolean","default":false,"description":"Read fresh instead of the cached answer."},"required":false,"description":"Read fresh instead of the cached answer.","name":"skipCache","in":"query"}],"responses":{"200":{"description":"The email authentication records graded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpsEmailAuthResponse"}}}},"400":{"description":"Bad request - Invalid input parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BadRequestError"}}}},"401":{"description":"Authentication required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"402":{"description":"The API key's workspace has no credits left on this brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InsufficientCreditsError"}}}},"403":{"description":"Access denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenError"}}}},"404":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFoundError"}}}},"429":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsError"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerError"}}}},"503":{"description":"The request could not be checked or served right now. It says nothing about the request; send it again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceUnavailableError"}}}}}}}},"webhooks":{}}