Crop Cultivation by Districts

The Filter Crops API endpoint allows users to retrieve specific crop details based on the provided cropId. This endpoint is essential for obtaining targeted information about a particular crop.

End Point
GET {{base_url}}/cropix/api/v1/cultivation-data/seasons/{seasonId}/districts

Request Method

  • GET

Headers

  • Content-Type: application/json
  • Authorization:  <token> 

Parameters

  • seasonId (required): The unique identifier for the cultivation season (e.g., 1 for the first season).

Response

Successful Response

Status Code: 200 OK

Response Body

{
 "message" : null,
 "resultStatus" : "SUCCESSFUL",
 "httpStatus" : "OK",
 "httpCode" : "200 OK",
 "payloadDto" : [ {
   "districtId" : 6,
   "districtName" : "Nuwara Eliya",
   "cultivations" : [ {
     "cropId" : 2,
     "cropName" : "Finger millet",
     "cultivation" : 175.8,
     "links" : [ ]
   } ],
   "links" : [ ]
 }, {
   "districtId" : 6,
   "districtName" : "Nuwara Eliya",
   "cultivations" : [ {
     "cropId" : 3,
     "cropName" : "Maize",
     "cultivation" : 111.9,
     "links" : [ ]
   } ],
   "links" : [ ]
 }, {
   "districtId" : 6,
   "districtName" : "Nuwara Eliya",
   "cultivations" : [ {
     "cropId" : 5,
     "cropName" : "Red Onion",
     "cultivation" : 22.7,
     "links" : [ ]
   } ],
   "links" : [ ]
 }
"numberOfElements" : 100
}
Example Request
curl -X GET "{{base_url}}/cropix/api/v1/cultivation-data/seasons/1/districts?page=4&size=100" 
-H "Content-Type: application/json" \
-H "Authorization: YOUR_ACCESS_TOKEN"

Crop Cultivation Per District

The Specific District by Season API endpoint allows users to retrieve detailed information about a specific district associated with a designated cultivation season. This is useful for understanding the specific agricultural data and activities relevant to that district in the given season.

End Point
GET {{base_url}}/cropix/api/v1/cultivation-data/seasons/{seasonId}/districts/{districtId}

Request Method

  • GET

Headers

  • Content-Type: application/json
  • Authorization:  <token> 

Parameters

  • seasonId (required): The unique identifier for the cultivation season (e.g., 1 for the first season).
  • districtId(required): The unique identifier for the administrative district (e.g., 2 for the Kandy district)

Response

Successful Response

Status Code: 200 OK

Response Body

{
 "message" : null,
 "resultStatus" : "SUCCESSFUL",
 "httpStatus" : "OK",
 "httpCode" : "200 OK",
 "payloadDto" : [ {
   "cropId" : 1,
   "cropName" : "Paddy",
   "cultivation" : 5635.58,
   "links" : [ ]
 }, {
   "cropId" : 16,
   "cropName" : "Bitter gourd",
   "cultivation" : 40.191,
   "links" : [ ]
 }, {
   "cropId" : 17,
   "cropName" : "Brinjal",
   "cultivation" : 56.74,
   "links" : [ ]
 }, {
   "cropId" : 18,
   "cropName" : "Bushita",
   "cultivation" : 20.8,
   "links" : [ ]
 }, {
   "cropId" : 19,
   "cropName" : "Cucumber",
   "cultivation" : 21.488,
   "links" : [ ]
 }, {
   "cropId" : 23,
   "cropName" : "Long Bean",
   "cultivation" : 66.28,
   "links" : [ ]
 }, {
   "cropId" : 24,
   "cropName" : "Luffa",
   "cultivation" : 38.048,
   "links" : [ ]
 }, {
   "cropId" : 25,
   "cropName" : "Okra",
   "cultivation" : 64.862,
   "links" : [ ]
 }, {
   "cropId" : 43,
   "cropName" : "Raddish",
   "cultivation" : 25.152,
   "links" : [ ]
 }, {
   "cropId" : 27,
   "cropName" : "Snake gourd",
   "cultivation" : 44.52,
   "links" : [ ]
 }, {
   "cropId" : 46,
   "cropName" : "Elephant Foot Yam",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 47,
   "cropName" : "Innala",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 48,
   "cropName" : "Kiriala",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 49,
   "cropName" : "Manioc/ Cassava",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 52,
   "cropName" : "Raja ala",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 50,
   "cropName" : "Sweet Potato",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 51,
   "cropName" : "Wel ala",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "cropId" : 37,
   "cropName" : "Capsicum",
   "cultivation" : 23.877,
   "links" : [ ]
 }, {
   "cropId" : 6,
   "cropName" : "Chilli",
   "cultivation" : 63.192,
   "links" : [ ]
 }, {
   "cropId" : 66,
   "cropName" : "Banana",
   "cultivation" : 0.0,
   "links" : [ ]
 } ],
 "totalPages" : 3,
 "totalElements" : 51,
 "last" : false,
 "size" : 20,
 "number" : 0,
 "sort" : {
   "empty" : true,
   "sorted" : false,
   "unsorted" : true
 },
 "numberOfElements" : 20
}
Example Request
curl -X GET "{{base_url}}/cropix/api/v1/cultivation-data/seasons/1/districts/2
-H "Content-Type: application/json" \
-H "Authorization: YOUR_ACCESS_TOKEN"

Crop Cultivation Monthly

The Months by Season API endpoint provides access to information about the months associated with a specific cultivation season. Users can retrieve details regarding the months during which cultivation activities take place for the specified season.

End Point
GET {{base_url}}/cropix/api/v1/cultivation-data/seasons/{seasonId}/months

Request Method

  • GET

Headers

  • Content-Type: application/json
  • Authorization:  <token> 

Parameters

  • This endpoint does not require any query parameters.

Response

Successful Response

Status Code: 200 OK

Response Body

{
 "message" : null,
 "resultStatus" : "SUCCESSFUL",
 "httpStatus" : "OK",
 "httpCode" : "200 OK",
 "payloadDto" : [ {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 88,
   "cropName" : "Amla",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 64,
   "cropName" : "Annona/Anoda",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 31,
   "cropName" : "Ash Plantain",
   "cultivation" : 3.45,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 32,
   "cropName" : "Ash Pumpkin",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 65,
   "cropName" : "Avocado",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 66,
   "cropName" : "Banana",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 33,
   "cropName" : "Beans",
   "cultivation" : 175.45,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 34,
   "cropName" : "Beet Roots",
   "cultivation" : 58.15,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 89,
   "cropName" : "Beli",
    "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 35,
   "cropName" : "Bellpepper",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 4,
   "cropName" : "Big Onion",
   "cultivation" : 0.1,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 90,
   "cropName" : "Bignary (Karawala Kabilla)",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 16,
   "cropName" : "Bitter gourd",
   "cultivation" : 95.23,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 7,
   "cropName" : "Black Gram",
   "cultivation" : 124.25,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 17,
   "cropName" : "Brinjal",
   "cultivation" : 221.656,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 18,
   "cropName" : "Bushita",
   "cultivation" : 13.91,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 36,
   "cropName" : "Cabbage",
   "cultivation" : 51.55,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 37,
   "cropName" : "Capsicum",
   "cultivation" : 107.117,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 38,
   "cropName" : "Carrot",
   "cultivation" : 48.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 39,
   "cropName" : "Cauliflower",
   "cultivation" : 1.3,
   "links" : [ ]
  } ],
 "totalPages" : 38,
 "totalElements" : 754,
 "last" : false,
 "size" : 20,
 "number" : 0,
 "sort" : {
   "empty" : true,
   "sorted" : false,
   "unsorted" : true
 },
 "numberOfElements" : 20
}
Example Request
curl -X GET "{{base_url}}/cropix/api/v1/cultivation-data/seasons/1/months
-H "Content-Type: application/json" \
-H "Authorization: YOUR_ACCESS_TOKEN"

Crop Cultivation Per Month

The Specific Month by Season API endpoint allows users to retrieve detailed information about a specific month associated with a designated cultivation season. This endpoint is useful for understanding the agricultural activities and data specific to that month within the season.

End Point
GET {{base_url}}/cropix/api/v1/cultivation-data/seasons/{seasonId}/months/{monthId}

Request Method

  • GET

Headers

  • Content-Type: application/json
  • Authorization:  <token> 

Parameters

  • seasonId (required): The unique identifier for the cultivation season (e.g., 1 for the first season).
  • monthId (required): The unique identifier for the specific month (e.g., 1 for January).

Response

Successful Response

Status Code: 200 OK

Response Body

{
 "message" : null,
 "resultStatus" : "SUCCESSFUL",
 "httpStatus" : "OK",
 "httpCode" : "200 OK",
 "payloadDto" : [ {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 88,
   "cropName" : "Amla",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 64,
   "cropName" : "Annona/Anoda",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 31,
   "cropName" : "Ash Plantain",
   "cultivation" : 3.45,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 32,
   "cropName" : "Ash Pumpkin",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 65,
   "cropName" : "Avocado",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 66,
   "cropName" : "Banana",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 33,
   "cropName" : "Beans",
   "cultivation" : 175.45,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 34,
   "cropName" : "Beet Roots",
   "cultivation" : 58.15,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 89,
   "cropName" : "Beli",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 35,
   "cropName" : "Bellpepper",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 4,
   "cropName" : "Big Onion",
   "cultivation" : 0.1,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 90,
   "cropName" : "Bignary (Karawala Kabilla)",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 16,
   "cropName" : "Bitter gourd",
   "cultivation" : 95.23,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 7,
   "cropName" : "Black Gram",
   "cultivation" : 124.25,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 17,
   "cropName" : "Brinjal",
   "cultivation" : 221.656,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 18,
   "cropName" : "Bushita",
   "cultivation" : 13.91,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 36,
   "cropName" : "Cabbage",
   "cultivation" : 51.55,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 37,
   "cropName" : "Capsicum",
   "cultivation" : 107.117,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 38,
   "cropName" : "Carrot",
   "cultivation" : 48.0,
   "links" : [ ]
 }, {
   "monthNumber" : 1,
   "monthName" : "January",
   "cropId" : 39,
   "cropName" : "Cauliflower",
   "cultivation" : 1.3,
   "links" : [ ]
  } ],
 "totalPages" : 6,
 "totalElements" : 108,
 "last" : false,
 "size" : 20,
 "number" : 0,
 "sort" : {
   "empty" : true,
   "sorted" : false,
   "unsorted" : true
 },
 "numberOfElements" : 20
}
Example Request
curl -X GET "{{base_url}}/cropix/api/v1/cultivation-data/seasons/1/months/1

-H "Content-Type: application/json" \

-H "Authorization: YOUR_ACCESS_TOKEN"

Seasonal Target District Wise

The Specific Month by Season API endpoint allows users to retrieve detailed information about a specific month associated with a designated cultivation season. This endpoint is useful for understanding the agricultural activities and data specific to that month within the season.

End Point
GET {{base_url}}/cropix/api/v1/cultivation-target-data/seasons/{seasonId}/districts

Request Method

  • GET

Headers

  • Content-Type: application/json
  • Authorization:  <token> 

Parameters

  • seasonId (required): The unique identifier for the cultivation season (e.g., 1 for the first season).

Response

Successful Response

Status Code: 200 OK

Response Body

{
 "message" : null,
 "resultStatus" : "SUCCESSFUL",
 "httpStatus" : "OK",
 "httpCode" : "200 OK",
 "payloadDto" : [ {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 1,
   "cropName" : "Paddy",
   "cultivation" : 17537.19,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 2,
   "cropName" : "Finger millet",
   "cultivation" : 3.4,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 3,
   "cropName" : "Maize",
   "cultivation" : 153.4,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 4,
   "cropName" : "Big Onion",
   "cultivation" : 10.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 5,
   "cropName" : "Red Onion",
   "cultivation" : 0.6,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 6,
   "cropName" : "Chilli",
   "cultivation" : 52.1,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 7,
   "cropName" : "Black Gram",
   "cultivation" : 113.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 8,
   "cropName" : "Cowpea",
   "cultivation" : 177.1,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 9,
   "cropName" : "Green gram",
   "cultivation" : 312.8,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 10,
   "cropName" : "Soya Bean",
   "cultivation" : 1.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 11,
   "cropName" : "Horse gram",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 12,
   "cropName" : "Gingerlly",
   "cultivation" : 0.1,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 13,
   "cropName" : "Ground nut",
   "cultivation" : 58.2,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 14,
   "cropName" : "Ginger",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
    "cropId" : 15,
   "cropName" : "Turmeric",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 16,
   "cropName" : "Bitter gourd",
   "cultivation" : 33.7,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 17,
   "cropName" : "Brinjal",
   "cultivation" : 44.3,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 18,
   "cropName" : "Bushita",
   "cultivation" : 0.2,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 18,
   "cropName" : "Yard Long bean (Bush Type)",
   "cultivation" : 0.0,
   "links" : [ ]
 }, {
   "districtId" : null,
   "districtName" : "",
   "cropId" : 19,
   "cropName" : "Cucumber",
   "cultivation" : 12.4,
   "links" : [ ]
 } ],
 "totalPages" : 58,
 "totalElements" : 1154,
 "last" : false,
 "size" : 20,
 "number" : 0,
 "sort" : {
   "empty" : true,
   "sorted" : false,
   "unsorted" : true
 },
 "numberOfElements" : 20
}
Example Request
curl -X GET "{{base_url}}/cropix/api/v1/cultivation-target-data/seasons/1/districts
-H "Content-Type: application/json" \
-H "Authorization: YOUR_ACCESS_TOKEN"

There are many vari of pass of lorem ipsum availab but the majority have suffered in some forms.There are many vari of pass of lorem ipsum availab but the majority have suffered in some forms.