shift-org / shift-org/shift-docs

More detailed status codes for API responses

Open
#559 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

API backend enhancement
Dominant language
JavaScript
Stars
30
Forks
25
Avg merge
9m
Merged PRs (30d)
1

Description

Most of our API responses are fairly generic — 200 for any successful request, and 400 for any client-based failure. (We might also return 500 for some server errors, not sure offhand.) That's broadly correct, but we could be more detailed to provide better feedback to clients.

Some

  • 201: event is created
  • 401: event secret wasn't provided
  • 403: event secret was provided, but isn't correct
  • 404: event can't be found
  • 413: request is too large (e.g. requested date range is too long)
  • 422: syntax is correct, but semantically invalid (e.g. end date is before start date)
  • 503: service unavailable

Contributor guide

No contributing guide indexed for this repository

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.

Research direction

No files or tests are named. Start by locating the API response handlers and existing response tests, then compare current generic 200/400 behavior with the proposed mappings. Done means the listed success, client-error, and service-unavailable cases return the intended status codes and are covered by tests.

Written by the indexing model from the issue text.

Assessment

Domain
api
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.