{
    "version" : "https://jsonfeed.org/version/1",
    "content" : "news",
    "type" : "single",
    "title" : "APIs in Government |Digital.gov",
    "description": "APIs in Government",
    "home_page_url" : "/preview/gsa/digitalgov.gov/bc-archive-content-3/","feed_url" : "/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/04/30/apis-in-government/index.json","item" : [
    {"title" :"APIs in Government","summary" : "This page is about what an Application Programming Interface or API is and what it does and how government agencies are using them to operate more efficiently.","date" : "2013-04-30T02:12:53-04:00","date_modified" : "2025-01-27T19:42:55-05:00","authors" : {"gray-brooks" : "Gray Brooks"},"topics" : {
        
            "application-programming-interface" : "Application programming interface",
            "open-data" : "Open data",
            "software-engineering" : "Software engineering"
            },"branch" : "bc-archive-content-3",
      "filename" :"2013-04-30-apis-in-government.md",
      
      "filepath" :"news/2013/04/2013-04-30-apis-in-government.md",
      "filepathURL" :"https://github.com/GSA/digitalgov.gov/blob/bc-archive-content-3/content/news/2013/04/2013-04-30-apis-in-government.md",
      "editpathURL" :"https://github.com/GSA/digitalgov.gov/edit/bc-archive-content-3/content/news/2013/04/2013-04-30-apis-in-government.md","slug" : "apis-in-government","url" : "/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/04/30/apis-in-government/","content" :"\u003ch2 id=\"what-are-apis-hahahugoshortcode1682s0hbhb\"\u003eWhat Are APIs? \u003cdiv class=\"image\"\u003e\n  \u003cimg\n    src=\"https://s3.amazonaws.com/digitalgov/_legacy-img/2014/08/250-x-86-API-letter-blocks-23575697-Hemera-Technologies-PhotoObjects.net-Thinkstock-87667306.jpg\"\n    alt=\"Children\u0026#39;s building blocks letters spelling A P I.\"/\u003e\u003c/div\u003e\n\n\u003c/h2\u003e\n\u003cp\u003eAn Application Programming Interface, or API, is a set of software instructions and standards that allows machine to machine communication—like when a website uses a widget to share a link on Twitter or Facebook.\u003c/p\u003e\n\u003cp\u003e[youtube http://www.youtube.com/watch?v=BVeiRCEwJx8]\u003c/p\u003e\n\u003cp\u003e\u003ca href=\"http://www.youtube.com/watch?v=nyqHClC_UXo\"\u003e\u003cem\u003e[Extended Version]\u003c/em\u003e\u003c/a\u003e\u003c/p\u003e\n\u003cp\u003eWhen we talk about APIs we are referring to Web services or Web APIs. This aligns with the current trends to use Web APIs to support sharing content and data between communities and applications. The content that is created in one place can be dynamically posted and updated in multiple locations on the Web, mobile, TV, etc.\u003c/p\u003e\n\u003cp\u003eAPIs can take many forms—the most functional enable a third party to query a data set at a granular level. The publishing of these types of APIs allows developers in agencies and from outside government to build apps, widgets, websites, and other tools based on government information and services—letting your audience get what they need from many places, not just your .gov website.\u003c/p\u003e\n\u003cp\u003eAPIs are not experimental. More than half of all the traffic for major companies like Twitter and eBay come through APIs. When the \u003ca href=\"http://blogs.census.gov/2012/07/25/pardon-our-dust-census-gov-transformation/\"\u003eCensus Bureau introduced their APIs\u003c/a\u003e, they saw a rise in access to their data.\u003c/p\u003e\n\u003cp\u003eJust a few of the many examples in government:\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003eThe Federal Aviation Administration provides travel websites and mobile apps with live airport status and delay information through its \u003ca href=\"http://services.faa.gov/docs/services/airport/\"\u003eAirport Service API\u003c/a\u003e.\u003c/li\u003e\n\u003cli\u003eThe \u003ca href=\"http://pillbox.nlm.nih.gov/API-documentation.html\"\u003ePillbox API\u003c/a\u003e from the National Library of Medicine powers third party mashups that serve consumers who need to quickly identify an unknown pill.\u003c/li\u003e\n\u003cli\u003eThe \u003ca href=\"https://scout.sunlightfoundation.com/\"\u003eSunlight Foundation’s ‘Scout’ project\u003c/a\u003e consumes the \u003ca href=\"https://www.federalregister.gov/blog/learn/developers\"\u003eFederal Register API\u003c/a\u003e to provide alerts and notifications for formal government action.\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eAPIs help extend agency information to other users. For example, the National Weather Service \u003ca href=\"http://graphical.weather.gov/xml/\"\u003epublishes an API\u003c/a\u003e that makes weather data available to developers within and outside of the organization. The API offers real-time access to data so that an app can automatically access the latest information instead of requiring a developer to return to the agency’s website and manually copy each update. This supports an enormous and innovative range of products that present up-to-date weather information to the public.\u003c/p\u003e\n\u003ch3 id=\"apis-and-data\"\u003eAPIs and Data\u003c/h3\u003e\n\u003cp\u003eAPIs can support \u003ca href=\"http://project-open-data.github.io/\"\u003eOpen Data initiatives\u003c/a\u003e. Well-designed APIs can make it easier for developers to use government data. APIs are an increasingly important means of publishing content. However, with any dataset which you may make available via API, it’s important to first allow access to the entire set via bulk download. APIs should be seen as a complement to bulk access.\u003c/p\u003e\n\u003ch2 id=\"benefits-of-apis\"\u003eBenefits of APIs\u003c/h2\u003e\n\u003cp\u003eProviding information and services through Web APIs supports interoperability and openness. Well-designed APIs make data freely available for use within agencies, between agencies, in the private sector, or by citizens.\u003c/p\u003e\n\u003cp\u003eAPIs:\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e\u003cstrong\u003eIncrease the reach of your services\u003c/strong\u003e by allowing other agencies, partners, and the private sector to integrate—and amplify—your agency’s data and content.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eSave time\u003c/strong\u003e through automation. You can update data or content once, and your API can refresh in multiple locations automatically on a website, mobile platforms, and on social media venues.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eSave costs\u003c/strong\u003e by allowing third-party innovators to use information and services to create new, useful products that are beyond the scope—or budget—of your agency.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eSpeed product development\u003c/strong\u003e through improved prototyping and ease of access for internal teams and sister agencies by allowing granular and open access to content.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eBuild markets\u003c/strong\u003e by improving access to government resources like health, economic, energy, education, environmental resources for entrepreneurs to build upon.\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eLearn more about the \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/benefits-of-apis/\" title=\"Benefits of APIs\"\u003ebenefits of APIs\u003c/a\u003e.\u003c/p\u003e\n\u003ch2 id=\"api-basics\"\u003eAPI Basics\u003c/h2\u003e\n\u003ch3 id=\"technical-basics\"\u003eTechnical Basics\u003c/h3\u003e\n\u003cp\u003eAn API is usually a standardized service based on a common protocol (rules for how the service works) and formats (schema for using the service) that are familiar to developers. APIs are, at their most basic, a combination of protocol (the means of interacting with data and services) and format (the model by which the data and services are arranged in order to allow such interaction).\u003c/p\u003e\n\u003cp\u003eAPI protocols are typically either SOAP (\u003ca href=\"http://en.wikipedia.org/wiki/SOAP\"\u003eSimple Object Access Protocol\u003c/a\u003e) or REST (\u003ca href=\"http://en.wikipedia.org/wiki/Representational_state_transfer\"\u003eRepresentational State Transfer\u003c/a\u003e). REST is preferred by many because it’s based on the familiar http Web protocol.\u003c/p\u003e\n\u003cp\u003eAPI formats are usually either XML (\u003ca href=\"http://en.wikipedia.org/wiki/XML\"\u003eExtensible Markup Language\u003c/a\u003e) or JSON (\u003ca href=\"http://en.wikipedia.org/wiki/JSON\"\u003eJavaScript Object Notation\u003c/a\u003e). JSON is increasingly popular with developers due to its speed, ease of use, and wide acceptance.\u003c/p\u003e\n\u003cp\u003eNew APIs are routinely described as RESTful JSON because they follow the REST architectural style and use JSON as its data representation format.\u003c/p\u003e\n\u003cp\u003eLearn more about \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/api-basics/\" title=\"API Basics\"\u003eAPI technical choices\u003c/a\u003e.\u003c/p\u003e\n\u003ch3 id=\"api-types\"\u003eAPI Types\u003c/h3\u003e\n\u003cp\u003eWhen considering APIs there are three types of uses.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e\u003cstrong\u003ePublic\u003c/strong\u003e. An agency makes information and services available to almost anyone to use for building their own applications. These APIs are built on top of public information and services. Applications can be used commercially. Developers can, for example, create a \u003ca href=\"http://en.wikipedia.org/wiki/Mashup_(web_application_hybrid)\"\u003emashup\u003c/a\u003e that uses government data—\u003ca href=\"http://explore.data.gov/Information-and-Communications/Census-API-By-Coordinates/6e4m-3gzc\"\u003elike Census block data\u003c/a\u003e—as a supporting part of an application.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003ePrivate.\u003c/strong\u003e Organizations use APIs across offices and divisions to share data to improve access and efficiency. These APIs are built on internal information and services. \u003ca href=\"http://apievangelist.com/2012/01/12/the-secret-to-amazons-success-internal-apis/\"\u003eAmazon famously required\u003c/a\u003e all data and functionality to be available ONLY through APIs. This created modular services that could be reused easily and prepared Amazon for innovation, such as easily deploying apps to smartphones.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eHybrid\u003c/strong\u003e. Some APIs are available both externally and internally. Your organization can limit access to some information to the public and make more available for internal use or to use with specific partners.\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eIt is important to understand these uses and to apply appropriate security, legal, and technical rules, depending on the use.\u003c/p\u003e\n\u003ch3 id=\"api-functions\"\u003eAPI Functions\u003c/h3\u003e\n\u003cp\u003eAPIs are mostly either read-only or read-write. A general way to differentiate the two is whether the underlying material is information that is meant to be broadcast (read-only) or a service that is meant to allow a consumer to interact with the government and supply information, such as submitting an online form (read-write). Security considerations will differ just as they do with Web pages (static vs. a system interface). Your IT security team is an important partner in design and deployment.\u003c/p\u003e\n\u003ch2 id=\"how-to-start-an-api-program\"\u003eHow to Start an API Program\u003c/h2\u003e\n\u003cp\u003eAPIs need to provide value to your agency and to developers. The best way to make that happen is to tie an API program to your agency mission.\u003c/p\u003e\n\u003col\u003e\n\u003cli\u003e\u003cstrong\u003eAudit\u003c/strong\u003e: Investigate what API efforts may already be active at your agency. Assemble a list of the information that your team or agency produces and the services you provide. Decide what material you would like to offer via API. Read more**** on \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/how-to-get-started-with-apis/#audit\"\u003eauditing APIs\u003c/a\u003e.****\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eAssemble Components\u003c/strong\u003e: Coordinate the creation of the API itself. Assemble the related documentation, components, and rollout plan. Test the API and coordinate with stakeholders. Read more**** on**** \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/how-to-get-started-with-apis/#assemble-components\"\u003eassembling the components\u003c/a\u003e.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eImplement\u003c/strong\u003e: Release the API to the intended audience, announce through marketing and community channels, and engage interested users. Read more**** on \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/how-to-get-started-with-apis/#implement\"\u003eimplementing the API\u003c/a\u003e.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eTrack Progress\u003c/strong\u003e: Monitor usage statistics, make improvements, and continue to engage with developers using the API. Read more \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/how-to-get-started-with-apis/\" title=\"How to Get Started with APIs\"\u003etracking the progress\u003c/a\u003e.\u003c/li\u003e\n\u003cli\u003e\u003cstrong\u003eRepeat\u003c/strong\u003e: Re-evaluate lessons learned with your agency’s Web presence and consider what material next makes sense as an API. Repeat the above steps. Read more about \u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/how-to-get-started-with-apis/\" title=\"How to Get Started with APIs\"\u003erepeating the process\u003c/a\u003e.\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch2 id=\"resources-and-tools-for-building-apis\"\u003eResources and Tools for Building APIs\u003c/h2\u003e\n\u003cul\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#hosted-api-tools\"\u003eHosted API Tools\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#api-standards-template\"\u003eAPI Standards Template\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#examples-apis-government\"\u003eExamples of APIs in Government\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#api-education-series\"\u003eAPI Education Series\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#case-studies\"\u003eCase Studies\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#how-to-make-apis-overview\"\u003eHow to Make APIs—An Overview\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/04/30/producing-apis-through-data-gov/\"\u003eProducing APIs through Data.gov\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/05/16/api-release-kit/\"\u003eAPI Release Kit\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/05/21/developer-kit/\"\u003e/Developer Kit\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#government-api-listserv\"\u003eU.S. Government APIs Listserv\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003e\u003ca href=\"/preview/gsa/digitalgov.gov/bc-archive-content-3/2013/03/12/resources-and-tools-for-apis/#recommended-reading\"\u003eRecommended Reading\u003c/a\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003ch2 id=\"common-questions-about-apis\"\u003eCommon Questions About APIs\u003c/h2\u003e\n\u003cul\u003e\n\u003cli\u003e\u003cstrong\u003eWhat is the difference between RSS and an API?\u003c/strong\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eRSS is typically a subscription model that usually stores at any one time only the most recent entries. By contrast, an API exists to expose the entire content store, regardless of whether it was recently published.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e\u003cstrong\u003eHow do APIs fit in with a mobile strategy?\u003c/strong\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eAPIs enable the content and services that they serve to be readily consumed by mobile apps as well as mobile interfaces. Either the agency or third parties are still needed to create one or more of these so that consumers of the information have an interface with which to interact. The task of creating the mobile app or mobile interface is quicker and easier with APIs, almost to the point of there being a pre-requisite. So, if you want to include certain material in the mobile Web presence of your agency, publishing an API of that material is a good first step.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e\u003cstrong\u003eWill I lose control of my content?\u003c/strong\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eNo more than you already do. In regards to public material, third parties that wish to scrape the content already do so, and the creation of APIs does not change that. Through the use of API keys and analytics you can actually maintain more control in many instances, by having a foundation to understand who is using your content, and how they are using it. Through an API terms of service, you then also have recourse to address any third-party use that violates your usage policy.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e\u003cstrong\u003eWhat about branding?\u003c/strong\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eBranding is much more than the URL of the content. Many agencies are finding that their brand \u003cem\u003eincreases\u003c/em\u003e, through savvy use of APIs and by allowing third parties to benefit from dynamic access to their content. Any concerns in regards to agency brand are addressed technologically and through the terms of service.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e**How does this relate to cloud computing? **\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eThe growth of cloud computing and APIs in government complement each other—both support more agile development and a more responsive and less expensive infrastructure. However, they can also be viewed independently of each other. The philosophy and technique of APIs function equally well, regardless of whether the host server is housed locally or “in the cloud”.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003e**What are the technical considerations for success of APIs? **\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eThe goal of an API is to provide reliable access to a specific service, to provide certain information or services. The technical considerations are similar to those of a website: uptime, timeliness, and a clear user experience (in this case, for developers).\u003c/p\u003e\n"}
  ]
}
