# BMUpdateButton API Operation (SOAP) (/api/nvp-soap/update-button-soap)



Updates a PayPal-hosted Payments Standard website button.

> **Note:** **Important:**
> The Button Manager API is deprecated. For new integrations, see the associated topic.
>
> | Button                                          | See                                                                               |
> | ----------------------------------------------- | --------------------------------------------------------------------------------- |
> | **Buy Now**<br />                               | [PayPal Checkout Overview](/checkout)<br />                                       |
> | **Add to Cart**<br />                           | [Solution Providers](https://www.paypal.com/webapps/mpp/solution-providers)<br /> |
> | **Donate**<br />                                | [Create a Donate button](/api/nvp-soap/paypal-payments-pro)<br />                 |
> | **Automatic Billing**<br /> **Subscribe**<br /> | [Subscriptions Overview](/subscriptions/about)<br />                              |

This operation replaces all fields in a button. Therefore, you must specify a value for each field that you want to include for the button, whether or not it changed.

## BMUpdateButton request [#bmupdatebutton-request]

The hosted button ID identifies the button to modify. The remaining request parameters specify the characteristics of your button.

![](https://www.paypalobjects.com/webstatic/en_US/developer/docs/api/BMUpdateButtonRequest.gif)

![OptionsDetailsType,Diagram](https://www.paypalobjects.com/webstatic/en_US/developer/docs/api/OptionDetailsType.gif)

![OptionSelectionDetailsType,Diagram](https://www.paypalobjects.com/webstatic/en_US/developer/docs/api/OptionSelectionDetailsType.gif)

### BMUpdateButton request parameters [#bmupdatebutton-request-parameters]

| Field<br />            | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `HostedButtonID`<br /> | `xs:string`<br /&#x3E; &#x2A;(Required)* The ID of the hosted button to modify.<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| `ButtonType`<br />     | `ebl:ButtonTypeType`<br /&#x3E; &#x2A;(Required)* The kind to update. Value is:<br /> `BUYNOW`. The **Buy Now** button.<br />`CART`. The **Add to Cart** button.<br />`SUBSCRIBE`. The **Subscribe** button.<br />`DONATE`. The **Donate** button.<br />`UNSUBSCRIBE`. The **Unsubscribe** button.<br />`VIEWCART`. The **View Cart** button.<br />`AUTOBILLING`. The **Automatic Billing** button. Since version 63.0.<br /> > **Note:** &#x2A;*Note:** You cannot change the kind of button after the button has been created.                 |
| `ButtonCode`<br />     | `ebl:ButtonCodeType`<br /&#x3E; &#x2A;(Optional)* The kind of button code to create. Value is:<br /> `HOSTED`. A secure button stored on PayPal. Default for all buttons except **View Cart** and **Unsubscribe**.<br />`ENCRYPTED`. An encrypted button, not stored on PayPal. The default for **View Cart** button.<br />`CLEARTEXT`. An unencrypted button, not stored on PayPal. The default for **Unsubscribe** button.<br /> > **Note:** &#x2A;*Note:** You cannot change the kind of button code after after the button has been created. |
| `ButtonSubType`<br />  | `ebl:ButtonSubTypeType`<br /&#x3E; &#x2A;(Optional)* The use of button you want to create. Value is:<br /> `PRODUCTS`. Use this button to purchase products. The default for the **Buy Now** and **Add to Cart** buttons.<br />`SERVICES`. The button to purchase services.<br /> > **Note:** &#x2A;*Note:** After the button is created, you cannot change its usage.                                                                                                                                                                           |
| `ButtonVar`<br />      | `xs:string`<br /&#x3E; &#x2A;(Optional)* HTML standard button variables<br /> Lists variables, where n is a digit between 0 and 999, inclusive; do not include leading zeros.<br /> Character length and limitations: 63 single-byte alphanumeric characters each<br />                                                                                                                                                                                                                                                                          |
| `OptionDetails`<br />  | `ns:OptionDetailsType`<br /&#x3E; &#x2A;(Optional)* Menu items.<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| `TextBox`<br />        | `xs:string`<br /&#x3E; &#x2A;(Optional)* Text description for a menu item<br /> Lists variables, where n is a digit between 0 and 1, inclusive.<br />                                                                                                                                                                                                                                                                                                                                                                                            |
| `ButtonImage`<br />    | `ebl:ButtonImageType`<br /&#x3E; &#x2A;(Optional)* The kind of button image. Value is:<br /> `REG`. Regular. The default.<br />`SML`. Small.<br />`CC`. The small button image with credit card logos. Not applicable for **Unsubscribe** or **View Cart** buttons.<br /> > **Note:** &#x2A;*Note:** Specify either the kind of button image or the URL.                                                                                                                                                                                         |
| `ButtonImageURL`<br /> | `xs:string`<br /&#x3E; &#x2A;(Optional)* The button's URL.<br /> > **Note:** &#x2A;*Note:** Specify either the kind of button image or the URL.                                                                                                                                                                                                                                                                                                                                                                                                  |
| `BuyNowText`<br />     | `ebl:BuyNowTextType`<br /&#x3E; &#x2A;(Optional)* The button text for a **Buy Now** button. Value is:<br /> `BUYNOW`. The button text is **Buy Now**. The default.<br />`PAYNOW`. The button text is **Pay Now**.<br />                                                                                                                                                                                                                                                                                                                          |
| `SubscribeText`<br />  | `ebl:SubscribeTextType`<br /&#x3E; &#x2A;(Optional)* The button text for a **Subscribe** button. Value is:<br /> `BUYNOW`. The button text is **Buy Now**.<br />`SUBSCRIBE`. The button text is **Subscribe**. The default.<br />                                                                                                                                                                                                                                                                                                                |
| `ButtonCountry`<br />  | `ebl:CountryCodeType`<br /&#x3E; &#x2A;(Optional)* The country in which the transaction occurs. By default, it is the merchant's country of registration with PayPal.<br />                                                                                                                                                                                                                                                                                                                                                                      |
| `ButtonLanguage`<br /> | `xs:string`<br /&#x3E; &#x2A;(Optional)* The language in which to display the button text. It must be compatible with the country code.<br /> Character length and limitations: Two single-byte alphanumeric characters.<br />                                                                                                                                                                                                                                                                                                                   |

### Option details fields [#option-details-fields]

| Field<br />                    | Description                                                                    |
| ------------------------------ | ------------------------------------------------------------------------------ |
| `OptionName`<br />             | `xs:string`<br /&#x3E; &#x2A;(Optional)* The menu name.<br />                  |
| `OptionSelectionDetails`<br /> | `ns:OptionSelectionDetailsType`<br /&#x3E; &#x2A;(Optional)* Menu items.<br /> |

### Option selection details fields [#option-selection-details-fields]

| Field                   | Description                                                                                                                                                                                    |
| ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `OptionSelection`<br /> | `xs:string`<br /&#x3E; &#x2A;(Optional)* The menu item's name.<br />                                                                                                                           |
| `Price`<br />           | `xs:string`<br /&#x3E; &#x2A;(Optional)* The price associated with the first menu item.<br /> > **Note:** &#x2A;*Note:** If you specify a price, you cannot set a button variable to `amount`. |

### Button language options [#button-language-options]

The button language must be compatible with the country identified by the country code.

| Country<br />                             | Button language options.<br />                                                                      |
| ----------------------------------------- | --------------------------------------------------------------------------------------------------- |
| All countries not identified below.<br /> | <br /> `en`. English. The default.<br />                                                            |
| Austria<br />                             | <br /> `de`. German. The default.<br />`en`. English.<br />                                         |
| Belgium<br />                             | <br /> `en`. English. The default.<br />`nl`. Dutch.<br />`fr`. French.<br />                       |
| Canada<br />                              | <br /> `en`. English. The default.<br />`fr`. French.<br />                                         |
| China (worldwide)<br />                   | <br /> `en`. English. The default.<br />`zh`. Chinese.<br />                                        |
| France<br />                              | <br /> `fr`. French. The default.<br />`en`. English.<br />                                         |
| Germany<br />                             | <br /> `de`. German. The default.<br />`en`. English.<br />                                         |
| Hong Kong<br />                           | <br /> `zh`. Chinese. The default.<br />`en`. English.<br />                                        |
| Italy<br />                               | <br /> `it`. Italian. The default.<br />`en`. English.<br />                                        |
| Japan<br />                               | <br /> `ja`. Japanese. The default.<br />`en`. English.<br />                                       |
| Mexico<br />                              | <br /> `es`. Spanish. The default.<br />`en`. English.<br />                                        |
| Netherlands<br />                         | <br /> `nl`. Dutch. The default.<br />`en`. English.<br />                                          |
| Poland<br />                              | <br /> `pl`. Polish. The default.<br />`en`. English.<br />                                         |
| Spain<br />                               | <br /> `es`. Spanish. The default.<br />`en`. English.<br />                                        |
| Switzerland<br />                         | <br /> `de`. German. The default.<br />`fr`. French.<br />`en`. English.<br />                      |
| United States<br />                       | <br /> `en`. English. The default.<br />`fr`. French.<br />`es`. Spanish.<br />`zh`. Chinese.<br /> |

## BMUpdateButton response [#bmupdatebutton-response]

The response contains the hosted button ID and the code for both the HTML in a website and a link in an email.

![](https://www.paypalobjects.com/webstatic/en_US/developer/docs/api/BMUpdateButtonResponse.gif)

### BMUpdateButton response fields [#bmupdatebutton-response-fields]

| Field<br />            | Description                                                                                            |
| ---------------------- | ------------------------------------------------------------------------------------------------------ |
| `Website`<br />        | `xs:string`<br /> HTML code for web pages.<br />                                                       |
| `Email`<br />          | `xs:string`<br /> Code for email links and links in other documents that support external links.<br /> |
| `HostedButtonID`<br /> | `xs:string`<br /> The ID of a PayPal-hosted button.<br />                                              |

## BMUpdateButton errors [#bmupdatebutton-errors]

| Error code  | Short and long messages                                                                                                                                            | User action                                                                                                                                                                                 |
| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 10001       | Internal Error<br />Internal Error                                                                                                                                 | To learn more about possible causes and corrective actions, see [What is API error code 10001?](https://www.paypal.com/selfhelp/article/what-is-api-error-code-10001-ts1041/3?channel=MTS). |
| 11923       | Invalid Argument<br />The button image value specified is invalid.                                                                                                 |                                                                                                                                                                                             |
| 11924       | Invalid Argument<br />The button image URL specified is invalid.                                                                                                   |                                                                                                                                                                                             |
| 11925       | Invalid Argument<br />The button type specified is invalid.                                                                                                        |                                                                                                                                                                                             |
| 11926       | Invalid Data<br />One of the parameters specified by using `ButtonVar` is invalid.                                                                                 |                                                                                                                                                                                             |
| 11927       | Invalid Argument<br />The **Buy Now** button text specified is invalid.                                                                                            |                                                                                                                                                                                             |
| 11928       | Invalid Argument<br />The email or merchant ID specified is invalid.                                                                                               |                                                                                                                                                                                             |
| 11929       | Invalid Data<br />A cart button must have an item name and amount specified.                                                                                       |                                                                                                                                                                                             |
| 11931       | Invalid Argument<br />The subscription button text specified is invalid.                                                                                           |                                                                                                                                                                                             |
| 11932       | Invalid Data<br />You must specify a corresponding number of entries for option names and selections.                                                              |                                                                                                                                                                                             |
| 11933       | Invalid Data<br />You cannot skip index numbers for option selections. Option selections must be specified sequentially.                                           |                                                                                                                                                                                             |
| 11934       | Invalid Data<br />You must specify the same number of entries for option prices and selections.                                                                    |                                                                                                                                                                                             |
| 11936       | Invalid Data<br />You cannot specify both an item price and prices for individual selections within an option.                                                     |                                                                                                                                                                                             |
| 11937       | Invalid Argument<br />A text box name specified is invalid. Text box names must not exceed 64 characters.                                                          |                                                                                                                                                                                             |
| 11938       | Invalid Argument<br />The button code value specified is invalid.                                                                                                  |                                                                                                                                                                                             |
| 11940       | Invalid Argument<br />An option name specified is invalid. Option names must not exceed 64 characters.                                                             |                                                                                                                                                                                             |
| 11941       | Invalid Argument<br />An option selection value specified is invalid. Option selection values must not exceed 64 characters.                                       |                                                                                                                                                                                             |
| 11942       | Invalid Argument<br />An option price value specified is invalid. Make sure any punctuation marks are in the correct places.                                       |                                                                                                                                                                                             |
| 11943       | Invalid Argument<br />The button country value specified is invalid.                                                                                               |                                                                                                                                                                                             |
| 11945       | Invalid Data<br />The button country and language code combination specified is invalid.                                                                           |                                                                                                                                                                                             |
| 11947       | Invalid Argument<br />The tax rate specified is invalid. Make sure any punctuation marks are in the correct places and value specified is in the range 0.0 to 100. |                                                                                                                                                                                             |
| 11948       | Invalid Argument<br />The amount specified is invalid. Make sure any punctuation marks are in the correct places.                                                  |                                                                                                                                                                                             |
| 11995       | Feature Temporarily Unavailable<br />This button cannot be created or updated now. Try again later.                                                                |                                                                                                                                                                                             |
| 12210<br /> | Invalid Argument<br />The currency code value specified is invalid.                                                                                                |                                                                                                                                                                                             |
| 13117<br /> | Invalid Argument<br />Subtotal amount is not valid.                                                                                                                |                                                                                                                                                                                             |
| 13118<br /> | Invalid Argument<br />Tax amount is not valid.                                                                                                                     |                                                                                                                                                                                             |
| 13119<br /> | Invalid Argument<br />Handling amount is not valid.                                                                                                                |                                                                                                                                                                                             |
| 13120<br /> | Invalid Argument<br />Shipping amount is not valid.                                                                                                                |                                                                                                                                                                                             |
