Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

`--limit` accepts non-integer values and sends a truncated number

Open Beginner friendly
#423 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@RaphaelFakhri is already working on this.

Since Oct 27, 2026.

  • #424 by @RaphaelFakhri — open

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
85/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript
Domain
cli

Research direction

Start in src/lib/pagination.ts at parseLimitOpt, where the issue says parseInt accepts partial numeric input. Check the existing invalid_limit error handling and run a list command with values such as 2.5 or 25abc against the described test server. Done means invalid values produce an error and exit code 1 without sending a request, while valid integer limits continue to work.

Written by the indexing model from the issue text.

Description

resend <resource> list --limit <n> is parsed with parseInt in src/lib/pagination.ts (parseLimitOpt). parseInt keeps the leading digits and ignores the rest, so non-integer input is not rejected even though the error message says --limit must be an integer between 1 and 100. The command sends a different limit and exits 0.

Steps to reproduce

  1. Start any HTTP server on port 4599 that logs requests and returns {"object":"list","has_more":false,"data":[]}.

  2. Run:

    RESEND_BASE_URL=http://127.0.0.1:4599 RESEND_API_KEY=re_test \
      resend emails list --limit 2.5 --json
    

Expected

invalid_limit error, exit code 1, no request sent.

Actual

The server receives GET /emails?limit=2 and the command exits 0. --limit 25abc sends limit=25 and --limit 1,000 sends limit=1.

This affects every command that uses parseLimitOpt (all list commands and the other paginated commands).

Dominant language
TypeScript
Stars
406
Forks
42
Avg merge
1d 17h
Merged PRs (30d)
19

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from resend/resend-cli

All issues in resend/resend-cli

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.