in a t3 project, do i use trpc for 3rd party APIs?
for example, i want to use this endpoint for github's api https://docs.github.com/en/rest/metrics/statistics?apiVersion=2022-11-28#get-all-contributor-commit-activity
should i be using trpc & making a router?
GitHub Docs
Repository statistics - GitHub Docs
3 Replies
No you should use https://github.com/octokit/octokit.js
GitHub
GitHub - octokit/octokit.js: The all-batteries-included GitHub SDK ...
The all-batteries-included GitHub SDK for Browsers, Node.js, and Deno. - GitHub - octokit/octokit.js: The all-batteries-included GitHub SDK for Browsers, Node.js, and Deno.
yea, but its not typesafe right?
getting a bunch of unsafe assignment and unsafe construction warnings
Have you tried restarting your TS language server after installing the packages? It can get stuck and not recognize the new types