prisma-archive / graphcool-lib

A convenient tool to use in Graphcool functions to make requests against your Graphcool API
33 stars 6 forks source link

Problem with Graphcool initialization #26

Open serverlesspolska opened 6 years ago

serverlesspolska commented 6 years ago

Hi there,

I try to use graphcool-lib in the following way:

const client = Graphcool(gcProjectId, { token: gcToken })
const api = client.api('simple/v1')
api.request(` some graphql query`)

But I get following error: TypeError: Cannot set property 'endpoints' of undefined.

PS. I don't use fromEvent function because I try to connect to my GraphCool db from Lambda function.

What am I doing wrong?