https://www.prisma.io/ logo
Join SlackCommunities
Powered by
# prisma-whats-new
  • m

    marika.w

    07/14/2017, 8:44 PM
    Can someone help me with permission query that checks for user role? I'm using the same perm query for Create/Update/Delete, but only Delete works, Create/Update both fail with insufficient permission. Query is this:
    Copy code
    query ($user_id: ID!) {
      SomeUserExists(
        filter: {
          id: $user_id,
          role: ADMIN
        }
      )
    }
    n
    • 2
    • 24
  • c

    cj

    07/14/2017, 9:45 PM
    is there a way to get the user id of who initiated that mutation in a function? I basically want to add a createdBy column to every type and set it in a function (to avoid doing it client side)
    n
    • 2
    • 4
  • p

    peterp

    07/14/2017, 9:46 PM
    can I batch a
    findById
    request?
  • p

    peterp

    07/14/2017, 9:47 PM
    given an array of user emails, can I run ONE query to check them all?
    a
    • 2
    • 4
  • m

    mike.johnson

    07/14/2017, 10:21 PM
    when using a create mutation, how can I supply a custom ID?
    a
    • 2
    • 29
  • c

    cj

    07/14/2017, 10:51 PM
    has anyone used auth0 and managed to get it to work with subscriptions? I'm passing it in the connectionParams: { authToken } but it still thinks I'm not authenticated
    a
    • 2
    • 15
  • t

    teo

    07/14/2017, 10:56 PM
    is there any easy way to provide a user-specific feed of other nodes that changes on queries instead of mutations? right now it seems like the only way to provide something like this is to update the list data for the user type on every mutation
    a
    • 2
    • 10
  • k

    kevinbrown

    07/14/2017, 11:02 PM
    How do you guys handle rate limiting? It occurs to me that someone could build a bot which just sits there and hits my
    graph.cool
    endpoint with a bunch of requests. Two concerns, the first is billing, that’d probably lead to some severe bill shock, and secondly, what protections are in place to stop someone registering a flood of users, etc?
    ❓ 2
    👍🏻 1
    l
    n
    • 3
    • 7
  • k

    kjones

    07/14/2017, 11:23 PM
    I'm trying to test out server side subscriptions in graph.cool and can't seem to get the subscription to trigger. I went and added a new function, selected server side subscription, gave it the
    User
    type, clicked define function and went with the default generated subscription of
    mutation_in: [CREATED, UPDATED, DELETED]
    and the function that just returns
    {data: event.data}
    . If I use the Test Run button the function works as expected, but when I update my user data it still shows 0 invocations and an empty log. I saw in the docs that there's a limitation where subscriptions won't work for the
    File
    type, is there any reason the other system type of
    User
    wouldn't work either?
    ☝️ 1
    ❓ 1
    t
    p
    • 3
    • 4
  • c

    cj

    07/14/2017, 11:41 PM
    shouldn't this
    Create
    permission only allow you to create a
    Customer
    if your authenticated
    User.id
    matches the
    Customer.createdBy.id
    ?
    Copy code
    query ($user_id: ID!) {
      SomeCustomerExists(filter: {
        createdBy: {
          id: $user_id 
        }
      })
    }
    • 1
    • 4
  • e

    enricenrich

    07/14/2017, 11:53 PM
    Does anyone know if it's possible to use Twitter login to create user / sign in without the need of Auth0 on Graphcool?
  • k

    katopz

    07/15/2017, 12:45 AM
    @enricenrich I just start working on it, should be available soon.
    e
    • 2
    • 5
  • m

    max

    07/15/2017, 12:55 AM
    Using React + react-apollo + Graph.cool. Is it possible to store and access variables locally similar to Redux on Apollo since Redux is underneath? I'm new to React + GraphQL.... I'm trying to handle a search string I set in one component and then access it from another. When I use a normal query, it's not refreshing my this.props and using subscribe feels like overkill...thoughts?
    • 1
    • 3
  • a

    auser

    07/15/2017, 1:34 AM
    Should be @enricenrich
  • a

    auser

    07/15/2017, 1:35 AM
    you can probably use a function to handle it
  • a

    auser

    07/15/2017, 1:35 AM
    you’d have to, I mean
  • m

    mike.johnson

    07/15/2017, 2:01 AM
    Forgot my password and now the password reset isn't sending emails ><
  • c

    cj

    07/15/2017, 2:42 AM
    having an issue with scalars and permissions. opened a ticket https://github.com/graphcool/api-bugs/issues/188
  • a

    auser

    07/15/2017, 3:24 AM
    Hm… perhaps I’m misunderstanding permissions, but… I can protect specific fields, right?
  • a

    auser

    07/15/2017, 3:25 AM
    If so, I’m getting a permissions error even when I’m not including those fields in a mutation
    n
    • 2
    • 2
  • h

    hammerspb

    07/15/2017, 4:11 AM
    Hi. I have some issues with getting user with fetchPolicy:'network-only'. When I load component first time - everything is fine. But when I try to refresh it (lets say using
    this.props.history.push('same url')
    ) apollo client doesn't send request to the server. It looks like it gets all data from cache.
    n
    • 2
    • 3
  • d

    dan_groch

    07/15/2017, 8:55 AM
    Hello 👋
  • d

    dan_groch

    07/15/2017, 8:55 AM
    Is it possible to extend the Query type which graphcool bootstraps for a new project?
  • d

    dan_groch

    07/15/2017, 8:56 AM
    If so, how would one go about it? I can't seem to find much guidance in the docs other than using SDL to define your data schema
    n
    • 2
    • 1
  • u

    12brols

    07/15/2017, 2:24 PM
    Hi everyone. I hope you’re having a good weekend.
  • u

    12brols

    07/15/2017, 2:25 PM
    Anyone knows if it’s possible to delete documents based on some filter and not on ID?
    a
    • 2
    • 2
  • i

    ilija

    07/15/2017, 3:09 PM
    Hey guys, got a question. Is it possible to share user data between graphcool projects? Only way i am thinking of is using auth0 (using same client)
    n
    • 2
    • 1
  • f

    frankspin

    07/15/2017, 3:57 PM
    Anyone tried this one out? https://github.com/graphcool-examples/functions/tree/master/auth0-authentication
    n
    • 2
    • 3
  • s

    signor_busi

    07/15/2017, 4:07 PM
    is it possible to create multiple records in one request without "naming" the records?
    p
    n
    a
    • 4
    • 29
  • s

    signor_busi

    07/15/2017, 4:07 PM
    I've seen this page: https://www.graph.cool/docs/faq/graphql-combining-multiple-queries-and-mutations-cahzai2eur/
1...270271272...637Latest