Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/api-docs/paths/path-admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,10 @@ export default {
type: 'object',
properties: {
token: {
refreshToken: 'string'
type: 'string'
},
refreshToken: {
type: 'string'
}
}
}
Expand Down
14 changes: 7 additions & 7 deletions src/api-docs/paths/path-client.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ export default {
description: 'Execute criteria query against the API settings',
security: [{ appAuth: [] }],
parameters: [
queryParameter('key', 'string', 'Switcher Key', true),
queryParameter('showReason', 'boolean', 'Show criteria execution reason (default: true)', false),
queryParameter('showStrategy', 'boolean', 'Show criteria execution strategy (default: true)', false),
queryParameter('bypassMetric', 'boolean', 'Bypass metric check (default: true)', false)
queryParameter('key', 'Switcher Key', true, 'string'),
queryParameter('showReason', 'Show criteria execution reason (default: true)', false, 'boolean'),
queryParameter('showStrategy', 'Show criteria execution strategy (default: true)', false, 'boolean'),
queryParameter('bypassMetric', 'Bypass metric check (default: true)', false, 'boolean')
],
requestBody: {
content: {
Expand Down Expand Up @@ -56,7 +56,7 @@ export default {
},
strategies: {
type: 'array',
items: configStrategy
items: configStrategy.ConfigStrategy
}
}
}
Expand All @@ -66,13 +66,13 @@ export default {
}
}
},
'/criteria/snapshot_check/:version': {
'/criteria/snapshot_check/{version}': {
get: {
tags: ['Client API'],
description: 'Check if snapshot version is up to date',
security: [{ appAuth: [] }],
parameters: [
pathParameter('version', 'string', 'Snapshot version', true)
pathParameter('version', 'Snapshot version', true)
],
responses: {
200: {
Expand Down
14 changes: 7 additions & 7 deletions src/api-docs/paths/path-component.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ export default {
}
}
},
'/component/generateApiKey/:component/': {
'/component/generateApiKey/{component}': {
get: {
tags: ['Component'],
description: 'Generate an API key for a component',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('component', 'Component ID', 'string', true)
pathParameter('component', 'Component ID', true)
],
responses: {
200: {
Expand All @@ -51,7 +51,7 @@ export default {
description: 'Get all components',
security: [{ bearerAuth: [] }],
parameters: [
queryParameter('domain', 'Domain ID', 'string', true),
queryParameter('domain', 'Domain ID', true, 'string'),
...pagination
],
responses: {
Expand All @@ -62,13 +62,13 @@ export default {
}
}
},
'/component/:id': {
'/component/{id}': {
get: {
tags: ['Component'],
description: 'Get a component',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Component ID', 'string', true)
pathParameter('id', 'Component ID', true)
],
responses: {
200: {
Expand All @@ -82,7 +82,7 @@ export default {
description: 'Update a component',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Component ID', 'string', true),
pathParameter('id', 'Component ID', true),
],
requestBody: {
content: {
Expand Down Expand Up @@ -113,7 +113,7 @@ export default {
description: 'Delete a component',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Component ID', 'string', true)
pathParameter('id', 'Component ID', true)
],
responses: {
200: {
Expand Down
28 changes: 15 additions & 13 deletions src/api-docs/paths/path-config-strategy.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export default {
}
}
},
'/configstrategy/:id': {
'/configstrategy/{id}': {
get: {
tags: ['ConfigStrategy'],
description: 'Get a Config Strategy',
Expand Down Expand Up @@ -105,7 +105,7 @@ export default {
}
}
},
'/configstrategy/history/:id': {
'/configstrategy/history/{id}': {
get: {
tags: ['ConfigStrategy'],
description: 'Get a Config Strategy history',
Expand Down Expand Up @@ -136,7 +136,7 @@ export default {
}
}
},
'/configstrategy/req/:strategy': {
'/configstrategy/req/{strategy}': {
get: {
tags: ['ConfigStrategy'],
description: 'Get Config Strategy requirements specification',
Expand Down Expand Up @@ -172,11 +172,13 @@ export default {
'application/json': {
schema: {
type: 'object',
strategiesAvailable: {
type: 'array',
items: {
type: 'string',
enum: Object.values(StrategiesType)
properties: {
strategiesAvailable: {
type: 'array',
items: {
type: 'string',
enum: Object.values(StrategiesType)
}
}
}
}
Expand All @@ -186,7 +188,7 @@ export default {
}
}
},
'/configstrategy/addval/:id': {
'/configstrategy/addval/{id}': {
patch: {
tags: ['ConfigStrategy'],
description: 'Add a value to a Config Strategy',
Expand Down Expand Up @@ -216,7 +218,7 @@ export default {
}
}
},
'/configstrategy/updateval/:id': {
'/configstrategy/updateval/{id}': {
patch: {
tags: ['ConfigStrategy'],
description: 'Update a value of a Config Strategy',
Expand Down Expand Up @@ -249,7 +251,7 @@ export default {
}
}
},
'/configstrategy/removeval/:id': {
'/configstrategy/removeval/{id}': {
patch: {
tags: ['ConfigStrategy'],
description: 'Remove a value of a Config Strategy',
Expand Down Expand Up @@ -279,7 +281,7 @@ export default {
}
}
},
'/configstrategy/values/:id': {
'/configstrategy/values/{id}': {
get: {
tags: ['ConfigStrategy'],
description: 'Get a Config Strategy values',
Expand All @@ -305,7 +307,7 @@ export default {
}
}
},
'/configstrategy/updateStatus/:id': {
'/configstrategy/updateStatus/{id}': {
patch: {
tags: ['ConfigStrategy'],
description: 'Update a Config Strategy status',
Expand Down
10 changes: 8 additions & 2 deletions src/api-docs/paths/path-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ export default {
parameters: [
...pagination,
queryParameter('group', 'Group ID', true),
queryParameter('fields', 'Fields to return', false, 'string', 'E.g.: key,description,activated.default')
queryParameter('fields', 'Fields to return - E.g.: key,description,activated.default', false, 'string')
],
responses: {
'200': {
Expand All @@ -339,7 +339,10 @@ export default {
tags: ['Config'],
description: 'Get Config history',
security: [{ bearerAuth: [] }],
parameters: [...pagination],
parameters: [
pathParameter('id', 'Config ID', true),
...pagination
],
responses: {
'200': {
description: 'Success',
Expand All @@ -351,6 +354,9 @@ export default {
tags: ['Config'],
description: 'Delete Config history',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Config ID', true)
],
responses: {
'200': {
description: 'Success',
Expand Down
10 changes: 8 additions & 2 deletions src/api-docs/paths/path-domain.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { pagination, pathParameter } from '../schemas/common';
import { commonArraySchemaContent, commonSchemaContent } from './common';

export default {
'domain/create': {
'/domain/create': {
post: {
tags: ['Domain'],
description: 'Domain creation',
Expand Down Expand Up @@ -225,7 +225,10 @@ export default {
tags: ['Domain'],
description: 'Get domain history',
security: [{ bearerAuth: [] }],
parameters: [...pagination],
parameters: [
pathParameter('id', 'Domain ID', true),
...pagination
],
responses: {
'200': {
description: 'Success',
Expand All @@ -237,6 +240,9 @@ export default {
tags: ['Domain'],
description: 'Delete domain history',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Domain ID', true)
],
responses: {
'200': {
description: 'Success',
Expand Down
12 changes: 6 additions & 6 deletions src/api-docs/paths/path-environment.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export default {
description: 'Get all environments',
security: [{ bearerAuth: [] }],
parameters: [
queryParameter('domain', 'Domain ID', 'string', true),
queryParameter('domain', 'Domain ID', true, 'string'),
...pagination
],
responses: {
Expand All @@ -35,13 +35,13 @@ export default {
}
}
},
'/environment/:id': {
'/environment/{id}': {
get: {
tags: ['Environment'],
description: 'Get an environment',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Environment ID', 'string', true)
pathParameter('id', 'Environment ID', true)
],
responses: {
200: {
Expand All @@ -55,7 +55,7 @@ export default {
description: 'Delete an environment',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Environment ID', 'string', true)
pathParameter('id', 'Environment ID', true)
],
responses: {
200: {
Expand All @@ -65,13 +65,13 @@ export default {
}
}
},
'/environment/recover/:id': {
'/environment/recover/{id}': {
patch: {
tags: ['Environment'],
description: 'Recover an environment',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'Environment ID', 'string', true)
pathParameter('id', 'Environment ID', true)
],
responses: {
200: {
Expand Down
18 changes: 9 additions & 9 deletions src/api-docs/paths/path-group-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export default {
description: 'Get all group configs',
security: [{ bearerAuth: [] }],
parameters: [
queryParameter('domain', 'Domain ID', 'string', true),
queryParameter('domain', 'Domain ID', true, 'string'),
...pagination
],
responses: {
Expand All @@ -35,13 +35,13 @@ export default {
}
}
},
'/groupconfig/:id': {
'/groupconfig/{id}': {
get: {
tags: ['GroupConfig'],
description: 'Get a group config',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'GroupConfig ID', 'string', true)
pathParameter('id', 'GroupConfig ID', true)
],
responses: {
200: {
Expand All @@ -55,7 +55,7 @@ export default {
description: 'Delete a group config',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'GroupConfig ID', 'string', true)
pathParameter('id', 'GroupConfig ID', true)
],
responses: {
200: {
Expand All @@ -69,7 +69,7 @@ export default {
description: 'Update a group config',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'GroupConfig ID', 'string', true)
pathParameter('id', 'GroupConfig ID', true)
],
requestBody: {
content: {
Expand All @@ -96,13 +96,13 @@ export default {
}
}
},
'/groupconfig/history/:id': {
'/groupconfig/history/{id}': {
get: {
tags: ['GroupConfig'],
description: 'Get a Group Config history',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'GroupConfig ID', 'string', true),
pathParameter('id', 'GroupConfig ID', true),
...pagination
],
responses: {
Expand All @@ -117,7 +117,7 @@ export default {
description: 'Delete a group config history',
security: [{ bearerAuth: [] }],
parameters: [
pathParameter('id', 'GroupConfig ID', 'string', true)
pathParameter('id', 'GroupConfig ID', true)
],
responses: {
200: {
Expand All @@ -127,7 +127,7 @@ export default {
}
}
},
'/groupconfig/updateStatus/:id': {
'/groupconfig/updateStatus/{id}': {
patch: {
tags: ['GroupConfig'],
description: 'Group Config environment update',
Expand Down
Loading