{"id":19894537,"url":"https://github.com/stepzen-dev/stepzen-rest-example","last_synced_at":"2026-06-08T02:32:18.853Z","repository":{"id":97527157,"uuid":"408494618","full_name":"stepzen-dev/stepzen-rest-example","owner":"stepzen-dev","description":"An example showing how to make a REST API available as GraphQL API through StepZen.","archived":false,"fork":false,"pushed_at":"2021-11-30T14:41:58.000Z","size":4,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-25T11:50:41.747Z","etag":null,"topics":["api","graphql","rest","rest-api"],"latest_commit_sha":null,"homepage":"","language":null,"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/stepzen-dev.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-09-20T15:19:20.000Z","updated_at":"2021-11-30T14:42:01.000Z","dependencies_parsed_at":"2023-03-13T16:12:41.236Z","dependency_job_id":null,"html_url":"https://github.com/stepzen-dev/stepzen-rest-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/stepzen-dev/stepzen-rest-example","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stepzen-dev%2Fstepzen-rest-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stepzen-dev%2Fstepzen-rest-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stepzen-dev%2Fstepzen-rest-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stepzen-dev%2Fstepzen-rest-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stepzen-dev","download_url":"https://codeload.github.com/stepzen-dev/stepzen-rest-example/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stepzen-dev%2Fstepzen-rest-example/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34046003,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-08T02:00:07.615Z","response_time":111,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["api","graphql","rest","rest-api"],"created_at":"2024-11-12T18:33:48.797Z","updated_at":"2026-06-08T02:32:18.836Z","avatar_url":"https://github.com/stepzen-dev.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# StepZen REST Example\n\nAn example showing how to make a REST API available as GraphQL API through StepZen.\n\n## Getting started\n\nBefore you're able to try out this example, you need to make sure that StepZen is installed on your local machine and that you're logged in. You can find how to do this in the [Getting Started with StepZen](https://stepzen.com/docs/quick-start) guide.\n\nAfter cloning this repository you need to run the following command to start this example:\n\n```\nstepzen start\n```\n\nThis will make a GraphQL API available at [http://localhost:5000/api/rest-example](http://localhost:5000/api/rest-example) with the GraphiQL Playground.\n\n## Sending requests\n\nThis project is using [My JSON Server](https://my-json-server.typicode.com/) to create a free REST API based on the contents of `db.json` in this repository. You can view an example of this REST API [here](https://my-json-server.typicode.com/stepzen-samples/stepzen-rest-example), and as you can see it has the following endpoints:\n\n- [/products](https://my-json-server.typicode.com/stepzen-samples/stepzen-rest-example/products)\n- [/products/[id]/categories](https://my-json-server.typicode.com/stepzen-samples/stepzen-rest-example/products/1/categories)\n- [/products/[id]/rating](https://my-json-server.typicode.com/stepzen-samples/stepzen-rest-example/products/1/rating)\n\nBased on the configuration that is passed to StepZen in `index.graphql` and `schema/ecommerce/graphql`, the schema for the GraphQL API is constructed. You can query the GraphQL API in example with the following query:\n\n```graphql\nquery GetProduct {\n  getProduct(id: 1) {\n    name\n    price\n    category {\n      name\n    }\n    rating {\n      average\n    }\n  }\n}\n```\n\nThis query will return product information from the REST API, by calling the endpoints `/products/1`, `/products/1/categories` and `/products/1/rating` and returning all this data in one JSON blob.\n\n## Questions\n\nDo you have any questions on this integration, or you want to check out other integrations you can make with [StepZen](https://stepzen.com/? Have a look at the website or join the [Discord channel](https://discord.com/channels/768229795544170506) for support.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstepzen-dev%2Fstepzen-rest-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstepzen-dev%2Fstepzen-rest-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstepzen-dev%2Fstepzen-rest-example/lists"}