Develop Your Own Application + Code Samples

Updated 2 weeks ago ​by nussi

Public GitHub Repository

You can find our public repository here https://github.com/SellerCloudTeam/graphql-api-samples. In it you will find two sample projects to draw example from - one JS client and one C# console app. Feel free to view, download and clone this project and experiment with your server graphql API.

Sample JS Project

Under the JS folder you will find a small React + Apollo app, which demonstrates the basic usage and main features of GraphQL.

In order to run this app locally, you need to

  1. clone the repository to your local environment.
  2. run npm install from inside the graphql-api-samples/src/js/ directory.
  3. find the config.js file inside the graphql-api-samples/src/js/src directory and modify line 4 to include a reference to your server.
  4. run npm start from inside the graphql-api-samples/src/js/ directory.
Once you have run the application and logged in with valid credentials upon request, you can navigate to the GraphiQL Browser tab. Here you can inspect the schema and see what fields have been defined for each type and can be queried. You can also experiment with custom queries, taking advantage of the built-in Intellisense support.

Sample C# Project

Under the csharp folder you will find a small console application which demonstrates how you can consume the API in .NET.

  1. clone the repository to your local environment.
  2. open the solutions in Visual Studio and find the Program.cs file in the Sample.DotNetFramework project. Modify lines 15, 18-19 to match your server id and credentials.
  3. Build and run the project.


How did we do?