When to use API? When to use the workflow? #98
-
What is the difference between using the API and using the workflow? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hi, @thenithinbalaji . TL;DR: In the profile-detail card, the API only calculates the contributions in the last year, and the workflow calculates all contributions since the user created the account. But the other cards don't have any difference in both ways. And the behavior might change in the future, and we are looking for another way to make API calculate all contributions. We deploy the API service on Vercel, and Vercel has a maximum execution timeout of 10 seconds when deployed on a Personal Account (Hobby plan). It easily exceeds timeout when we fetch all contributions from GitHub GraphQL API for most users, so we only calculate the few data in API. |
Beta Was this translation helpful? Give feedback.
Hi, @thenithinbalaji .
TL;DR: In the profile-detail card, the API only calculates the contributions in the last year, and the workflow calculates all contributions since the user created the account. But the other cards don't have any difference in both ways. And the behavior might change in the future, and we are looking for another way to make API calculate all contributions.
We deploy the API service on Vercel, and Vercel has a maximum execution timeout of 10 seconds when deployed on a Personal Account (Hobby plan). It easily exceeds timeout when we fetch all contributions from GitHub GraphQL API for most users, so we only calculate the few data in API.
If possible, currently, I recomm…