Comments (11)
@M8874 once you deploy your project on VERCEL, you use your project's domain URL, https://spotify-readme-ten-omega.vercel.app/
, to reference it in your GITHUB profile homepage README.md
like this:
<a href="https://github.com/tthn0/Spotify-Readme">
<img src="https://spotify-readme-ten-omega.vercel.app/api" alt="Current Spotify Song">
</a>
and that's pretty much it. if you still have problems send me or anyone else who's helping you a separate message because these errors are not related to project bugs, rather personal errors.
so please mark this issue as closed or resolved.
hope these steps were able to resolve your issue.
from spotify-readme.
@M8874 add me on Discord, sventripikal
, and i will help you through there. but mark this issue as closed please.
from spotify-readme.
Hello @M8874,
Please do not share your Client Secret to the public, even in its Base64 encoded form. I just edited your response to redact it. I recommend that you to regenerate it before trying again. The issue here is that you wrapped curly braces around your Base64 encoded string. Please remove those before making your curl
request, and it should work fine. Refer to this example below:
Correct:
-H "Authorization: Basic qJiLwViEYlyviJcMfscrxSuyBFEOkytAsCoonBqzNORhKEtTmEfBTuXOZOZcApyiwXlvvQvSIJfCndZiH="
Incorrect:
-H "Authorization: Basic {qJiLwViEYlyviJcMfscrxSuyBFEOkytAsCoonBqzNORhKEtTmEfBTuXOZOZcApyiwXlvvQvSIJfCndZiH=}"
Additionally, it seems like you mistakenly put a [
as well as a )
in the string for the -d
flag in your request. Of course, replace {CODE}
(yes, also replace the curly braces) with its respective value, just like with the -H
flag above.
Correct:
-d "grant_type=authorization_code&redirect_uri=http://localhost/callback/&code={CODE}"
Incorrect:
-d "grant_type=authorization_code&redirect_uri[=http://localhost/callback/&code={CODE)"
from spotify-readme.
Thank you for the response. In the example there, I changed 9 characters, don't worry about security.
from spotify-readme.
Thank you very much @tthn0. I fixed the code, but now I have a new error. I don't know why it occurred, but I've already checked everything. As far as I understand, the error is with the indicator
{"error": "invalid_client", "error_description": "Invalid client"}
curl \
-X POST \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Authorization: Basic e2MzMmVlMjgxZDc1gyg5NDVlODhiZGNkYjEyMjhhhTE0NzJjjNDIzN2Ez7MGY0ODc1OGJiMzN9" \
-d "grant_type=authorization_code&redirect_uri=http://localhost/callback/&code=AQA33N-LHY0Y6eW3CJ702_5DtncKsSKXWv7VffgfggertgL3Ws3sgaDhu9uomJhqZxjXVMV9lQlZGhnAORjStOdWuPxhvvoe-_GJr6C9cGocpcCs2SI0u3Au4x3MCmWUlmW4O6oh_b_MUjTu_3ls7Zi58neoGj587xarCpDfXqddeWAX6ydDflKnRIVYaP_RZ-zZte_tExgHUM" \
https://accounts.spotify.com/api/token
from spotify-readme.
@M8874 For your -H
flag that represents authorization, are you sure you encoded your {CLIENT_ID}:{CLIENT_SECRET}
correctly? Usually the encoded string should end with an equal sign.
from spotify-readme.
Hello @tthn0, thanks for your help. I seem to be useless; I can't even complete such a simple task. 😉
from spotify-readme.
I apologize for such a request; I understand that your time is valuable, and I may be bothering you unnecessarily. Could you please write to me on Telegram at @?
I just want to understand what I'm doing wrong. I want to add a widget to my web portfolio. Currently, there is a widget that is not mine at https://magical-lokum-134348.netlify.app/.
from spotify-readme.
@M8874 I do not use Telegram unfortunately. Are you on Discord? You may add me there; my username is tthn
.
from spotify-readme.
@M8874 hello, I just had the same issue but it happened to be that the CALLBACK_CODE that is embedded in the URL when you apply this step https://accounts.spotify.com/authorize?client_id={CLIENT_ID}&response_type=code&scope=user-read-currently-playing,user-read-recently-played&redirect_uri=http://localhost/callback/
actually expires after some time & returning to that step before running the terminal script helped since it gave me a different code to add to the -d &code=
. not sure when it actually expires but after redoing that step the script returns the JSON object with the REFRESH_TOKEN you need. hope this helps.
from spotify-readme.
@SVENTRIPIKAL Hello, thanks for your help. I received the REFRESH_TOKEN, but I still can't get anything to work. https://spotify-readme-ten-omega.vercel.app/
from spotify-readme.
Related Issues (20)
- [Request] Link to redirect to current song HOT 3
- Recently played section HOT 3
- 404 error when deploying HOT 2
- 500 Internal Server Error on /api HOT 1
- caching access tokens HOT 3
- Deployment Issue "This Serverless Function has crashed" HOT 3
- Deployment Error: 404: NOT_FOUND and ImportModuleError: Unable to import module 'vc__handler__python HOT 2
- 404 error HOT 1
- 500 ERROR - Unable to import module 'vc__handler__python' HOT 6
- [Request] Auto refresh on next song HOT 1
- Getting HTTP error code 500 after deployment HOT 1
- Images HOT 2
- help HOT 4
- This Serverless Function has crashed. HOT 1
- Vercel functions crash HOT 2
- I am getting an Error 404 HOT 10
- Vercel deployment error HOT 1
- Interesting issue with svg load on hover in Firefox
- Previews HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spotify-readme.