Error message when trying to make the first fake - trade in the course tutorial


I’m struggling to find out why i get this error when trying to duplicate what Ivan does in the episode ( Using Gemini – BUY ORDER - min 8:40).

I’m attaching a screenshot of the powershell error and my atom window. Would hugely appreciate your guys help :slight_smile: image

Hey @Sebastian_xndr, hope you are ok.

Would be great if you share the entire code properly, you can follow this guide to post properly the code:

Carlos Z

Hello @thecil, hope your doing well too,

here the preformatted code and thx for sharing the info!


const GeminiAPI = require("gemini-api").default;
const secret = "3YQwQr1CEgQSCFicmcPpSNoSfUtJ"
const key = "WtfpmzWgmVD1M3NrUGaL"
const restClient = new GeminiAPI({key,secret,sandbox:true});

.then(response => console.log(response));


PS C:\Users\sebas\Documents\Ivan on Tech_Programming\Java 101> node index.js
          triggerUncaughtException(err, true /* fromPromise */);

[UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "#<Object>".] {
  code: ←[32m'ERR_UNHANDLED_REJECTION'←[39m
PS C:\Users\sebas\Documents\Ivan on Tech_Programming\Java 101>

have a good day


1 Like

Alright just figured it out: I simply didn’t have my Gemini - account verified for the device and was therefore not able to place orders.

1 Like

Also you have an error in your key, which should start with account-

const key = "account-someNumbers";

Then, try with this function syntax:

    .then(_res => {

Sorry for the delay man, hope this helps you.

Carlos Z

1 Like