{"id":19832138,"url":"https://github.com/petrnikolas/nestjs-graphql-example","last_synced_at":"2025-07-06T14:38:52.801Z","repository":{"id":122237736,"uuid":"438291885","full_name":"PetrNikolas/nestjs-graphql-example","owner":"PetrNikolas","description":"NestJS and GraphQL example","archived":false,"fork":false,"pushed_at":"2021-12-14T15:08:04.000Z","size":130,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-11T10:19:50.768Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PetrNikolas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-12-14T14:52:21.000Z","updated_at":"2021-12-14T15:08:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"539935ad-0952-475d-a34c-941f1c0b9a22","html_url":"https://github.com/PetrNikolas/nestjs-graphql-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PetrNikolas%2Fnestjs-graphql-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PetrNikolas%2Fnestjs-graphql-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PetrNikolas%2Fnestjs-graphql-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PetrNikolas%2Fnestjs-graphql-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PetrNikolas","download_url":"https://codeload.github.com/PetrNikolas/nestjs-graphql-example/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241191626,"owners_count":19925302,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T11:36:34.365Z","updated_at":"2025-02-28T17:45:10.541Z","avatar_url":"https://github.com/PetrNikolas.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NestJS and GraphQL example\n\n## Installation\n\n```bash\n$ npm install\n```\n\n## Running the app\n\n```bash\n# development\n$ npm run start\n\n# watch mode\n$ npm run start:dev\n\n# production mode\n$ npm run start:prod\n```\n\n## Test\n\n```bash\n# unit tests\n$ npm run test\n\n# e2e tests\n$ npm run test:e2e\n\n# test coverage\n$ npm run test:cov\n```\n\n## GraphQL\n```bash\nopen http://localhost:3000/graphql in browser\n```\n\n### Examples\n\n#### Query\n```graphql\n# Get user by ID\nquery{\n    user(userId: \"USER_ID\") {\n        userId\n        age\n        email\n    }\n}\n\n# Get multiple users by IDs\nquery{\n    users(userIds: [\"USER_ID\"]) {\n        userId\n        age\n        email\n    }\n}\n\n# Get all users\nquery{\n    users {\n        userId\n        age\n        email\n    }\n}\n```\n\n#### Mutations\n```graphql\n# Create user\nmutation{createUser(createUserData: {\n  email: \"hello@mail.com\",\n  age: 28}) {\n    userId\n    email\n    age\n    isSubscribed\n  }\n}\n\n# Update user by ID\nmutation{updateUser(updateUserData: {\n    userId: \"USER_ID\"\n    age: 29}) {\n        userId\n        email\n        age\n        isSubscribed\n    }\n}\n\n# Delete user by ID\nmutation{\n    deleteUser(deleteUserData: {\n        userId: \"USER_ID\"}) {\n        userId\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpetrnikolas%2Fnestjs-graphql-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpetrnikolas%2Fnestjs-graphql-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpetrnikolas%2Fnestjs-graphql-example/lists"}