Breeding Lot
The PostAddBreedingLot endpoint is responsible for registering a new breeding lot in the MIMS system. This registration can be viewed on screen CAD345.
How to register a breeding lot
HTTP POST Request
| Request Type | Example URL |
|---|---|
| POST | {{url_base}}/PostAddBreedingLot |
| Example | http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostAddBreedingLot" |
Input Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| LotNo | String(25) | Yes | External code of the breeding lot |
| FarmNo | String(25) | Yes | External code of the property |
| AnimalMaterialNo | String(25) | Yes | External code of the animal material |
| AnimalLineageNo | String(25) | Yes | External code of the animal lineage |
| ShedQty | Integer | No | Quantity of sheds associated with the lot |
| AnimalSexType | AnimalSexType | Yes | Enumerator with possible values for Animal Sex Type: astMixed (Mixed), astFemale (Female) or astMale (Male) |
Return
| Parameter | Type | Required | Description |
|---|---|---|---|
| WebServiceReturn | WebServiceReturn | Yes | Standard WebService response information in method execution |
| BreedingLotCode | Integer | Yes | Internal breeding lot code generated in the MIMS system |
Request Example
curl --location 'http://seuIPePorta/datasnap/rest/RESTWebServiceMethods/"PostAddBreedingLot"' \
--header 'Content-Type: application/json' \
--data '{
"LotNo": "L12345",
"FarmNo": "FARM001",
"AnimalMaterialNo": "MAT125",
"AnimalLineageNo": "LIN1",
"ShedQty": 1,
"AnimalSexType": "astMixed"
}'
Response Example
{
"WebServiceReturn": {
"Status": "wrsSuccess",
"ErrorCode": "",
"Message": "",
"Actor": "",
"ReturnQuestion": null
},
"BreedingLotCode": 101
}
🐞 Possible Errors
| Code | Message |
|---|---|
| BLE‑001 | The provided Lot parameter (LotNo) already exists! |
| BLE‑002 | The provided "AnimalLineageNo" ([value sent in request]) is not linked to the Animal Type of the provided "AnimalMaterialNo" ([value sent in request])! |