Етапи (Умови) оплати

Інформація про оплату може бути зазначена за допомогою поля milestones що містить об’єкти Milestone

POST /api/2.5/tenders HTTP/1.0
Authorization: Bearer broker
Content-Length: 2931
Content-Type: application/json
Host: lb-api-sandbox.prozorro.gov.ua
DATA:
{
  "data": {
    "title": "футляри до державних нагород",
    "mainProcurementCategory": "goods",
    "procuringEntity": {
      "name": "Державне управління справами",
      "identifier": {
        "scheme": "UA-EDR",
        "id": "00037256",
        "uri": "http://www.dus.gov.ua/",
        "legalName": "Державне управління справами"
      },
      "address": {
        "countryName": "Україна",
        "postalCode": "01220",
        "region": "м. Київ",
        "locality": "м. Київ",
        "streetAddress": "вул. Банкова, 11, корпус 1"
      },
      "contactPoint": {
        "name": "Державне управління справами",
        "telephone": "+0440000000"
      },
      "kind": "general"
    },
    "value": {
      "amount": 500,
      "currency": "UAH"
    },
    "minimalStep": {
      "amount": 15,
      "currency": "UAH"
    },
    "items": [
      {
        "description": "футляри до державних нагород",
        "classification": {
          "scheme": "ДК021",
          "id": "44617100-9",
          "description": "Cartons"
        },
        "additionalClassifications": [
          {
            "scheme": "ДКПП",
            "id": "17.21.1",
            "description": "папір і картон гофровані, паперова й картонна тара"
          }
        ],
        "unit": {
          "name": "кг",
          "code": "KGM",
          "value": {
            "amount": 6
          }
        },
        "quantity": 5,
        "deliveryDate": {
          "startDate": "2021-03-18T00:00:00+02:00",
          "endDate": "2021-03-21T00:00:00+02:00"
        },
        "deliveryAddress": {
          "countryName": "Україна",
          "postalCode": "79000",
          "region": "м. Київ",
          "locality": "м. Київ",
          "streetAddress": "вул. Банкова 1"
        }
      }
    ],
    "enquiryPeriod": {
      "endDate": "2021-03-23T00:00:00+02:00"
    },
    "tenderPeriod": {
      "endDate": "2021-03-30T00:00:00+02:00"
    },
    "procurementMethodType": "belowThreshold",
    "milestones": [
      {
        "title": "signingTheContract",
        "code": "prepayment",
        "type": "financing",
        "duration": {
          "days": 5,
          "type": "banking"
        },
        "sequenceNumber": 0,
        "percentage": 45.55
      },
      {
        "title": "deliveryOfGoods",
        "code": "postpayment",
        "type": "financing",
        "duration": {
          "days": 7,
          "type": "calendar"
        },
        "sequenceNumber": 1,
        "percentage": 54.45
      }
    ]
  }
}

Response: 201 Created
Content-Type: application/json
Location: http://lb-api-sandbox.prozorro.gov.ua/api/2.5/tenders/cc1418f989634e5ebec00becb174f72d
X-Content-Type-Options: nosniff
{
  "data": {
    "title": "футляри до державних нагород",
    "date": "2021-03-16T00:00:00+02:00",
    "dateModified": "2021-03-16T00:00:00+02:00",
    "tenderID": "UA-2021-03-16-000001",
    "owner": "broker",
    "mainProcurementCategory": "goods",
    "milestones": [
      {
        "id": "356c9c8a670647a3b548c10e0b85316b",
        "title": "signingTheContract",
        "type": "financing",
        "code": "prepayment",
        "percentage": 45.55,
        "duration": {
          "days": 5,
          "type": "banking"
        },
        "sequenceNumber": 0
      },
      {
        "id": "a26e16936f294618af8d0531339331d3",
        "title": "deliveryOfGoods",
        "type": "financing",
        "code": "postpayment",
        "percentage": 54.45,
        "duration": {
          "days": 7,
          "type": "calendar"
        },
        "sequenceNumber": 1
      }
    ],
    "procurementMethod": "open",
    "awardCriteria": "lowestCost",
    "submissionMethod": "electronicAuction",
    "status": "active.enquiries",
    "items": [
      {
        "id": "60ffd7cbd43d4b8b93e58e914f4e5b19",
        "description": "футляри до державних нагород",
        "additionalClassifications": [
          {
            "scheme": "ДКПП",
            "id": "17.21.1",
            "description": "папір і картон гофровані, паперова й картонна тара"
          }
        ],
        "quantity": 5.0,
        "deliveryDate": {
          "startDate": "2021-03-18T00:00:00+02:00",
          "endDate": "2021-03-21T00:00:00+02:00"
        },
        "deliveryAddress": {
          "streetAddress": "вул. Банкова 1",
          "locality": "м. Київ",
          "region": "м. Київ",
          "postalCode": "79000",
          "countryName": "Україна"
        },
        "classification": {
          "description": "Cartons",
          "scheme": "ДК021",
          "id": "44617100-9"
        },
        "unit": {
          "name": "кг",
          "code": "KGM",
          "value": {
            "amount": 6.0,
            "currency": "UAH",
            "valueAddedTaxIncluded": true
          }
        }
      }
    ],
    "value": {
      "amount": 500.0,
      "currency": "UAH",
      "valueAddedTaxIncluded": true
    },
    "enquiryPeriod": {
      "startDate": "2021-03-16T00:00:00+02:00",
      "endDate": "2021-03-23T00:00:00+02:00"
    },
    "tenderPeriod": {
      "startDate": "2021-03-23T00:00:00+02:00",
      "endDate": "2021-03-30T00:00:00+02:00"
    },
    "procuringEntity": {
      "name": "Державне управління справами",
      "identifier": {
        "scheme": "UA-EDR",
        "id": "00037256",
        "legalName": "Державне управління справами",
        "uri": "http://www.dus.gov.ua/"
      },
      "address": {
        "streetAddress": "вул. Банкова, 11, корпус 1",
        "locality": "м. Київ",
        "region": "м. Київ",
        "postalCode": "01220",
        "countryName": "Україна"
      },
      "contactPoint": {
        "name": "Державне управління справами",
        "telephone": "+0440000000"
      },
      "kind": "general"
    },
    "minimalStep": {
      "amount": 15.0,
      "currency": "UAH",
      "valueAddedTaxIncluded": true
    },
    "procurementMethodType": "belowThreshold",
    "id": "cc1418f989634e5ebec00becb174f72d",
    "next_check": "2021-03-23T00:00:00+02:00"
  },
  "access": {
    "token": "e52663fc65a840e998dfd864e35d273c",
    "transfer": "ba09e5edede8459f92b1fd1cb76bd246"
  }
}

Давайте оновимо milestones:

PATCH /api/2.5/tenders/cc1418f989634e5ebec00becb174f72d?acc_token=e52663fc65a840e998dfd864e35d273c HTTP/1.0
Authorization: Bearer broker
Content-Length: 161
Content-Type: application/json
Host: lb-api-sandbox.prozorro.gov.ua
DATA:
{
  "data": {
    "milestones": [
      {},
      {
        "title": "anotherEvent",
        "description": "Підозрілий опис"
      }
    ]
  }
}

Response: 200 OK
Content-Type: application/json
X-Content-Type-Options: nosniff
{
  "data": {
    "title": "футляри до державних нагород",
    "date": "2021-03-16T00:00:00+02:00",
    "dateModified": "2021-03-16T00:00:00+02:00",
    "tenderID": "UA-2021-03-16-000001",
    "owner": "broker",
    "mainProcurementCategory": "goods",
    "milestones": [
      {
        "id": "356c9c8a670647a3b548c10e0b85316b",
        "title": "signingTheContract",
        "type": "financing",
        "code": "prepayment",
        "percentage": 45.55,
        "duration": {
          "days": 5,
          "type": "banking"
        },
        "sequenceNumber": 0
      },
      {
        "id": "a26e16936f294618af8d0531339331d3",
        "title": "anotherEvent",
        "description": "Підозрілий опис",
        "type": "financing",
        "code": "postpayment",
        "percentage": 54.45,
        "duration": {
          "days": 7,
          "type": "calendar"
        },
        "sequenceNumber": 1
      }
    ],
    "procurementMethod": "open",
    "awardCriteria": "lowestCost",
    "submissionMethod": "electronicAuction",
    "status": "active.enquiries",
    "items": [
      {
        "id": "60ffd7cbd43d4b8b93e58e914f4e5b19",
        "description": "футляри до державних нагород",
        "additionalClassifications": [
          {
            "scheme": "ДКПП",
            "id": "17.21.1",
            "description": "папір і картон гофровані, паперова й картонна тара"
          }
        ],
        "quantity": 5.0,
        "deliveryDate": {
          "startDate": "2021-03-18T00:00:00+02:00",
          "endDate": "2021-03-21T00:00:00+02:00"
        },
        "deliveryAddress": {
          "streetAddress": "вул. Банкова 1",
          "locality": "м. Київ",
          "region": "м. Київ",
          "postalCode": "79000",
          "countryName": "Україна"
        },
        "classification": {
          "description": "Cartons",
          "scheme": "ДК021",
          "id": "44617100-9"
        },
        "unit": {
          "name": "кг",
          "code": "KGM",
          "value": {
            "amount": 6.0,
            "currency": "UAH",
            "valueAddedTaxIncluded": true
          }
        }
      }
    ],
    "value": {
      "amount": 500.0,
      "currency": "UAH",
      "valueAddedTaxIncluded": true
    },
    "enquiryPeriod": {
      "startDate": "2021-03-16T00:00:00+02:00",
      "endDate": "2021-03-23T00:00:00+02:00"
    },
    "tenderPeriod": {
      "startDate": "2021-03-23T00:00:00+02:00",
      "endDate": "2021-03-30T00:00:00+02:00"
    },
    "procuringEntity": {
      "name": "Державне управління справами",
      "identifier": {
        "scheme": "UA-EDR",
        "id": "00037256",
        "legalName": "Державне управління справами",
        "uri": "http://www.dus.gov.ua/"
      },
      "address": {
        "streetAddress": "вул. Банкова, 11, корпус 1",
        "locality": "м. Київ",
        "region": "м. Київ",
        "postalCode": "01220",
        "countryName": "Україна"
      },
      "contactPoint": {
        "name": "Державне управління справами",
        "telephone": "+0440000000"
      },
      "kind": "general"
    },
    "minimalStep": {
      "amount": 15.0,
      "currency": "UAH",
      "valueAddedTaxIncluded": true
    },
    "procurementMethodType": "belowThreshold",
    "id": "cc1418f989634e5ebec00becb174f72d",
    "next_check": "2021-03-23T00:00:00+02:00"
  }
}

Для мультилотових тендерів кожен об’єкт Milestone може відноситись до конретного лоту

PATCH /api/2.5/tenders/cc1418f989634e5ebec00becb174f72d?acc_token=e52663fc65a840e998dfd864e35d273c HTTP/1.0
Authorization: Bearer broker
Content-Length: 130
Content-Type: application/json
Host: lb-api-sandbox.prozorro.gov.ua
DATA:
{
  "data": {
    "milestones": [
      {
        "relatedLot": "f0414ee8a82d45e6a8947ddea6ce5d67"
      },
      {
        "relatedLot": "f0414ee8a82d45e6a8947ddea6ce5d67"
      }
    ]
  }
}

Response: 200 OK
Content-Type: application/json
X-Content-Type-Options: nosniff
{
  "data": {
    "title": "футляри до державних нагород",
    "date": "2021-03-16T00:00:00+02:00",
    "dateModified": "2021-03-16T00:00:00+02:00",
    "tenderID": "UA-2021-03-16-000001",
    "owner": "broker",
    "mainProcurementCategory": "goods",
    "milestones": [
      {
        "id": "356c9c8a670647a3b548c10e0b85316b",
        "title": "signingTheContract",
        "type": "financing",
        "code": "prepayment",
        "percentage": 45.55,
        "duration": {
          "days": 5,
          "type": "banking"
        },
        "sequenceNumber": 0,
        "relatedLot": "f0414ee8a82d45e6a8947ddea6ce5d67"
      },
      {
        "id": "a26e16936f294618af8d0531339331d3",
        "title": "anotherEvent",
        "description": "Підозрілий опис",
        "type": "financing",
        "code": "postpayment",
        "percentage": 54.45,
        "duration": {
          "days": 7,
          "type": "calendar"
        },
        "sequenceNumber": 1,
        "relatedLot": "f0414ee8a82d45e6a8947ddea6ce5d67"
      }
    ],
    "procurementMethod": "open",
    "awardCriteria": "lowestCost",
    "submissionMethod": "electronicAuction",
    "status": "active.enquiries",
    "items": [
      {
        "id": "60ffd7cbd43d4b8b93e58e914f4e5b19",
        "description": "футляри до державних нагород",
        "additionalClassifications": [
          {
            "scheme": "ДКПП",
            "id": "17.21.1",
            "description": "папір і картон гофровані, паперова й картонна тара"
          }
        ],
        "quantity": 5.0,
        "deliveryDate": {
          "startDate": "2021-03-18T00:00:00+02:00",
          "endDate": "2021-03-21T00:00:00+02:00"
        },
        "deliveryAddress": {
          "streetAddress": "вул. Банкова 1",
          "locality": "м. Київ",
          "region": "м. Київ",
          "postalCode": "79000",
          "countryName": "Україна"
        },
        "classification": {
          "description": "Cartons",
          "scheme": "ДК021",
          "id": "44617100-9"
        },
        "unit": {
          "name": "кг",
          "code": "KGM",
          "value": {
            "amount": 6.0,
            "currency": "UAH",
            "valueAddedTaxIncluded": true
          }
        }
      }
    ],
    "value": {
      "amount": 500.0,
      "currency": "UAH",
      "valueAddedTaxIncluded": true
    },
    "enquiryPeriod": {
      "startDate": "2021-03-16T00:00:00+02:00",
      "endDate": "2021-03-23T00:00:00+02:00"
    },
    "tenderPeriod": {
      "startDate": "2021-03-23T00:00:00+02:00",
      "endDate": "2021-03-30T00:00:00+02:00"
    },
    "procuringEntity": {
      "name": "Державне управління справами",
      "identifier": {
        "scheme": "UA-EDR",
        "id": "00037256",
        "legalName": "Державне управління справами",
        "uri": "http://www.dus.gov.ua/"
      },
      "address": {
        "streetAddress": "вул. Банкова, 11, корпус 1",
        "locality": "м. Київ",
        "region": "м. Київ",
        "postalCode": "01220",
        "countryName": "Україна"
      },
      "contactPoint": {
        "name": "Державне управління справами",
        "telephone": "+0440000000"
      },
      "kind": "general"
    },
    "minimalStep": {
      "amount": 15.0,
      "currency": "UAH",
      "valueAddedTaxIncluded": true
    },
    "lots": [
      {
        "id": "f0414ee8a82d45e6a8947ddea6ce5d67",
        "title": "lot title",
        "description": "lot description",
        "date": "2021-03-16T00:00:00+02:00",
        "status": "active",
        "value": {
          "amount": 500.0,
          "currency": "UAH",
          "valueAddedTaxIncluded": true
        },
        "minimalStep": {
          "amount": 15.0,
          "currency": "UAH",
          "valueAddedTaxIncluded": true
        }
      }
    ],
    "procurementMethodType": "belowThreshold",
    "id": "cc1418f989634e5ebec00becb174f72d",
    "next_check": "2021-03-23T00:00:00+02:00"
  }
}

Будте обачні, об’єкт lot не може бути видалено, якщо в нього вказані етапи оплати

DELETE /api/2.5/tenders/cc1418f989634e5ebec00becb174f72d/lots/f0414ee8a82d45e6a8947ddea6ce5d67?acc_token=e52663fc65a840e998dfd864e35d273c HTTP/1.0
Authorization: Bearer broker
Content-Length: 0
Host: lb-api-sandbox.prozorro.gov.ua

Response: 422 Unprocessable Entity
Content-Type: application/json
X-Content-Type-Options: nosniff
{
  "status": "error",
  "errors": [
    {
      "location": "body",
      "name": "milestones",
      "description": [
        {
          "relatedLot": [
            "relatedLot should be one of the lots."
          ]
        },
        {
          "relatedLot": [
            "relatedLot should be one of the lots."
          ]
        }
      ]
    }
  ]
}