getShippingMethod
get
/ccagent/v1/shippingMethods/{id}
Get Shipping Method. Get a shipping method.This Endpoint is clone of StoreFront endpoint and it can be used if application running on agent/admin server need access to shipping methods data configured for StoreFront.
Request
Supported Media Types
- application/json
Path Parameters
- id
-
Type:
stringRequired:truethe id of the shipping method to get
Response
Supported Media Types
- application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : getShippingMethod_response
- description
-
Type:
stringDescription of the shipping method. - displayName
-
Type:
stringThe display name for the shipping method given the current locale. - displaySequence
-
Type:
integerUsed to determine the ordering of shipping methods in the UI. Lower values should appear first in any ordered list. - eligibleForProductWithSurcharges
-
Type:
booleanwhether this shipping method is enabled for products with surcharges or not. - enabled
-
Type:
booleanwhether this shipping method is enabled or not. - ranges
-
Type:
arrayrangesAdditional Properties Allowed:The price ranges for this shipping method. - repositoryId
-
Type:
stringthe id of the newly created shipping method item - shippingCalculator
-
Type:
stringA valid key for the available calculator types. - shippingGroupType
-
Type:
stringShipping group type. - shipToLocations
-
Type:
arrayshipToLocationsAdditional Properties Allowed:List of shipping locations - taxCode
-
Type:
stringA valid tax code for calculating tax on shipping. - type
-
Type:
integerThe type property of the shipping method.
Nested Schema : ranges
Nested Schema : shipToLocations
Nested Schema : items
Type:
object- amount
-
Type:
numberThe monetary value for the range. - high
-
Type:
numberThe upper boundary of the range. - low
-
Type:
numberThe lower boundary of the range. - repositoryId
-
Type:
stringThe repository id of this priceRange item.
Nested Schema : items
Type:
object- repositoryId
-
Type:
stringAllowed shipping country-region IDs.
Example application/json
{
"shippingCalculator":"priceRange",
"eligibleForProductWithSurcharges":null,
"ranges":[
{
"amount":4.5,
"high":49.99,
"low":0,
"repositoryId":"groundRange_01"
},
{
"amount":8.5,
"high":99.99,
"low":50,
"repositoryId":"groundRange_02"
},
{
"amount":11,
"high":null,
"low":100,
"repositoryId":"groundRange_03"
}
],
"displayName":"Ground",
"displaySequence":7,
"repositoryId":"groundShippingMethod",
"description":null,
"type":0,
"taxCode":null,
"shippingGroupType":"hardgoodShippingGroup",
"enabled":true,
"shipToLocations":[
{
"repositoryId":"100001"
}
]
}
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|
|------------------|------------------|
|31015|No shipping method found with id: {0}|
Body
Root Schema : errorModel
Type:
object- devMessage
-
Type:
stringAn optional non-localized message containing technical information for developers - errorCode
-
Type:
stringThe numerical code identifying the error - errors
-
Type:
arrayerrorsAdditional Properties Allowed:An optional list of errors if multiple errors were encountered - message
-
Type:
stringThe localized message describing the error - moreInfo
-
Type:
stringAn optional non-localized message with more information - o:errorPath
-
Type:
stringAn optional machine readable description of where the error occurred - status
-
Type:
stringThe HTTP status code - type
-
Type:
stringThe URI to the HTTP state code definition
Nested Schema : errors
Nested Schema : items
Type:
object- devMessage
-
Type:
stringAn optional non-localized message containing technical information for developers - errorCode
-
Type:
stringThe numerical code identifying the error - message
-
Type:
stringThe localized message describing the error - moreInfo
-
Type:
stringAn optional non-localized message with more information - o:errorPath
-
Type:
stringAn optional machine readable description of where the error occurred - status
-
Type:
stringThe HTTP status code
Examples
Sample Response Payload returned by endpoint:
{
"shippingCalculator": "priceRange",
"eligibleForProductWithSurcharges": null,
"ranges": [
{
"amount": 4.5,
"high": 49.99,
"low": 0,
"repositoryId": "groundRange_01"
},
{
"amount": 8.5,
"high": 99.99,
"low": 50,
"repositoryId": "groundRange_02"
},
{
"amount": 11,
"high": null,
"low": 100,
"repositoryId": "groundRange_03"
}
],
"displayName": "Ground",
"displaySequence": 7,
"repositoryId": "groundShippingMethod",
"description": null,
"type": 0,
"taxCode": null,
"shippingGroupType": "hardgoodShippingGroup",
"enabled": true,
"shipToLocations": [{"repositoryId": "100001"}]
}