copies entire Header class in chained_requests test script
This commit is contained in:
@@ -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"):
|
||||
'''
|
||||
|
||||
Reference in New Issue
Block a user