Create Data Element

POST /ws/rest/service/v1/ds/data-elements

Version: 20.10

Purpose

To create custom data elements

Request Format

All parameters should be URL encoded.

Both input and output in JSON format in the body.

Request Parameters

The following parameters can be included in the request:

Request Parameter

Required?

Description

data_element

Yes

Name of the unique data element

data_definition

Yes

Field definition to create the data element of that type

form_label

Yes

The DE label name

Description

No

 

Tooltip

No

 

Valid Fields Based on the data_definition Value

Specify the following field for a data element that has the corresponding data_definition value.

Data Element Field

Required

data_definition Value

height

Yes

Image Picker

height

Yes

SYS Rich Text

no_of_lines

Yes

textarea (as data_source)

decimal_format (default value is '8')

No

Decimal Amount

hide_currency_symbol (valid values are Yes, and No (default).

No

SYS Numeric Query Based

Response Format

A JSON object is returned in the following format:

{

"data": [],

"message": [],

"status": <REST status code value>

}

A successful response displays a status code 200.

A failed response displays a message with a status code.

Sample Request

This is an example of a sample request.

{

"data": [

{

"data_element": "sampleDE",

"data_definition": "Decimal Amount",

"form_label": "Sample Decimal Element",

"description": "Test DE",

"decimal_format": "5"

},

{

"data_element": "sampleImgDE",

"data_definition": "Image Picker",

"form_label": "Sample Image Picker",

"description": "Test Image DE",

"tooltip": "Test Image DE"

}

]

}

Sample Partial Success Response

This is an example of a response that created the data element SampleDE, but failed creating the data element, sampleImgDE.

{

"data": [

{

"data_element": "sampleDE",

"data_definition": "Decimal Amount",

"form_label": "Sample Decimal Element",

"description": "Test DE",

"tooltip": null,

"decimal_format": "5" ,

"Pre-Defined Category": null

}

],

"message": [

{

"data_element": "sampleDE",

"message": "success"

},

{

"data_element": "sampleImgDE",

"message": "height is required",

"status": 505

}

],

"status": 3000

}

Supported Validation Messages and Status Codes

The following status codes and messages can display in the response to a request.

Status Code

Validation Message

200

Success

1101

Empty or Invalid JSON data

3000

Partial create

3002

Invalid JSON input

Related Topics

Data Structure Setup

Authorization

Get Data Elements

Update Data Element

Delete Data Elements

Create DDS Definition

Update DDS Definition

Delete DDS Definition

Get DDS Definition

Create DDS Data

Update DDS Data

Delete DDS Data

Get DDS Data

Get Data Definition

Create Data Definition

Update Data Definition

Delete Data Definition

Response Error Codes



Last Published Tuesday, July 1, 2025