interledger / interledger/open-payments-node
Make createAuthenticatedClient's `privateKey` input type clear
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 10
- Forks
- 4
- Avg merge
- 27m
- Merged PRs (30d)
- 3
Description
In open-payments package README and in lack of JSDoc comments, it's not clear what goes in privateKey parameter of createAuthenticatedClient function.
So far, I've seen people writing:
- path to key (passes, as expected)
- a string in
-----BEGIN PRIVATE KEYformat (fails) - a base64 encoded string (fails)
Buffer.from(base64PrivateKeyString, 'base64')(passes)
If we can write more examples (in README as well as JSDoc) and/or restrict TypeScript types, that would be very helpful. Throwing any errors earlier would be helpful too.
Contributor guide
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 the open-payments package README and the createAuthenticatedClient entry point. Confirm the accepted privateKey representations and decide whether the change is documentation, JSDoc, TypeScript typing, or early validation. Done means the accepted input is stated consistently with examples and any chosen behavior is covered.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, typescript
- Domain
- api, documentation
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 38/100