Retrieving Tender Information
Getting list of all tenders
GET /tenders HTTP/1.1
HTTP/1.1 200 OK
Sorting
Tenders retuned are sorted by modification time.
Limiting number of Tenders returned
You can control the number of data entries in the tenders feed (batch size) with limit parameter. If not specified, data is being returned in batches of 100 elements.
Batching
The response contains next_page element with the following properties:
- offset
This is the parameter you have to add to the original request you made to get next page.
- path
This is path section of URL with original parameters and offset parameter added/replaced above.
- uri
The full version of URL for next page.
If next page request returns no data (i.e. empty array) then there is little sense in fetching further pages.
Synchronizing
It is often necessary to be able to syncronize central database changes with other database (we’ll call it “local”). The default sorting “by modification date” together with Batching mechanism allows one to implement synchronization effectively. The synchronization process can go page by page until there is no new data returned. Then the synchronizer has to pause for a while to let central database register some changes and attempt fetching subsequent page. The next_page guarantees that all changes from the last request are included in the new batch.
The safe frequency of synchronization requests is once per 5 minutes.
Reading the individual tender information
GET /tenders/64e93250be76435397e8c992ed4214d1 HTTP/1.1
HTTP/1.1 200 OK
Reading the tender documents list
GET /tenders/64e93250be76435397e8c992ed4214d1/documents HTTP/1.1
HTTP/1.1 200 OK
Example request:
GET /api/2.5/tenders/3f5ff57c43ca4ba6b3a1d0619b7a14c3/documents HTTP/1.0
Authorization: Bearer broker
Host: public-api-sandbox.prozorro.gov.ua
HTTP/1.0 200 OK
Content-Type: application/json
{
"data": [
{
"documentType": "technicalSpecifications",
"description": "document description modified",
"id": "dcc28f9e5b0a4475ae1511c9195924ba",
"datePublished": "2023-10-10T01:00:01+03:00",
"hash": "md5:00000000000000000000000000000000",
"title": "Notice.pdf",
"format": "application/pdf",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/6d5acc9f6744445090ee6163719b792e?Signature=sgMJT6uclURHXV1QkzMq700s6436i6ynr4LaZyZf5B4O1Sn6ed7A8ogX5x1LCHhuC5HKuPrXHgPRYIyDC6H%2BDg%3D%3D&KeyID=a8968c46",
"documentOf": "tender",
"dateModified": "2023-10-10T01:00:01+03:00",
"author": "tender_owner",
"language": "uk"
},
{
"hash": "md5:00000000000000000000000000000000",
"title": "AwardCriteria.pdf",
"format": "application/pdf",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/8b660719e71c4e3b80ac24648fac52c2?Signature=KztTkrH3lsmZaP%2BWO8J%2BbI7PYNNV%2FDEQjh%2BizLUhw8aULUu%2BxQgMmxFapPOUaK4nNViYOHS8wZXvQIukYB2EAg%3D%3D&KeyID=a8968c46",
"documentOf": "tender",
"language": "uk",
"id": "9e36c772ea13480da2398a2c2bd63fe5",
"datePublished": "2023-10-10T01:00:01+03:00",
"dateModified": "2023-10-10T01:00:01+03:00",
"author": "tender_owner"
}
]
}
Reading the tender document
The document can be retrieved by requesting the url returned in structures from document list request in data[*].url. It is safe to provide the download URL to end user for download.