GraphQL Bookstore API

Security Learning Environment - Deliberately Vulnerable GraphQL API

Security Warning: This API contains intentional vulnerabilities for educational purposes. DO NOT deploy in production!
POST Queries & Mutations  |  GET Queries only  |  Use with online GraphQL tools, Postman, curl, etc.
Chapter I: The Injection
"Beyond the veil of queries lies a passage where shadows speak in database tongues. Those who master the ancient art of string concatenation may bend the data realm to their will, extracting secrets from tables unseen."
Chapter II: The Broken Access
"In the halls of the API, doors stand unlocked for all who seek. The internal chambers of user data lie bare to any traveler - no guardian questions those who walk the hidden corridors."
Chapter III: The Misplaced Trust
"The order bears the mark of its creator, yet any hand may seize it. When ownership goes unverified, the boundaries between yours and theirs dissolve into shadow."
Chapter IV: The Open Ledger
"Fields once forbidden now yield to the clever coder's touch. When all paths lead to the throne, when every attribute accepts the whisperer's will, true power transcends mere mortal constraints."
Chapter V: The Extending Reach
"Beyond the visible web lies a realm of machines and metadata. The curious can traverse the boundary between the public face and the hidden infrastructure that powers the kingdom."
Chapter VI: The Unwatched Treasury
"Crown jewels - order records, payment ledgers, system statistics - all lie within reach of the unguarded gate. The keepers have left their treasures unwatched, accessible to any who know where to look."
Chapter VII: The Skeleton Key
"A single key unlocks many doors, yet this key was forged from common words. The authentication bearer need only speak the secret phrase to command the realm's resources."
Query Runner
Response will appear here...
🔒 Login
📝 Register
Quick Examples
# Query books (no auth) query { books(limit:5) { id title price } }
# Get book by ID query { book(id:1) { id title description author { firstName lastName } } }
# Search books query { books(search:"code") { id title price } }
# Login mutation { login(username:"admin", password:"password123") { success token } }
# Register mutation { register(username:"user", firstName:"John", lastName:"Doe", password:"pass") { success } }
# Get current user query { me { id username role firstName } }
# Update profile mutation { updateProfile(phone:"1234567890", city:"NYC") { success } }
# Add to cart mutation { addToCart(bookId:1, quantity:2) { success } }
# View cart query { cart { id items { bookId quantity } } }
# Remove from cart mutation { removeFromCart(bookId:1) { success } }
# Create order mutation { createOrder { success orderId } }
# View orders query { orders { id orderNumber status totalAmount } }
# Cancel order mutation { cancelOrder(orderId:"xxx") { success } }
# Create review mutation { createReview(bookId:1, rating:5, comment:"Great!") { success } }
# View reviews query { bookReviews(bookId:1) { id rating comment } }
# Delete review mutation { deleteReview(reviewId:1) { success } }
# Register webhook mutation { registerWebhook(url:"https://example.com", events:"order.created") { success } }
# Test webhook mutation { testWebhook(webhookId:"xxx") { success } }
# Advanced search query { _searchAdvanced(query:"python") { id title price } }
# External resource query { _fetchExternalResource(url:"http://example.com") { content } }
Available Queries
QueryNo Auth
books
List books with filters
QueryNo Auth
book(id)
Get book details
QueryAuth
me
Get current user
QueryAuth
cart
Get shopping cart
QueryAuth
orders
Get order history
QueryNo Auth
_searchAdvanced
Advanced book search
QueryNo Auth
_internalUserSearch
Search users by username
QueryNo Auth
_fetchExternalResource
Fetch external URL content
Available Mutations
MutationNo Auth
register
Create account
MutationNo Auth
login
Get JWT token
MutationAuth
addToCart
Add to cart
MutationAuth
createOrder
Create order
MutationAuth
cancelOrder
Cancel order
MutationAuth
createReview
Add review
MutationAuth
deleteReview
Delete review
MutationAuth
updateProfile
Update user profile
MutationAuth
registerWebhook
Register webhook
MutationAuth
testWebhook
Test webhook endpoint
Features
📚
Book Catalog
🛒
Shopping Cart
📝
Reviews
🔗
Webhooks
🔒
JWT Auth
🢛
Orders