saveLayoutStructure

put

/ccadmin/v1/layouts/{id}/structure

Save Layout Structure. Persists the layout structure to the repository

Request

Supported Media Types
Path Parameters
Body ()
Root Schema : saveLayoutStructure_request
Type: object
Show Source
Example:
{
    "layout":{
        "regions":[
            {
                "cssClass":"custom-header",
                "width":12,
                "repositoryId":"basicHeaderRegionCheckoutPage",
                "widgets":[
                    {
                        "repositoryId":"basicHeaderWidgetInst"
                    }
                ]
            },
            {
                "cssClass":"custom-body",
                "width":6,
                "repositoryId":"9colCheckoutBody",
                "widgets":[
                    {
                        "repositoryId":"checkoutRegistrationInst"
                    },
                    {
                        "repositoryId":"checkoutCustomerDetailsInst"
                    },
                    {
                        "repositoryId":"checkoutPaymentDetailsInst"
                    }
                ]
            },
            {
                "cssClass":"custom-body",
                "width":6,
                "repositoryId":"3colCheckoutSide",
                "widgets":[
                    {
                        "repositoryId":"checkoutCartSummaryInst"
                    },
                    {
                        "repositoryId":"checkoutOrderSummaryInst"
                    }
                ]
            },
            {
                "cssClass":"custom-body",
                "width":12,
                "repositoryId":"1colCyberSourcePaymentAuthorization",
                "widgets":[
                    {
                        "repositoryId":"cyberSourcePaymentAuthorizationInst"
                    }
                ]
            },
            {
                "cssClass":"custom-footer",
                "width":12,
                "repositoryId":"footerRegionCheckoutPage",
                "widgets":[
                    {
                        "repositoryId":"footerInst"
                    }
                ]
            }
        ]
    }
}
Nested Schema : layout
Type: object
Layout
Show Source
Nested Schema : regions
Type: array
Regions
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : widgets
Type: array
Widgets
Show Source
Nested Schema : items
Type: object
Show Source
Back to Top

Response

Supported Media Types

200 Response

Following model is returned when operation succeeds.
Body ()
Root Schema : saveLayoutStructure_response
Type: object
Show Source
Nested Schema : regions
Type: array
Regions
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : widgets
Type: array
Widgets
Show Source
Nested Schema : items
Type: object
Show Source
Nested Schema : descriptor
Type: object
Descriptor
Show Source
Example Response (application/json)
{
    "regions":[
        {
            "cssClass":"custom-header",
            "name":"basicHeader",
            "width":12,
            "repositoryId":"basicHeaderRegionCheckoutPage",
            "widgets":[
                {
                    "displayName":"Basic Header",
                    "repositoryId":"basicHeaderWidgetInst",
                    "descriptor":{
                        "repositoryId":"basicHeaderWidget",
                        "minWidth":3,
                        "editableWidget":true
                    }
                }
            ],
            "height":300
        },
        {
            "cssClass":"custom-body",
            "name":"checkoutBody",
            "width":9,
            "repositoryId":"9colCheckoutBody",
            "widgets":[
                {
                    "displayName":"Checkout Registration",
                    "repositoryId":"checkoutRegistrationInst",
                    "descriptor":{
                        "repositoryId":"checkoutRegistration",
                        "minWidth":3,
                        "editableWidget":true
                    }
                },
                {
                    "displayName":"Checkout Customer Details",
                    "repositoryId":"checkoutCustomerDetailsInst",
                    "descriptor":{
                        "repositoryId":"checkoutCustomerDetails",
                        "minWidth":3,
                        "editableWidget":true
                    }
                },
                {
                    "displayName":"Checkout Payment Details",
                    "repositoryId":"checkoutPaymentDetailsInst",
                    "descriptor":{
                        "repositoryId":"checkoutPaymentDetails",
                        "minWidth":3,
                        "editableWidget":true
                    }
                }
            ],
            "height":300
        },
        {
            "cssClass":"custom-body",
            "name":"checkoutSidebar",
            "width":3,
            "repositoryId":"3colCheckoutSide",
            "widgets":[
                {
                    "displayName":"Checkout Cart Summary",
                    "repositoryId":"checkoutCartSummaryInst",
                    "descriptor":{
                        "repositoryId":"checkoutCartSummary",
                        "minWidth":3,
                        "editableWidget":true
                    }
                },
                {
                    "displayName":"Checkout Order Summary",
                    "repositoryId":"checkoutOrderSummaryInst",
                    "descriptor":{
                        "repositoryId":"checkoutOrderSummary",
                        "minWidth":3,
                        "editableWidget":true
                    }
                }
            ],
            "height":300
        },
        {
            "cssClass":"custom-body",
            "name":"cyberSourcePaymentAuthorization",
            "width":12,
            "repositoryId":"1colCyberSourcePaymentAuthorization",
            "widgets":[
                {
                    "displayName":"CyberSource Payment Authorization",
                    "repositoryId":"cyberSourcePaymentAuthorizationInst",
                    "descriptor":{
                        "repositoryId":"cyberSourcePaymentAuthorization",
                        "minWidth":3,
                        "editableWidget":false
                    }
                }
            ],
            "height":0
        },
        {
            "cssClass":"custom-footer",
            "name":"footer",
            "width":12,
            "repositoryId":"footerRegionCheckoutPage",
            "widgets":[
                {
                    "displayName":"Footer",
                    "repositoryId":"footerInst",
                    "descriptor":{
                        "repositoryId":"footer",
                        "minWidth":3,
                        "editableWidget":true
                    }
                }
            ],
            "height":300
        }
    ],
    "displayName":"Checkout",
    "name":"CheckoutPageLayout",
    "repositoryId":"checkoutPageLayout"
}

Default Response

The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: |Error Code|Description| |------------------|------------------| |32006|Error updating layout structure| |32014|No widgets were specified for region (Occurs when 'widgets' is omitted from a region in the request)| |32015|A layout must contain at least 1 region| |32001|Error retrieving the layout by its ID.| |32012|The specified widget does not exist| |32013|No regions were specified for layout (Occurs when 'regions' is omitted from request)| |32010|The specified layout does not exist| |32011|The specified region does not exist| |32009|Region width specified is smaller than minimum width for widget. (regionId)| |32007|Region contains widgets. Unable to delete. (regionId)| |32008|Region width must be between 1 and 12. (regionId)|
Body ()
Root Schema : errorModel
Type: object
Show Source
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Show Source
Nested Schema : items
Type: object
Show Source
Back to Top