-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
For Beginners
- Loading branch information
Showing
1 changed file
with
69 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
# MODULES | ||
import requests | ||
from os import system as SYSS | ||
from sys import exit as EXT | ||
|
||
"""main checker""" | ||
class main(object): | ||
|
||
"""untuk mengecheck bin ada atau tidak""" | ||
@classmethod | ||
def check(cls, bins): | ||
if bins == '': | ||
EXT('[!] Bin not found!') | ||
else: | ||
cls.main(bins) | ||
|
||
"""requests data json""" | ||
@classmethod | ||
def main(cls, x): | ||
x = { | ||
'author': 'DR4G0N5', | ||
'url': 'https://bins-su-api.now.sh/api/'+x, | ||
'version': '0.1.1' | ||
} | ||
req = requests.get(x['url']) | ||
requests_json = req.json() | ||
|
||
"""untuk check binnya valid / tidak""" | ||
if requests_json['result'] == 'false': | ||
EXT('[!] Bin Error.') | ||
else: | ||
r = requests_json['data'] | ||
cls.main_check(r, x) | ||
|
||
"""pengeluaran data""" | ||
@classmethod | ||
def main_check(cls, r, xx): | ||
full_data = r | ||
|
||
"""datanya""" | ||
data = { | ||
'Bin': full_data['bin'], | ||
'Vendor': full_data['vendor'], | ||
'Type': full_data['type'], | ||
'Level': full_data['level'], | ||
'Bank': full_data['bank'], | ||
'Country': full_data['country'] | ||
} | ||
print(""" | ||
[+] Author: {} | ||
[+] Version: {}""".format(xx['author'],xx['version'])) | ||
print(""" | ||
[+] Bin: {} | ||
[+] vendor: {} | ||
[+] Type: {} | ||
[+] Level: {} | ||
[+] Bank: {} | ||
[+] Country: {}""".format(data['Bin'], | ||
data['Vendor'], | ||
data['Type'], | ||
data['Level'], | ||
data['Bank'], | ||
data['Country'])) | ||
|
||
if __name__ == '__main__': | ||
|
||
"""pemanggil bin""" | ||
BINS = input('[+] Bin: ') | ||
main.check(BINS) |