commercetools / commercetools/nodejs

NodeJS client error code is http statuscode, not commercetools error code

Open
#1,655 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
77
Forks
70
PR merge metrics
No merged PRs in 30d

Description

I believe that since the HTTP statuscode is already available on both error.status and response.statusCode, the field error.code should contain the commercetools error code string, as documented on https://docs.commercetools.com/api/errors.

Contributor guide

Open the contributing guide

Research direction

Read the commercetools API errors documentation first, then inspect the Node.js client error-handling path where error.status, response.statusCode, and error.code are populated. Done means error.code contains the documented commercetools error code while the HTTP status remains available through the existing status fields.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.