TypeError: Invalid URL
at new NodeError (node:internal/errors:393:5)
at URL.onParseError (node:internal/url:565:9)
at new URL (node:internal/url:645:5)
at default_1 (/project/node_modules/near-api-js/lib/utils/setup-node-fetch.js:20:77)
at HTTPClient.DEFAULT_FETCHER [as fetcher] (/project/node_modules/@leonardo-ai/sdk/src/lib/http.ts:18:12)
at HTTPClient.request (/project/node_modules/@leonardo-ai/sdk/src/lib/http.ts:63:30)
at User.do$ (/project/node_modules/@leonardo-ai/sdk/src/lib/sdks.ts:124:42)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at User.getUserSelf (/project/node_modules/@leonardo-ai/sdk/src/sdk/user.ts:83:26)
at Website.generateVideo (/project/src/infinite/libs/website.ts:192:18) {
input: '[object Request]',
code: 'ERR_INVALID_URL'
}
const me = await this.leonardo.user.getUserSelf();
console.log(me);
TypeError: Invalid URL at new NodeError (node:internal/errors:393:5) at URL.onParseError (node:internal/url:565:9) at new URL (node:internal/url:645:5) at default_1 (/project/node_modules/near-api-js/lib/utils/setup-node-fetch.js:20:77) at HTTPClient.DEFAULT_FETCHER [as fetcher] (/project/node_modules/@leonardo-ai/sdk/src/lib/http.ts:18:12) at HTTPClient.request (/project/node_modules/@leonardo-ai/sdk/src/lib/http.ts:63:30) at User.do$ (/project/node_modules/@leonardo-ai/sdk/src/lib/sdks.ts:124:42) at processTicksAndRejections (node:internal/process/task_queues:95:5) at User.getUserSelf (/project/node_modules/@leonardo-ai/sdk/src/sdk/user.ts:83:26) at Website.generateVideo (/project/src/infinite/libs/website.ts:192:18) { input: '[object Request]', code: 'ERR_INVALID_URL' }
or
node v18.12.1 yarn 1.22.19 "@leonardo-ai/sdk": "^4.10.1",