{"id":19739312,"url":"https://github.com/mukailasam/graphql1","last_synced_at":"2026-05-09T09:36:36.814Z","repository":{"id":195532504,"uuid":"693104067","full_name":"mukailasam/graphql1","owner":"mukailasam","description":"A Golang CRUD GraphQL API","archived":false,"fork":false,"pushed_at":"2023-09-27T15:37:23.000Z","size":12,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-10T19:44:57.530Z","etag":null,"topics":["crud","crud-api","database","go","golang","graphql","graphql-golang"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mukailasam.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2023-09-18T11:04:47.000Z","updated_at":"2023-10-08T01:36:06.000Z","dependencies_parsed_at":"2024-06-21T19:03:26.704Z","dependency_job_id":null,"html_url":"https://github.com/mukailasam/graphql1","commit_stats":null,"previous_names":["ftsog/graphql1","mukailasam/graphql1"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mukailasam%2Fgraphql1","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mukailasam%2Fgraphql1/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mukailasam%2Fgraphql1/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mukailasam%2Fgraphql1/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mukailasam","download_url":"https://codeload.github.com/mukailasam/graphql1/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241068170,"owners_count":19903974,"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":["crud","crud-api","database","go","golang","graphql","graphql-golang"],"created_at":"2024-11-12T01:16:54.093Z","updated_at":"2026-05-09T09:36:36.777Z","avatar_url":"https://github.com/mukailasam.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"### GraphQL1\nA Golang CRUD GraphQL API\n\n### What is GraphQL\nWikipedia: GraphQL is an open-source data query and manipulation language for APIs and a query runtime engine.\n\nGraphQL enables declarative data fetching where a client can specify exactly what data it needs from an API. Instead of multiple endpoints that return separate data, a GraphQL server exposes a single endpoint and responds with precisely the data a client asked for.\n\n### Basic Concepts:\nSchema: The foundation of a GraphQL server. It defines the types of data that can be queried and the relationships between them.\n\nTypes: GraphQL has scalar types (e.g., Int, String, Boolean) and complex types (e.g., Object types, Interface types, Union types).\n\nQueries: Clients send queries to request specific data. A query describes the data structure the client expects in response.\n\nMutations: Used to modify data on the server. Similar to queries, but for operations that cause changes.\n\n\n### Setup\n+ Clone the repository\\\n`git clone https://github.com/mukailasam/graphql1`\n+ Change directory into the program directory\\\n`cd graphql1`\n+ Start the API server\\\n`go run .`\n\nafter starting the server start making use of the Queries\n\nNote: There are 5 posts with the id(7, 8, 9, 10, 11)already created and they are stored in the sqlite database, but you can add yours by making use of create post query. besides creating post you can do all other stuff too, like reading a single post, all posts, updating a post and deleting a post. You can do all these stuff using the queries below\n\n### Queries\nCreate a post\\\n`\nhttp://127.0.0.1:8080/graphql?query=mutation+_{create(title:\"First Post\",body:\"Hello, word\"){title,body}}\n`\n\nRead all posts\\\n`\nhttp://127.0.0.1:8080/graphql?query={posts{title,body}}\n`\n\nRead a Post\\\n`\nhttp://127.0.0.1:8080/graphql?query={post(id:11){title,body}}\n`\n\nUpdate a post\\\n`\nhttp://127.0.0.1:8080/graphql?query=mutation+_{update(id:11,title:\"First Post\",body:\"Hey buddy\"){title,body}}\n`\n\nDelete a post\\\n`\nhttp://127.0.0.1:8080/graphql?query=mutation+_{delete(id:11){title,body}}\n`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmukailasam%2Fgraphql1","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmukailasam%2Fgraphql1","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmukailasam%2Fgraphql1/lists"}