Skip to content

Instantly share code, notes, and snippets.

@nagornyi
Created May 27, 2022 07:10
class TestRailAPI {
constructor(domain, username, apikey) {
this.base_url = `${domain}/index.php?`;
this.auth = Buffer.from(`${username}:${apikey}`).toString('base64');
this.headers = {
'Content-Type': 'application/json',
Authorization: `Basic ${this.auth}`
};
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment