Tutorial
Here is the list of requests:
GET /api/2.5/requests HTTP/1.0
Authorization: Basic dGVzdF9zYXM6dGVzdF9zYXNfdG9rZW4=
Host: audit-api-sandbox.prozorro.gov.ua
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogOH19LCAiY2x1c3Rlcl90aW1lIjogeyJjbHVzdGVyVGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogOH19LCAic2lnbmF0dXJlIjogeyJoYXNoIjogeyIkYmluYXJ5IjogeyJiYXNlNjQiOiAiL3doVkZSb1dRSzhNYk5WcHgrS24rQmJJWVhjPSIsICJzdWJUeXBlIjogIjAwIn19LCAia2V5SWQiOiA3MzcyMTgxMzExOTc0Mjc3MTIyfX19; Path=/
{
"data": [],
"next_page": {
"offset": "",
"path": "/api/2.5/requests",
"uri": "http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests"
}
}
There are no requests, so let’s post one:
Примітка
Next action allowed to users that belongs to next auth group:
public
POST /api/2.5/requests HTTP/1.0
Authorization: Basic cHVibGljOnB1YmxpYw==
Content-Length: 1232
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"tenderId": "ffffffffffffffffffffffffffffffff",
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"parties": [
{
"name": "party name",
"address": {
"streetAddress": "test street address",
"locality": "test locality",
"region": "test region",
"postalCode": "test postalCode",
"countryName": "test country"
},
"contactPoint": {
"email": "test@example.com"
}
}
],
"documents": [
{
"title": "doc.txt",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/df1080bf9c774ba4b27f28f1d5b9c652?Signature=yU3LyBGl1zeg6mlMzWaMBl4KwCcfNeO58fmJDoFzvI4Cn30VJwDjDhwNW1%2FNZvXQ3lExaIcz0VPygSbWv1vkAg%3D%3D&KeyID=a8968c46",
"hash": "md5:00000000000000000000000000000000",
"format": "plain/text"
}
]
}
}
Response: 201 Created
Content-Type: application/json
Location: http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests/43800a9d9fc84e13862b58969c904b8c
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTB9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDEwfX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"dateModified": "2018-01-01T02:00:00+02:00",
"dateCreated": "2018-01-01T02:00:00+02:00",
"requestId": "UA-R-2018-01-01-000001",
"tenderId": "ffffffffffffffffffffffffffffffff",
"documents": [
{
"id": "97b4005ab68d462e9a6e101c804addfd",
"hash": "md5:00000000000000000000000000000000",
"title": "doc.txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/df1080bf9c774ba4b27f28f1d5b9c652?Signature=OZBoQZnZihQIpBoi5eojoquIpAe3DJoXrSnxl%252BvDwpywgysRKjdf8VoI8jgqu87vJJVcPhLLc90vuSOZuEJqCg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:00:00+02:00",
"dateModified": "2018-01-01T02:00:00+02:00",
"author": "request_owner"
}
],
"parties": [
{
"id": "a532f2e60d874493ab4f1e53e7bb9539",
"name": "party name",
"datePublished": "2018-01-01T02:00:00+02:00",
"address": {
"streetAddress": "test street address",
"locality": "test locality",
"region": "test region",
"postalCode": "test postalCode",
"countryName": "test country"
},
"contactPoint": {
"email": "test@example.com"
},
"roles": [
"public"
]
}
],
"owner": "public",
"id": "43800a9d9fc84e13862b58969c904b8c"
}
}
Documents can be added to the object with separate request:
Примітка
Next action allowed to users that belongs to next auth group:
public
POST /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c/documents HTTP/1.0
Authorization: Basic cHVibGljOnB1YmxpYw==
Content-Length: 315
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"title": "doc(1).txt",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/6e4e052020524377a5d5c66c08000ba1?Signature=XMsBXAprJGrPSBE0sUMfBpd7d8puyzhw1PJnlM%2FNZSwCJYLnJCa7CI7unQfT2h1HZdYDJmzVVXziPVIwLLURCw%3D%3D&KeyID=a8968c46",
"hash": "md5:00000000000000000000000000000000",
"format": "plain/text"
}
}
Response: 201 Created
Content-Type: application/json
Location: http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests/43800a9d9fc84e13862b58969c904b8c/documents/cb9274a0ef6b40c8bf3d6c9bad2fd5cc
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTJ9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDEyfX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(1).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/6e4e052020524377a5d5c66c08000ba1?Signature=YFNaTNWcITSPPBImzR%252BfDMHgtJSaLVWbxJKrS8VFTR%252BSqd4L63e1rEySYJr5k%252BfNYqiLWi4NAZW%2FO1JT1LHsDg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "request_owner"
}
}
Documents can be changed:
Примітка
Next action allowed to users that belongs to next auth group:
public
PUT /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c/documents/cb9274a0ef6b40c8bf3d6c9bad2fd5cc HTTP/1.0
Authorization: Basic cHVibGljOnB1YmxpYw==
Content-Length: 326
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"title": "doc(2).json",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/4d52c0946e8a4999929db0c4e72b2fee?Signature=AhAdnVKR22WUb2VNfZ6AngI28xPruzRm9dy3YCYl7ruo8Pz%2FxDsjvcpH4rLey%2BI2JiZf%2FyD73KmzQ5Uuy4wLBQ%3D%3D&KeyID=a8968c46",
"hash": "md5:00000000000000000000000000000000",
"format": "application/json"
}
}
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTR9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE0fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(2).json",
"format": "application/json",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/4d52c0946e8a4999929db0c4e72b2fee?Signature=aDGWSUzxCNw8%252BsEj4h77bkcZS5K8C9jN%252BHnei3NRNrtWzu0nUFqxO%2FO%2FGws8v%2F%252BS9rTXWhsww%252Bs9eqx0gcTmBg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:02:00+02:00",
"dateModified": "2018-01-01T02:02:00+02:00",
"author": "request_owner"
}
}
And the object itself can be changed by patching answer field only:
Примітка
Next action allowed to users that belongs to next auth group:
sas
PATCH /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c HTTP/1.0
Authorization: Basic dGVzdF9zYXM6dGVzdF9zYXNfdG9rZW4=
Content-Length: 73
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"answer": "monitoringCreated",
"reason": "There is my answer"
}
}
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTZ9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE2fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"dateAnswered": "2018-01-01T02:03:00+02:00",
"dateModified": "2018-01-01T02:03:00+02:00",
"dateCreated": "2018-01-01T02:00:00+02:00",
"requestId": "UA-R-2018-01-01-000001",
"tenderId": "ffffffffffffffffffffffffffffffff",
"documents": [
{
"id": "97b4005ab68d462e9a6e101c804addfd",
"hash": "md5:00000000000000000000000000000000",
"title": "doc.txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/df1080bf9c774ba4b27f28f1d5b9c652?Signature=OZBoQZnZihQIpBoi5eojoquIpAe3DJoXrSnxl%252BvDwpywgysRKjdf8VoI8jgqu87vJJVcPhLLc90vuSOZuEJqCg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:00:00+02:00",
"dateModified": "2018-01-01T02:00:00+02:00",
"author": "request_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(1).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/6e4e052020524377a5d5c66c08000ba1?Signature=YFNaTNWcITSPPBImzR%252BfDMHgtJSaLVWbxJKrS8VFTR%252BSqd4L63e1rEySYJr5k%252BfNYqiLWi4NAZW%2FO1JT1LHsDg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "request_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(2).json",
"format": "application/json",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/4d52c0946e8a4999929db0c4e72b2fee?Signature=aDGWSUzxCNw8%252BsEj4h77bkcZS5K8C9jN%252BHnei3NRNrtWzu0nUFqxO%2FO%2FGws8v%2F%252BS9rTXWhsww%252Bs9eqx0gcTmBg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:02:00+02:00",
"dateModified": "2018-01-01T02:02:00+02:00",
"author": "request_owner"
}
],
"parties": [
{
"id": "a532f2e60d874493ab4f1e53e7bb9539",
"name": "party name",
"datePublished": "2018-01-01T02:00:00+02:00",
"address": {
"streetAddress": "test street address",
"locality": "test locality",
"region": "test region",
"postalCode": "test postalCode",
"countryName": "test country"
},
"contactPoint": {
"email": "test@example.com"
},
"roles": [
"public"
]
}
],
"owner": "public",
"reason": "There is my answer",
"answer": "monitoringCreated",
"id": "43800a9d9fc84e13862b58969c904b8c"
}
}
Documents related to answer also can be added to the object with separate request:
Примітка
Next action allowed to users that belongs to next auth group:
sas
POST /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c/documents HTTP/1.0
Authorization: Basic dGVzdF9zYXM6dGVzdF9zYXNfdG9rZW4=
Content-Length: 315
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"title": "doc(3).txt",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/29ec040bd85647289a6f7627985f4970?Signature=jBfRFdjWn4nG0gnM7obV1yfjiueCaZnVpEvgRH9qT3rDKrPUrp8RjpMLQHREpEYRu09s8f0%2BzO3584wQLixaBw%3D%3D&KeyID=a8968c46",
"hash": "md5:00000000000000000000000000000000",
"format": "plain/text"
}
}
Response: 201 Created
Content-Type: application/json
Location: http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests/43800a9d9fc84e13862b58969c904b8c/documents/10c6bafb0d53454292de4a2b0bc54d5b
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTh9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE4fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"id": "10c6bafb0d53454292de4a2b0bc54d5b",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(3).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/29ec040bd85647289a6f7627985f4970?Signature=oskLJCq7LX%2F8vlfsSoOiMpRSIbTAoXU4CB%2FpjLh%2FjqEbYXOBRDATxl6vu%2FHJ5VJXYiE6WspuJGWt8JMbQjzkBw%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "monitoring_owner"
}
}
Lets get all request documents:
GET /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c/documents HTTP/1.0
Host: audit-api-sandbox.prozorro.gov.ua
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTh9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE4fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": [
{
"id": "97b4005ab68d462e9a6e101c804addfd",
"hash": "md5:00000000000000000000000000000000",
"title": "doc.txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/df1080bf9c774ba4b27f28f1d5b9c652?Signature=OZBoQZnZihQIpBoi5eojoquIpAe3DJoXrSnxl%252BvDwpywgysRKjdf8VoI8jgqu87vJJVcPhLLc90vuSOZuEJqCg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:00:00+02:00",
"dateModified": "2018-01-01T02:00:00+02:00",
"author": "request_owner"
},
{
"id": "10c6bafb0d53454292de4a2b0bc54d5b",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(3).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/29ec040bd85647289a6f7627985f4970?Signature=oskLJCq7LX%2F8vlfsSoOiMpRSIbTAoXU4CB%2FpjLh%2FjqEbYXOBRDATxl6vu%2FHJ5VJXYiE6WspuJGWt8JMbQjzkBw%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "monitoring_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(2).json",
"format": "application/json",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/4d52c0946e8a4999929db0c4e72b2fee?Signature=aDGWSUzxCNw8%252BsEj4h77bkcZS5K8C9jN%252BHnei3NRNrtWzu0nUFqxO%2FO%2FGws8v%2F%252BS9rTXWhsww%252Bs9eqx0gcTmBg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:02:00+02:00",
"dateModified": "2018-01-01T02:02:00+02:00",
"author": "request_owner"
}
]
}
Once answer has been provided it can no longer be changed, lets make an attempt:
Примітка
Next action allowed to users that belongs to next auth group:
sas
PATCH /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c HTTP/1.0
Authorization: Basic dGVzdF9zYXM6dGVzdF9zYXNfdG9rZW4=
Content-Length: 50
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"reason": "There is my another answer"
}
}
Response: 403 Forbidden
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTZ9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE2fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"status": "error",
"errors": [
{
"location": "url",
"name": "permission",
"description": "Forbidden"
}
]
}
Lets take a look at request. Notice that part of parties fields is not visible in public api:
GET /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c HTTP/1.0
Host: audit-api-sandbox.prozorro.gov.ua
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTh9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE4fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"dateAnswered": "2018-01-01T02:03:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"dateCreated": "2018-01-01T02:00:00+02:00",
"requestId": "UA-R-2018-01-01-000001",
"tenderId": "ffffffffffffffffffffffffffffffff",
"documents": [
{
"id": "97b4005ab68d462e9a6e101c804addfd",
"hash": "md5:00000000000000000000000000000000",
"title": "doc.txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/df1080bf9c774ba4b27f28f1d5b9c652?Signature=OZBoQZnZihQIpBoi5eojoquIpAe3DJoXrSnxl%252BvDwpywgysRKjdf8VoI8jgqu87vJJVcPhLLc90vuSOZuEJqCg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:00:00+02:00",
"dateModified": "2018-01-01T02:00:00+02:00",
"author": "request_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(1).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/6e4e052020524377a5d5c66c08000ba1?Signature=YFNaTNWcITSPPBImzR%252BfDMHgtJSaLVWbxJKrS8VFTR%252BSqd4L63e1rEySYJr5k%252BfNYqiLWi4NAZW%2FO1JT1LHsDg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "request_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(2).json",
"format": "application/json",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/4d52c0946e8a4999929db0c4e72b2fee?Signature=aDGWSUzxCNw8%252BsEj4h77bkcZS5K8C9jN%252BHnei3NRNrtWzu0nUFqxO%2FO%2FGws8v%2F%252BS9rTXWhsww%252Bs9eqx0gcTmBg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:02:00+02:00",
"dateModified": "2018-01-01T02:02:00+02:00",
"author": "request_owner"
},
{
"id": "10c6bafb0d53454292de4a2b0bc54d5b",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(3).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/29ec040bd85647289a6f7627985f4970?Signature=oskLJCq7LX%2F8vlfsSoOiMpRSIbTAoXU4CB%2FpjLh%2FjqEbYXOBRDATxl6vu%2FHJ5VJXYiE6WspuJGWt8JMbQjzkBw%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "monitoring_owner"
}
],
"parties": [
{
"id": "a532f2e60d874493ab4f1e53e7bb9539",
"name": "party name",
"datePublished": "2018-01-01T02:00:00+02:00",
"roles": [
"public"
]
}
],
"owner": "public",
"reason": "There is my answer",
"answer": "monitoringCreated",
"id": "43800a9d9fc84e13862b58969c904b8c"
}
}
But hidden parties fields would be visible for reviewer and you’ll need an access token to see it:
Примітка
Next action allowed to users that belongs to next auth group:
sas
public
GET /api/2.5/requests/43800a9d9fc84e13862b58969c904b8c HTTP/1.0
Authorization: Basic dGVzdF9zYXM6dGVzdF9zYXNfdG9rZW4=
Host: audit-api-sandbox.prozorro.gov.ua
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMTh9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDE4fX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"dateAnswered": "2018-01-01T02:03:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"dateCreated": "2018-01-01T02:00:00+02:00",
"requestId": "UA-R-2018-01-01-000001",
"tenderId": "ffffffffffffffffffffffffffffffff",
"documents": [
{
"id": "97b4005ab68d462e9a6e101c804addfd",
"hash": "md5:00000000000000000000000000000000",
"title": "doc.txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/df1080bf9c774ba4b27f28f1d5b9c652?Signature=OZBoQZnZihQIpBoi5eojoquIpAe3DJoXrSnxl%252BvDwpywgysRKjdf8VoI8jgqu87vJJVcPhLLc90vuSOZuEJqCg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:00:00+02:00",
"dateModified": "2018-01-01T02:00:00+02:00",
"author": "request_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(1).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/6e4e052020524377a5d5c66c08000ba1?Signature=YFNaTNWcITSPPBImzR%252BfDMHgtJSaLVWbxJKrS8VFTR%252BSqd4L63e1rEySYJr5k%252BfNYqiLWi4NAZW%2FO1JT1LHsDg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "request_owner"
},
{
"id": "cb9274a0ef6b40c8bf3d6c9bad2fd5cc",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(2).json",
"format": "application/json",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/4d52c0946e8a4999929db0c4e72b2fee?Signature=aDGWSUzxCNw8%252BsEj4h77bkcZS5K8C9jN%252BHnei3NRNrtWzu0nUFqxO%2FO%2FGws8v%2F%252BS9rTXWhsww%252Bs9eqx0gcTmBg%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:02:00+02:00",
"dateModified": "2018-01-01T02:02:00+02:00",
"author": "request_owner"
},
{
"id": "10c6bafb0d53454292de4a2b0bc54d5b",
"hash": "md5:00000000000000000000000000000000",
"title": "doc(3).txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/29ec040bd85647289a6f7627985f4970?Signature=oskLJCq7LX%2F8vlfsSoOiMpRSIbTAoXU4CB%2FpjLh%2FjqEbYXOBRDATxl6vu%2FHJ5VJXYiE6WspuJGWt8JMbQjzkBw%253D%253D&KeyID=a8968c46",
"datePublished": "2018-01-01T02:01:00+02:00",
"dateModified": "2018-01-01T02:01:00+02:00",
"author": "monitoring_owner"
}
],
"parties": [
{
"id": "a532f2e60d874493ab4f1e53e7bb9539",
"name": "party name",
"datePublished": "2018-01-01T02:00:00+02:00",
"address": {
"streetAddress": "test street address",
"locality": "test locality",
"region": "test region",
"postalCode": "test postalCode",
"countryName": "test country"
},
"contactPoint": {
"email": "test@example.com"
},
"roles": [
"public"
]
}
],
"owner": "public",
"reason": "There is my answer",
"answer": "monitoringCreated",
"id": "43800a9d9fc84e13862b58969c904b8c"
}
}
Lets add another request and leave it without an answer:
POST /api/2.5/requests HTTP/1.0
Authorization: Basic cHVibGljOnB1YmxpYw==
Content-Length: 1236
Content-Type: application/json
Host: audit-api-sandbox.prozorro.gov.ua
DATA:
{
"data": {
"tenderId": "ffffffffffffffffffffffffffffffff",
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"parties": [
{
"name": "party name",
"address": {
"streetAddress": "test street address",
"locality": "test locality",
"region": "test region",
"postalCode": "test postalCode",
"countryName": "test country"
},
"contactPoint": {
"email": "test@example.com"
}
}
],
"documents": [
{
"title": "doc.txt",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/24757d61607549ccb347a76248307a82?Signature=CTpNQxTVZ5c%2BNU3F7qG%2BOpdsYSs5BFBdorcoygX2KiR70ZY%2B9VachFK3cJoCcNloHLcXKiHAoBlhgMSdqfsrDQ%3D%3D&KeyID=a8968c46",
"hash": "md5:00000000000000000000000000000000",
"format": "plain/text"
}
]
}
}
Response: 201 Created
Content-Type: application/json
Location: http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests/bb3ceafb38eb48eba58f89a4dfdf1718
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMjB9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDIwfX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": {
"description": "Yo-ho-ho",
"violationType": [
"corruptionDescription",
"corruptionProcurementMethodType",
"corruptionPublicDisclosure",
"corruptionBiddingDocuments",
"documentsForm",
"corruptionAwarded",
"corruptionCancelled",
"corruptionContracting",
"corruptionChanges",
"other",
"corruptionUntimely",
"corruptionBidSecurity",
"corruptionFailureDocuments",
"corruptionConsideration",
"servicesWithoutProcurementProcedure",
"useProceduresNotByLaw",
"rejectionOfBidsNotByLaw",
"inaccuratePersonalData",
"deadlineForThePublicationDocumentation",
"notComplyDecisionACU",
"contractsWithoutProcurement"
],
"dateModified": "2018-02-01T02:00:00+02:00",
"dateCreated": "2018-02-01T02:00:00+02:00",
"requestId": "UA-R-2018-02-01-000001",
"tenderId": "ffffffffffffffffffffffffffffffff",
"documents": [
{
"id": "0578989b6241460a8eab680b718c053b",
"hash": "md5:00000000000000000000000000000000",
"title": "doc.txt",
"format": "plain/text",
"url": "http://public-docs-sandbox.prozorro.gov.ua/get/24757d61607549ccb347a76248307a82?Signature=KwQl3l5ZjU3gWdFGfQnv4TUEFPmo4%252BhMVoDTa5pra7OFsspFEkCJrmHXGpPOww5R%252BEx6l8EEQsVjWPELfSl%252BBw%253D%253D&KeyID=a8968c46",
"datePublished": "2018-02-01T02:00:00+02:00",
"dateModified": "2018-02-01T02:00:00+02:00",
"author": "request_owner"
}
],
"parties": [
{
"id": "c2c7c5e0cd2c48178d693c816bad885f",
"name": "party name",
"datePublished": "2018-02-01T02:00:00+02:00",
"address": {
"streetAddress": "test street address",
"locality": "test locality",
"region": "test region",
"postalCode": "test postalCode",
"countryName": "test country"
},
"contactPoint": {
"email": "test@example.com"
},
"roles": [
"public"
]
}
],
"owner": "public",
"id": "bb3ceafb38eb48eba58f89a4dfdf1718"
}
}
Here are all available requests:
GET /api/2.5/requests?opt_fields=answer HTTP/1.0
Host: audit-api-sandbox.prozorro.gov.ua
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMjB9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDIwfX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": [
{
"dateModified": "2018-01-01T02:01:00+02:00",
"answer": "monitoringCreated",
"id": "43800a9d9fc84e13862b58969c904b8c"
},
{
"dateModified": "2018-02-01T02:00:00+02:00",
"id": "bb3ceafb38eb48eba58f89a4dfdf1718"
}
],
"next_page": {
"offset": 1728901091.368,
"path": "/api/2.5/requests?opt_fields=answer&offset=1728901091.368",
"uri": "http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests?opt_fields=answer&offset=1728901091.368"
}
}
Feed modes available:
by default - all requests
mode=answered
- requests that have an answermode=not_answered
- requests that dont’t have an answer
For example:
GET /api/2.5/requests?mode=answered&opt_fields=answer HTTP/1.0
Host: audit-api-sandbox.prozorro.gov.ua
Response: 200 OK
Content-Type: application/json
Set-Cookie: SESSION=eyJvcGVyYXRpb25fdGltZSI6IHsiJHRpbWVzdGFtcCI6IHsidCI6IDE3Mjg5MDEwOTEsICJpIjogMjB9fSwgImNsdXN0ZXJfdGltZSI6IHsiY2x1c3RlclRpbWUiOiB7IiR0aW1lc3RhbXAiOiB7InQiOiAxNzI4OTAxMDkxLCAiaSI6IDIwfX0sICJzaWduYXR1cmUiOiB7Imhhc2giOiB7IiRiaW5hcnkiOiB7ImJhc2U2NCI6ICIvd2hWRlJvV1FLOE1iTlZweCtLbitCYklZWGM9IiwgInN1YlR5cGUiOiAiMDAifX0sICJrZXlJZCI6IDczNzIxODEzMTE5NzQyNzcxMjJ9fX0=; Path=/
{
"data": [
{
"dateModified": "2018-01-01T02:01:00+02:00",
"answer": "monitoringCreated",
"id": "43800a9d9fc84e13862b58969c904b8c"
}
],
"next_page": {
"offset": 1728901091.313,
"path": "/api/2.5/requests?mode=answered&opt_fields=answer&offset=1728901091.313",
"uri": "http://audit-api-sandbox.prozorro.gov.ua/api/2.5/requests?mode=answered&opt_fields=answer&offset=1728901091.313"
}
}