https://www.prisma.io/ logo
Join SlackCommunities
Powered by
# orm-help
  • a

    alec

    06/08/2018, 6:32 PM
    Does anyone know if u it's possible to write a query inside a mutation? Something Like this:
    Copy code
    mutation createBrighten {
      createBrighten(
        senderId: "sdfjhsjdfh83bjsfnbjsdfb"
        receiverId: {
           User(phoneNumber: "2222222222") {
        	  id
      	}
        complimentId: "sdjfdjs7dfbjdfnks9"
        pictureId: "sdkfh7dsfu23urbedd"
      ) {
        id
      } 
    }
  • o

    orange_man

    06/08/2018, 7:36 PM
    how do i secure my prisma endpoint on prisma cloud?
  • o

    orange_man

    06/08/2018, 7:36 PM
    right now anyone can just hit the endpoint and make mutations with playground
  • f

    freethejazz

    06/08/2018, 7:37 PM
    I believe you want to specify a secret in prisma.yml in order to sign JWT tokens. Looking for a link to those docs
  • o

    orange_man

    06/08/2018, 7:37 PM
    oh nice, yea that would be great to know
  • f

    freethejazz

    06/08/2018, 7:38 PM
    https://www.prisma.io/docs/reference/service-configuration/prisma.yml/overview-and-example-foatho8aip#example
  • f

    freethejazz

    06/08/2018, 7:38 PM
    not a comprehensive description, but an example at least
  • f

    freethejazz

    06/08/2018, 7:38 PM
    might get you a bit further along the path 🙂
  • f

    freethejazz

    06/08/2018, 7:39 PM
    aah here
  • f

    freethejazz

    06/08/2018, 7:39 PM
    https://www.prisma.io/docs/reference/service-configuration/prisma.yml/yaml-structure-ufeshusai8#secret-(optional)
  • o

    orange_man

    06/08/2018, 7:39 PM
    ah! i totally missed this while going thru the docs
  • f

    freethejazz

    06/08/2018, 7:40 PM
    that second link is a lot more descriptive and helpful. Also links to the mechanics of requesting an API token
  • o

    orange_man

    06/08/2018, 7:41 PM
    ok, so i set that in the yml, and the prisma server will autmoatically look for a Authorization header with ‘Bearer jwt….’. if it can decrypt it, then all is good
  • o

    orange_man

    06/08/2018, 7:42 PM
    and on my graphql server, i need to take care of signing a jwt with the same secret
  • f

    freethejazz

    06/08/2018, 7:43 PM
    bingo! found an example here of that: https://www.prisma.io/docs/reference/prisma-api/concepts-utee3eiquo/#api-token
    o
    • 2
    • 5
  • f

    freethejazz

    06/08/2018, 7:43 PM
    search for
    generating a service token
  • j

    Jonathan

    06/08/2018, 7:46 PM
    Are there any up to date docs for integrating graphCool with Auth0? Everything I've found is based on previous versions and doesn't work from what I can tell.
  • o

    orange_man

    06/08/2018, 7:47 PM
    awesome @freethejazz, this is so helpful
    🎉 2
  • f

    freethejazz

    06/08/2018, 7:50 PM
    @Jonathan Not sure about graphcool 😕 . Based on the Prisma docs, it seems like auth is up to the application to do. The Auth0 integration would be handled at the client-facing GraphQL API layer just before delegating to the Prisma Server GraphQL API
    j
    • 2
    • 2
  • j

    Jonathan

    06/08/2018, 8:04 PM
    I've got everything working on the client side. When user logs in they get redirected to the Auth0 login page then are returned with an access token. I just don't understand how to pass the access token to graphCool and add user info such as firstName, lastName, etc.
  • j

    Jonathan

    06/08/2018, 8:06 PM
    I'm getting this message from GraphCool: "Argument 'authProvider' expected type 'AuthProviderSignupData!' and not sure what I need to do
  • n

    nilan

    06/08/2018, 8:06 PM
    Please use threads 🙂
  • j

    Jonathan

    06/08/2018, 8:07 PM
    How do I make a thread?
  • b

    brant

    06/08/2018, 8:08 PM
  • b

    brant

    06/08/2018, 8:08 PM
    hover the message and click the little chat bubble beside the emoji one
    👍 1
    h
    • 2
    • 7
  • b

    brant

    06/08/2018, 8:57 PM
    I don’t know if it’s by design (to let only very motivated ppl in) but the prisma website still links to slack.graph.cool which doesn’t exist
    n
    • 2
    • 5
  • s

    sebstr

    06/08/2018, 9:29 PM
    I've been working on my Prisma DB for a week now, Great fun! 🙂 I need help understanding how to run it in production.. Right now I run it with yarn dev. And if I dont use this the endpoint goes straight to the cluster which is not so good.. How do I run it on my pc in "production mode" ?
    • 1
    • 1
  • b

    brant

    06/08/2018, 10:45 PM
    I have a bit of a weird case: is it possible to store a value as an array of text? it isn’t an array of any other types
  • c

    CHaBou

    06/08/2018, 11:34 PM
    Hi all! I'm building a React (nextjs) app with, for the first time, a graphql (prisma-cloud demo) endpoint... And this is fantastic. Thank you for your hard work. Developper's experience is awesome.
    🙌 2
  • c

    CHaBou

    06/08/2018, 11:38 PM
    What is the best way to debug webhook (Serverside subscription: https://www.prisma.io/docs/reference/server_side-subscriptions/overview-to1ahf0ob6)? I've configured one but nothing happens. And I don't know how to have some log/error to understand my mistake.
    n
    • 2
    • 14
1...525354...637Latest