๐ง Node.js serverless microservices for automating things
MIT License
These are microservices for automating everyday tasks, written in TypeScript/Node.js and deployed to ZEIT.
Endpoint: services.anandchowdhary.now.sh/api
/wikipedia-summary
Returns the introductory text for a search term. Try it โ
Query param | Description | Example |
---|---|---|
q |
Search query | Oswald Labs |
limit |
Max length of summary | 300 |
min |
Minimum length of summary | 8 |
cacheAge |
Seconds to cache for | 86400 |
/github-contributors
Returns an SVG image with profile pictures of contributors of a repository on GitHub. Try it โ
Query param | Description | Example |
---|---|---|
repo |
GitHub repository path | elninotech/uppload |
width |
Profile picture width in pixels | 85 |
itemsPerLine |
Number of pictures per line | 8 |
padding |
Padding between pictures in pixels | 5 |
cacheAge |
Seconds to cache for | 86400 |
/github-members
Returns an SVG image with profile pictures of members of a repository on GitHub. Try it โ
Query param | Description | Example |
---|---|---|
org |
GitHub organization name | elninotech |
width |
Profile picture width in pixels | 85 |
itemsPerLine |
Number of pictures per line | 8 |
padding |
Padding between pictures in pixels | 5 |
cacheAge |
Seconds to cache for | 86400 |
/github-files
Returns a Shields.io schema for a badge with the number of files in a GitHub repository's directory. Try it โ
Query param | Description | Example |
---|---|---|
repo |
GitHub repository path | elninotech/uppload |
path |
Directory path | src/i18n |
add 1
|
Add to number of files | 0 |
subtract 1
|
Subtract from number of files | 1 |
label |
Shield label | i18n |
message 2
|
Shield message | $1$ language$S$ |
color |
Shield color | blueviolet |
cacheAge |
Seconds to cache for | 3600 |
These endpoints are used as webhooks for a cron job, and fetch data from various web services' APIs and update my Life Data GitHub repo.
Endpoint | Description | File |
---|---|---|
/spotify |
My top artists data from Spotify | top-artists.yml |
/wakatime |
My programming data from Wakatime | development.yml |
/owntracks |
My real-time location from OwnTracks | location.json |
/yoga |
My heart rate from HealthKit | heart-rate.yml |
/yoga |
My step count from HealthKit | step-count.yml |
/yoga |
My flights climbed from HealthKit | flights-climbed.yml |
/yoga |
My distance from HealthKit | distance.yml |
/yoga |
My active energy from HealthKit | active-energy.yml |
/yoga |
My basal energy from HealthKit | basal-energy.yml |
/instagram-highlights |
My story highlights from Instagram | instagram-highlights.json |
/pocket-casts |
My podcasts list from Pocket Casts | podcasts.yml |
/pocket-casts |
My listening history from Pocket Casts | podcast-history.yml |
/gmail |
My email summary from Gmail | emails.yml |
Several secret keys are required to run these services, particularly my private access tokens for third-party services.
.env
file.now.json
using Now Secretssecrets.gpg
, using the public key public.asc
(also on OpenPGP)