From 352a223d95d06b6170f73768d622ed69dd007cd22a22b6413b1a11b0afdfc5ac Mon Sep 17 00:00:00 2001 From: PioApocalypse Date: Mon, 9 Feb 2026 16:53:16 +0100 Subject: [PATCH] copies entire Header class in chained_requests test script --- tests/chained_requests.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/tests/chained_requests.py b/tests/chained_requests.py index 4fe49bd..23fe802 100644 --- a/tests/chained_requests.py +++ b/tests/chained_requests.py @@ -1,6 +1,15 @@ import os, json, requests from getpass import getpass -from classes import Header + +class Header: + ''' + Class to standardize the format of the headers of our http requests. + ''' + def __init__(self, apikey=""): + '''Init method, apikey suggested but not required (empty by default).''' + self.auth = {"Authorization" : apikey} + self.content = {"Content-Type" : "application/json"} + self.dump = {**self.auth, **self.content} def get_entry_from_elabid(elabid, entryType="items"): '''