<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://en.bitcoin.it/w/index.php?action=history&amp;feed=atom&amp;title=BIP_0171</id>
	<title>BIP 0171 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://en.bitcoin.it/w/index.php?action=history&amp;feed=atom&amp;title=BIP_0171"/>
	<link rel="alternate" type="text/html" href="https://en.bitcoin.it/w/index.php?title=BIP_0171&amp;action=history"/>
	<updated>2026-05-13T23:53:09Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://en.bitcoin.it/w/index.php?title=BIP_0171&amp;diff=68154&amp;oldid=prev</id>
		<title>934: Update BIP text with latest version from https://github.com/bitcoin/bips/blob/9d44e594b0baa509/bip-0171.mediawiki</title>
		<link rel="alternate" type="text/html" href="https://en.bitcoin.it/w/index.php?title=BIP_0171&amp;diff=68154&amp;oldid=prev"/>
		<updated>2020-08-21T16:52:40Z</updated>

		<summary type="html">&lt;p&gt;Update BIP text with latest version from https://github.com/bitcoin/bips/blob/9d44e594b0baa509/bip-0171.mediawiki&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 16:52, 21 August 2020&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l9&quot;&gt;Line 9:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 9:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Comments-Summary: No comments yet.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Comments-Summary: No comments yet.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Comments-URI: https://github.com/bitcoin/bips/wiki/Comments:BIP-0171&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Comments-URI: https://github.com/bitcoin/bips/wiki/Comments:BIP-0171&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Status: &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Draft&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Status: &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Rejected&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Type: Standards Track&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Type: Standards Track&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Created: 2017-03-04&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   Created: 2017-03-04&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>934</name></author>
	</entry>
	<entry>
		<id>https://en.bitcoin.it/w/index.php?title=BIP_0171&amp;diff=66764&amp;oldid=prev</id>
		<title>934: Update BIP text with latest version from https://github.com/bitcoin/bips/blob/b5723035e23896d0/bip-0171.mediawiki</title>
		<link rel="alternate" type="text/html" href="https://en.bitcoin.it/w/index.php?title=BIP_0171&amp;diff=66764&amp;oldid=prev"/>
		<updated>2019-09-24T17:58:35Z</updated>

		<summary type="html">&lt;p&gt;Update BIP text with latest version from https://github.com/bitcoin/bips/blob/b5723035e23896d0/bip-0171.mediawiki&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{bip}}&lt;br /&gt;
{{BipMoved|bip-0171.mediawiki}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  BIP: 171&lt;br /&gt;
  Layer: Applications&lt;br /&gt;
  Title: Currency/exchange rate information API&lt;br /&gt;
  Author: Luke Dashjr &amp;lt;luke+bip@dashjr.org&amp;gt;&lt;br /&gt;
  Comments-Summary: No comments yet.&lt;br /&gt;
  Comments-URI: https://github.com/bitcoin/bips/wiki/Comments:BIP-0171&lt;br /&gt;
  Status: Draft&lt;br /&gt;
  Type: Standards Track&lt;br /&gt;
  Created: 2017-03-04&lt;br /&gt;
  License: BSD-2-Clause&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Abstract==&lt;br /&gt;
&lt;br /&gt;
A common interface for requesting currency exchange rate information from a server.&lt;br /&gt;
&lt;br /&gt;
==Copyright==&lt;br /&gt;
&lt;br /&gt;
This BIP is licensed under the BSD 2-clause license.&lt;br /&gt;
&lt;br /&gt;
==Specification==&lt;br /&gt;
&lt;br /&gt;
Four requests are defined, which are all made by a GET request to a common URI with parameters encoded in application/x-www-form-urlencoded format.&lt;br /&gt;
All matching parameters may be specified with multiple comma-separated values, which are to be interpreted as &amp;quot;any of these&amp;quot;.&lt;br /&gt;
Each result is always in JSON format, with a line-feed (never a carriage-return) separating multiple results.&lt;br /&gt;
&lt;br /&gt;
Authentication for subscription-based services MAY be supported using standard HTTP authentication.&lt;br /&gt;
It is recommended to use TLS (HTTPS) and/or Linked Data Signatures, so that MITM attackers cannot deceive the client.&lt;br /&gt;
&lt;br /&gt;
To be BIP 171 compatible, servers MUST support at least one currency-pair compared to XBT.&lt;br /&gt;
All inquiries for bitcoin amounts MUST be specified in XBT, even if the presentation to the end user is in another unit.&lt;br /&gt;
(FIXME: or should this be satoshis?)&lt;br /&gt;
&lt;br /&gt;
Currency-pair tokens are arbitrary Strings no longer than 255 characters, which may include any ASCII [https://tools.ietf.org/html/rfc3986#section-2.3 RFC 3986 unreserved characters] (ie, alphanumerics and the hyphen, underscore, period, and tilde symbols).&lt;br /&gt;
&lt;br /&gt;
Currency code(s) used herein are defined as such:&lt;br /&gt;
&lt;br /&gt;
* All ISO 4217 codes are valid currency codes.&lt;br /&gt;
* XBT is defined as 100000000 satoshis (commonly known as 1 BTC).&lt;br /&gt;
* Strings longer than 3 characters may be used for currencies without an applicable code. (If a shorter code is desired despite this, it may be padded with space(s) to the left until it is 4 characters. Software MAY strip these spaces.)&lt;br /&gt;
&lt;br /&gt;
Rate is defined as the amount of quote-currency to be exchanged for one unit of the base-currency.&lt;br /&gt;
In other words, &amp;lt;code&amp;gt;1 baseCurrency = rate quoteCurrency&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
===Enumerating supported currency-pair tokens===&lt;br /&gt;
&lt;br /&gt;
Parameters:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;mode&amp;#039;&amp;#039; - Always &amp;quot;list&amp;quot; for this request.&lt;br /&gt;
* &amp;#039;&amp;#039;quote&amp;#039;&amp;#039; - If provided, the server MAY limit the results to only currency-pairs describing a currency with the given currency code(s).&lt;br /&gt;
* &amp;#039;&amp;#039;base&amp;#039;&amp;#039; - If provided, the server MAY limit the results to only currency-pairs describing currency rates compared to the given currency code(s).&lt;br /&gt;
* &amp;#039;&amp;#039;locale&amp;#039;&amp;#039; - If provided, the server MAY limit the results to only currency-pairs supporting the given Unicode CLDR locale(s).&lt;br /&gt;
&lt;br /&gt;
Each currency-pair will receive a separate result, a JSON Object, with the following information:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;cp&amp;#039;&amp;#039; - The currency-pair token.&lt;br /&gt;
* &amp;#039;&amp;#039;quote&amp;#039;&amp;#039; - The currency code for the quote currency.&lt;br /&gt;
* &amp;#039;&amp;#039;base&amp;#039;&amp;#039; - The currency code for the base currency.&lt;br /&gt;
* &amp;#039;&amp;#039;locale&amp;#039;&amp;#039; - If provided, a String with the applicable Unicode CLDR locale.&lt;br /&gt;
* &amp;#039;&amp;#039;desc&amp;#039;&amp;#039; - Optional description. For example, it could be &amp;quot;Based on Florida BTM prices.&amp;quot; or any other short String that provides information useful to the user. SHOULD be shorter than 45 characters.&lt;br /&gt;
* &amp;#039;&amp;#039;signature&amp;#039;&amp;#039; - Optional. May be used for Linked Data Signatures.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
    Request: http://api.example.tld/?mode=list&amp;amp;quote=USD&amp;amp;base=XBT&amp;amp;locale=en_US,en_GB&lt;br /&gt;
    Result:&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;quote&amp;quot;:&amp;quot;USD&amp;quot;, &amp;quot;base&amp;quot;: &amp;quot;XBT&amp;quot;, &amp;quot;locale&amp;quot;: &amp;quot;en_US&amp;quot;, &amp;quot;desc&amp;quot;: &amp;quot;Smoothed averages&amp;quot;}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;quote&amp;quot;:&amp;quot;USD&amp;quot;, &amp;quot;base&amp;quot;: &amp;quot;XBT&amp;quot;, &amp;quot;locale&amp;quot;: &amp;quot;en_US&amp;quot;, &amp;quot;desc&amp;quot;: &amp;quot;Updated per-trade&amp;quot;}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-european&amp;quot;, &amp;quot;quote&amp;quot;:&amp;quot;USD&amp;quot;, &amp;quot;base&amp;quot;: &amp;quot;XBT&amp;quot;, &amp;quot;locale&amp;quot;: &amp;quot;en_GB&amp;quot;}&lt;br /&gt;
&lt;br /&gt;
===Currency-pair information===&lt;br /&gt;
&lt;br /&gt;
Parameters:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;mode&amp;#039;&amp;#039; - Always &amp;quot;info&amp;quot; for this request.&lt;br /&gt;
* &amp;#039;&amp;#039;cp&amp;#039;&amp;#039; - Currency pair(s) for which information is requested.&lt;br /&gt;
&lt;br /&gt;
Each currency-pair will receive a separate result, a JSON Object, with the following information:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;cp&amp;#039;&amp;#039; - The currency-pair token.&lt;br /&gt;
* &amp;#039;&amp;#039;quote&amp;#039;&amp;#039; - The currency code for the quote currency.&lt;br /&gt;
* &amp;#039;&amp;#039;base&amp;#039;&amp;#039; - The currency code for the base currency.&lt;br /&gt;
* &amp;#039;&amp;#039;locale&amp;#039;&amp;#039; - If provided, a String with the applicable Unicode CLDR locale.&lt;br /&gt;
* &amp;#039;&amp;#039;desc&amp;#039;&amp;#039; - Optional description. For example, it could be &amp;quot;Based on Florida BTM prices.&amp;quot; or any other short String that provides information useful to the user. SHOULD be shorter than 45 characters.&lt;br /&gt;
* &amp;#039;&amp;#039;longdesc&amp;#039;&amp;#039; - Optional description, but may be longer and include newlines.&lt;br /&gt;
* &amp;#039;&amp;#039;symbol&amp;#039;&amp;#039; - An Array of prefix and suffix for the quote currency. Each may be either a fixed String, an Array of two Strings (negative and positive), or null. Any positive or negative symbols must be included in this prefix/suffix; it MUST NOT be implied otherwise.&lt;br /&gt;
* &amp;#039;&amp;#039;digits&amp;#039;&amp;#039; - The type of digits to use for the quote currency&amp;#039;s numbers. &amp;quot;arabic&amp;quot; should be used for common 0-9 digits.&lt;br /&gt;
* &amp;#039;&amp;#039;grouping&amp;#039;&amp;#039; - An Array alternating between Numbers representing a series of digits, and Strings used as delimiters. If terminated by a zero, the final grouping is to be repeated continually. For example, the common US locale thousands grouping would be &amp;lt;code&amp;gt;[3, &amp;quot;,&amp;quot;, 0]&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;#039;&amp;#039;fraction_sep&amp;#039;&amp;#039; - A String to be placed between whole numbers and a fractional amount.&lt;br /&gt;
* &amp;#039;&amp;#039;fraction_digits&amp;#039;&amp;#039; - Array of absolute minimum (even for whole numbers) number of fractional digits, minimum fractional digits when a fraction exists, and maximum number of fractional digits when absolute precision is not demanded (below which is to be rounded in an implementation-dependent manner).&lt;br /&gt;
* &amp;#039;&amp;#039;minpoll&amp;#039;&amp;#039; - A Number of seconds indicating a minimum time between polls to the server. Clients should be prudent about not polling too often, even if this number is low.&lt;br /&gt;
* &amp;#039;&amp;#039;longpoll&amp;#039;&amp;#039; - If provided and true, indicates longpolling is supported by the server.&lt;br /&gt;
* &amp;#039;&amp;#039;history&amp;#039;&amp;#039; - If provided, indicates the server has historical records going back no earlier than the POSIX timestamp provided as a value.&lt;br /&gt;
* &amp;#039;&amp;#039;archive&amp;#039;&amp;#039; - If provided, indicates the server no longer has current rates, and has no historical rates more recent than the POSIX timestamp provided as a value.&lt;br /&gt;
* &amp;#039;&amp;#039;signature&amp;#039;&amp;#039; - Optional. May be used for Linked Data Signatures.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
    Request: http://api.example.tld/?mode=info&amp;amp;cp=XBTUSD-ver4,2&lt;br /&gt;
    Result:&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;quote&amp;quot;:&amp;quot;USD&amp;quot;, &amp;quot;base&amp;quot;: &amp;quot;XBT&amp;quot;, &amp;quot;locale&amp;quot;: &amp;quot;en_US&amp;quot;, &amp;quot;desc&amp;quot;: &amp;quot;Smoothed averages&amp;quot;, &amp;quot;longdesc&amp;quot;: &amp;quot;USD price quotes as compared to Bitcoin value\n\nRecommended for casual usage&amp;quot;, &amp;quot;symbol&amp;quot;: [[&amp;quot;-$&amp;quot;, &amp;quot;$&amp;quot;], null], &amp;quot;digits&amp;quot;: &amp;quot;arabic&amp;quot;, &amp;quot;grouping&amp;quot;: [3, &amp;quot;,&amp;quot;, 0], &amp;quot;fraction_sep&amp;quot;: &amp;quot;.&amp;quot;, &amp;quot;fraction_digits&amp;quot;: [0, 2, 2], &amp;quot;minpoll&amp;quot;: 300, &amp;quot;longpoll&amp;quot;: true, &amp;quot;history&amp;quot;: 1457231416}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;quote&amp;quot;:&amp;quot;USD&amp;quot;, &amp;quot;base&amp;quot;: &amp;quot;XBT&amp;quot;, &amp;quot;locale&amp;quot;: &amp;quot;en_US&amp;quot;, &amp;quot;desc&amp;quot;: &amp;quot;Updated per-trade&amp;quot;, &amp;quot;longdesc&amp;quot;: &amp;quot;Maximum precision USD price quotes as compared to Bitcoin value&amp;quot;, &amp;quot;symbol&amp;quot;: [[&amp;quot;-$&amp;quot;, &amp;quot;$&amp;quot;], null], &amp;quot;digits&amp;quot;: &amp;quot;arabic&amp;quot;, &amp;quot;grouping&amp;quot;: [3, &amp;quot;,&amp;quot;, 0], &amp;quot;fraction_sep&amp;quot;: &amp;quot;.&amp;quot;, &amp;quot;fraction_digits&amp;quot;: [0, 2, 2], &amp;quot;minpoll&amp;quot;: 3600, &amp;quot;longpoll&amp;quot;: false, &amp;quot;history&amp;quot;: 1467458333.1225}&lt;br /&gt;
&lt;br /&gt;
===Current exchange rate===&lt;br /&gt;
&lt;br /&gt;
Parameters:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;mode&amp;#039;&amp;#039; - Always &amp;quot;rate&amp;quot; for this request.&lt;br /&gt;
* &amp;#039;&amp;#039;cp&amp;#039;&amp;#039; - Currency pair(s) for which rate is requested.&lt;br /&gt;
* &amp;#039;&amp;#039;type&amp;#039;&amp;#039; - Type of exchange rate data being requested. May be &amp;quot;high&amp;quot;, &amp;quot;low&amp;quot;, &amp;quot;average&amp;quot;, &amp;quot;typical&amp;quot;, or any other arbitrary name. If omitted, the server may provide any rates it deems appropriate.&lt;br /&gt;
* &amp;#039;&amp;#039;minrate&amp;#039;&amp;#039;, &amp;#039;&amp;#039;maxrate&amp;#039;&amp;#039; - If specified, indicates this request is a longpoll. The server should not send a response until the rate(s) fall below or above (respectively) the provided value.&lt;br /&gt;
* &amp;#039;&amp;#039;nonce&amp;#039;&amp;#039; - If specified, the server SHOULD return it in each result.&lt;br /&gt;
&lt;br /&gt;
Each currency-pair receives a separate result (a JSON Object) with all requested rate types:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;cp&amp;#039;&amp;#039; - The currency-pair token.&lt;br /&gt;
* &amp;#039;&amp;#039;time&amp;#039;&amp;#039; - The time (as a POSIX timestamp) the rate information is applicable to (should be approximately the request time).&lt;br /&gt;
* &amp;#039;&amp;#039;rates&amp;#039;&amp;#039; - A JSON Object with each rate type provided as a key, and a Number as the value specifying the rate.&lt;br /&gt;
* &amp;#039;&amp;#039;nonce&amp;#039;&amp;#039; - Only if the request specified a nonce, the server SHOULD include it here as a JSON String.&lt;br /&gt;
* &amp;#039;&amp;#039;signature&amp;#039;&amp;#039; - Optional. May be used for Linked Data Signatures.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
    Request: http://api.example.tld/?mode=rate&amp;amp;cp=XBTUSD-ver4,2&amp;amp;type=typical,high&lt;br /&gt;
    Result:&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488767410.5463133, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1349.332215, &amp;quot;high&amp;quot;: 1351.2}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488767410, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1350.111332}}&lt;br /&gt;
&lt;br /&gt;
===Historical exchange rates===&lt;br /&gt;
&lt;br /&gt;
Parameters:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;mode&amp;#039;&amp;#039; - Always &amp;quot;history&amp;quot; for this request.&lt;br /&gt;
* &amp;#039;&amp;#039;cp&amp;#039;&amp;#039; - Currency pair(s) for which rate is requested.&lt;br /&gt;
* &amp;#039;&amp;#039;type&amp;#039;&amp;#039; - Type of exchange rate data being requested. May be &amp;quot;high&amp;quot;, &amp;quot;low&amp;quot;, &amp;quot;average&amp;quot;, &amp;quot;typical&amp;quot;, or any other arbitrary name. If omitted, the server may provide any rates it deems appropriate.&lt;br /&gt;
* &amp;#039;&amp;#039;from&amp;#039;&amp;#039; - POSIX timestamp the results should begin with.&lt;br /&gt;
* &amp;#039;&amp;#039;to&amp;#039;&amp;#039; - POSIX timestamp the results should end with. If omitted, the present time shall be used.&lt;br /&gt;
* &amp;#039;&amp;#039;nearest&amp;#039;&amp;#039; - If provided and true, indicates that only the nearest timestamp to &amp;quot;from&amp;quot; must be returned, and a range is not desired. (&amp;quot;to&amp;quot; should be omitted in this case.)&lt;br /&gt;
* &amp;#039;&amp;#039;ratedelta&amp;#039;&amp;#039;, &amp;#039;&amp;#039;timedelta&amp;#039;&amp;#039; - If specified, the server may omit data where the rate or time has not changed since the last provided rate and time. If both are provided, either a significant rate change OR time change should trigger a new record in the results.&lt;br /&gt;
&lt;br /&gt;
A result is provided for each currency-pair and timestamp record, in the same format as the current exchange rate request.&lt;br /&gt;
Records MUST be provided in chronological order, but only within the scope of the applicable currency-pair (ie, it is okay to send the full history for one currency-pair, and then the full history for the next; or to intermix them out of any given order).&lt;br /&gt;
&lt;br /&gt;
If there is no exact record for the times specified by &amp;quot;from&amp;quot; and/or &amp;quot;to&amp;quot;, a single record before &amp;quot;from&amp;quot; and/or after &amp;quot;to&amp;quot; should also be included.&lt;br /&gt;
This is not necessary when only the nearest record is requested, or when &amp;quot;to&amp;quot; is omitted (ie, ending at the most recent record).&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
    Request: http://api.example.tld/?mode=history&amp;amp;cp=XBTUSD-ver4,2&amp;amp;type=typical&amp;amp;ratedelta=0.1&amp;amp;timedelta=10&amp;amp;from=1488759998&amp;amp;to=1488760090&lt;br /&gt;
    Result:&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760000, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1300}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760010, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1301.1}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760020, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1320}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760030, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1305}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760000.1, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1300}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760010.2, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1301.1}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760020.2, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1320.111332}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760031, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1305.222311}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760040, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1303.33}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760042, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1303.33}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760050, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1305}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760052, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1307}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760060, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1309}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760072, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1308}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760062, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1309.55555555}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760072, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1308}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;XBTUSD-ver4&amp;quot;, &amp;quot;time&amp;quot;: 1488760082, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1309}}&lt;br /&gt;
      {&amp;quot;cp&amp;quot;:&amp;quot;2&amp;quot;, &amp;quot;time&amp;quot;: 1488760082, &amp;quot;rates&amp;quot;: {&amp;quot;typical&amp;quot;: 1309.1}}&lt;br /&gt;
&lt;br /&gt;
==Motivation==&lt;br /&gt;
&lt;br /&gt;
End users often desire to see fiat currency information in their Bitcoin wallet software.&lt;br /&gt;
Due to the nature of Bitcoin, there is inherently no authoritative source for exchange rates.&lt;br /&gt;
There are many independent providers of such information, but they all use different formats for providing it, so wallet software is currently forced to implement dedicated code for each provider.&lt;br /&gt;
&lt;br /&gt;
By providing a standard interface for retrieving this information, wallets (and other software) and service providers can implement it once, and become immediately interoperable with all other compatible implementations.&lt;br /&gt;
&lt;br /&gt;
==Rationale==&lt;br /&gt;
&lt;br /&gt;
Why are multiple results separated by a line-feed rather than using a JSON Array?&lt;br /&gt;
&lt;br /&gt;
* Clients ought to cache historical data, and using a line-feed format allows them to simply append to a cache file.&lt;br /&gt;
* Parsing JSON typically requires the entire data parsed together as a single memory object. Using simple lines to separate results, however, allows parsing a single result at a time.&lt;br /&gt;
&lt;br /&gt;
What if long descriptions require line and paragraph breaks?&lt;br /&gt;
&lt;br /&gt;
* Clients should word-wrap long lines, and JSON escapes newlines as &amp;quot;\n&amp;quot; which can be used doubly (&amp;quot;\n\n&amp;quot;) for paragraph breaks.&lt;br /&gt;
&lt;br /&gt;
==Backwards compatibility==&lt;br /&gt;
&lt;br /&gt;
While this new standard is adopted, software and providers can continue to use and provide their current formats until they are no longer needed.&lt;br /&gt;
&lt;br /&gt;
==Reference implementation==&lt;br /&gt;
&lt;br /&gt;
TODO&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
&lt;br /&gt;
* [https://w3c-dvcg.github.io/ld-signatures/ Draft W3c Linked Data Signatures specification]&lt;/div&gt;</summary>
		<author><name>934</name></author>
	</entry>
</feed>