import { IRequestConfig } from 'angular' ; const SYSTEM_REQUEST_HEADER_NAME = 'osd-system-request' ; const LEGACY_SYSTEM_API_HEADER_NAME = 'osd-system-api' ; param originalHeaders return export function addSystemApiHeader ( originalHeaders ) { const systemApiHeaders = { [ SYSTEM_REQUEST_HEADER_NAME ] : true , } ; return { ... originalHeaders , ... systemApiHeaders , } ; } param request return export function isSystemApiRequest ( request ) { const { headers } = request ; return ( headers && ( ! ! headers [ SYSTEM_REQUEST_HEADER_NAME ] || ! ! headers [ LEGACY_SYSTEM_API_HEADER_NAME ] ) ) ; }