feat(todoist): add app, authentication, docs (#826)

This commit is contained in:
Ian Levesque
2023-01-07 09:09:39 -05:00
committed by GitHub
parent ff0bde059a
commit 1a4a1f7f8b
19 changed files with 418 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
import { TBeforeRequest } from '@automatisch/types';
const addAuthHeader: TBeforeRequest = ($, requestConfig) => {
if ($.auth.data?.apiToken) {
const authorizationHeader = `Bearer ${$.auth.data.apiToken}`;
requestConfig.headers.Authorization = authorizationHeader;
}
return requestConfig;
};
export default addAuthHeader;