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

feat(vault): server-side pinning broker routes

Open
#45 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
54/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
next.js, typescript
Domain
api, backend, security

Research direction

Start by locating the existing /api/vault/pin* and /api/vault/quota/* route handlers, the session authentication and user-scoping code, and the Pinata and Lighthouse service adapters. Then read the route handler tests and run them to understand the current conventions. Done means adding authenticated broker routes for pin, unpin, and quota, with mocked-provider tests for success, auth, size limits, and typed errors that do not leak tokens.

Written by the indexing model from the issue text.

Description

enhancement helia storage tier-2

Summary

Add session-authenticated routes that perform pin, unpin and quota calls to Pinata and Lighthouse on the server, so provider credentials never reach the browser.

Estimated size: M

Motivation

Provider tokens are currently shipped to every browser as NEXT_PUBLIC_* variables.

Current state in this repo

  • services/pinata.ts reads NEXT_PUBLIC_PINATA_JWT and services/lighthouse.ts reads NEXT_PUBLIC_LIGHTHOUSE_KEY in the browser.
  • /api/vault/pin* and /api/vault/quota/* only record audit data; they do not call the providers.

Proposal

  • Add /api/vault/broker/pin, /unpin and /quota route handlers, authenticated with the existing session and scoped to the user.
  • Read credentials from server-only env vars (for example PINATA_JWT, LIGHTHOUSE_API_KEY); choose the provider by request parameter.
  • Enforce a request body size limit and basic rate limiting.
  • Additive only: leave the browser adapters untouched in this PR (they switch over in the follow-up).

Acceptance criteria

  • Unauthenticated requests get 401.
  • A pin, unpin and quota call succeeds through the broker against mocked providers.
  • No provider secret is read from a NEXT_PUBLIC_* variable on the broker path.
  • Errors from the provider are mapped to typed responses without leaking tokens into logs.

Out of scope

  • Switching the browser adapters over (separate issue).
  • New providers.

Dependencies

  • None; can be picked up independently.

Testing plan

  • Route handler tests with mocked provider HTTP; auth and size-limit cases.

Part of #43. Ground rules for the content layer: no secrets in the repo, content-layer failures must never block or discard quantum execution, and tests and docs ship with every PR.

Dominant language
Python
Stars
2
Forks
4
Avg merge
6h 54m
Merged PRs (30d)
7

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No 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 QMeshPy/distributed-quantum

All issues in QMeshPy/distributed-quantum

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.