add poc api settings

This commit is contained in:
Laura Klünder 2024-12-28 15:59:59 +01:00
parent 0f9dcd5722
commit 5efca75f6f
2 changed files with 4 additions and 1 deletions

View file

@ -36,7 +36,7 @@ class Command(BaseCommand):
help = 'import APs from noc'
def handle(self, *args, **options):
r = requests.get(settings.POC_BASE+"antenna-locations")
r = requests.get(settings.POC_BASE+"/antenna-locations", headers={'ApiKey': settings.POC_API_SECRET})
r.raise_for_status()
items = TypeAdapter(list[PocImportItem]).validate_python(r.json())