forked from prisma/prisma1
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgraphcool.yml
More file actions
executable file
·47 lines (43 loc) · 1.34 KB
/
graphcool.yml
File metadata and controls
executable file
·47 lines (43 loc) · 1.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
types: ./types.graphql
# Wilcard permission that allows all API operations for everyone
# for the sake of the demo. In a real-world project, you would
# specify permissions only for certain operations and can further constrain
# who should be able to perform an operation using permission queries.
permissions:
- operation: "*"
functions:
# Payment function using the implementation in `./src/pay.js`
pay:
handler:
code:
src: ./src/pay.js
# Define environment variable accessible by the function in `./src/pay.js`
environment:
STRIPE_KEY: pk_test_6pRNASCoBOKtIshFeQd4XMUh
type: resolver
schema: ./src/pay.graphql
# Authentication functions from: `https://github.com/graphcool/modules/tree/master/authentication/email-password`
signup:
type: resolver
schema: ./src/email-password/signup.graphql
handler:
code:
src: ./src/email-password/signup.js
authenticate:
type: resolver
schema: ./src/email-password/authenticate.graphql
handler:
code:
src: ./src/email-password/authenticate.js
loggednInUser:
type: resolver
schema: ./src/email-password/loggedInUser.graphql
handler:
code:
src: ./src/email-password/loggedInUser.js
# Permanent Auth Token / Root Tokens
rootTokens:
- defaultToken
- signup
- authenticate
- loggedInUser