CustomObjectDefinitions resource (Data API 23.2)
Summary
Http Method | Resource | Description |
---|---|---|
POST | /custom_object_definitions/{object_type}/attribute_definition_search |
Searches the attribute definitions of the specified custom object type. The query attribute specifies a complex query that can be used to narrow down the search. Attributes are grouped into different buckets. These are the list of searchable attributes with their corresponding buckets: Main:
Definition version:
Only attributes in the same bucket can be joined using a disjunction (OR). For instance, when joining localizable and description above, only a conjunction is allowed (AND), whereas display_name and description can be joined using a disjunction because they are in the same bucket. If an attribute is used in a disjunction (OR) that violates this rule, an exception will be thrown. Additionally, attribute definitions can also be searched by attribute group.
These attributes are not searchable or sortable for built in system attributes. They work normally for non system attributes. Note that only searchable attributes can be used in sorting. |
GET | /custom_object_definitions/{object_type}/attribute_definitions | Action to get all the attribute definitions with no filtering. |
GET | /custom_object_definitions/{object_type}/attribute_definitions/{id} | Action to get attribute definition information. |
PATCH | /custom_object_definitions/{object_type}/attribute_definitions/{id} | Updates the attribute definition with the specified information. |
DELETE | /custom_object_definitions/{object_type}/attribute_definitions/{id} | Deletes the attribute definition by ID |
PUT | /custom_object_definitions/{object_type}/attribute_definitions/{id} | Creates a attribute definition using the information provided. |
POST | /custom_object_definitions/{object_type}/attribute_group_search |
Searches for attribute groups. The query attribute specifies a complex query that can be used to narrow down the search. These are the list of searchable attributes:
The output of the query can also be sorted. These are the list of sortable attributes:
|
GET | /custom_object_definitions/{object_type}/attribute_groups | Action to get all the attribute groups with no filtering. |
PUT | /custom_object_definitions/{object_type}/attribute_groups/{group_id}/attribute_definitions/{def_id} | Assign an attribute definition to an attribute group. |
DELETE | /custom_object_definitions/{object_type}/attribute_groups/{group_id}/attribute_definitions/{def_id} | Un-assign an attribute definition from an attribute group. |
GET | /custom_object_definitions/{object_type}/attribute_groups/{id} | Action to get attribute group information. |
PATCH | /custom_object_definitions/{object_type}/attribute_groups/{id} | Updates the attribute group with the specified information. |
DELETE | /custom_object_definitions/{object_type}/attribute_groups/{id} | Deletes the attribute group by ID |
PUT | /custom_object_definitions/{object_type}/attribute_groups/{id} | Creates a attribute group using the information provided. |
Search Attribute Definitions for Custom Object
Searches the attribute definitions of the specified custom object type.
The query attribute specifies a complex query that can be used to narrow down the search. Attributes are grouped into different buckets. These are the list of searchable attributes with their corresponding buckets:
Main:
- id - String
- display_name* - Localized String
- description* - Localized String
- key - boolean
- mandatory - boolean
- searchable - boolean
- system - boolean
- visible - boolean
Definition version:
- localizable - boolean
- site_specific - boolean
- value_type - one of {string, int, double, text, html, date, image, boolean, money, quantity, datetime, email, password, set_of_string, set_of_int, set_of_double, enum_of_string, enum_of_int, unknown}
Only attributes in the same bucket can be joined using a disjunction (OR). For instance, when joining localizable and description above, only a conjunction is allowed (AND), whereas display_name and description can be joined using a disjunction because they are in the same bucket. If an attribute is used in a disjunction (OR) that violates this rule, an exception will be thrown.
- group - String
These attributes are not searchable or sortable for built in system attributes. They work normally for non system attributes.
Note that only searchable attributes can be used in sorting.
Url
POST https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_definition_search
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Request Document
Response Document
ObjectAttributeDefinitionSearchResult
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
object_type | String | The type of object | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
400 | MalformedSearchParameterException |
Indicates the query is ill-formed. | |
404 | ObjectTypeNotFoundException |
objectType (String) |
Indicates that the object type cannot be found. |
Sample
REQUEST:
POST /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definition_search HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Accept: application/json
{
"query" : {
"text_query": {
"fields": ["id", "description"],
"search_phrase": "my"
}
},
"select" : "(**)"
}
RESPONSE:
HTTP/1.1 200 OK
Content-Length: 67
Content-Type: application/json; charset=UTF-8
{
"_v" : "23.2",
"count" : 2,
"hits" : [
{
"description": {
"default": "Description",
"es": "mia description"
},
"display_name": {
"default": "default name",
"es": "nombre"
},
"key": false,
"id" : "my-attributedefinition1",
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/my-attributedefinition1",
"localizable": true,
"mandatory": false,
"queryable": true,
"searchable": false,
"system": false,
"site_specific": false,
"value_type": "string",
"visible": false
},
{
"display_name": {
"default": "second name",
"fr": "non de plume"
},
"key": true,
"id" : "my-attributedefinition2",
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/my-attributedefinition2",
"localizable": true,
"mandatory": true,
"queryable": true,
"searchable": true,
"system": false,
"site_specific": false,
"value_type": "string",
"visible": true
}
],
"query" : { "text_query": { "fields": ["id", "description"], "search_phrase": "my" } },
"select": "**",
"start" : 0,
"total" : 2
}
Get Attribute Definitions for Custom Object
Action to get all the attribute definitions with no filtering.Url
GET https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_definitions?start={Integer}&count={Integer}&select={String}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
object_type | String | mandatory=true |
Query Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
count | Integer | Optional count for retrieving only a subset of the items (default is 25). | |
select | String | The property selector. | |
start | Integer | Optional start index for retrieving the items from a given index (default 0). |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
Sample
REQUEST:
GET /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions?select=(**) HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Accept: application/json
RESPONSE:
HTTP/1.1 200 OK
Content-Length: 67
Content-Type: application/json; charset=UTF-8
{
"_v" : "23.2",
"count" : 2,
"data" : [{
"_v" : "23.2",
"description": {
"default": "Description",
"es": "mia description"
},
"display_name": {
"default": "default name",
"es": "nombre"
},
"key": false,
"id": "MyAttributeDefinition"
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition",
"localizable": true,
"mandatory": false,
"queryable": true,
"searchable": false,
"site_specific": false,
"system": false,
"value_type": "string",
"visible": false
},
{
"_v" : "23.2",
"display_name": {
"default": "Color"
},
"key": false,
"id": "color"
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/color",
"localizable": false,
"mandatory": false,
"queryable": true,
"searchable": true,
"site_specific": false,
"system": false,
"value_type": "string",
"visible": false
}],
"select": "**",
"start" : 0,
"total" : 2
}
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"_type":"fault",
"fault":{
"type":"ObjectTypeNotFoundException",
"message":"No object type with ID 'Product2' was found."
}
}
Get Attribute Definition for Custom Object
Action to get attribute definition information.Url
GET https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_definitions/{id}?expand={String}&select={String}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | The id of the requested attribute definition. | minLength=1 |
object_type | String | The object type id that contains these definitions | mandatory=true |
Query Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
expand | String | The expand "value" is available to retrieve value definitions of the attribute definition. | |
select | String | The selector for the get. If not passed, then the defaultSelector will be used instead. |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
404 | AttributeDefinitionNotFoundException |
attributeDefinitionId (String) objectDefinitionId (String) |
Thrown in case the attribute definition does not exist matching the given id |
Sample
REQUEST:
GET /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Accept: application/json
RESPONSE:
HTTP/1.1 200 OK
Content-Length: 67
Content-Type: application/json; charset=UTF-8
{
"_v" : "23.2",
"description": {
"default": "Description",
"es": "mia description"
},
"display_name": {
"default": "default name",
"es": "nombre"
},
"key": false,
"id": "MyAttributeDefinition"
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition",
"localizable": true,
"mandatory": false,
"queryable": true,
"searchable": false,
"site_specific": false,
"system": false,
"value_type": "string",
"visible": false
}
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"_type":"fault",
"fault":{
"type":"AttributeDefinitionNotFoundException",
"message":"No attribute definition with ID 'MyAttributeDefinition' for object 'Global_String' was found."
}
}
Update Attribute Definition for Custom Object
Updates the attribute definition with the specified information.Url
PATCH https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_definitions/{id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Request Document
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | The id of the requested attribute definition. | minLength=1 |
object_type | String | The object type id that contains these definitions | mandatory=true |
Header Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
If-Match | String |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
400 | AttributeDefinitionKeyReadOnlyException |
objectType (String) attributeDefinitionId (String) |
Thrown when trying to modify a key attribute of custom object |
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
404 | AttributeDefinitionNotFoundException |
attributeDefinitionId (String) objectDefinitionId (String) |
Thrown in case the attribute definition does not exist matching the given id |
Sample
REQUEST:
PATCH /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
x-dw-resource-state: 860cde3040519cce439cd99e209f8a87c3ad0b7e2813edbf6f5501f763b73bd5
{
"description": {
"default": "Modified Description"
},
"display_name": {
"sp": "nombre primero"
},
"searchable": true,
"visible": true
}
# in case of success:
RESPONSE:
HTTP/1.1 200 OK
Content-Length: 67
Content-Type: application/json; charset=UTF-8
x-dw-resource-state: 860cde3040519cce439cd99e209f8a87c3ad0b7e2813edbf6f5501f763b73bd5
{
"_v" : "23.2",
"description": {
"default": "Modified Description",
"sp": "mia description"
},
"display_name": {
"default": "default name",
"sp": "nombre primero"
},
"id": "MyAttributeDefinition",
"key": false,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition",
"localizable": true,
"mandatory": false,
"queryable": true,
"searchable": true,
"site_specific": false,
"system": false,
"value_type": "string",
"visible": true
}
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"_type":"fault",
"fault":{
"type":"AttributeDefinitionNotFoundException",
"message":"No attribute definition with ID 'MyAttributeDefinition' for object 'Global_String' was found."
}
}
Delete Attribute Definition for Custom Object
Deletes the attribute definition by IDUrl
DELETE https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_definitions/{id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | Attribute definition id to remove | minLength=1, nullable=false |
object_type | String | The metadata object that contains these definitions | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
400 | AttributeDefinitionReadOnlyException |
objectType (String) attributeDefinitionId (String) |
Thrown when trying to delete a internal attribute of custom object |
400 | AttributeDefinitionKeyReadOnlyException |
objectType (String) attributeDefinitionId (String) |
Thrown when trying to delete a key attribute of custom object |
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
404 | AttributeDefinitionNotFoundException |
attributeDefinitionId (String) objectDefinitionId (String) |
Thrown in case the attribute definition does not exist matching the given id |
Sample
REQUEST:
DELETE /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Content-Type: application/json; charset=UTF-8
# in case of success:
RESPONSE:
HTTP/1.1 204 No Content
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"_type":"fault",
"fault":{
"type":"AttributeDefinitionNotFoundException",
"message":"No attribute definition with ID 'MyAttributeDefinition' for object 'Global_String' was found."
}
}
Create Attribute Definition for Custom Object
Creates a attribute definition using the information provided.Url
PUT https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_definitions/{id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Request Document
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | The id of the attribute definition to create. | mandatory=true, nullable=false |
object_type | String | The metadata object that contains these definitions | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
400 | AttributeDefinitionKeyReadOnlyException |
objectType (String) attributeDefinitionId (String) |
Thrown when trying to create a key attribute of a custom object |
400 | AttributeDefinitionCreateException |
attributeDefinitionId (String) |
if the attribute definition could not be created. |
400 | AttributeDefinitionLocalizableNotAllowedException |
attributeDefinitionId (String) valueType (Enum {string, int, double, text, html, date, image, boolean, money, quantity, datetime, email, password, set_of_string, set_of_int, set_of_double, enum_of_string, enum_of_int, unknown}) |
if trying to create a localizable attribute with a non-localizable type |
400 | IdConflictException |
bodyID (String) urlID (String) |
if the Id in request is not the same as the ID in document. |
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
Sample
REQUEST:
PUT /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Accept: application/json
{
"description": {
"default": "Description",
"es": "mia description"
},
"display_name": {
"default": "default name",
"es": "nombre"
},
"key": false,
"localizable": true,
"mandatory": false,
"searchable": false,
"site_specific": false,
"value_type": "string",
"visible": false
}
RESPONSE:
HTTP/1.1 201 CREATED
Content-Length: 67
Location: https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition
Content-Type: application/json; charset=UTF-8
{
"_v" : "23.2",
"description": {
"default": "Description",
"es": "mia description"
},
"display_name": {
"default": "default name",
"es": "nombre"
},
"id": "MyAttributeDefinition",
"key": false,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_definitions/MyAttributeDefinition",
"localizable": true,
"mandatory": false,
"queryable": true,
"searchable": false,
"site_specific": false,
"system": false,
"value_type": "string",
"visible": false
}
Search Attribute Groups for Custom Object
Searches for attribute groups.
The query attribute specifies a complex query that can be used to narrow down the search. These are the list of searchable attributes:
- id - String
- display_name - Localized <String>
- description - Localized <String>
- position - Double
- internal - Boolean
The output of the query can also be sorted. These are the list of sortable attributes:
- id - String
- display_name - Localized <String>
- description - Localized <String>
- position - Double
- internal - Boolean
Url
POST https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_group_search
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Request Document
Response Document
ObjectAttributeGroupSearchResult
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
object_type | String | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
400 | MalformedSearchParameterException |
Thrown if the query is ill-formed. | |
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
Sample
REQUEST:
POST /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_group_search HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Accept: application/json
{
"query" : {
"text_query": {
"fields": ["id", "description"],
"search_phrase": "my"
}
},
"select" : "(**)"
}
RESPONSE:
HTTP/1.1 200 OK
Content-Length: 67
Content-Type: application/json; charset=UTF-8
{
"_v" : "23.2",
"count" : 2,
"hits" : [
{
"id" : "my-attributegroup1",
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 1.0,
"internal" : false,
"definitions_count" : 5,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup1"
},
{
"id" : "my-attributegroup2",
"display_name" : {
"default" : "my-display_name"
},
"position" : 2.0,
"internal" : false,
"definitions_count" : 12,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup2"
}
],
"query" : { "text_query": { "fields": ["id", "description"], "search_phrase": "my" } },
"select": "**",
"start" : 0,
"total" : 2
}
Get Attribute Groups for Custom Object
Action to get all the attribute groups with no filtering.Url
GET https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups?start={Integer}&count={Integer}&select={String}&expand={String}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
object_type | String | mandatory=true |
Query Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
count | Integer | Optional count for retrieving only a subset of the items (default is 25). | |
expand | String | ||
select | String | The property selector. | |
start | Integer | Optional start index for retrieving the items from a given index (default 0). |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
Sample
REQUEST:
GET /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups?select=(**) HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Content-Type: application/json; charset=UTF-8
# in case of success:
RESPONSE:
HTTP/1.1 200 OK
Expires: Thu, 01-Aug-2014 00:00:00 GMT
{
"_v" : "23.2",
"count" : 2,
"data" : [{
"_v" : "23.2",
"id" : "my-attributegroup",
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 1.0,
"internal" : false,
"definitions_count" : 17,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_objects/Global_String/attribute_groups/my-attributegroup"
},
{
"_v" : "23.2",
"id" : "my-attributegroup2",
"display_name" : {
"default" : "my-display_name2"
},
"description" : {
"default" : "my-description2"
},
"position" : 2.0,
"internal" : false,
"definitions_count" : 4,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_objects/Global_String/attribute_groups/my-attributegroup2"
}],
"select": "**",
"start" : 0,
"total" : 2
}
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Expires: Thu, 01-Jan-1970 00:00:00 GMT
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"ObjectTypeNotFoundException",
"message":"No object type with ID 'Global_String' was found."
}
}
Assign Custom Object Attribute Definition to Attribute Group
Assign an attribute definition to an attribute group.Url
PUT https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups/{group_id}/attribute_definitions/{def_id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
def_id | String | The ID of the attribute definition. | minLength=1 |
group_id | String | The ID of the attribute group. | minLength=1 |
object_type | String | The ID of the custom object that contains the attribute definition and attribute group. | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Indicates the specified custom object is not found. |
404 | AttributeGroupNotFoundException |
attributeGroupId (String) |
Indicates the specified attribute group is not found. |
404 | AttributeDefinitionNotFoundException |
attributeDefinitionId (String) objectDefinitionId (String) |
Indicates the specified attribute definition is not found. |
Sample
REQUEST:
PUT /s/-/dw/data/v23_2/custom_object_definitions/my-object/attribute_groups/my-attributegroup/attribute_definitions/my-attributedef HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
# in case of success:
RESPONSE:
HTTP/1.1 204 No Content
Content-Length: 67
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"ObjectTypeNotFoundException",
"message":"No object type with ID 'my-object' was found."
}
}
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeGroupNotFoundException",
"message":No attribute group with ID 'my-attributegroup' was found.
}
}
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeDefinitionNotFoundException",
"message":"No attribute definition with ID 'my-attributedef' for object 'my-object' was found.
}
}
Un-assign Custom Object Attribute Definition from Attribute Group
Un-assign an attribute definition from an attribute group.Url
DELETE https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups/{group_id}/attribute_definitions/{def_id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
def_id | String | The ID of the attribute definition. | minLength=1 |
group_id | String | The ID of the attribute group. | minLength=1 |
object_type | String | The ID of the custom object that contains the attribute definition and attribute group. | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Indicates the specified custom object is not found. |
404 | AttributeGroupNotFoundException |
attributeGroupId (String) |
Indicates the specified attribute group is not found. |
404 | AttributeDefinitionNotFoundException |
attributeDefinitionId (String) objectDefinitionId (String) |
Indicates the specified attribute definition is not found. |
Sample
REQUEST:
DELETE /s/-/dw/data/v23_2/custom_object_definitions/my-object/attribute_groups/my-attributegroup/attribute_definitions/my-attributedef HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
# in case of success:
RESPONSE:
HTTP/1.1 204 No Content
Content-Length: 67
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"ObjectTypeNotFoundException",
"message":"No object type with ID 'my-object' was found."
}
}
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeGroupNotFoundException",
"message":No attribute group with ID 'my-attributegroup' was found.
}
}
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeDefinitionNotFoundException",
"message":"No attribute definition with ID 'my-attributedef' for object 'my-object' was found.
}
}
Get Attribute Group for Custom Object
Action to get attribute group information.Url
GET https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups/{id}?select={String}&expand={String}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | The id of the requested attribute group. | minLength=1 |
object_type | String | the object type id that contains this attribute group | mandatory=true |
Query Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
expand | String | ||
select | String |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
404 | AttributeGroupNotFoundException |
attributeGroupId (String) |
Thrown in case the attribute group does not exist matching the given id |
Sample
REQUEST:
GET /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Content-Type: application/json; charset=UTF-8
# in case of success:
RESPONSE:
HTTP/1.1 200 OK
Expires: Thu, 01-Aug-2014 00:00:00 GMT
x-dw-resource-state: 43c2d7a118bd0a4034399ed86c86654b40c198ea64fd3195e5587d9211d10d7e
{
"_v" : "23.2",
"id" : "my-attributegroup",
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 1.0,
"internal" : false,
"definitions_count" : 17,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_objects/Global_String/attribute_groups/my-attributegroup"
}
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Expires: Thu, 01-Jan-1970 00:00:00 GMT
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeGroupNotFoundException",
"message":"No attribute group with ID 'my-attributegroup' was found."
}
}
Update Attribute Group for Custom Object
Updates the attribute group with the specified information.Url
PATCH https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups/{id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Request Document
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | The id of the requested attribute group. | minLength=1 |
object_type | String | the object type id that contains this attribute group | mandatory=true |
Header Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
If-Match | String |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
404 | AttributeGroupNotFoundException |
attributeGroupId (String) |
Thrown in case the attribute group does not exist matching the given id |
Sample
REQUEST:
PATCH /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
x-dw-resource-state: 860cde3040519cce439cd99e209f8a87c3ad0b7e2813edbf6f5501f763b73bd5
{
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 11.0,
"internal" : false
}
# in case of success:
RESPONSE:
HTTP/1.1 200 OK
Content-Length: 67
Content-Type: application/json; charset=UTF-8
x-dw-resource-state: 860cde3040519cce439cd99e209f8a87c3ad0b7e2813edbf6f5501f763b73bd5
{
"_v" : "23.2",
"id" : "my-attributegroup",
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 11.0,
"internal" : false,
"definitions_count" : 17,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup"
}
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeGroupNotFoundException",
"message":"No attribute group with ID 'my-attributegroup' was found."
}
}
Delete Attribute Groups for Custom Object
Deletes the attribute group by IDUrl
DELETE https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups/{id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | One attribute group id to remove | |
object_type | String | the object type id that contains this attribute group | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
404 | AttributeGroupNotFoundException |
attributeGroupId (String) |
Thrown in case the attribute group does not exist matching the given id |
Sample
REQUEST:
DELETE /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
# in case of success:
RESPONSE:
HTTP/1.1 204 No Content
# in case of failure:
RESPONSE:
HTTP/1.1 404 Not Found
Expires: Thu, 01-Jan-1970 00:00:00 GMT
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeGroupNotFoundException",
"message":"No attribute group with ID 'my-attributegroup' was found."
}
}
Create Attribute Group for Custom Object
Creates a attribute group using the information provided.Url
PUT https://hostname:port/dw/data/v23_2/custom_object_definitions/{object_type}/attribute_groups/{id}
Formats
json, xml
Authentication
Name | Description |
---|---|
OAuth | Authentication via OAuth token. |
Request Document
Response Document
Path Parameters
Parameter | Type | Description | Constraints |
---|---|---|---|
id | String | The id of the attribute group to create. | minLength=1 |
object_type | String | the object type id that contains this attribute group | mandatory=true |
In case of a failure Fault Document is returned.
Faults
Status | Type | Arguments | Description |
---|---|---|---|
400 | IdConflictException |
bodyID (String) urlID (String) |
when the id in the body does not match that provided in the URL |
404 | ObjectTypeNotFoundException |
objectType (String) |
Thrown in case the object type cannot be found |
Sample
REQUEST:
PUT /s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
{
"_v" : "23.2",
"id" : "attributegroup1",
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 1.0,
}
# in case of success:
RESPONSE:
HTTP/1.1 201 CREATED
Content-Length: 67
Location: https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup
Content-Type: application/json; charset=UTF-8
x-dw-resource-state: 860cde3040519cce439cd99e209f8a87c3ad0b7e2813edbf6f5501f763b73bd5
{
"_v" : "23.2",
"id" : "attributegroup1",
"display_name" : {
"default" : "my-display_name",
"en" : "An English my-display_name",
"de" : "A German my-display_name"
},
"description" : {
"default" : "my-description",
"en" : "An English my-description",
"de" : "A German my-description"
},
"position" : 1.0,
"internal" : true,
"definitions_count" : 0,
"link" : "https://example.com/s/-/dw/data/v23_2/custom_object_definitions/Global_String/attribute_groups/my-attributegroup"
}
# in case of failure:
RESPONSE:
HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
"_v" : "23.2",
"fault":{
"type":"AttributeGroupCreateException",
"message":"The attribute group with ID 'my-attributegroup' could not be created.
}
}