I hosted the REST API on Vercel, configured the environment variable, everything is fine! But every time I try to search for a letter, I get this issue:
<br />
<b>Fatal error</b>: Uncaught Error: Call to undefined function SpotifyLyricsApi\curl_init() in /var/task/user/src/Spotify.php:37
Stack trace:
#0 /var/task/user/src/Spotify.php(74): SpotifyLyricsApi\Spotify->getToken()
#1 /var/task/user/api/index.php(27): SpotifyLyricsApi\Spotify->checkTokenExpire()
#2 {main}
thrown in <b>/var/task/user/src/Spotify.php</b> on line <b>37</b><br />
Would you know what this could be or how to fix it? Also, I don't know if it's related, but when I started the build, a warning message appeared in the console.
Warning: PHP Startup: Unable to load dynamic library 'mongodb' (tried: /vercel/path0/.vercel/builders/node_modules/@libphp/amazon-linux-2-v82/native/php/modules/mongodb (/vercel/path0/.vercel/builders/node_modules/@libphp/amazon-linux-2-v82/native/php/modules/mongodb: cannot open shared object file: No such file or directory), /vercel/path0/.vercel/builders/node_modules/@libphp/amazon-linux-2-v82/native/php/modules/mongodb.so (libutf8proc.so.1: cannot open shared object file: No such file or directory)) in Unknown on line
14:36:56.952 | Warning: PHP Startup: Unable to load dynamic library 'swoole' (tried: /vercel/path0/.vercel/builders/node_modules/@libphp/amazon-linux-2-v82/native/php/modules/swoole (/vercel/path0/.vercel/builders/node_modules/@libphp/amazon-linux-2-v82/native/php/modules/swoole: cannot open shared object file: No such file or directory), /vercel/path0/.vercel/builders/node_modules/@libphp/amazon-linux-2-v82/native/php/modules/swoole.so (libodbc.so.2: cannot open shared object file: No such file or directory)) in Unknown on line 0
Hi,
The issue should be resolved with the commit 38bc05d3ee841452a4cc03a00eba15453fa61ae2. My apologies for the error, and I appreciate your patience. Delete the olddeployment and proceed with re-deploying the project from start. To re-deploy you can click on the below button.
I hosted the REST API on Vercel, configured the environment variable, everything is fine! But every time I try to search for a letter, I get this issue:
Would you know what this could be or how to fix it? Also, I don't know if it's related, but when I started the build, a warning message appeared in the console.