nodeSolidServer / nodeSolidServer/node-solid-server

User Registration problems via JSON

オープン
#1,023 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

revisit
主要言語
JavaScript
スター
1.8k
フォーク
308
PR マージ指標
30日以内にマージされた PR はありません

説明

I want to be able to register users through the solid server api via the /api/accounts/new endpoint. Using python I could do the following:

import requests

data = {
    'email': '...valid email',
    'username': '...valid username',
    'name': '...valid name',
    'password': '...valid password'
}
url = 'https://mysolidserver.com/api/accounts/new'
response = requests.post(url, data=data)
print(response.status_code) # which is 401

I am given a status code of 401 since I'm redirected to the username.mysolidserver.com page. This is awkward API UX since I'm expecting a confirmation response, probably in JSON with a status code in the 200's. Moreover, if I set headers={'Content-Type': 'application/json'} in the request, I am given an error claiming that the username is not valid.

Fortunately if the registration doesn't work, I'm given a status code of 400, so I can use this fact right now in my app.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

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

調査の方向性

まず、フォームデータと application/json を使って /api/accounts/new への POST リクエストを再現し、リダイレクト、ステータスコード、レスポンスボディを確認します。有効な登録が 2xx ステータスの有用な JSON 成功レスポンスを受け取り、無効な登録が引き続き適切なエラーレスポンスを返すようになれば、変更は完了です。

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

評価

技術スタック
javascript, nodejs
領域
api, authentication, backend
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

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

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