This class provides RESTful services to get geo node details. It performs the service by delegating to the GeoNode BOD service.
com.ibm.commerce.rest.store.handler.GeoNodeHandler
| HTTP Method | Path | Description |
|---|---|---|
| GET | /store/{storeId}/geonode | Find geo nodes that match the type and the name. |
| GET | /store/{storeId}/geonode?q={q} | Find geo nodes based on query name. See each query for details on input and output. |
| GET | /store/{storeId}/geonode/byParentGeoNode/{parentgeoid} | Gets the geo nodes by the parent geo node unique ID. |
| GET | /store/{storeId}/geonode/byTopGeoNode | Gets the top geo nodes. |
| GET | /store/{storeId}/geonode/byTopGeoNode | Gets the top geo nodes for the site. |
Find geo nodes that match the type and the name.
findGeoByTypeAndName
false
true
| Name | Description | Parameter Type | Data Type | Required | Allow Multiple |
|---|---|---|---|---|---|
| storeId | The store identifier. | path | string | true | N/A |
| siteLevelSearch | The site level search flag. If it is 'true', a site level search will be performed; otherwise, a store level search will be performed. Optional parameter; when it is not set, it is defaulted to 'true'. | query | string | false | false |
| type | The type of the geo nodes. | query | string | true | false |
| HTTP Status Code | Description |
|---|---|
| 200 | The requested completed successfully. |
| 400 | Bad request. Some of the inputs provided to the request aren't valid. |
| 401 | Not authenticated. The user session isn't valid. |
| 403 | The user isn't authorized to perform the specified request. |
| 500 | Internal server error. Additional details will be contained on the server logs. |
Find geo nodes based on query name. See each query for details on input and output.
findByQuery
false
true
| Name | Description | Parameter Type | Data Type | Required | Allow Multiple |
|---|---|---|---|---|---|
| storeId | The store identifier. | path | string | true | N/A |
| q | The query name. | query | string | true | false |
| HTTP Status Code | Description |
|---|---|
| 200 | The requested completed successfully. |
| 400 | Bad request. Some of the inputs provided to the request aren't valid. |
| 401 | Not authenticated. The user session isn't valid. |
| 403 | The user isn't authorized to perform the specified request. |
| 500 | Internal server error. Additional details will be contained on the server logs. |
Gets the geo nodes by the parent geo node unique ID.
findGeoByParentGeoId
false
true
| Name | Description | Parameter Type | Data Type | Required | Allow Multiple |
|---|---|---|---|---|---|
| storeId | The store identifier. | path | string | true | N/A |
| parentgeoid | The parent geo node identifier. | path | string | true | N/A |
| HTTP Status Code | Description |
|---|---|
| 200 | The requested completed successfully. |
| 400 | Bad request. Some of the inputs provided to the request aren't valid. |
| 401 | Not authenticated. The user session isn't valid. |
| 403 | The user isn't authorized to perform the specified request. |
| 500 | Internal server error. Additional details will be contained on the server logs. |
GET /wcs/resources/store/10001/geonode/byParentGeoNode/10003?responseFormat=json
200
{
"GeoNode": [
{
"Description": [
{
"shortDescription": "Calgary"
}
],
"name": "Calgary",
"type": "CITY",
"uniqueID": "10004"
},
{
"Description": [
{
"shortDescription": "Edmonton"
}
],
"name": "Edmonton",
"type": "CITY",
"uniqueID": "10005"
},
{
"Description": [
{
"shortDescription": "Lethbridge"
}
],
"name": "Lethbridge",
"type": "CITY",
"uniqueID": "10006"
},
{
"Description": [
{
"shortDescription": "Medicine Hat"
}
],
"name": "Medicine Hat",
"type": "CITY",
"uniqueID": "10007"
},
{
"Description": [
{
"shortDescription": "Red Deer"
}
],
"name": "Red Deer",
"type": "CITY",
"uniqueID": "10008"
},
{
"Description": [
{
"shortDescription": "St. Albert"
}
],
"name": "St. Albert",
"type": "CITY",
"uniqueID": "10009"
},
{
"Description": [
{
"shortDescription": "Strathcona County"
}
],
"name": "Strathcona County",
"type": "CITY",
"uniqueID": "10010"
}
],
"recordSetComplete": "true",
"recordSetCount": "7",
"recordSetStartNumber": "0",
"recordSetTotal": "7",
"resourceId": "http:\/\/localhost:80\/wcs\/resources\/store\/10001\/geonode\/byParentGeoNode\/10003?responseFormat=json",
"resourceName": "geonode"
}
Gets the top geo nodes.
findTopGeoNodes
false
true
| Name | Description | Parameter Type | Data Type | Required | Allow Multiple |
|---|---|---|---|---|---|
| storeId | The store identifier. | path | string | true | N/A |
| siteLevelSearch | The site level search flag. If it is 'true', a site level search will be performed; otherwise, a store level search will be performed. Optional parameter; when it is not set, it is defaulted to 'true'. | query | string | false | false |
| HTTP Status Code | Description |
|---|---|
| 200 | The requested completed successfully. |
| 400 | Bad request. Some of the inputs provided to the request aren't valid. |
| 401 | Not authenticated. The user session isn't valid. |
| 403 | The user isn't authorized to perform the specified request. |
| 500 | Internal server error. Additional details will be contained on the server logs. |
GET /wcs/resources/store/10001/geonode/byTopGeoNode?siteLevelSearch=false&responseFormat=json
200
{
"GeoNode": [
{
"Description": [
{
"shortDescription": "Canada"
}
],
"name": "Canada",
"type": "CNTY",
"uniqueID": "10001"
},
{
"Description": [
{
"shortDescription": "United States"
}
],
"name": "United States",
"type": "CNTY",
"uniqueID": "10002"
}
],
"recordSetComplete": "true",
"recordSetCount": "2",
"recordSetStartNumber": "0",
"recordSetTotal": "2",
"resourceId": "http:\/\/localhost:80\/wcs\/resources\/store\/10001\/geonode\/byTopGeoNode?siteLevelSearch=false&responseFormat=json",
"resourceName": "geonode"
}
Gets the top geo nodes for the site.
findTopGeoNodes
false
true
| Name | Description | Parameter Type | Data Type | Required | Allow Multiple |
|---|---|---|---|---|---|
| storeId | The store identifier. | path | string | true | N/A |
| HTTP Status Code | Description |
|---|---|
| 200 | The requested completed successfully. |
| 400 | Bad request. Some of the inputs provided to the request aren't valid. |
| 401 | Not authenticated. The user session isn't valid. |
| 403 | The user isn't authorized to perform the specified request. |
| 500 | Internal server error. Additional details will be contained on the server logs. |
GET /wcs/resources/store/10001/geonode/byTopGeoNode?siteLevelSearch=false&responseFormat=json
200
{
"GeoNode": [
{
"Description": [
{
"shortDescription": "Canada"
}
],
"name": "Canada",
"type": "CNTY",
"uniqueID": "10001"
},
{
"Description": [
{
"shortDescription": "United States"
}
],
"name": "United States",
"type": "CNTY",
"uniqueID": "10002"
}
],
"recordSetComplete": "true",
"recordSetCount": "2",
"recordSetStartNumber": "0",
"recordSetTotal": "2",
"resourceId": "http:\/\/localhost:80\/wcs\/resources\/store\/10001\/geonode\/byTopGeoNode?siteLevelSearch=false&responseFormat=json",
"resourceName": "geonode"
}
| Name | Data Type | Required |
|---|---|---|
| recordSetTotal | string | false |
| GeoNode | geonode-geonode_item array | false |
| recordSetStartNumber | string | false |
| recordSetComplete | string | false |
| recordSetCount | string | false |
| Name | Data Type | Required |
|---|---|---|
| userDataField | geonode-geonode_item.userDataField array | false |
| type | string | false |
| name | string | false |
| uniqueID | string | false |
| Description | geonode-geonode_item.Description array | false |
| Name | Data Type | Required |
|---|---|---|
| shortDescription | string | false |
| Name | Data Type | Required |
|---|---|---|
| value | string | false |
| key | string | true |