“ratingEntry” Resource Type#
Represents a vendor rating entry as part of Vendor Rating Management in Business Central.
Note
For information about enabling APIs for Business Central, please refer to Enabling APIs for Dynamics 365 Business Central.
Methods#
Method | Return Type | Description |
---|---|---|
GET ratingEntry | ratingEntry | Gets a ratingEntry object. |
POST ratingEntry | ratingEntry | Creates a ratingEntry object. |
Navigation#
Navigation | Return Type | Description |
---|---|---|
ratingType | ratingTypes | Gets the rating types associated with the current vendor rating entry. |
ratings | ratings | Gets the ratings associated with the current vendor rating entry. |
Properties#
Property | Type | Description |
---|---|---|
id | GUID | The unique ID of the vendor rating entry. Non-editable. |
entryNo | Int | Specifies the unique entry number of this vendor rating entry. |
JSON Representation#
The following code shows a JSON representation of the ratingEntry resource.
{
"id": "Guid",
"entryNo": "int64",
"vendorNo": "string",
"type": "string",
"no": "string",
"description": "string",
"vendorGroupCode": "string",
"itemGroupCode": "string",
"postingDate": "date",
"documentDate": "date",
"ratingGroup": "string",
"ratingTypeCode": "string",
"ratingTypeDescription": "string",
"ratingCode": "string",
"ratingDescription": "string",
"ratingPoints": "decimal",
"quantityTarget": "decimal",
"quantityActual": "decimal",
"quantityDelta": "decimal",
"quantityDeltaPercent": "decimal",
"ratingReferenceDate": "string",
"promisedReceiptDate": "date",
"expectedReceiptDate": "date",
"plannedReceiptDate": "date",
"dateDeltaInDays": "decimal",
"sourceType": "int32",
"sourceSubtype": "string",
"sourceID": "string",
"sourceRefNo": "int32",
"referenceType": "int32",
"referenceSubtype": "string",
"referenceID": "string",
"referenceRefNo": "int32",
"correction": "boolean",
"correctionEntryNo": "int32"
}
HTTP Requests#
Get ratingEntries#
Retrieves the properties and relationships of a ratingEntry object for Business Central.
HTTP Request#
Replace the URL prefix for Business Central depending on your environment, following the guideline.
GET businesscentralPrefix/kumavision/kvsvrm/v1.0/companies({id})/ratingEntries({id})
Request Headers#
Header | Value |
---|---|
Authorization | Bearer {token}. Required. |
Request Body#
For this method, no request body is required.
Response#
If successful, this method returns the 200 OK
response code and a ratingEntry object in the response body.
Example#
Request
The following code shows an example of the request.
GET https://{businesscentralPrefix}/api/kumavision/kvsvrm/v1.0/companies({id})/ratingEntries({id})
Response The following code shows an example of the response.
{
"@odata.context": "https://{businesscentralPrefix}/api/kumavision/kvsvrm/v1.0/companies({id})/ratingEntries",
"value": [
{
"@odata.etag": "W/\"JzIwOzExNTI1ODE3MDQyMTQ4NDIwOTIyMTswMDsn\"",
"id": "92a9db65-60ac-ed11-9eb2-c7df0d0ebfab",
"entryNo": 1,
"vendorNo": "10000",
"type": "0",
"no": "",
"description": "",
"vendorGroupCode": "",
"itemGroupCode": "",
"postingDate": "2023-02-14",
"documentDate": "2023-02-14",
"ratingGroup": "0",
"ratingTypeCode": "TEST",
"ratingTypeDescription": "",
"ratingCode": "B",
"ratingDescription": "",
"ratingPoints": 0,
"quantityTarget": 0,
"quantityActual": 0,
"quantityDelta": 0,
"quantityDeltaPercent": 0,
"ratingReferenceDate": "0",
"promisedReceiptDate": "0001-01-01",
"expectedReceiptDate": "0001-01-01",
"plannedReceiptDate": "0001-01-01",
"dateDeltaInDays": 0,
"sourceType": 0,
"sourceSubtype": "0",
"sourceID": "",
"sourceRefNo": 0,
"referenceType": 0,
"referenceSubtype": "0",
"referenceID": "",
"referenceRefNo": 0,
"correction": false,
"correctionEntryNo": 0
}
]
}
Create ratingEntries#
Creates a vendor rating entry in Business Central.
HTTP Request#
Replace the URL prefix for Business Central depending on your environment, following the guideline.
POST businesscentralPrefix/kumavision/kvsvrm/v1.0/companies({id})/ratingEntries({id})
Request Headers#
Header | Value |
---|---|
Authorization | Bearer {token}. Required. |
Content-Type | application/json |
If-Match | Required. If this request header is included and the eTag provided does not match the current tag of the ratingEntry, the ratingEntry will not be updated. |
Request Body#
In the request body, supply a JSON representation of a ratingEntry object.
Response#
If successful, this method returns the 201 Created
response code and a ratingEntry object in the response body.
Example#
Request
The following code shows an example of the request.
POST https://{businesscentralPrefix}/api/kumavision/kvsvrm/v1.0/companies({id})/ratingEntries
Content-type: application/json
{
"vendorNo": "10000",
"postingDate": "2023-02-14",
"documentDate": "2023-02-14",
"ratingTypeCode": "TEST",
"ratingCode": "B"
}
Response The following code shows an example of the response.
HTTP/1.1 201 Created
Content-type: application/json
{
"@odata.context": "https://{businesscentralPrefix}/api/kumavision/kvsvrm/v1.0/$metadata#companies({id})/ratingEntries/$entity",
"@odata.etag": "W/\"JzIwOzE4NDA3ODQzNzAxNjMxNTk5MDMxMTswMDsn\"",
"id": "118c6853-61ac-ed11-9eb2-c7df0d0ebfab",
"entryNo": 2,
"vendorNo": "10000",
"type": "0",
"no": "",
"description": "",
"vendorGroupCode": "",
"itemGroupCode": "",
"postingDate": "2023-02-14",
"documentDate": "2023-02-14",
"ratingGroup": "0",
"ratingTypeCode": "TEST",
"ratingTypeDescription": "",
"ratingCode": "B",
"ratingDescription": "",
"ratingPoints": 0,
"quantityTarget": 0,
"quantityActual": 0,
"quantityDelta": 0,
"quantityDeltaPercent": 0,
"ratingReferenceDate": "0",
"promisedReceiptDate": "0001-01-01",
"expectedReceiptDate": "0001-01-01",
"plannedReceiptDate": "0001-01-01",
"dateDeltaInDays": 0,
"sourceType": 0,
"sourceSubtype": "0",
"sourceID": "",
"sourceRefNo": 0,
"referenceType": 0,
"referenceSubtype": "0",
"referenceID": "",
"referenceRefNo": 0,
"correction": false,
"correctionEntryNo": 0
}