WakaTime already provides you with badges, but I wanted to add custom text to the badge and access my other data for future use. That's why I created this custom API. Feel free to use it to make your own badges!
- Get Your API Token: Obtain your API token from WakaTime.
- Host the Code: Download and host this code on Railway or any other hosting platform.
- Set Environment Variable: Add an environment variable
ACCESS_TOKEN
with your WakaTime API token.
- Go to shields.io: Navigate to shields.io.
- Dynamic JSON Badge: Select "Dynamic JSON Badge".
- Insert API Link: Use your API link in the URL query.
- Label and JSONPath: Add a label name and use JSONPath to extract the data you want from the API.
Now you can create customized badges with personalized text and data directly from your WakaTime API!