Last active
June 27, 2024 10:42
-
-
Save sheepla/a810c16ac7aaecbbf9e3990bf7ea5413 to your computer and use it in GitHub Desktop.
JSON Schema for HAR: HTTP Archive (not official specification)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"$schema": "http://json-schema.org/draft-07/schema#", | |
"title": "HTTP Archive (HAR) Schema", | |
"type": "object", | |
"properties": { | |
"log": { | |
"type": "object", | |
"properties": { | |
"version": { | |
"type": "string" | |
}, | |
"creator": { | |
"type": "object", | |
"properties": { | |
"name": { | |
"type": "string" | |
}, | |
"version": { | |
"type": "string" | |
}, | |
"comment": { | |
"type": "string" | |
} | |
}, | |
"required": ["name"] | |
}, | |
"pages": { | |
"type": "array", | |
"items": { | |
"type": "object", | |
"properties": { | |
"startedDateTime": { | |
"type": "string", | |
"format": "date-time" | |
}, | |
"id": { | |
"type": "string" | |
}, | |
"title": { | |
"type": "string" | |
}, | |
"pageTimings": { | |
"type": "object", | |
"properties": { | |
"onContentLoad": { | |
"type": "number" | |
}, | |
"onLoad": { | |
"type": "number" | |
} | |
} | |
} | |
}, | |
"required": ["startedDateTime", "id"] | |
} | |
}, | |
"entries": { | |
"type": "array", | |
"items": { | |
"type": "object", | |
"properties": { | |
"startedDateTime": { | |
"type": "string", | |
"format": "date-time" | |
}, | |
"time": { | |
"type": "number" | |
}, | |
"request": { | |
"type": "object", | |
"properties": { | |
"method": { | |
"type": "string" | |
}, | |
"url": { | |
"type": "string", | |
"format": "uri" | |
}, | |
"httpVersion": { | |
"type": "string" | |
}, | |
"headers": { | |
"type": "array", | |
"items": { | |
"type": "object", | |
"properties": { | |
"name": { | |
"type": "string" | |
}, | |
"value": { | |
"type": "string" | |
} | |
}, | |
"required": ["name", "value"] | |
} | |
}, | |
"queryString": { | |
"type": "array", | |
"items": { | |
"type": "object", | |
"properties": { | |
"name": { | |
"type": "string" | |
}, | |
"value": { | |
"type": "string" | |
} | |
}, | |
"required": ["name", "value"] | |
} | |
} | |
}, | |
"required": ["method", "url", "httpVersion"] | |
}, | |
"response": { | |
"type": "object", | |
"properties": { | |
"status": { | |
"type": "number" | |
}, | |
"statusText": { | |
"type": "string" | |
}, | |
"httpVersion": { | |
"type": "string" | |
}, | |
"headers": { | |
"type": "array", | |
"items": { | |
"type": "object", | |
"properties": { | |
"name": { | |
"type": "string" | |
}, | |
"value": { | |
"type": "string" | |
} | |
}, | |
"required": ["name", "value"] | |
} | |
} | |
}, | |
"required": ["status", "statusText", "httpVersion"] | |
}, | |
"cache": { | |
"type": "object", | |
"properties": { | |
"beforeRequest": { | |
"type": "object", | |
"properties": { | |
"lastAccess": { | |
"type": "string", | |
"format": "date-time" | |
}, | |
"eTag": { | |
"type": "string" | |
}, | |
"hitCount": { | |
"type": "number" | |
} | |
} | |
} | |
} | |
}, | |
"timings": { | |
"type": "object", | |
"properties": { | |
"blocked": { | |
"type": "number" | |
}, | |
"dns": { | |
"type": "number" | |
}, | |
"ssl": { | |
"type": "number" | |
}, | |
"connect": { | |
"type": "number" | |
}, | |
"send": { | |
"type": "number" | |
}, | |
"wait": { | |
"type": "number" | |
}, | |
"receive": { | |
"type": "number" | |
} | |
} | |
}, | |
"_initiator": { | |
"type": "object", | |
"properties": { | |
"type": { | |
"type": "string" | |
}, | |
"stack": { | |
"type": "array", | |
"items": { | |
"type": "object", | |
"properties": { | |
"url": { | |
"type": "string" | |
}, | |
"lineNumber": { | |
"type": "integer" | |
}, | |
"columnNumber": { | |
"type": "integer" | |
}, | |
"functionName": { | |
"type": "string" | |
} | |
} | |
} | |
} | |
} | |
} | |
}, | |
"required": ["startedDateTime", "time", "request", "response"] | |
} | |
} | |
}, | |
"required": ["version", "creator", "entries"] | |
} | |
}, | |
"required": ["log"] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment