prismagraphql/freecom-tutorial

Name: freecom-tutorial

Owner: Prisma

Description: Full-stack tutorial series to build your own customer chat

Created: 2017-04-10 11:59:04.0

Updated: 2018-05-19 01:24:54.0

Pushed: 2017-07-22 18:17:11.0

Homepage: https://www.graph.cool/freecom/

Size: 93

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Freecom Full-Stack Tutorial Series

In this repository, you find the code for each chapter of the Freecom tutorial series. With every new chapter, we're adding two new folders to the repository that will generally be named as follows:

Note that you'll have to add your own GraphQL endpoint in src/index.js.

Previous Chapters

The chapters provide a high-level overview on the concepts being used. If you want to code along, watch our videos to get step-by-step instructions for implementing the next features.

Getting the GraphQL Endpoint

This is what the data model for Freecom looks like:

 Message {
ent: Agent @relation(name: "MessagesFromAgents")
nversation: Conversation @relation(name: "MessagesInConversation")
eatedAt: DateTime!
: ID!
xt: String!
datedAt: DateTime!


 Conversation {
ent: Agent @relation(name: "ConversationsFromAgent")
eatedAt: DateTime!
stomer: Customer @relation(name: "ConversationsFromCustomer")
: ID!
ssages: [Message!]! @relation(name: "MessagesInConversation")
ackChannelIndex: Int!
datedAt: DateTime!


 Agent {
nversations: [Conversation!]! @relation(name: "ConversationsFromAgent")
eatedAt: DateTime!
: ID!
ageUrl: String!
ssages: [Message!]! @relation(name: "MessagesFromAgents")
ackUserId: String!
ackUserName: String!
datedAt: DateTime!


 Customer {
nversations: [Conversation!]! @relation(name: "ConversationsFromCustomer")
eatedAt: DateTime!
: ID!
me: String!
datedAt: DateTime!

You can generate your own GraphQL API from this schema by using the Graphcool CLI:

stall the Graphcool CLI
install -g graphcool

t the GraphQL Endpoint
hcool init --schema http://graphqlbin.com/freecom.graphql --name Freecom
Help & Community Slack Status

Say hello in our Slack or visit the Graphcool Forum if you run into issues or have questions. We love talking to you!


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.