@steedos/service-api 2.2.73 → 2.2.75

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +5 -2
  2. package/package.json +5 -4
package/index.js CHANGED
@@ -12,6 +12,9 @@ const {
12
12
 
13
13
  const _ = require('lodash');
14
14
 
15
+ const validator = require('validator');
16
+ const enablePlayground = validator.toBoolean(process.env.STEEDOS_GRAPHQL_ENABLE_CONSOLE || 'true', true)
17
+
15
18
  /**
16
19
  * @typedef {import('moleculer').Context} Context Moleculer's Context
17
20
  * @typedef {import('http').IncomingMessage} IncomingRequest Incoming HTTP Request
@@ -82,11 +85,11 @@ module.exports = {
82
85
  apiKey: process.env.APOLLO_ENGINE_KEY
83
86
  },
84
87
  subscriptions: false,
85
- playground: {
88
+ playground: enablePlayground ? {
86
89
  settings: {
87
90
  'request.credentials': 'same-origin'
88
91
  }
89
- },
92
+ }: false,
90
93
  introspection: true
91
94
  }
92
95
  })
package/package.json CHANGED
@@ -1,20 +1,21 @@
1
1
  {
2
2
  "name": "@steedos/service-api",
3
- "version": "2.2.73",
3
+ "version": "2.2.75",
4
4
  "main": "index.js",
5
5
  "license": "MIT",
6
6
  "dependencies": {
7
- "@steedos/auth": "2.2.73",
7
+ "@steedos/auth": "2.2.75",
8
8
  "graphql": "^15.8.0",
9
9
  "graphql-iso-date": "^3.6.1",
10
10
  "graphql-type-json": "^0.3.2",
11
11
  "moleculer": "^0.14.21",
12
12
  "moleculer-apollo-server": "^0.3.6",
13
- "moleculer-web": "^0.10.4"
13
+ "moleculer-web": "^0.10.4",
14
+ "validator": "^13.6.0"
14
15
  },
15
16
  "private": false,
16
17
  "publishConfig": {
17
18
  "access": "public"
18
19
  },
19
- "gitHead": "d5ea4eb9a8d9f53e36dd52bd8023643621077be9"
20
+ "gitHead": "790f79e47209ee16c8dc01dafdf068b31a048330"
20
21
  }