Skip to content

A GraphQL style query library for Google Sheet written with Google Apps Script

License

Notifications You must be signed in to change notification settings

ashtonfei/graphql-sheet

Repository files navigation

graphql-sheet

A GraphQL style query library for Google Sheet written with Google Apps Script

Introduction on YouTube

Graphql Sheet Library (Preview)

Demo Links

  1. Demo Database with demo script
  2. Demo Web App Build
  3. JSON download content service

Add the library to your spreadsheet

1AkIU9D7-QTAytM1m7gALogopMttzp7Ir8ArWU_7K7zSvq8ZIT_kj64m4

Create a new database with Graphql

function demo() {
	const id = SpreadsheetApp.getActive().getId();
	const db = new Graphql.create(id);

	const users = db.query(
		`query getActiveStatus($status:string!){
            users(status:$status){
                name
                status
                joinDate
                gender
                posts{
                    id
                    title
                    description
                    channels{
                        id
                        name
                        url
                    }
                }
            }
        }`,
		{ status: "active" }
	);
	console.log(users);
}

About

A GraphQL style query library for Google Sheet written with Google Apps Script

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published