-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
replace core file with usage examples
- Loading branch information
1 parent
0e248f4
commit 6315fae
Showing
4 changed files
with
42 additions
and
7 deletions.
There are no files selected for viewing
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
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
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
(ns hibp-client.examples | ||
(:require [hibp-client.pwned-password :as pwned-password] | ||
[hibp-client.breach :as breach] | ||
[hibp-client.paste :as paste])) | ||
|
||
(defn -main [& args] | ||
|
||
;; Checking if a password is pwned | ||
(println (pwned-password/pwned? "12345")) | ||
;; => true | ||
|
||
;; Getting breaches for a specific account | ||
(println (breach/get-for-account "[email protected]")) | ||
;; => ({:description In approximately March 2015, the free web hosting prov... | ||
|
||
;; Getting breaches for a specific account, filtering the results | ||
(println (breach/get-for-account "[email protected]" | ||
{:truncate-response true})) | ||
;; => ({:name 000webhost} {:name Adobe} {:name BitcoinTalk} {:name Bitly} {... | ||
|
||
;; Getting all breaches | ||
(println (breach/get-all)) | ||
;; => ({:description In approximately March 2015, the free web hosting prov... | ||
|
||
;; Getting all breaches for a domain | ||
(println (breach/get-all "adobe.com")) | ||
;; => ({:description In October 2013, 153 million Adobe accounts were breac... | ||
|
||
;; Getting a breach by its name | ||
(println (breach/get-for-name "Adobe")) | ||
;; => {:description In October 2013, 153 million Adobe accounts were breach... | ||
|
||
;; Getting all breach data classes | ||
(println (breach/get-data-classes)) | ||
;; => (Account balances Age groups Ages Astrological signs Auth tokens Avat... | ||
|
||
;; Getting all pastes for a specific account | ||
(println (paste/get-for-account "[email protected]"))) | ||
;; => ({:source Pastebin, :id suPshHZ1, :title nil, :date 2017-09-06T03:41:... |