From 67bfd75de1396cddce6d3e8a7be6787c111c6847 Mon Sep 17 00:00:00 2001 From: Alec Jacobs Date: Fri, 3 Jun 2022 09:46:39 -0700 Subject: [PATCH] feat(plugins/pagerduty): add ClientApiDependencies type * have ClientApiConfig join ClientApiDependencies with custom configuration Signed-off-by: Alec Jacobs --- plugins/pagerduty/src/api/types.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/plugins/pagerduty/src/api/types.ts b/plugins/pagerduty/src/api/types.ts index e747fd40fe..4f80d39816 100644 --- a/plugins/pagerduty/src/api/types.ts +++ b/plugins/pagerduty/src/api/types.ts @@ -81,12 +81,15 @@ export type OnCallsResponse = { oncalls: OnCall[]; }; -export type ClientApiConfig = { - eventsBaseUrl?: string; +export type ClientApiDependencies = { discoveryApi: DiscoveryApi; fetchApi: FetchApi; }; +export type ClientApiConfig = ClientApiDependencies & { + eventsBaseUrl?: string; +}; + export type RequestOptions = { method: string; headers: HeadersInit;