Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Support x402 v1 402s (requirements in the body, X-PAYMENT header)

クローズ
#14 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

@franciscorodr26 がすでに取り組んでいます。

2026年10月7日 から。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
56/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
typescript
領域
payments

調査の方向性

Start by reading the x402 response parsing and payment-header handling, then inspect test/real-merchants.test.ts for the existing v2 fixtures and tests. Add tests for the captured v1 responses and verify opt-in parsing, strict rejection of unknown keys, v1 payment headers, and refusal of a wrong payee or higher price before signing; the issue does not name the implementation files.

索引モデルが issue の本文から書いたものです。

説明

enhancement good first issue

Why

Some live merchants on Base still speak x402 v1: the requirements come only in the JSON body (x402Version: 1, network: "base", maxAmountRequired) and they expect an X-PAYMENT header back. Seen on 2026-10-07: Neynar, SLAMai (CryptoSlam) and Browserbase. Today the SDK refuses these 402s (no PAYMENT-REQUIRED header).

What

  • Opt-in v1 compatibility (policy.acceptV1: true): parse the v1 body into the same PaymentRequirements shape (map base → eip155:8453, maxAmountRequired → amount), then run exactly the same policy checks.
  • Send the payment as v1 X-PAYMENT for those merchants; read the receipt from X-PAYMENT-RESPONSE (already supported).
  • Strict schemas as for v2; unknown keys rejected.

Acceptance

  • Unit tests with the captured v1 402s (see test/real-merchants.test.ts for the v2 ones).
  • A v1 402 asking for a different payee or a higher price is refused before signing, same as v2.
主要言語
TypeScript
スター
0
フォーク
0
平均マージ
3時間 51分
マージ済み PR(30日)
3

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

DeepFirstHQ/deepfirstsearch のほかの issue

DeepFirstHQ/deepfirstsearch の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。