Conference on National Platforms for SDG Reporting Building the solution for NRPs : innovative approaches and technologies Dissemination through web services / APIs Conference on National Platforms for SDG Reporting 22-24 January 2018, New York
Data interoperability Data interoperability is about allowing multiple actors in a data ecosystem to more easily share and integrate data from different sources It is about the use of generic, flexible technologies
What is an API? Application Programming Interface “A reusable interface that different applications can use to easily connect to an information system”
APIs as part of data dissemination strategy Objective: Promote the use of data and statistics to implement and follow up the 2030 Agenda by enabling third-parties to create innovative applications that respond to information needs of policy and decision makers at all levels Strategy: Make interoperable data available on the web through well documented and easy to integrate APIs, following open standards and best practices
Design APIs with needs of developers in mind Easy to learn and easy to use Well documented, using an API description language (e.g., swagger) Self-explanatory Explorable and discoverable Clean front end Graceful error handling Secure, reliable and meeting performance requirements Based on IT and statistical standards
Some good practices when designing APIs Research how key user groups would want to use the API Which problems do they need to tackle? Which apps do they want to build? What data objects / resources would they want to use in their apps? Design a prototype of the API using an API description language Build a test application that solves a real problem, and refine the API capabilities Useful to have a pilot group of API consumers that can provide feedback during API design process
Some good practices after publishing APIs Help potential users find the API Monitor and analyze usage Collect feedback from users Discover patterns of use Monitor up time (reliability) and response time (performance)
UNSD portfolio of APIs Global SDG Indicators API https://unstats.un.org/SDGAPI/swagger/ UN Comtrade API https://comtrade.un.org/data/dev/portal/ UN Data portal API http://data.un.org/Host.aspx?Content=API SDMX Web Service http://data.un.org/WS/ Monthly Bulletin of Statistics Web Services https://unstats.un.org/unsd/mbs/api/wsMbsServices.asmx
https://unstats.un.org/SDGAPI/swagger/
Limitations of APIs: The case for linked data Most Web APIs use identifiers with local scope and don’t provide links to third-party information resources. Different APIs usually implement specialized data models and access interfaces Programmers first need to understand the methods available and write custom code to retrieve data from each individual API Need to invest significant efforts to integrate multiple datasets into a single user application (mashup) Clients need to be tightly coupled to the structure of the data at the source