misp-galaxy/tools/tidal-api/api/api.py
2024-02-21 16:24:48 +01:00

15 lines
374 B
Python

import requests
class TidalAPI:
def __init__(self):
self.base_url = 'https://app-api.tidalcyber.com/api/v1/'
def get_data(self, endpoint):
url = self.base_url + endpoint
try:
response = requests.get(url)
return response.json()
except Exception as e:
print(f'Error: {e}')
return None