FlexibleForms Configs Storage version v1.0
http://localhost
Forms Configs Storage API
API for accessing flexible forms configs
/converter-storage/forms/configs
API for managing form configs
Create new form config
Retrieve a list of config items.
post /converter-storage/forms/configs
Create new form config
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Flexible form config",
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"description": "UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"formName": {
"description": "Name of corresponding form",
"type": "string"
},
"config": {
"description": "Form config content"
}
},
"required": [
"formName",
"config"
]
}
Example:
{
"jobExecutionId": "67dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "NEW"
}
HTTP status code 201
Returns a newly created item, with server-controlled fields like 'id' populated
Headers
- Location: required(string)
URI to the created config item
Body
Media type: application/json
Type: any
Example:
{
"jobExecutionId": "67dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "NEW"
}
HTTP status code 400
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Body
Media type: text/plain
Type: any
Example:
"unable to add config -- malformed JSON at 13:3"
HTTP status code 401
Not authorized to perform requested action
Body
Media type: text/plain
Type: any
Example:
unable to create configs -- unauthorized
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: text/plain
Type: any
Example:
Internal server error, contact administrator
get /converter-storage/forms/configs
Retrieve a list of config items.
HTTP status code 200
Returns a list of config items
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Collection of forms configs",
"type": "object",
"additionalProperties": false,
"properties": {
"formConfigs": {
"description": "List of forms configs",
"type": "array",
"id": "formConfigList",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Flexible form config",
"additionalProperties": false,
"properties": {
"id": {
"description": "UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"formName": {
"description": "Name of corresponding form",
"type": "string"
},
"config": {
"description": "Form config content"
}
},
"required": [
"formName",
"config"
]
}
},
"totalRecords": {
"description": "Total number of forms configs",
"type": "integer"
}
},
"required": [
"formConfigs",
"totalRecords"
]
}
Example:
{
"snapshots": [
{
"jobExecutionId": "67dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "NEW"
},
{
"jobExecutionId": "17dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "PARSING_IN_PROGRESS"
},
{
"jobExecutionId": "27dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "PARSING_IN_PROGRESS"
}
],
"totalRecords": 3
}
HTTP status code 400
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Body
Media type: text/plain
Type: any
Example:
unable to list configs -- malformed parameter 'query', syntax error at column 6
HTTP status code 401
Not authorized to perform requested action
Body
Media type: text/plain
Type: any
Example:
unable to list configs -- unauthorized
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: text/plain
Type: any
Example:
internal server error, contact administrator
Get, Delete or Update a specific form config by form name
Update config item with given {configId}
Delete config item with given {configId}
Retrieve config item with given {configId}
put /converter-storage/forms/configs/{formName}
Update config item with given {configId}
URI Parameters
- formName: required(string)
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Flexible form config",
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"description": "UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"formName": {
"description": "Name of corresponding form",
"type": "string"
},
"config": {
"description": "Form config content"
}
},
"required": [
"formName",
"config"
]
}
Example:
{
"jobExecutionId": "67dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "NEW"
}
HTTP status code 200
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Flexible form config",
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"description": "UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"formName": {
"description": "Name of corresponding form",
"type": "string"
},
"config": {
"description": "Form config content"
}
},
"required": [
"formName",
"config"
]
}
HTTP status code 204
Item successfully updated
HTTP status code 400
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Body
Media type: text/plain
Type: any
Example:
"unable to update config -- malformed JSON at 13:4"
HTTP status code 404
Item with a given ID not found
Body
Media type: text/plain
Type: any
Example:
"config not found"
HTTP status code 409
Optimistic locking version conflict
Body
Media type: text/plain
Type: any
Example:
version conflict
HTTP status code 422
Validation errors
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: text/plain
Type: any
Example:
internal server error, contact administrator
delete /converter-storage/forms/configs/{formName}
Delete config item with given {configId}
URI Parameters
- formName: required(string)
HTTP status code 204
Item deleted successfully
HTTP status code 400
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Body
Media type: text/plain
Type: any
Example:
"unable to delete config -- constraint violation"
HTTP status code 404
Item with a given ID not found
Body
Media type: text/plain
Type: any
Example:
"config not found"
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: text/plain
Type: any
Example:
Internal server error, contact administrator
get /converter-storage/forms/configs/{formName}
Retrieve config item with given {configId}
URI Parameters
- formName: required(string)
HTTP status code 200
Returns item with a given ID
Body
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Flexible form config",
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"description": "UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"formName": {
"description": "Name of corresponding form",
"type": "string"
},
"config": {
"description": "Form config content"
}
},
"required": [
"formName",
"config"
]
}
Example:
{
"jobExecutionId": "67dfac11-1caf-4470-9ad1-d533f6360bdd",
"status": "NEW"
}
HTTP status code 404
Item with a given ID not found
Body
Media type: text/plain
Type: any
Example:
"config not found"
HTTP status code 500
Internal server error, e.g. due to misconfiguration
Body
Media type: text/plain
Type: any
Example:
internal server error, contact administrator