summaryrefslogtreecommitdiffstats
path: root/backend/database/seed.graphql
diff options
context:
space:
mode:
authorWes Bos <wesbos@gmail.com>2018-01-30 12:41:01 -0500
committerWes Bos <wesbos@gmail.com>2018-01-30 12:41:01 -0500
commitcd0b07b3adb36fb5ec098f9e511ab45d774fee7b (patch)
treea203e5010219ccea1acc6bbd2c0a4bcfa0a78615 /backend/database/seed.graphql
parent0a1648bf47490b312169c531aeb51ef4725e8d2e (diff)
Move to Prisma Backend
Diffstat (limited to 'backend/database/seed.graphql')
-rw-r--r--backend/database/seed.graphql24
1 files changed, 24 insertions, 0 deletions
diff --git a/backend/database/seed.graphql b/backend/database/seed.graphql
new file mode 100644
index 0000000..5779328
--- /dev/null
+++ b/backend/database/seed.graphql
@@ -0,0 +1,24 @@
+mutation {
+ createUser(data: {
+ email: "developer@example.com"
+ password: "$2a$10$hACwQ5/HQI6FhbIISOUVeusy3sKyUDhSq36fF5d/54aAdiygJPFzm" # plaintext password: "nooneknows"
+ name: "Sarah"
+ posts: {
+ create: [{
+ title: "Hello World"
+ text: "This is my first blog post ever!"
+ isPublished: true
+ }, {
+ title: "My Second Post"
+ text: "My first post was good, but this one is better!"
+ isPublished: true
+ }, {
+ title: "Solving World Hunger"
+ text: "This is a draft..."
+ isPublished: false
+ }]
+ }
+ }) {
+ id
+ }
+} \ No newline at end of file