Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

445
Views
Cannot send a responce to Etsy API v3 (Quick Start Tutorial)

Attempting to follow Etsys Open API v3 quick start tutorial (https://developers.etsy.com/documentation/tutorials/quickstart) I have encountered an error where the request I am making to Etsy is being considered a 400 bad request. My implementation thus far is as follows.

I have successfully obtained an API keystring (not requesting full access) and made a successful ping request to return my application id as shown in the tutorial.

Using the provided code generator.js script, I have been able to generate a code challenge, verifier, and URL.

I have then taken this full URL and pasted it as the href in the index.hbs.

Attempting to implement the redirect_uri route (in server.js) I have set the ClientID to the API keystring given by Etsy and set the clientVerifier as the code challenge returned from the code-generator.js script.

I have also accessed my app on Etsy and added http://localhost:3003/oauth/redirect (and https://api.etsy.com/v3/public/oauth/token) as callback URL’s.

The rest of the code I left untouched. Using node server.js I can js and visit http://localhost:3003, click authenticate with Etsy, and am met with ‘oops’

From my node terminal I can see the following 400 error suggesting the request was incorrect:

Response {
  size: 0,
  timeout: 0,
  [Symbol(Body internals)]: {
    body: PassThrough {
      _readableState: [ReadableState],
      _events: [Object: null prototype],
      _eventsCount: 5,
      _maxListeners: undefined,
      _writableState: [WritableState],
      allowHalfOpen: true,
      [Symbol(kCapture)]: false,
      [Symbol(kCallback)]: null
    },
    disturbed: false,
    error: null
  },
  [Symbol(Response internals)]: {
    url: 'https://api.etsy.com/v3/public/oauth/token',
    status: 400,
    statusText: 'Bad Request',
    headers: Headers { [Symbol(map)]: [Object: null prototype] },
    counter: 0
  }
}

I appreciate it is not always wise to copy paste code but considering this is a quick start tutorial I believed I would be fine. Unfortunately not...

I simply want the email address of the member who owns the app (or any other data as this is purely for testing purposes) to be returned as JSON.

I would appreciate it if anyone who has successfully got through this tutorial (or could scan through my attempt) could let me know my stupid mistake. Alternatively, if anyone knows any reasonable tutorials on how to make a request to an API that would work in this case that would be appreciated too.

TLDR: API request 400 error, pls help

Cheers, CF

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

There's often a response body being streamed back to you, as well as the basic 400 response, that would contain a detailed error message. In my experience, Etsy's servers are pretty good at returning a meaningful error message such as "missing x-api-key" or "access token has expired" etc. I'd suggest you read the response stream and log or print it somehow. You don't show your code, but the fact that you seem to have logged the Response object itself tells me you haven't read response data stream from it. You've also not shared the code you used to make the request, there are many http client libraries you could be using.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!