(redirectUrl: string)
| 2 | import { OfferInfo } from './interfaces/types.js'; |
| 3 | |
| 4 | export const generateLoginRedirect = (redirectUrl: string): string => { |
| 5 | const loginRedirectUrl = new URL(ID_LOGIN_ENDPOINT); |
| 6 | loginRedirectUrl.searchParams.set('noHostRedirect', 'true'); |
| 7 | loginRedirectUrl.searchParams.set('redirectUrl', redirectUrl); |
| 8 | loginRedirectUrl.searchParams.set('client_id', EPIC_CLIENT_ID); |
| 9 | return loginRedirectUrl.toString(); |
| 10 | }; |
| 11 | |
| 12 | export const generateCheckoutUrl = (offers: OfferInfo[]): string => { |
| 13 | const offersParams = offers |
no outgoing calls
no test coverage detected