diff --git a/typescript/formsApps.d.ts b/typescript/formsApps.d.ts index a5d63bc5..ce40aab9 100644 --- a/typescript/formsApps.d.ts +++ b/typescript/formsApps.d.ts @@ -373,6 +373,16 @@ type _NewFormsApp = { }> /** Google analytics tag id */ googleAnalyticsTagId?: string + /** + * OAuth2 authentication settings for the forms app. + * + * If `forceOAuthAuthentication` is `true`, all users will be required to + * authenticate via the OAuth2 provider specified in `integrationProviderId`. + */ + oAuth2Authentication?: { + integrationProviderId: string + forceOAuthAuthentication?: boolean + } } export type NewVolunteersFormsApp = _NewFormsApp & { diff --git a/typescript/integrations.d.ts b/typescript/integrations.d.ts index 1658459f..fee0df16 100644 --- a/typescript/integrations.d.ts +++ b/typescript/integrations.d.ts @@ -18,6 +18,7 @@ export type IntegrationType = | 'NYLAS' | 'SHAREPOINT' | 'CIVIC_REC' + | 'OAUTH_2' type IntegrationBase = { organisationId: string @@ -302,6 +303,22 @@ export type IntegrationCivicRec = IntegrationBase & { } } +export type IntegrationOAuth2Provider = { + id: string + label: string + clientId: string + clientSecret: ConstrainedSecret + attributeRequestMethod: 'GET' | 'POST' + issuerURL: string +} + +export type IntegrationOAuth2 = IntegrationBase & { + type: 'OAUTH_2' + configuration: { + providers: IntegrationOAuth2Provider[] + } +} + export type DeleteIntegrationValidationResults = { forms: Array<{ formId: number @@ -338,3 +355,4 @@ export type Integration = | IntegrationNylas | IntegrationSharepoint | IntegrationCivicRec + | IntegrationOAuth2