magicLink service init

i have this error when i want to use the MagicLink Service instanciation object : DOMAIN_ORIGIN: window.location ? window.location.origin : ‘’,
^
ReferenceError: window is not defined
at new ce (C:\clubMetadev3\web-nft-client\backend\node_modules@magic-sdk\provider\src\core\sdk.ts:162:22)
at Object. (C:\clubMetadev3\web-nft-client\backend\src\common\magic.service.ts:8:15)
at Module._compile (node:internal/modules/cjs/loader:1126:14)
at Object.Module._extensions…js (node:internal/modules/cjs/loader:1180:10)
at Module.load (node:internal/modules/cjs/loader:1004:32)
at Function.Module._load (node:internal/modules/cjs/loader:839:12)
at Module.require (node:internal/modules/cjs/loader:1028:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object. (C:\clubMetadev3\web-nft-client\backend\src\common\constant.ts:5:1) at Module._compile (node:internal/modules/cjs/loader:1126:14)

is there any solution to this problem ?