CartViewmodel is part of Dynamicweb frontend name space and the pageview viewmodel - used for minicarts.
If you want full blown cart in json, you should use the cart or orders endpoint of the webapi - that will give you an OrderViewmodel which has i.e. custom order fields.
See: https://doc.dynamicweb.com/api/html/2b7ce250-5717-9ef7-d73f-0ebece363e8a.htm
You can see an example from the Swift:
http://r4.master.public2.dynamicweb.dk/dwapi/ecommerce/carts/ced5bab913af496688e8df53c19d5278
Response will look like this:
{
"Id": "string",
"Secret": "string",
"ShopId": "string",
"DisplayName": "string",
"VoucherCode": "string",
"Weight": 0,
"Volume": 0,
"CreatedAt": "2021-11-04T12:39:20.679Z",
"Modified": "2021-11-04T12:39:20.679Z",
"CompletedDate": "2021-11-04T12:39:20.679Z",
"Completed": true,
"StateId": "string",
"StateName": "string",
"StateDescription": "string",
"IntegrationOrderId": "string",
"RecurringOrderId": 0,
"CustomerUserId": 0,
"CustomerNumber": "string",
"CustomerEan": "string",
"CustomerRefId": "string",
"CustomerCompany": "string",
"CustomerTitle": "string",
"CustomerName": "string",
"CustomerFirstName": "string",
"CustomerSurname": "string",
"CustomerMiddleName": "string",
"CustomerHouseNumber": "string",
"CustomerInitials": "string",
"CustomerPrefix": "string",
"CustomerAddress": "string",
"CustomerAddress2": "string",
"CustomerZip": "string",
"CustomerCity": "string",
"CustomerCountry": "string",
"CustomerCountryCode": "string",
"CustomerRegion": "string",
"CustomerPhone": "string",
"CustomerEmail": "string",
"CustomerCell": "string",
"CustomerAccepted": true,
"DeliveryCompany": "string",
"DeliveryName": "string",
"DeliveryFirstName": "string",
"DeliverySurname": "string",
"DeliveryMiddleName": "string",
"DeliveryTitle": "string",
"DeliveryHouseNumber": "string",
"DeliveryInitials": "string",
"DeliveryPrefix": "string",
"DeliveryAddress": "string",
"DeliveryAddress2": "string",
"DeliveryZip": "string",
"DeliveryCity": "string",
"DeliveryCountry": "string",
"DeliveryCountryCode": "string",
"DeliveryRegion": "string",
"DeliveryPhone": "string",
"DeliveryEmail": "string",
"DeliveryCell": "string",
"NewsletterSubscribe": true,
"TransactionCardnumber": "string",
"TransactionCardType": "string",
"TransactionNumber": "string",
"TransactionStatus": "string",
"ShippingDate": "2021-11-04T12:39:20.679Z",
"OrderLines": [
{
"Id": "string",
"ProductId": "string",
"ProductVariantId": "string",
"ProductLanguageId": "string",
"ProductName": "string",
"ProductNumber": "string",
"ProductVariantName": "string",
"ProductImage": "string",
"Reference": "string",
"Quantity": 0,
"Weight": 0,
"Volume": 0,
"UnitId": "string",
"StockLocationId": 0,
"OrderLineType": "Product",
"OrderLineFields": {
"additionalProp1": {
"SystemName": "string",
"Name": "string",
"Type": "string",
"ListType": 0
},
"additionalProp2": {
"SystemName": "string",
"Name": "string",
"Type": "string",
"ListType": 0
},
"additionalProp3": {
"SystemName": "string",
"Name": "string",
"Type": "string",
"ListType": 0
}
}
}
],
"OrderFields": {
"additionalProp1": {
"SystemName": "string",
"Name": "string",
"Type": "string",
"ListType": 0
},
"additionalProp2": {
"SystemName": "string",
"Name": "string",
"Type": "string",
"ListType": 0
},
"additionalProp3": {
"SystemName": "string",
"Name": "string",
"Type": "string",
"ListType": 0
}
}
}