
* feat(carbone): add carbone integration * Update list-apps.spec.js to ensure Carbone is the first application in the alphabetically sorted list Previously, the test expected DeepL to be the first in the list. Now, this change ensures that Carbone will take precedence as it will come first in the alphabetical order.
13 lines
334 B
TypeScript
13 lines
334 B
TypeScript
import { TBeforeRequest } from '@automatisch/types';
|
|
|
|
const addAuthHeader: TBeforeRequest = ($, requestConfig) => {
|
|
if ($.auth.data?.apiKey) {
|
|
requestConfig.headers.Authorization = `Bearer ${$.auth.data.apiKey}`;
|
|
requestConfig.headers['carbone-version'] = '4';
|
|
}
|
|
|
|
return requestConfig;
|
|
};
|
|
|
|
export default addAuthHeader;
|