mattdamon108 / Rust_graphql_api_boilerplate
A Boilerplate of GraphQL API built in Rust + Warp + Juniper + Diesel
Stars: ✭ 91
Programming Languages
rust
11053 projects
Projects that are alternatives of or similar to Rust graphql api boilerplate
Rails Devise Graphql
A Rails 6 boilerplate to create your next Saas product. Preloaded with graphQL, devise, JWT, CanCanCan, RailsAdmin, Rubocop, Rspec, i18n and more.
Stars: ✭ 199 (+118.68%)
Mutual labels: graphql, graphql-api, boilerplate
Catalyst
Typescript NodeJS Microservices Boilerplate with Generator CLI - Moleculer, GraphQL, REST, OAuth2, Jaeger, Grafana, Prometheus, Ory Hydra, Ory Keto w/ Access Control middleware, Moleculer-DB GraphQL mixin, Pug, Redis, sibling client repo (login, persistance layer, react-native-web, ios, android)
Stars: ✭ 30 (-67.03%)
Mutual labels: graphql, boilerplate
Graphql Spqr
Java 8+ API for rapid development of GraphQL services
Stars: ✭ 843 (+826.37%)
Mutual labels: graphql, graphql-api
Relay Fullstack
☝️🏃 Modern Relay Starter Kit - Integrated with Relay, GraphQL, Express, ES6/ES7, JSX, Webpack, Babel, Material Design Lite, and PostCSS
Stars: ✭ 986 (+983.52%)
Mutual labels: graphql, boilerplate
React App
Create React App with server-side code support
Stars: ✭ 614 (+574.73%)
Mutual labels: graphql, boilerplate
Api Platform
Create REST and GraphQL APIs, scaffold Jamstack webapps, stream changes in real-time.
Stars: ✭ 7,144 (+7750.55%)
Mutual labels: graphql, graphql-api
React Firebase Starter
Boilerplate (seed) project for creating web apps with React.js, GraphQL.js and Relay
Stars: ✭ 4,366 (+4697.8%)
Mutual labels: graphql, boilerplate
Niklick
Rails Versioned API solution template for hipsters! (Ruby, Ruby on Rails, REST API, GraphQL, Docker, RSpec, Devise, Postgress DB)
Stars: ✭ 39 (-57.14%)
Mutual labels: graphql, boilerplate
Data Source Base
Boilerplate for creating a GrAMPS-compatible data source.
Stars: ✭ 52 (-42.86%)
Mutual labels: graphql, boilerplate
Wertik Js
💪 A library that powers your app with GraphQL + Rest API
Stars: ✭ 56 (-38.46%)
Mutual labels: graphql, boilerplate
Pup
The Ultimate Boilerplate for Products.
Stars: ✭ 563 (+518.68%)
Mutual labels: graphql, boilerplate
Graph Node
Graph Node indexes data from blockchains such as Ethereum and serves it over GraphQL
Stars: ✭ 884 (+871.43%)
Mutual labels: graphql, graphql-api
Laravel Vue Boilerplate
🐘 A Laravel 6 SPA boilerplate with a users CRUD using Vue.js 2.6, GraphQL, Bootstrap 4, TypeScript, Sass, and Pug.
Stars: ✭ 472 (+418.68%)
Mutual labels: graphql, boilerplate
Graphql Music
🎸A workshop in building a GraphQL API
Stars: ✭ 33 (-63.74%)
Mutual labels: graphql, graphql-api
Preact Redux Isomorphic
preact-redux-isomorphic PWA SPA SSR best practices and libraries in under 80kB page size (for live demo click the link below)
Stars: ✭ 85 (-6.59%)
Mutual labels: graphql, boilerplate
React Starter Kit
React Starter Kit — front-end starter kit using React, Relay, GraphQL, and JAM stack architecture
Stars: ✭ 21,060 (+23042.86%)
Mutual labels: graphql, boilerplate
Graphql Engine
Blazing fast, instant realtime GraphQL APIs on your DB with fine grained access control, also trigger webhooks on database events.
Stars: ✭ 24,845 (+27202.2%)
Mutual labels: graphql, graphql-api
Ultimate Backend
Multi tenant SaaS starter kit with cqrs graphql microservice architecture, apollo federation, event source and authentication
Stars: ✭ 978 (+974.73%)
Mutual labels: graphql, boilerplate
Rust GraphQL API Boilerplate
This is a boilerplate built with Rust.
Features
- DB migration with Diesel
- Sign up
- Sign in
- Change password
- Profile Update
- JSON web token authentication
Stacks
- Rust
- Warp - Web server framework
- Juniper - GraphQL library
- Diesel - ORM
- DB: Postgres
- JSON Web Token : Authentication
Run
Without Docker
$ git clone https://github.com/mattdamon108/rust_graphql_api_boilerplate
$ cd rust_graphql_api_boilerplate
$ echo DATABASE_URL=postgres://username:[email protected]/rust_boilerplate > .env
$ diesel setup
$ diesel migration run
$ cargo run
Build with Docker
$ docker build -t rust_gql .
$ docker run --rm -d -p 3030:3030 --name running_rust_gql rust_gql
Change the listening port from
127.0.0.1
to0.0.0.0
inmain.rs
. Because rust GraphQL API in docker container needs to listen to0.0.0.0
instead of local interface in order for host to access to the API.
GraphiQL : connect to 127.0.0.1:3030 with browser
Schema
Query
query {
getMyProfile {
ok
error
user {
id
email
first_name
last_name
bio
avatar
}
}
}
Note: JSON web token is needed to be sent as
authorization
in header.
Mutation
Sign Up
mutation {
signUp(
email: "[email protected]"
password: "12345678"
firstName: "graphql"
lastName: "rust"
) {
ok
error
user {
id
email
first_name
last_name
bio
avatar
}
}
}
Sign In
mutation {
signIn(email: "[email protected]", password: "12345678") {
token
}
}
Change Password
Note: JSON web token is needed to be sent as authorization
in header.
mutation {
changePassword(password: "87654321") {
ok
error
user {
id
email
first_name
last_name
bio
avatar
}
}
}
Change Profile
Note: JSON web token is needed to be sent as authorization
in header.
mutation {
changeProfile(bio: "Rust fan") {
ok
error
user {
id
email
first_name
last_name
bio
avatar
}
}
}
Next to do
- [x] User Sign up
- [x] Hash User Password - with bcrypt crate
- [x] User Sign in based on Token authentication
- [x] User profile Update
- [x] ERROR HANDLING (important!)
- [x] Deploy using Docker after compile
- [ ] Optimizing the multithread
References
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].