Skip to content

Instantly share code, notes, and snippets.

@azurekid
Last active September 17, 2024 12:06
Show Gist options
  • Save azurekid/67e55cbb51d884f0e250429ff241c300 to your computer and use it in GitHub Desktop.
Save azurekid/67e55cbb51d884f0e250429ff241c300 to your computer and use it in GitHub Desktop.
openapi: 3.0.0
info:
title: HaveIBeenPwned
version: 1.0.0
servers:
- url: https://haveibeenpwned.com/api/v3
paths:
/breachedaccount/{email}:
get:
operationId: HaveIBeenPwned
summary: This path checks if a email address is part of any data breaches from HaveIBeenPwned.
parameters:
- in: path
name: email
schema:
type: string
required: true
- name: User-Agent
in: header
schema:
type: string
default: Default User-Agent
responses:
'200':
description: Successful response
content:
application/json: {}
'400':
description: The account does not comply with an acceptable format
content:
application/json: {}
'401':
description: API Key is missing or invalid
content:
application/json: {}
'403':
description: Unauthorized
content:
application/json: {}
'404':
description: User Not Found in any data breaches
content:
application/json: {}
'429':
description: Rate limit exceeded
content:
application/json: {}
'503':
description: Service unavailable
content:
application/json: {}
default:
description: default
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment