Method
|
POST
|
URL
|
/v2/<object_full_identifier>/fields
|
Parameters
|
|
Response Content Type
|
application/json
|
Field
|
Description
|
Type
|
Required
|
---|---|---|---|
io_name
|
Name of the field to create
|
String
|
Yes
|
io_identifier
|
Identifier of the field to create
|
String
|
Yes
|
io_namespace
|
Namespace of the field to create, specified with the identifier of the namespace.
|
String
|
Yes
|
io_application
|
Application of the field to create, with the application name specified.
|
String
|
Yes
|
io_datatype
|
Data type of the field to create, with the data type identifier specified.
|
String
|
Yes
|
Fields with the Relationship data type
|
Relationship related to the field to create.
|
JSON code that specifies relationship data.
|
Yes
|
Fields with the Dynamic Relationship data type
|
Dynamic relationship related to the field to create.
|
JSON code that specifies dynamic relationship data.
|
Yes
|
Fields with the Option List data type
|
Option list related to the field to create.
|
JSON array that specifies option list values.
|
Yes
|
io_<identifier>
|
Nonmandatory field attributes
|
Based on the field data type, JSON representation as described in REST API Data Type Representation.
|
Not required. If not set, default values apply.
|
Field
|
Description
|
Type
|
Required
|
---|---|---|---|
io_type
|
The relationship type. Supported values are referential, master, and hierarchical.
|
String
|
Yes
|
targets
|
An array that specifies the target objects for the relationship by their full identifiers.
|
Array of String
|
Not required if hasAllTargets is set to true, required otherwise.
|
hasAllTargets
|
Attribute that specifies the relationship can have any target object. This removes the need to specify all platform objects in the targets array and applies only to dynamic relationships.
|
Boolean
|
Not required. If hasAllTargets is set to true and objects are specified in the targets array, an error is thrown.
|
io_name
|
Name of the relationship to create.
|
String
|
Not required. If not specified, the source object and field identifier are combined and used to set this value.
|
io_identifier
|
Identifier of the relationship to create.
|
String
|
Not required. If not specified, the source object and field identifier are combined and used to set this value.
|
Field
|
Description
|
Type
|
Required
|
---|---|---|---|
io_name
|
Name of the option to create.
|
String
|
Yes
|
io_identifier
|
Identifier of the option to create.
|
String
|
Yes
|
HTTP Status Code
|
Error Message
|
---|---|
400
|
The body of the request is empty
|
400
|
The body of the request has invalid format
|
400
|
The required parameters are not informed
|
500
|
Body: Error Creating Fields. Exception={...}
Status: Internal Server error
|