A function wraps the genius.com API.
BaseURL: https://genius-function.vercel.app/api
Example: https://genius-function.vercel.app/api/artists?id=1985
id
ID of the artist
format
Format for text bodies related to the document, One or more of dom
, plain
, and html
, separated by commas
, defaults to plain
Example: https://genius-function.vercel.app/api/referents?id=2842074
id
ID of the referent, only support song_id
format
Format for text bodies related to the document, One or more of dom
, plain
, and html
, separated by commas
, defaults to plain
per_page
Number of results, defaults to 10
page
Paginated offset, defaults to 1
Example: https://genius-function.vercel.app/api/search?q=frank%20ocean
q
The term to search for
Example: https://genius-function.vercel.app/api/songs?id=2842074
id
ID of the song
format
Format for text bodies related to the document, One or more of dom
, plain
, and html
, separated by commas
, defaults to plain
-
Get your Genius CLIENT ACCESS TOKEN from Genius
-
Clone, deploy the project
> git clone https://github.com/KusStar/genius-function
> cd genius-function
> yarn deploy
vercel --prod
- Set up the
ACCESS_TOKEN
to the Environment Variables of your project settings