Skip to main content
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
+
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
GEThttps://facebook.com/user/id
GEThttps://facebook.com/user/id/events
GEThttps://facebook.com/user/id/friends-suggestions
GEThttps://facebook.com/user/id/friends-birthdays
…
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
GraphQL API Requests
query {
user(id:18794326) {
name
events {
count
}
friends_suggestions(first: 1) {
name
mutual_friends {
count
}
}
}
}
{
"data": {
"user": {
"name": "Brandon Minnick",
"events": {
"count": 4
},
"friends_suggestions": [{
"name": "Seth Juarez",
"mutual_friends": {
"count": 18
}
}
]
}
}
}
Query Response
GitHub
GraphQL API
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
GraphQL APIs Have One Endpoint
Each GraphQL Request Uses The Same API Endpoint
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
GraphQL APIs Are Self Documenting
Users can explore GraphQL APIs using GraphiQL
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
GraphQL Requests Are POST Requests
GraphQL requests leverage the HTTP POST Method
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
{ “query” : “[Your GraphQL Query]” }
GraphQL Request Body is JSON
JSON contains one field: query
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
GraphQL Response is JSON
Like REST APIs, GraphQL APIs return JSON
Let’s Write
Some Code
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
 GraphQL-DotNet
 Open Source (160+ Contributors)
 120M NuGet Downloads
AWS
AppSync
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
Resources
https://codetraveler.io/dotnet-graphql-kcdc/
@TheCodeTraveler https://codetraveler.io/dotnet-graphql-kcdc/
Thank You
https://codetraveler.io/dotnet-graphql-kcdc/