TritonDataCenter / TritonDataCenter/node-triton
the user-agent for cloudapi requests should differ for `triton` CLI vs lib usage
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 60
- Forks
- 36
- Avg merge
- 3d 8h
- Merged PRs (30d)
- 1
Description
Currently the User-Agent for cloudapi requests from node-triton are set in lib/cloudapi2.js to "triton/$ver ($archInfo; node/$nodever)". That value is the same whether the triton CLI is being used, or if node-triton is being used as a lib. It would help in some cloudapi log analysis if it differed by default.
As well it would be nice if usage as a lib encouraged and facilitated (perhaps even required) that calling code supply a user-agent, or part of the user-agent.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with lib/cloudapi2.js, where node-triton currently sets the cloudapi User-Agent. Trace how requests are made for the triton CLI and library use, then define separate defaults and a way for library callers to provide a User-Agent or supplement it; done means the two usage modes produce distinguishable values and caller customization is supported.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- api, cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100