Home › Topics › Payments › BIP 71

BIP 71: Payment Protocol MIME types

Also known as: BIP71, BIP-0071.

In plain English: Defines official internet media types (MIME types) for payment protocol messages. These labels let browsers and email programs recognize a Bitcoin payment request and pass it to the right wallet.

Status
Deployed
Type
Specification
Layer
Applications
Authors
Gavin Andresen
Assigned
Last changed
Topics
Payments, Contracts
Source
bip-0071.mediawiki on GitHub · Markdown

Full specification

Abstract

This BIP defines a MIME (RFC 2046) Media Type for Bitcoin payment request messages.

Motivation

Wallet or server software that sends payment protocol messages over email or http should follow Internet standards for properly encapsulating the messages.

Specification

The Media Type (Content-Type in HTML/email headers) for bitcoin protocol messages shall be:

MessageType/Subtype
PaymentRequestapplication/bitcoin-paymentrequest
Paymentapplication/bitcoin-payment
PaymentACKapplication/bitcoin-paymentack

Payment protocol messages are encoded in binary.

Example

A web server generating a PaymentRequest message to initiate the payment protocol would precede the binary message data with the following headers:

Content-Type: application/bitcoin-paymentrequest
Content-Transfer-Encoding: binary

Questions about BIP 71

What is BIP 71?

BIP 71, “Payment Protocol MIME types”, is a specification Bitcoin Improvement Proposal written by Gavin Andresen and assigned in July 2013. Defines official internet media types (MIME types) for payment protocol messages. These labels let browsers and email programs recognize a Bitcoin payment request and pass it to the right wallet.

Is BIP 71 active?

Yes. BIP 71 has the status Deployed, which means it is live: adopted by the Bitcoin network or by widely used software.

Who wrote BIP 71?

BIP 71 was written by Gavin Andresen. Its number was assigned on July 29, 2013.

Which BIPs build on BIP 71?

2 other BIPs reference BIP 71: BIP 70 (Payment Protocol) and BIP 123 (BIP Classification).

Where can I read the full BIP 71 specification?

The complete text of BIP 71 is on this page, taken unchanged from the official bitcoin/bips repository on GitHub. It is also available as Markdown and JSON.

BIPs that build on BIP 71

  • BIP 70: Payment Protocol: Deployed. Defines a payment protocol in which a merchant sends a signed payment request directly to the customer's wallet. It aimed to improve checkout and protect against attackers swapping addresses, though…
  • BIP 123: BIP Classification: Deployed. Sets out a way to classify BIPs into layers, such as consensus, peer services, APIs and applications, according to which part of the system they affect. This helps readers judge how widely a…

Related proposals

  • BIP 20: URI Scheme: Closed. An early proposal for "bitcoin:" links that bundle an address and amount, so clicking or scanning one opens a wallet ready to pay. It was superseded by BIP 21.
  • BIP 21: URI Scheme: Closed. Defines the "bitcoin:" link format that packages an address, amount, label and message into one string, often shown as a QR code. Wallets read these links to fill in payment details automatically,…
  • BIP 52: Durable, Low Energy Bitcoin PoW: Closed. Proposed replacing Bitcoin's mining puzzle with one designed for optical computing chips, so mining costs would depend more on hardware than on electricity. The aim was to cut energy use and spread…
  • BIP 70: Payment Protocol: Deployed. Defines a payment protocol in which a merchant sends a signed payment request directly to the customer's wallet. It aimed to improve checkout and protect against attackers swapping addresses, though…
  • BIP 72: bitcoin: uri extensions for Payment Protocol: Deployed. Extends "bitcoin:" links (BIP 21) with a parameter pointing to a payment request from the payment protocol (BIP 70). Wallets that support the protocol fetch the merchant's signed request, while…
  • BIP 73: Use "Accept" header for response type negotiation with Payment Request URLs: Deployed. Lets a payment request web link return either a webpage or a payment request file, depending on what the requesting software asks for. This allows short links that fit in QR codes to serve both…