{"_id":"waterline-graphql","_rev":"41-30c85de7d96c7dea8f9f40fc9c51107e","name":"waterline-graphql","dist-tags":{"latest":"1.1.1"},"versions":{"0.0.1":{"name":"waterline-graphql","version":"0.0.1","keywords":["adapter","graphql","orm","waterline"],"author":{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"},"license":"MIT","_id":"waterline-graphql@0.0.1","maintainers":[{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"}],"homepage":"https://github.com/wistityhq/waterline-graphql#readme","bugs":{"url":"https://github.com/wistityhq/waterline-graphql/issues"},"xo":{"envs":["node","mocha"],"rules":{"strict":0,"new-cap":0,"dot-notation":0,"padded-blocks":0,"global-require":0,"no-else-return":0,"prefer-reflect":0,"consistent-this":0,"no-extra-parens":0,"no-invalid-this":0,"prefer-template":0,"no-throw-literal":0,"consistent-return":0,"max-nested-callbacks":[1,6],"no-implicit-coercion":0,"no-unused-expressions":0,"prefer-arrow-callback":0,"babel/object-shorthand":0},"space":true,"esnext":true,"ignores":["node_modules/**","bower_components/**","coverage/**"]},"dist":{"shasum":"e91d9279ecb509e84429fd28e420c1a3d9673ab8","tarball":"https://registry.npmjs.org/waterline-graphql/-/waterline-graphql-0.0.1.tgz","integrity":"sha512-aIqt8IvCIw8J40VtzMtAnimJsg/GYGOZYT0pKdztj6CkI4h22vYNMgmk0SmDDjt+stWFhTEzk9vdwW/ewB7z5A==","signatures":[{"sig":"MEQCIBSP9P+QLyH+ZzY5HABzob3QJ+dJsEvjSJ6hcouQnxzzAiBoCN31LrCB7XrHy5jiSCFsOQEi3YZsJV98waJscaFejQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"./lib","_from":".","_shasum":"e91d9279ecb509e84429fd28e420c1a3d9673ab8","engines":{"npm":">= 2.0.0","node":">= 0.12.0"},"gitHead":"2ea06076658f2ca399fb33c0f80851449a965659","scripts":{"test":"xo","prepublish":"npm prune"},"_npmUser":{"name":"wistityhq","email":"hack@wistity.co"},"repository":{"url":"git://github.com/wistityhq/waterline-graphql.git","type":"git"},"_npmVersion":"2.14.7","description":"GraphQL adapter for the Waterline ORM.","directories":{"lib":"./lib"},"_nodeVersion":"4.2.1","dependencies":{"lodash":"^3.10.1","graphql":"^0.4.7","waterline":"^0.10.26"},"devDependencies":{"xo":"^0.9.0","babel":"^5.0.0","mocha":"^2.3.3","eslint":"^1.6.0","babel-eslint":"^4.1.3","eslint-config-standard":"^4.4.0","eslint-plugin-standard":"^1.3.1"}},"1.0.0":{"name":"waterline-graphql","version":"1.0.0","keywords":["adapter","graphql","orm","waterline"],"author":{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"},"license":"MIT","_id":"waterline-graphql@1.0.0","maintainers":[{"name":"wistityhq","email":"hack@wistity.co"}],"homepage":"https://github.com/wistityhq/waterline-graphql#readme","bugs":{"url":"https://github.com/wistityhq/waterline-graphql/issues"},"xo":{"envs":["node","mocha"],"rules":{"strict":0,"new-cap":0,"dot-notation":0,"padded-blocks":0,"global-require":0,"no-else-return":0,"prefer-reflect":0,"consistent-this":0,"no-extra-parens":0,"no-invalid-this":0,"prefer-template":0,"no-throw-literal":0,"consistent-return":0,"no-trailing-spaces":[2,{"skipBlankLines":true}],"max-nested-callbacks":[1,6],"no-implicit-coercion":0,"no-unused-expressions":0,"prefer-arrow-callback":0,"babel/object-shorthand":0},"space":true,"esnext":true,"globals":["_"],"ignores":["node_modules/**","coverage/**","test/**"]},"dist":{"shasum":"d95c6061c5c015420796ea647ca870a0326dc72b","tarball":"https://registry.npmjs.org/waterline-graphql/-/waterline-graphql-1.0.0.tgz","integrity":"sha512-LSOJZKzsZGGQl4A/ceEMBLwKNzDbdWiNxhCEBA+qeghdFdjMJ6TodC2AL7YsekSYUSedLHcxrqSaAYuAGXPdcw==","signatures":[{"sig":"MEYCIQD/013ij7koho31JpHUgLBINKOgp2Q1qpCsP0dSlbVQ3wIhAJ9N0XCCn3FOj4SG9HbC379IFT7Qt9QM26b7zj4OPqgy","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"./lib/adapter.js","_from":".","_shasum":"d95c6061c5c015420796ea647ca870a0326dc72b","engines":{"npm":">= 2.0.0","node":">= 0.12.0"},"gitHead":"8b328c8ba3196851aa717e0df355c7a03b896f56","scripts":{"test":"xo","prepublish":"npm prune"},"_npmUser":{"name":"wistityhq","email":"hack@wistity.co"},"repository":{"url":"git://github.com/wistityhq/waterline-graphql.git","type":"git"},"_npmVersion":"2.14.7","description":"GraphQL adapter for the Waterline ORM.","directories":{"lib":"./lib"},"_nodeVersion":"4.2.1","dependencies":{"lodash":"^3.10.1"},"devDependencies":{"xo":"^0.9.0","babel":"^5.0.0","mocha":"^2.3.3","eslint":"^1.6.0","babel-eslint":"^4.1.3","eslint-config-standard":"^4.4.0","eslint-plugin-standard":"^1.3.1"},"peerDependencies":{"graphql":">=0.4.2","waterline":">=0.10.26"}},"1.0.1":{"name":"waterline-graphql","version":"1.0.1","keywords":["adapter","graphql","orm","waterline"],"author":{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"},"license":"MIT","_id":"waterline-graphql@1.0.1","maintainers":[{"name":"wistityhq","email":"hack@wistity.co"}],"homepage":"https://github.com/wistityhq/waterline-graphql#readme","bugs":{"url":"https://github.com/wistityhq/waterline-graphql/issues"},"xo":{"envs":["node","mocha"],"rules":{"strict":0,"new-cap":0,"dot-notation":0,"padded-blocks":0,"global-require":0,"no-else-return":0,"prefer-reflect":0,"consistent-this":0,"no-extra-parens":0,"no-invalid-this":0,"prefer-template":0,"no-throw-literal":0,"consistent-return":0,"no-trailing-spaces":[2,{"skipBlankLines":true}],"max-nested-callbacks":[1,6],"no-implicit-coercion":0,"no-unused-expressions":0,"prefer-arrow-callback":0,"babel/object-shorthand":0},"space":true,"esnext":true,"globals":["_"],"ignores":["node_modules/**","coverage/**","test/**"]},"dist":{"shasum":"338b61385bcbe27f77f6edb080ca1100bb8bbb32","tarball":"https://registry.npmjs.org/waterline-graphql/-/waterline-graphql-1.0.1.tgz","integrity":"sha512-gGj76WZXJmCom2sxHX1tYcnJn7B9ZVn7/rV019AIoM0VykanWzbmezXDIu3Q8OtMBAggbO8dYeGr6NsODwvEuQ==","signatures":[{"sig":"MEUCID5PIa624YNJR0G/tfcqsRoe5bG24GsKK2UYTRy/PJUBAiEA+sIjwUmbCaL2M6VWZPD5gymUsGE1rRMlqp9euTHVqn8=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"./lib/adapter.js","_from":".","_shasum":"338b61385bcbe27f77f6edb080ca1100bb8bbb32","engines":{"npm":">= 2.0.0","node":">= 0.12.0"},"gitHead":"13fb36143d5b71277d8f82af06aeca3977116af9","scripts":{"test":"xo","prepublish":"npm prune"},"_npmUser":{"name":"wistityhq","email":"hack@wistity.co"},"repository":{"url":"git://github.com/wistityhq/waterline-graphql.git","type":"git"},"_npmVersion":"2.14.7","description":"GraphQL adapter for the Waterline ORM.","directories":{"lib":"./lib"},"_nodeVersion":"4.2.1","dependencies":{"lodash":"^3.10.1"},"devDependencies":{"xo":"^0.9.0","babel":"^5.0.0","mocha":"^2.3.3","eslint":"^1.6.0","babel-eslint":"^4.1.3","eslint-config-standard":"^4.4.0","eslint-plugin-standard":"^1.3.1"},"peerDependencies":{"graphql":">=0.4.2","waterline":">=0.10.26"}},"1.1.0":{"name":"waterline-graphql","version":"1.1.0","keywords":["adapter","graphql","orm","waterline"],"author":{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"},"license":"MIT","_id":"waterline-graphql@1.1.0","maintainers":[{"name":"wistityhq","email":"hack@wistity.co"}],"homepage":"https://github.com/wistityhq/waterline-graphql#readme","bugs":{"url":"https://github.com/wistityhq/waterline-graphql/issues"},"xo":{"envs":["node","mocha"],"rules":{"strict":0,"new-cap":0,"dot-notation":0,"padded-blocks":0,"global-require":0,"no-else-return":0,"prefer-reflect":0,"consistent-this":0,"no-extra-parens":0,"no-invalid-this":0,"prefer-template":0,"no-throw-literal":0,"consistent-return":0,"no-trailing-spaces":[2,{"skipBlankLines":true}],"max-nested-callbacks":[1,6],"no-implicit-coercion":0,"no-unused-expressions":0,"prefer-arrow-callback":0,"babel/object-shorthand":0},"space":true,"esnext":true,"globals":["_"],"ignores":["node_modules/**","coverage/**","test/**"]},"dist":{"shasum":"c1f743061e9af2e1843e4c1dc3487faaa981fb49","tarball":"https://registry.npmjs.org/waterline-graphql/-/waterline-graphql-1.1.0.tgz","integrity":"sha512-pyW52Wy+bbf+7k5lHwuMfCGypvcQb1MGm3uDOhDecvZMVZDLdUdNWyGbENyxtsFwfyuHqLQmrsvu+n0gxxgP7g==","signatures":[{"sig":"MEUCIQCsX0F/qmGz3DFTbQC2+tG+6ZSVfd2K+TRMF+SfGtSexQIgdXdyicov5fJ8yZgueJEwxU+sS/Q6J/p9/1lVxSs4jZw=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"lib/adapter.js","_from":".","_shasum":"c1f743061e9af2e1843e4c1dc3487faaa981fb49","engines":{"npm":">= 2.0.0","node":">= 0.12.0"},"gitHead":"27158ce9aa8bfede2d7176d5968909bb86cd3e49","scripts":{"test":"xo","prepublish":"npm prune"},"_npmUser":{"name":"wistityhq","email":"hack@wistity.co"},"repository":{"url":"git://github.com/wistityhq/waterline-graphql.git","type":"git"},"_npmVersion":"3.3.9","description":"GraphQL adapter for the Waterline ORM.","directories":{"lib":"./lib"},"_nodeVersion":"5.0.0","dependencies":{"lodash":"^3.10.1"},"devDependencies":{"xo":"^0.11.0"},"peerDependencies":{"graphql":">=0.4.2","waterline":">=0.10.26"}},"1.1.1":{"name":"waterline-graphql","version":"1.1.1","keywords":["adapter","graphql","orm","waterline"],"author":{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"},"license":"MIT","_id":"waterline-graphql@1.1.1","maintainers":[{"name":"wistityhq","email":"hack@wistity.co"}],"homepage":"https://github.com/wistityhq/waterline-graphql#readme","bugs":{"url":"https://github.com/wistityhq/waterline-graphql/issues"},"xo":{"envs":["node","mocha"],"rules":{"strict":0,"new-cap":0,"dot-notation":0,"padded-blocks":0,"global-require":0,"no-else-return":0,"prefer-reflect":0,"consistent-this":0,"no-extra-parens":0,"no-invalid-this":0,"prefer-template":0,"no-throw-literal":0,"consistent-return":0,"no-trailing-spaces":[2,{"skipBlankLines":true}],"max-nested-callbacks":[1,6],"no-implicit-coercion":0,"no-unused-expressions":0,"prefer-arrow-callback":0,"babel/object-shorthand":0},"space":true,"esnext":true,"globals":["_"],"ignores":["node_modules/**","coverage/**","test/**"]},"dist":{"shasum":"d80a7881c1280a55a6b0d6ee77612f22a7289086","tarball":"https://registry.npmjs.org/waterline-graphql/-/waterline-graphql-1.1.1.tgz","integrity":"sha512-1KLOFj2ldxb8SS7h6ueZKt5/5iRtYpEeCEEpDoDuhklfy1HJ534NaYods9sgVRI6zYMllTAmCsifRJATvkmeKw==","signatures":[{"sig":"MEUCIQC1x247rTuJA0qfGwKgS1uEDr2srEIq5omN0/NhMzLyUAIgGhlsZwGzIjSum+Co3Gi80fuYXCQpd61zFh3RQ4hhGG8=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"lib/adapter.js","_from":".","_shasum":"d80a7881c1280a55a6b0d6ee77612f22a7289086","engines":{"npm":">= 2.0.0","node":">= 0.12.0"},"gitHead":"29e67899b84bc8ac5177bc8402cc874367de6b4a","scripts":{"test":"xo","prepublish":"npm prune"},"_npmUser":{"name":"wistityhq","email":"hack@wistity.co"},"repository":{"url":"git://github.com/wistityhq/waterline-graphql.git","type":"git"},"_npmVersion":"3.3.12","description":"GraphQL adapter for the Waterline ORM.","directories":{"lib":"./lib"},"_nodeVersion":"4.2.3","dependencies":{"lodash":"~3.10.1"},"devDependencies":{"xo":"~0.11.2","pre-commit":"~1.1.2"},"peerDependencies":{"graphql":">=0.4.2","waterline":">=0.10.26"},"_npmOperationalInternal":{"tmp":"tmp/waterline-graphql-1.1.1.tgz_1454427821106_0.5753999699372798","host":"packages-6-west.internal.npmjs.com"}}},"time":{"created":"2015-10-15T12:23:37.401Z","modified":"2026-06-23T12:06:37.171Z","0.0.1":"2015-10-15T12:23:37.401Z","1.0.0":"2015-10-21T08:50:42.620Z","1.0.1":"2015-10-21T09:53:23.734Z","1.1.0":"2015-11-16T10:30:31.688Z","1.1.1":"2016-02-02T15:43:43.477Z"},"bugs":{"url":"https://github.com/wistityhq/waterline-graphql/issues"},"author":{"url":"http://wistity.co","name":"Wistity team","email":"hack@wistity.co"},"license":"MIT","homepage":"https://github.com/wistityhq/waterline-graphql#readme","keywords":["adapter","graphql","orm","waterline"],"repository":{"url":"git://github.com/wistityhq/waterline-graphql.git","type":"git"},"description":"GraphQL adapter for the Waterline ORM.","maintainers":[{"email":"pierre.burgy@gmail.com","name":"pierreburgy"},{"email":"aurelsicoko@gmail.com","name":"aurelsicoko"},{"email":"bodin.alex@gmail.com","name":"alexandrebodin"},{"email":"jean-sebastien.herbaux@hotmail.fr","name":"convly"},{"email":"nicolas.andre@strapi.io","name":"nico-strapi"},{"email":"adrien.lepoutre@strapi.io","name":"strapi.adzouz"},{"email":"simon.norris@strapi.io","name":"cache-your-dreams"},{"email":"ben.irvin@gmail.com","name":"baronvoninternet"},{"email":"marc.roig.campos@strapi.io","name":"marc-roig-strapi"},{"email":"jhoward1994@gmail.com","name":"jhoward1994"},{"email":"basselkanso82@gmail.com","name":"bassel17"}],"readme":"# GraphQL adapter for Waterline\n\nInspired by [waterline-to-graphql adapter](https://github.com/agenthunt/waterline-to-graphql)\n\n## Installation\n\nInstall the latest stable release with the npm command-line tool:\n\n```bash\n$ npm install waterline-graphql\n```\n\n## Usage\n\n### From Waterline collections to GraphQL schemas\n\n```javascript\n// Import the adapter\nconst WaterlineGraphQL = require('waterline-graphql');\n\n// Convert Waterline collections to GraphQL schemas\nWaterlineGraphQL.getGraphQLSchema({\n  collections: strapi.orm.collections,\n  usefulFunctions: true\n}, function (schemas) {\n  // Use your schemas here...\n});\n```\n\n### Execute GraphQL queries\n\n```javascript\nconst graphql = require('graphql').graphql();\n\n// Build your query\nconst query = '{ users{firstName lastName articles{title comments{text}}} }';\n\n// Execute the query\ngraphql(schemas, query)\n  .then(function (result) {\n    console.log(result);\n  })\n  .catch(function (error) {\n    console.log(error);\n  });\n```\n\n## Configuration\n\n```javascript\n{\n  collections: strapi.orm.collections // Required attributes\n  usefulFunctions: true|false // Allow you to access to powerful useful functions\n}\n```\n\nNote: If you are using standalone Waterline models, your models need to be patched with an\nassociations array. [See the issue here](https://github.com/balderdashy/waterline/issues/797).\n\n## Complex queries\n\nYou can execute more complex queries like this.\n\nThis example will return 10 user's records sorted alphabetically by `firstName`:\n\n```javascript\nlet query = '{ users(limit: 10, sort: \"firstName ASC\"){firstName lastName articles{title comments{text}}} }';\n```\n\nYou can access to the 10 next users by adding the `skip` parameter:\n\n```javascript\nlet query = '{ users(limit: 10, sort: \"firstName ASC\", skip: 10){firstName lastName articles{title comments{text}}} }';\n```\n\nAnd you also can select those records in a period between two dates:\n\n```javascript\nlet query = '{ users(limit: 10, sort: \"firstName ASC\", skip: 10, start: \"09/21/2015\", end:\" 09/22/2015\"){firstName lastName articles{title comments{text}}} }';\n```\n\n## Useful functions (mutations)\n\n### getLatestModel (count: Int!, start: Date, end: Date)\n\nThis example will return the five latest subscribers between the September 27th\nand the September 28th 2015.\n\n```javascript\nlet query = '{ getLatestUsers(count: 5, start: \"9/27/2015\", end: \"9/28/2015\") }';\n```\n\n### getFirstModel (count: Int!, start: Date, end: Date)\n\nThis example will return the five first articles from the September 27th 2015.\n\n```javascript\nlet query = '{ getFirstArticles(count: 5, start: \"9/27/2015\") }';\n```\n\n### countModel (start: Date, end: Date)\n\nThis example will return the number of subscribers the September 28th 2015.\n\n```javascript\nlet query = '{ countUsers(start: \"9/28/2015\", end: \"9/28/2015\") }';\n```\n","readmeFilename":"README.md","users":{"ecomuere":true,"goliatone":true}}