{"id":18367952,"url":"https://github.com/devignesh/graphql-django","last_synced_at":"2025-07-27T02:38:45.370Z","repository":{"id":45920981,"uuid":"244461083","full_name":"devignesh/graphQL-Django","owner":"devignesh","description":"This is simple blog post app using django and graphql","archived":false,"fork":false,"pushed_at":"2023-08-18T05:10:05.000Z","size":38,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-22T03:51:13.931Z","etag":null,"topics":["django","graphene-django","graphql","python"],"latest_commit_sha":null,"homepage":null,"language":"Python","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/devignesh.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":"2020-03-02T19:50:21.000Z","updated_at":"2023-04-17T14:31:38.000Z","dependencies_parsed_at":"2024-11-05T23:28:02.147Z","dependency_job_id":"974c718c-23b2-47a0-bc09-8398168c4f5f","html_url":"https://github.com/devignesh/graphQL-Django","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/devignesh%2FgraphQL-Django","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devignesh%2FgraphQL-Django/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devignesh%2FgraphQL-Django/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devignesh%2FgraphQL-Django/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devignesh","download_url":"https://codeload.github.com/devignesh/graphQL-Django/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247522305,"owners_count":20952520,"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":["django","graphene-django","graphql","python"],"created_at":"2024-11-05T23:24:04.206Z","updated_at":"2025-04-06T17:31:35.650Z","avatar_url":"https://github.com/devignesh.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# graphQL-Django\n\nThis is simple blog post app using django and graphQL, We design an api schema for blogpost and comment. \n\nIn graphQL Queries and mutation is used for getting data and changing data in server.\n\nGraphene we can use Django to create GraphQL APIs.\n\n--------------------------------------------------------\n\n# Start the project\n\nClone the repository :\n\n1: git clone git@github.com:devignesh/graphQL-Django.git\n\n2: cd graphQL-Django\n\n    I. pipenv shell   \n\n    II. pipenv install\n\n    III. cd blog  # app name\n\n3: python manage.py makemigrations  \n\n4: python mange.py migrate\n\n5: python mange.py runserver  \n\n6: http://127.0.0.1:8000/graphql/    #open in your browser\n\n\n----------------------------------------------------------\n\n\n# queries\n\nTo get all the blog post \n----------------------------------------------------------\n\n    query {\n    blogpostall {\n        id\n        author\n        title\n        description\n        publishedDate\n        updatedAt\n    }\n    }\n\nTo get the blogpost with Comments\n----------------------------------------------------------\n\n    query {\n    blogpostall {\n        id\n        author\n        title\n        description\n        publishedDate\n        updatedAt\n        commentSet {\n            id\n            comment\n        }\n\n    }\n    }\n    \n    # Response\n    \n            {\n          \"data\": {\n            \"blogpostall\": [\n              {\n                \"id\": \"1\",\n                \"author\": \"vignesh\",\n                \"title\": \"Python Django\",\n                \"description\": \"Sample Blog\",\n                \"publishedDate\": \"2020-03-03T02:31:22+00:00\",\n                \"updatedAt\": null,\n                \"commentSet\": [\n                  {\n                    \"id\": \"13\",\n                    \"comment\": \"comment\"\n                  },\n                  {\n                    \"id\": \"3\",\n                    \"comment\": \"Third comment\"\n                  }\n                ]\n              },\n              {\n                \"id\": \"2\",\n                \"author\": \"vicky\",\n                \"title\": \"Django graphQL\",\n                \"description\": \"Django testing\",\n                \"publishedDate\": \"2020-03-02T21:04:18.194415+00:00\",\n                \"updatedAt\": null,\n                \"commentSet\": [\n                  {\n                    \"id\": \"19\",\n                    \"comment\": \"test\"\n                  },\n                  {\n                    \"id\": \"16\",\n                    \"comment\": \"vv\"\n                  },\n                  {\n                    \"id\": \"15\",\n                    \"comment\": \"vv\"\n                  },\n                  {\n                    \"id\": \"14\",\n                    \"comment\": \"vv\"\n                  },\n                  {\n                    \"id\": \"12\",\n                    \"comment\": \"value\"\n                  },\n                  {\n                    \"id\": \"5\",\n                    \"comment\": \"File performance\"\n                  },\n                  {\n                    \"id\": \"4\",\n                    \"comment\": \"Mannual data\"\n                  }\n                ]\n              }\n             }\n\nQuery for get the particular blogpost and comments based on its ID \n---------------------------------------------------------------------\n\n    query {\n    blogs(id:1) {\n        id\n        author\n        title\n        description\n        publishedDate\n        commentSet {\n        \n            id\n            comment\n        }\n\n    }\n    }\n\n\n# Mutation \n\nCreate a new blog post mutation \n----------------------------------------------------------\n\n    mutation {\n    createBlog (author:\"vigneshkumar\", title:\"Test blog\", description:\"test description\") {\n        \n        createblogpost {\n        id\n        author\n        title\n        description\n        publishedDate\n        updatedAt\n        }\n    }\n    }\n    \n    # Response \n                {\n          \"data\": {\n            \"createBlog\": {\n              \"createblogpost\": {\n                \"id\": \"8\",\n                \"author\": \"vickykumar\",\n                \"title\": \"test create blog\",\n                \"description\": \"test blog description\",\n                \"publishedDate\": \"2020-03-03T06:56:12.902488+00:00\"\n                \"updatedAt\": null\n              }\n            }\n          }\n        }\n\nUpdate a existing blog post based on  blog ID,\n----------------------------------------------------------\n\n    mutation {\n    updateblog (blogId:7, author:\"updated\", title:\"updated title\", description:\"updated desc\") {\n        blogupdate {\n        id\n        author\n        title\n        description\n        publishedDate\n        updatedAt\n        }\n    }\n    }\n\nCreate a New comment \n----------------------------------------------------------\n\n    mutation {\n    createcomment (author:\"updated\", comment:\"test comment\") {\n        createcommentpost {\n        id\n        comment\n        author {\n            id\n        }\n    }\n    }\n    }\n\nDelete a existing comment based on comment ID\n----------------------------------------------------------\n\n    mutation {\n    deletecomment(commentId:1) {\n        commentId\n    }\n    }\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevignesh%2Fgraphql-django","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevignesh%2Fgraphql-django","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevignesh%2Fgraphql-django/lists"}