This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from gql import gql, Client | |
from gql.transport.aiohttp import AIOHTTPTransport | |
# Select your transport with a defined url endpoint | |
transport = AIOHTTPTransport(url="https://cloud.caisy.io/api/v3/e/593065a4-0e27-4c4b-b1e3-25e3fd3ebfb9/graphql", | |
headers={'x-caisy-apikey': '2GjbTs8uQAh4IblXQs8YAYrvboKXvi54'} | |
) | |
# Create a GraphQL client using the defined transport | |
client = Client(transport=transport, fetch_schema_from_transport=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
const fs = require('fs'); | |
const path = require('path'); | |
const program = require('commander'); | |
const { Source, buildSchema } = require('graphql'); | |
const del = require('del'); | |
program | |
.option('--schemaFilePath [value]', 'path of your graphql schema file') | |
.option('--destDirPath [value]', 'dir you want to store the generated queries') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var pg = require('pg'); | |
var shimmer = require('shimmer'); | |
function wrapQuery(orig, name) { | |
return function wrappedFunction(sql) { | |
console.time("PSQL: " +sql); | |
var args = arguments | |
var index = args.length - 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"lastUpload":"2019-08-09T13:03:03.604Z","extensionVersion":"v3.4.1"} |