PIMS View Dictionary Management API
POST/pim/manage/views
- Requires Data Manager ApiKey permissions.
- Example URI: https://instancename.piminto.com/api/en-us/pim/manage/views
Views enable efficient access to specific and essential product information. By setting data filters within views, you can conveniently retrieve a refined subset of data (products) based on attribute values. Configure views for various purposes and assign them to corresponding users.
To utilize this API, send a POST request with a JSON body. Set the action key in the JSON body to one of the following values:
- listPimViews: Retrieve information about all Views in PIMS.
- addPimView: Add a new View to PIMS.
- editPimView: Modify information about an existing View in PIMS.
- deletePimView: Delete a View.
Below is the description of the JSON keys for the PimView object:
- name: The name of the PIM View.
- comment: A comment or description of the View.
- label: Describes the label associated with the PIM View. The label is used as an identifier or descriptor for the view and aids in user understanding.
- attributes: A list of JSON objects in which the attributes serve as keys. ✔Please ensure that the attributes listed exist within the PIMS system.
JSON keys for the attribute object:
- attribute: Attribute names.
- readonly: Specifies whether the attribute is read-only.
- group: Specifies the group to which the attribute belongs.
- transform: Defines any attribute transformations, mapping original attribute names to desired names.
- default: Specifies the default value for the attribute. This value is used when creating a product if no specific value is provided.
In all APIs that return a product object using a View, only the attributes that were defined within the View will be returned. This ensures that you receive only the specific attributes of the product that were specified in the View.
Feel free to modify the JSON body according to your requirements while adhering to the provided structure and keys.
Use Example Value and Schema for Json requests
Request
- application/json
Body
required
- List Pim Views
- Add/Edit Pim View
- Delete Pim View
Possible values: [listViews
]
Possible values: [addPimView
, editPimView
]
The name of the PIM View
definition objectrequired
attributes objectrequired
A list of JSON objects in which the attributes serve as keys
nameattribute objectrequired
attribute name
Possible values: [true
, false
]
Specifies whether the attribute is read-only
Specifies the group to which the attribute belongs
Defines any attribute transformations, mapping original attribute names to desired names
Specifies the default value for the attribute. This value is used when creating a product if no specific value is provided
A comment or description of the View
Describes the label associated with the PIM View. The label is used as an identifier or descriptor for the view and aids in user understanding.
Possible values: [deletePimView
]
The name of the PIM View
Responses
- 200
- default
success
- application/json
- Schema
- Example (from schema)
- List Pim Views
- Add/Edit Pim View
- Delete Pim View
Schema
- List Pim Views
- Add/Edit Pim View
- Delete Pim View
- Array [
- ]
data object[]
Collection objects PimView
definition objectrequired
attributes objectrequired
A list of JSON objects in which the attributes serve as keys
nameattribute objectrequired
attribute name
Possible values: [true
, false
]
Specifies whether the attribute is read-only
Specifies the group to which the attribute belongs
Defines any attribute transformations, mapping original attribute names to desired names
Specifies the default value for the attribute. This value is used when creating a product if no specific value is provided
A comment or description of the View
Describes the label associated with the PIM View. The label is used as an identifier or descriptor for the view and aids in user understanding.
data objectrequired
definition objectrequired
attributes objectrequired
A list of JSON objects in which the attributes serve as keys
nameattribute objectrequired
attribute name
Possible values: [true
, false
]
Specifies whether the attribute is read-only
Specifies the group to which the attribute belongs
Defines any attribute transformations, mapping original attribute names to desired names
Specifies the default value for the attribute. This value is used when creating a product if no specific value is provided
A comment or description of the View
Describes the label associated with the PIM View. The label is used as an identifier or descriptor for the view and aids in user understanding.
Provides additional information about the API execution result, if available.
The status of the API request. A value of "OK" indicates that the request was successfully sent and processed.
{}
{
"data": [
{
"name": "namepimview",
"definition": {
"attributes": {
"sku": {
"group": "Basic",
"readonly": true,
"transform": "",
"default": ""
},
"status": {
"readonly": false,
"group": "Basic",
"transform": "",
"default": "inactive"
},
"title": {
"readonly": false,
"group": "Basic",
"transform": "",
"default": ""
},
"variation_of": {
"readonly": false,
"group": "",
"transform": "",
"default": ""
},
"variation_attributes": {
"group": "",
"readonly": false,
"transform": "",
"default": ""
},
"variation_skus": {
"group": "",
"readonly": false,
"default": "",
"transform": ""
},
"thumbnail": {
"readonly": false,
"group": "Basic",
"transform": "",
"efault": ""
},
"categories": {
"transform": "",
"default": "",
"readonly": false,
"group": "Basic"
}
},
"label": "Store",
"comment": "For store site"
}
}
],
"status": "OK"
}
{
"data": {
"name": "namepimview",
"definition": {
"attributes": {
"sku": {
"group": "Basic",
"readonly": true,
"transform": "",
"default": ""
},
"status": {
"readonly": false,
"group": "Basic",
"transform": "",
"default": "inactive"
},
"title": {
"readonly": false,
"group": "Basic",
"transform": "",
"default": ""
},
"variation_of": {
"readonly": false,
"group": "",
"transform": "",
"default": ""
},
"variation_attributes": {
"group": "",
"readonly": false,
"transform": "",
"default": ""
},
"variation_skus": {
"group": "",
"readonly": false,
"default": "",
"transform": ""
},
"thumbnail": {
"readonly": false,
"group": "Basic",
"transform": "",
"efault": ""
},
"categories": {
"transform": "",
"default": "",
"readonly": false,
"group": "Basic"
}
},
"label": "Store",
"comment": "For store site"
}
},
"status": "OK",
"status_message": ""
}
{
"status": "OK",
"status_message": ""
}
If there is an error with the API request, additional information will be provided in the response body.
Examples of error messages include:
- addView: if the attributes are not found in PIMS:
"status_message": "Attribute name Attribute not found!"
"status_message": "View with the same name already exist!"
"status_message": "Access denied!"
- editView, deleteView:
"status_message": "View does not exist"
- application/json
- Schema
- Example (from schema)
Schema
Possible values: [Error
]
The status of the API request. A value of "Error" indicates that the request was not successfully sent or processed.
Provides a message that describes the reason for the error that occurred while processing the API request.
{
"status": "Error",
"status_message": "string"
}