budget.md

 

API

API Overview

Out team provides free REST services for you to get the up-to-date Moldova budget data. No authorization required. Later we'll add the ability for you to register your email and get the latest updates and changes in the API.
If you need the specific data on educational institutes, you can access in here: http://afla.md/info/api/

Disclaimer

Where does the data come from?

The data on BugetMD portal is taken from data.gov.md portal. Such Open data is the data provided by public authorities in the machine readable format, at the disaggregated level. However, they do not contain personal information, trade secrets and state secrets. Identification and publication of data sets of interest to citizens and businesses is one of the duties of public authorities. This practice will increase transparency of the public sector performance and responsiveness.

Who is responsible for the data being accurate?

Since the data is provided by the public authorities, they take the full responsibility for that.

API Services

Common (base) URL for the API: http://www.buget.md/ws/

Expenditures list

URL: /expenditureslist/[parameters]

Parameters (all of them are optional)

  • page_number - number of expenditures per page (see below) to return
  • page - page to start with, e.g.page=1&page_number=10 will return records from 0 to 10, page=1&page_number=10 return records 10...20
  • sort_by - field to sort the records through (field names can be found in the result set returned by the web service)
  • sort_method - ASC for ascending sort order and DESC for descending

Returns:

JSON array with two elements:
  • expenditures - array with all the expenditures found
  • num_rows - total number of the rows found with the given conditions

Each record in the expenditures' array contains:
  • summary_expenditure_id - unique id of the expenditure
  • summary_expenditure_approved_sum
  • summary_expenditure_adjusted_sum
  • summary_expenditure_executed_sum
  • article_item_id
  • atricle_item_name_en- name of the article item in English language
  • article_name_ru - name of the article item in Russian language
  • article_name_ro - name of the article item in Romanian language
  • subgroup_id
  • subgroup_name en - name of the subgroup in English language
  • subgroup_name_ru - name of the subgroup in Russian language
  • subgroup_name_ro- name of the subgroup in Romanian language
  • expenditure_type_id
  • expenditure_type_name en - name of the expenditure type in English language
  • expenditure_type_name_ru- name of the expenditure type in Russian language
  • expenditure_type_name_ro- name of the expenditure type in Romanian language
  • institution_id
  • institution_name_en - name of the institution n English language
  • institution_name_ru - name of the institution in Russian language
  • institution_name_ro- name of the institution in Romanian language
  • source id
  • source_name en - name of the source in English language
  • source_name_ru - name of the source in Russian language
  • source_name_ro- name of the source in Romanian language

Examples:

Request: http://www.buget.md/ws/expenditureslist?page=1&page_number=10
Response:
{"expenditures":[{"summary_expenditure_id":"1","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"2","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"3","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"4","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"5","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"6","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"7","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"8","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"9","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""},{"summary_expenditure_id":"10","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":""}],"num_rows":"950008"}

Expenditure item details

Examples:

Request: http://www.buget.md/ws/expendituresdetails/1
Response: {"expenditures":{"summary_expenditure_id":"1","summary_expenditure_approved_sum":"0.00","summary_expenditure_adjusted_sum":"-7375600.00","executed_sum":"0.00","year":"2009","article_item_id":"1","article_item_name_en":"Remuneration of work","article_item_name_ro":"","article_item_name_ru":"","subgroup_id":"34","subgroup_name_en":"Hospitals","":"0","type_id":"1","type_name_en":"Personnel","institution_id":"3736","institution_name_en":"IMSP Hospital Association Republican curative and rehabilitation sanatoria","source_id":"2","source_name_en":"Special means"}}

Authorities list

URL: /authoritieslist/

Returns:

JSON array with two elements:
  • authorities - array with all the authorities found
  • num_rows - total number of the rows found with the given conditions
Each record in the authorities array contains:
  • authority_id
  • authority_name_en
  • authority_name_ro
  • authority_name_ru

Examples:


Request: http://www.buget.md/ws/authoritieslist/
Response:
{"authorities":[{"id":"1","name_en":"Parliament","name_ro":"","name_ru":""},{"id":"2","name_en":"Republic of Moldova's Presidency Office (apparatus)","name_ro":"","name_ru":""},{"id":"3","name_en":"Court of Accounts","name_ro":"","name_ru":""},{"id":"4","name_en":"State Office (Chancellery)","name_ro":"","name_ru":""},{"id":"5","name_en":"Constitutional Court","name_ro":"","name_ru":""},{"id":"6","name_en":"Senior Council of Magistracy","name_ro":"","name_ru":""},{"id":"7","name_en":"Supreme Court of Justice","name_ro":"","name_ru":""},{"id":"8","name_en":"Economic Court of Appeals","name_ro":"","name_ru":""},{"id":"9","name_en":"General Attorney's Office","name_ro":"","name_ru":""},{"id":"10","name_en":"Ministry of Economy","name_ro":"","name_ru":""}],"num_rows":"170"}

Groups list

URL: /groupslist/

Returns:

JSON array with two elements:
  • groups - array with all the groups found
  • num_rows - total number of the rows found with the given conditions
Each record in the groups array contains:
  • group_id
  • group_name_en
  • group_name_ro
  • group_name_ru

Examples:

Request: http://www.buget.md/ws/groupslist/
Response:
{"groups":[{"id":"1","name_en":"General purpose state services","name_ro":"","name_ru":""},{"id":"2","name_en":"Utilities and housing","name_ro":"","name_ru":""},{"id":"3","name_en":"Culture, arts, sports and youth activities","name_ro":"","name_ru":""},{"id":"4","name_en":"Justice","name_ro":"","name_ru":""},{"id":"5","name_en":"Social care and social insurance","name_ro":"","name_ru":""},{"id":"6","name_en":"Other economy-related services","name_ro":"","name_ru":""},{"id":"7","name_en":"Research and innovations","name_ro":"","name_ru":""},{"id":"8","name_en":"Education","name_ro":"","name_ru":""},{"id":"9","name_en":"Services and activities unattributable to any other core groups","name_ro":"","name_ru":""},{"id":"10","name_en":"Restoring the state reserves","name_ro":"","name_ru":""},{"id":"11","name_en":"Agriculture, forestry, fishery and water service","name_ro":"","name_ru":""},{"id":"12","name_en":"Healthcare","name_ro":"","name_ru":""},{"id":"13","name_en":"Enforcement of public order and national security","name_ro":"","name_ru":""},{"id":"14","name_en":"National defense","name_ro":"","name_ru":""},{"id":"15","name_en":"Foreign relations","name_ro":"","name_ru":""},{"id":"16","name_en":"Industry and construction","name_ro":"","name_ru":""},{"id":"17","name_en":"Fuel and energy","name_ro":"","name_ru":""},{"id":"18","name_en":"Net lending","name_ro":"","name_ru":""},{"id":"19","name_en":"State debt servicing","name_ro":"","name_ru":""},{"id":"20","name_en":"Transports, roads, communications and IT","name_ro":"","name_ru":""},{"id":"21","name_en":"Environment protection and hydrometeorology","name_ro":"","name_ru":""}],"num_rows":"21"}

Regions list

URL: http://www.buget.md/ws/regionslist/[parameters]

Parameters:

  • page_number - number of regions per page (see below) to return
  • page - page to start with, e.g.page=1&page_number=10 will return records from 0 to 10, page=1&page_number=10 return records 10...20
  • sort_by - field to sort the records through (field names can be found in the result set returned by the web service)
  • sort_method - ASC for ascending sort order and DESC for descending

Returns:

JSON array with two elements:
  • regions - array with all the regions found
  • num_rows - total number of the rows found with the given conditions
Each record in the groups array contains:
  • region_id
  • region_name_en
  • region_name_ro
  • region_name_ru

Examples:

Request: http://boost/ws/regionslist
Response:
{"regions":[{"id":"1","name_en":"Mayoralty of Condrita","name_ro":"","name_ru":"","boost_id":"0008","":"0"},{"id":"2","name_en":"Mayoralty of municipality of Chisinau","name_ro":"","name_ru":"","boost_id":"4930","":"0"},{"id":"3","name_en":"Mayoralty of the city of Vadul lui Voda","name_ro":"","name_ru":"","boost_id":"5242","":"0"},{"id":"4","name_en":"Mayoralty of the city of Vatra","name_ro":"","name_ru":"","boost_id":"5248","":"0"},{"id":"5","name_en":"Mayoralty of the city of Durlesti","name_ro":"","name_ru":"","boost_id":"5253","":"0"},{"id":"6","name_en":"Mayoralty of Gratiesti","name_ro":"","name_ru":"","boost_id":"5264","":"0"},{"id":"7","name_en":"Mayoralty of the city of Cricova","name_ro":"","name_ru":"","boost_id":"5275","":"0"},{"id":"8","name_en":"Mayoralty of the city of Singera","name_ro":"","name_ru":"","boost_id":"5284","":"0"},{"id":"9","name_en":"Mayoralty of Tohatin","name_ro":"","name_ru":"","boost_id":"5298","":"0"},{"id":"10","name_en":"Mayoralty of Bubuieci","name_ro":"","name_ru":"","boost_id":"5305","":"0"},{"id":"11","name_en":"Mayoralty of Ciorescu","name_ro":"","name_ru":"","boost_id":"5312","":"0"},{"id":"12","name_en":"Mayoralty of the city of Codru","name_ro":"","name_ru":"","boost_id":"5322","":"0"},{"id":"13","name_en":"Mayoralty of Ghidighici","name_ro":"","name_ru":"","boost_id":"5328","":"0"},{"id":"14","name_en":"Mayoralty of Cruzesti","name_ro":"","name_ru":"","boost_id":"5335","":"0"},{"id":"15","name_en":"Mayoralty of Colonita","name_ro":"","name_ru":"","boost_id":"5342","":"0"},{"id":"16","name_en":"Mayoralty of Truseni","name_ro":"","name_ru":"","boost_id":"5348","":"0"},{"id":"17","name_en":"Mayoralty of Budesti","name_ro":"","name_ru":"","boost_id":"5358","":"0"},{"id":"18","name_en":"Mayoralty of Stauceni","name_ro":"","name_ru":"","boost_id":"5365","":"0"},{"id":"19","name_en":"Mayoralty of Bacioi","name_ro":"","name_ru":"","boost_id":"5377","":"0"},{"id":"20","name_en":"Mayoralty of Elizaveta","name_ro":"","name_ru":"","boost_id":"0030","":"0"}],"num_rows":"935"}

Articles list

URL: /articleslist/

Returns:

JSON array with two elements:
  • articles - array with all the articles found
  • num_rows - total number of the rows found with the given conditions
Each record in the groups array contains:
  • article_id
  • article_name_en
  • article_name_ro
  • article_name_ru

Examples:

Request: http://buget.md/ws/articleslist/
Response:
{"articles":[{"id":"1","name_en":"Remuneration of work","name_ro":"","name_ru":""},{"id":"2","name_en":"Mandatory state social insurance premiums","name_ro":"","name_ru":""},{"id":"3","name_en":"Payment for goods and services","name_ro":"","name_ru":""},{"id":"4","name_en":"Duty travels","name_ro":"","name_ru":""},{"id":"5","name_en":"Employer's share of the mandatory health insurance premiums","name_ro":"","name_ru":""},{"id":"6","name_en":"Transfers for goods and services","name_ro":"","name_ru":""},{"id":"7","name_en":"Transfers to population","name_ro":"","name_ru":""},{"id":"8","name_en":"Capital investments","name_ro":"","name_ru":""},{"id":"9","name_en":"Purchase of fixed assets","name_ro":"","name_ru":""},{"id":"10","name_en":"Capital repair works","name_ro":"","name_ru":""},{"id":"11","name_en":"Transfers for production purposes","name_ro":"","name_ru":""},{"id":"12","name_en":"Transfers abroad","name_ro":"","name_ru":""},{"id":"13","name_en":"Capital transfers within country","name_ro":"","name_ru":""},{"id":"14","name_en":"Transfers to financial facilities and other organizations","name_ro":"","name_ru":""},{"id":"15","name_en":"Other current expenditure","name_ro":"","name_ru":""},{"id":"16","name_en":"Other capital spending","name_ro":"","name_ru":""},{"id":"17","name_en":"Purchase of land","name_ro":"","name_ru":""},{"id":"18","name_en":"Net lending","name_ro":"","name_ru":""},{"id":"19","name_en":"Payment of interest on internal loans","name_ro":"","name_ru":""},{"id":"20","name_en":"Payment of interest on external loans","name_ro":"","name_ru":""},{"id":"21","name_en":"Capital transfers to implement the externally-funded projects","name_ro":"","name_ru":""},{"id":"22","name_en":"Establishment of state exchequer (treasury)","name_ro":"","name_ru":""},{"id":"23","name_en":"Payment on the commitments owed to international finance facilities","name_ro":"","name_ru":""},{"id":"24","name_en":"Purchase of shares","name_ro":"","name_ru":""},{"id":"25","name_en":"Payment of interest by another-tier public administration authorities","name_ro":"","name_ru":""},{"id":"26","name_en":"Current transfers to implement the externally-funded projects","name_ro":"","name_ru":""}],"num_rows":"26"}

Insitutions list

URL: /institutions/[parameters]

Parameters (all of them are optional)

  • page_number - number of institutions per page (see below) to return
  • page - page to start with, e.g.page=1&page_number=10 will return records from 0 to 10, page=1&page_number=10 return records 10...20
  • sort_by - field to sort the records through (field names can be found in the result set returned by the web service)
  • sort_method - ASC for ascending sort order and DESC for descending

Returns:

JSON array with two elements:
  • institutions - array with all the insitutions found
  • num_rows - total number of the rows found with the given conditions

Each record in the insitutions array contains:
  • institution_id
  • institution_name_en
  • institution_name_ro
  • instituion_name_ru
  • authority_id
  • authority_name_en
  • region_id
  • region_name_en
  • institution_type_id
  • institution_type_name_en

Examples:

Request: http://www.buget.md/ws/institutionslist?page=1&page_number=10
Response:
{"institutions":[{"id":"1","name_en":"-","name_ro":"","name_ru":""},{"id":"2","name_en":"Parliament","name_ro":"","name_ru":""},{"id":"3","name_en":"Parliament","name_ro":"","name_ru":""},{"id":"4","name_en":"Directorate service of the Moldovan Parliament buildings","name_ro":"","name_ru":""},{"id":"5","name_en":"Auto basis of the Moldovan Parliament","name_ro":"","name_ru":""},{"id":"6","name_en":"Republic of Moldova's Presidency Office (apparatus)","name_ro":"","name_ru":""},{"id":"7","name_en":"Court of Moldova","name_ro":"","name_ru":""},{"id":"8","name_en":"State Chancellery","name_ro":"","name_ru":""},{"id":"9","name_en":"State Chancellery","name_ro":"","name_ru":""},{"id":"10","name_en":"State Chancellery","name_ro":"","name_ru":""}],"num_rows":"31336"}

Institution details

Examples:

Request: http://www.buget.md/ws/institutionsdetails/164
Response: {"institutions":{"id":"164","name_en":"State Inspectorate for Plant Protection","name_ro":"","name_ru":"","authority_id":"12","authority_name_en":"Ministry of Agriculture and Food Industry","region_id":"935","region_name_en":"none region","type_id":"40","type_name_en":"Other agriculture related activities and facilities"}}