# SetPaymentOptions API Operation (/archive/adaptive-payments/api/set-payment-options)



> **Note:** **Important:** Adaptive Payments is not available for new         integrations. PayPal provides this documentation to support existing         integrations. If you're starting an integration,         [we recommend our latest solutions](https://www.paypal.com/us/business/accept-payments).

Specifies settings for a payment. If you start a payment by specifying an     `actionType` of `CREATE` in a `Pay` API call,     you can use the `SetPaymentOptions` API to specify settings for the     payment.

## SetPaymentsOptionsRequest Message [#setpaymentsoptionsrequest-message]

### SetPaymentOptionsRequest Fields [#setpaymentoptionsrequest-fields]

| Field<br />                | Description<br />                                                                                                                                                                                                                                                                         |
| -------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `payKey`<br />             | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The pay key that identifies the payment for which                     you want to set payment options. This is the pay key returned in the                     `PayResponse` message.<br />                                     |
| `displayOptions`<br />     | `ap:DisplayOptions`<br /&#x3E;                  &#x2A;(Optional)* Specifies display items in payment flows and                     emails.<br />                                                                                                                                          |
| `initiatingEntitity`<br /> | `ap:InitiatingEntity`<br /&#x3E;                  &#x2A;(Optional)* The PayPal financial partner that is initiating                     the payment. A financial partner must be granted permission by PayPal                     before the financial partner can use PayPal APIs.<br /> |
| `shippingAddressId`<br />  | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Sender's shipping address ID.<br />                                                                                                                                                                                             |
| `senderOptions`<br />      | `ap:SenderOptions`<br /&#x3E;                  &#x2A;(Optional)* Specifies information to be provided by the                     sender, and optionally can include the sender address.<br />                                                                                             |
| `receiverOptions`<br />    | `ap:ReceiverOptions`<br /&#x3E;                  &#x2A;(Optional)* Specifies information about each receiver.<br />                                                                                                                                                                       |
| `requestEnvelope`<br />    | `common:requestEnvelope`<br /&#x3E;                  &#x2A;(Required)* Information                     common to each API operation, such as the language in which an error                     message is returned.<br />                                                                |

### DisplayOptions Fields [#displayoptions-fields]

| Field<br />                    | Description<br />                                                                                                                                                                                                                                                                                                                                                                |
| ------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `emailHeaderImageUrl`<br />    | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* The URL of the image that displays in the in the                     header of customer emails. The URL cannot exceed 1,024 characters. The                     image dimensions are 43 pixels high x 240 pixels wide.<br />                                                                                           |
| `emailMarketingImageUrl`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* The URL of the image that displays in the in                     customer emails. The URL cannot exceed 1,024 characters. The image                     dimensions are 80 pixels high x 530 pixels wide.<br />                                                                                                         |
| `headerImageUrl`<br />         | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* The URL of an image that displays in the header of                     a payment page. If set, it overrides the header image URL specified in                     your account's Profile. The URL cannot exceed 1,024 characters. The                     image dimensions are 90 pixels high x 750 pixels wide.<br /> |
| `businessName`<br />           | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* The business name to display. The name cannot                     exceed 128 characters.<br />                                                                                                                                                                                                                         |

### InitiatingEntity Fields [#initiatingentity-fields]

| Field<br />                 | Description<br />                                                                                                                                                                                                                                                                                                                                                                                                                         |
| --------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `institutionCustomer`<br /> | `ap:InstitutionCustomer`<br /&#x3E;                  &#x2A;(Optional)* Details about the party that initiated this                     payment. This payment is made by the API caller on behalf of the                     initiating party. The initiating party can be an institution or a                     customer of the institution. The initiating party must be set up by                     PayPal Merchant Services.<br /> |

### Institution Customer Fields [#institution-customer-fields]

| Field<br />                   | Description<br />                                                                                                                                                                                           |
| ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `countryCode`<br />           | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The two-character country code of the home country                     of the end consumer<br />                                                  |
| `displayName`<br />           | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The full name of the consumer as known by the                     institution.<br />                  Maximum length: 200 characters<br />        |
| `email`<br />                 | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* The email address of the consumer as known by the                     institution.<br />                  Maximum length: 127 characters<br />    |
| `firstName`<br />             | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The first name of the consumer as known by the                     institution.<br />                  Maximum length: 64 characters<br />        |
| `institutionCustomerId`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The unique identifier assigned to the consumer by                     the institution.<br />                  Maximum length: 64 characters<br /> |
| `institutionId`<br />         | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The unique identifier assigned to the institution.<br />                  Maximum length: 64 characters<br />                                     |
| `lastName`<br />              | `xs:string`<br /&#x3E;                  &#x2A;(Required)* The last name of the consumer as known by the                     institution.<br />                  Maximum length: 64 characters<br />         |

### SenderOptions Fields [#senderoptions-fields]

| Field<br />                             | Description<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| --------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `requireShippingAddressSelection`<br /> | `xs:boolean`<br /&#x3E;                  &#x2A;(Optional)* If `true`, require the sender to select                     a shipping address during the embedded payment flow; default is                     `false`.<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `referrerCode`<br />                    | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* A code that identifies the partner associated with                     this transaction.<br />                  Maximum length: 32 characters.<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| `addressOverride`<br />                 | `xs:boolean`<br /&#x3E;                  &#x2A;(Optional)* Determines whether pages in the user interface                     will enable the user to override the specified shipping address (that                     is, the address specified in the                     `shippingAddress` container of this SetPaymentOptions API                     call). Only applicable for the embedded payment flow. True by default.                     If `addressOverride` is `true`, the specified                     shipping address is displayed as first, followed by other addresses in                     the sender's profile, along with an option to add a new shipping                     address. The sender thus can override the specified shipping address                     (that is, the sender can override the address in this                     SetPaymentOptions API call). If `addressOverride` is                     `false`, the sender cannot change the address in this                     SetPaymentOptions API call. Note that if no address is specified in                     this SetPaymentOptions API call, the buyer's shipping addresses are                     presented for selection.<br /> |
| `shippingAddress`<br />                 | `ap:ShippingAddressInfo`<br /&#x3E;                  &#x2A;(Optional)* Container for the sender's shipping address. After                     you specify an address using this container, the address will be                     returned as part of a PaymentDetails API response.<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |

### ReceiverOptions Fields [#receiveroptions-fields]

| Field<br />         | Description<br />                                                                                                                                                                                                                                                                                                                                    |
| ------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `description`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* A description you want to associate with the                     payment. This overrides the value of the memo in Pay API for each                     receiver. If this is not specified the value in the memo will be used.<br />                  Maximum length: 1000 characters<br /> |
| `customId`<br />    | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* An external reference or identifier you want to                     associate with the payment.<br />                  Maximum length: 1000 characters<br />                                                                                                                               |
| `invoiceData`<br /> | `ap:InvoiceData`<br /&#x3E;                  &#x2A;(Optional)* Item information for the payment, which could                     appear on an invoice.<br />                                                                                                                                                                                         |
| `receiver`<br />    | `ap:ReceiverIdentifier`<br /&#x3E;                  &#x2A;(Optional)* Receiver ID associated with these options.<br />                                                                                                                                                                                                                               |

### ShippingAddressInfo Fields [#shippingaddressinfo-fields]

| Field<br />           | Description<br />                                                                                                                                                                              |
| --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `addresseeName`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Person's name associated with this shipping                     address.<br />                  Maximum length: 128 characters<br /> |
| `street1`<br />       | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* First street address.<br />                  Maximum length: 128 characters<br />                                                    |
| `street2`<br />       | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Second street address.<br />                  Maximum length: 128 characters<br />                                                   |
| `city`<br />          | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Name of city.<br />                  Maximum length: 128 characters<br />                                                            |
| `state`<br />         | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* State or province.<br />                  Maximum length: 128 characters<br />                                                       |
| `zip`<br />           | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* U.S. ZIP code or other country-specific postal                     code.<br />                  Maximum length: 128 characters<br /> |
| `country`<br />       | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Country code.<br />                  Maximum length: 128 characters<br />                                                            |
| `phone`<br />         | `ap:PhoneNumber`<br /&#x3E;                  &#x2A;(Optional)* Phone number.<br />                                                                                                             |

### PhoneNumber Fields [#phonenumber-fields]

| Field<br />  | Description<br />                                                                                                                                                                                                                                                                                                                                                                       |
| ------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `type`<br /> | `ap:PhoneType`<br /&#x3E;                  &#x2A;(Optional)* Specifies the type of phone number. Currently,                     only `MOBILE` is valid. Other Value is:<br />                  `NONE` — None of the other choices`HOME` — Home phone`WORK` — Work phone`BUSINESS` — Business phone`MOBILE` — Mobile phone`FAX_HOME` — Fax home phone`FAX_BUSINESS` — Fax business phone |

### InvoiceData Fields [#invoicedata-fields]

| Field<br />           | Description<br />                                                                                                     |
| --------------------- | --------------------------------------------------------------------------------------------------------------------- |
| `item`<br />          | `ap:InvoiceItem`<br /&#x3E;                  &#x2A;(Optional)* Any number of items associated with the payment.<br /> |
| `totalTax`<br />      | `xs:decimal`<br /&#x3E;                  &#x2A;(Optional)* Total tax associated with the payment.<br />               |
| `totalShipping`<br /> | `xs:decimal`<br /&#x3E;                  &#x2A;(Optional)* Total shipping charge associated with the payment.<br />   |

### InvoiceItem Fields [#invoiceitem-fields]

| Field<br />        | Description<br />                                                                                      |
| ------------------ | ------------------------------------------------------------------------------------------------------ |
| `name`<br />       | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Name of item.<br />                          |
| `identifier`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* External reference to item or item ID.<br /> |
| `price`<br />      | `xs:decimal`<br /&#x3E;                  &#x2A;(Optional)* Total of item line.<br />                   |
| `itemPrice`<br />  | `xs:decimal`<br /&#x3E;                  &#x2A;(Optional)* Price of an individual item.<br />          |
| `itemCount`<br />  | `xs:int`<br /&#x3E;                  &#x2A;(Optional)* Item quantity.<br />                            |

### ReceiverIdentifier Fields [#receiveridentifier-fields]

| Field<br />       | Description<br />                                                                                                                                                                                                                                                                                                                                                                                                                             |
| ----------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `email`<br />     | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Receiver's email address.<br />                  Maximum length: 127 characters<br />                                                                                                                                                                                                                                                                                               |
| `accountId`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Receiver's account ID value (which is the same as                     the Payer ID value used in the Express Checkout API). The account ID                     value is an encrypted PayPal account ID. This account ID value can be                     specified instead of a PayPal address.<br />                  Maximum length: 13 single-byte alphanumeric characters<br /> |
| `phone`<br />     | `common:PhoneNumberType`<br /&#x3E;                  &#x2A;(Optional)* Receiver's phone number.<br />                                                                                                                                                                                                                                                                                                                                         |

### PhoneNumberType Fields [#phonenumbertype-fields]

| Field<br />         | Description<br />                                                                       |
| ------------------- | --------------------------------------------------------------------------------------- |
| `countryCode`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Required)* Telephone country code.<br /> |
| `phoneNumber`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Required)* Telephone number.<br />       |
| `extension`<br />   | `xs:string`<br /&#x3E;                  &#x2A;(Optional)* Telephone extension.<br />    |

### RequestEnvelope Fields [#requestenvelope-fields]

| Field<br />           | Description<br />                                                                                                                                                                                                                                                                                         |
| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `detailLevel`<br />   | `common:DetailLevelCode`<br /&#x3E;                  &#x2A;(Optional)* Level of detail required by the client application                     for components. Value is:<br />                  `ReturnAll` — This value provides the maximum level of                             detail (default).<br /> |
| `errorLanguage`<br /> | `xs:string`<br /&#x3E;                  &#x2A;(Required)* RFC 3066 language in which error messages are                     returned; by default it is `en_US`, which is the only                     language currently supported.<br />                                                                 |

## SetPaymentOptionsResponse Message [#setpaymentoptionsresponse-message]

### ResponseEnvelope Fields [#responseenvelope-fields]

| Field<br />           | Description<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `ack`<br />           | `common:AckCode`<br />                  Acknowledgment code. Value is:<br />                  `Success` — The operation completed successfully.<br />`Failure` — The operation failed.<br />`SuccessWithWarning` — The operation completed                             successfully; however, there is a warning message.<br />`FailureWithWarning `— The operation failed with a                             warning message.<br />                                   |
| `build`<br />         | `xs:string`<br />                  Build number. It is used only by PayPal Merchant Technical Support.<br />                                                                                                                                                                                                                                                                                                                                                           |
| `correlationId`<br /> | `xs:string`<br />                  Correlation identifier. It is a 13-character, alphanumeric string (for                     example, `db87c705a910e`) that is used only by PayPal                     Merchant Technical Support.<br />                  &#x2A;*Note:** You must log and store this data for every                     response you receive. PayPal Technical Support uses the information to                     assist with reported issues.<br /> |
| `timestamp`<br />     | `xs:datetime`<br />                  Date on which the response was sent, for example:<br />                  `2012-04-02T22:33:35.774-07:00`<br />                  &#x2A;*Note:** You must log and store this data for every                     response you receive. PayPal Technical Support uses the information to                     assist with reported issues.<br />                                                                                       |

## PPFault Message [#ppfault-message]

The `PPFaultMessage` returns `ErrorData` and the     `ResponseEnvelope` information to your application if an error     occurs.

### FaultMessage Fields [#faultmessage-fields]

| Field<br />              | Description<br />                                                                                                                                                     |
| ------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `error`<br />            | `common:ErrorData`<br />                  Detailed error information.<br />                                                                                           |
| `responseEnvelope`<br /> | `common:ResponseEnvelope`<br />                  Common response information, including a timestamp and the response                     acknowledgment status.<br /> |

### ErrorData Fields [#errordata-fields]

| Field<br />         | Description<br />                                                                                                                                                                                                                                                                                                                                |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `category`<br />    | `common:ErrorCategory`<br />                  The location where the error occurred.<br />                  Value is:<br />                  `System` — The system encountered errors; try again<br />`Application` — The application encountered errors; try                             again<br />`Request` — The request was incorrect<br /> |
| `domain`<br />      | `xs:string`<br />                  The domain to which this service belongs.<br />                                                                                                                                                                                                                                                               |
| `errorId`<br />     | `xs:long`<br />                  A 6-digit number that uniquely identifies a particular error.<br />                                                                                                                                                                                                                                             |
| `exceptionID`<br /> | This field is not used.<br />                                                                                                                                                                                                                                                                                                                    |
| `message`<br />     | `xs:string`<br />                  A description of the error.<br />                                                                                                                                                                                                                                                                             |
| `parameter`<br />   | `common:ErrorParameter`<br />                  Represents contextual information about the error.<br />                                                                                                                                                                                                                                          |
| `severity`<br />    | `common:ErrorSeverity`<br />                  The severity of the error encountered.<br />                  Value is:<br />                  `Error` — Processing of the request was interrupted<br />`Warning` — Processing of the request was completed<br />                                                                                  |
| `subdomain`<br />   | This field is not used.<br />                                                                                                                                                                                                                                                                                                                    |

### ResponseEnvelope Fields [#responseenvelope-fields-1]

| Field<br />           | Description<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `ack`<br />           | `common:AckCode`<br />                  Acknowledgment code. Value is:<br />                  `Success` — The operation completed successfully.<br />`Failure` — The operation failed.<br />`SuccessWithWarning` — The operation completed                             successfully; however, there is a warning message.<br />`FailureWithWarning `— The operation failed with a                             warning message.<br />                                   |
| `build`<br />         | `xs:string`<br />                  Build number. It is used only by PayPal Merchant Technical Support.<br />                                                                                                                                                                                                                                                                                                                                                           |
| `correlationId`<br /> | `xs:string`<br />                  Correlation identifier. It is a 13-character, alphanumeric string (for                     example, `db87c705a910e`) that is used only by PayPal                     Merchant Technical Support.<br />                  &#x2A;*Note:** You must log and store this data for every                     response you receive. PayPal Technical Support uses the information to                     assist with reported issues.<br /> |
| `timestamp`<br />     | `xs:datetime`<br />                  Date on which the response was sent, for example:<br />                  `2012-04-02T22:33:35.774-07:00`<br />                  &#x2A;*Note:** You must log and store this data for every                     response you receive. PayPal Technical Support uses the information to                     assist with reported issues.<br />                                                                                       |

## SetPaymentOptions Examples Using NVP and CURL [#setpaymentoptions-examples-using-nvp-and-curl]

These examples use NVP for the data binding and CURL to deliver the HTTP     request to the PayPal sandbox endpoint. Line breaks are provided for ease of     reading; each CURL command is a single line and each request and response is a     string without line breaks or extra whitespace.

### Specifying Invoice Data [#specifying-invoice-data]

This example shows how to set up purchase details for display on the payment     review page, for user authorization. The details include the item description,     item count, item price, total shipping, and total tax.

> **Note:** **Note:** The sample code below uses the         `insecure` setting to work around the certificate for testing in         a sandbox environment. For actual implementations, you must specify the         location of the certificate.

#### Request [#request]

<div className="pl-[1.625rem]" />

```text lineNumbers
curl https://svcs.sandbox.paypal.com/AdaptivePayments/SetPaymentOptions
-s
--insecure
-H "X-PAYPAL-SECURITY-USERID: [api_username]"
-H "X-PAYPAL-SECURITY-PASSWORD: [api_password]"
-H "X-PAYPAL-SECURITY-SIGNATURE: [api_signature]"
-H "X-PAYPAL-REQUEST-DATA-FORMAT: NV"
-H "X-PAYPAL-RESPONSE-DATA-FORMAT: NV"
-H "X-PAYPAL-APPLICATION-ID: [app_id]"
-d requestEnvelope.errorLanguage=en_US
-d receiverOptions[0].receiver.email=test@test.com
-d receiverOptions[0].invoiceData.item[0].name=ITEM1
-d receiverOptions[0].invoiceData.item[0].price=50.0
-d receiverOptions[0].invoiceData.item[0].itemCount=2
-d receiverOptions[0].invoiceData.item[0].itemPrice=25.0
-d receiverOptions[0].invoiceData.totalTax=25.0
-d receiverOptions[0].invoiceData.totalShipping=25.0
-d payKey=[pay_key]
```

### Specifying a Shipping Address [#specifying-a-shipping-address]

This example shows how to provide a shipping address for inclusion on the     payment review page.

> **Note:** **Note:** The sample code below uses the         `insecure` setting to work around the certificate for testing in         a sandbox environment. For actual implementations, you must specify the         location of the certificate.

#### Request [#request-1]

<div className="pl-[1.625rem]" />

```text lineNumbers
curl https://svcs.sandbox.paypal.com/AdaptivePayments/SetPaymentOptions
-s
--insecure
-H "X-PAYPAL-SECURITY-USERID:[api_username]"
-H "X-PAYPAL-SECURITY-PASSWORD:[api_password]"
-H "X-PAYPAL-SECURITY-SIGNATURE:[api_signature]"
-H "X-PAYPAL-REQUEST-DATA-FORMAT: NV"
-H "X-PAYPAL-RESPONSE-DATA-FORMAT: NV"
-H "X-PAYPAL-APPLICATION-ID:[app_id]"
-d requestEnvelope.errorLanguage=en_US
-d receiverList.receiver(0).email=test@test.com
-d senderOptions.shippingAddress.addresseeName=John
-d senderOptions.shippingAddress.city=San+Jose
-d senderOptions.shippingAddress.country=US
-d senderOptions.shippingAddress.phone.countryCode=91
-d senderOptions.shippingAddress.phone.phoneNumber=408123456
-d senderOptions.shippingAddress.phone.type=MOBILE
-d senderOptions.shippingAddress.state=CA
-d senderOptions.shippingAddress.street1=17+Magneson+St
-d senderOptions.shippingAddress.street2=building+1
-d senderOptions.shippingAddress.zip=12345
-d payKey=[pay_key]
```

## SetPaymentOptions Errors [#setpaymentoptions-errors]

| Code<br />   | Message<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | Additional Information<br /> |
| ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------- |
| 520002       | Internal error                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |                              |
| 520003<br /> | Authentication failed. API credentials are incorrect.<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | Since 1.6.0<br />            |
| 550001<br /> | User is not allowed to perform this action<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |                              |
| 550001<br /> | This payment request must be authorized by the sender                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |                              |
| 540031<br /> | You do not have permission to set these payment options<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |                              |
| 540031<br /> | You do not have permission to set these payment options<br />                  Operation is not permitted because the credentials do not match those                     of the initial operation<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | Since 1.6.0<br />            |
| 580001       | Invalid request: \<value>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              | Since 1.6.0<br />            |
| 580022<br /> | Invalid request parameter: payKey with value \<value><br />payKey \<value> has already been used to make a payment<br />displayOptions has already been set and cannot be set multiple                             times<br />initiationEntity has already been set and cannot be set multiple                             times<br />Invalid Request Parameter: institutionId with value \<value><br />The instituion ID \<value> is not activated<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |                              |
| 580022<br /> | Invalid request parameter: \<value><br />Invalid Request Parameter: institutionId with value \<value><br />The institution id \<value> is not activated<br />The clientDetails parameter is missing<br />Invalid request parameter: payKey with value \<value><br />Invalid Phone Country Code \<value><br />Invalid Country Code \<value> for Receiver<br />Invalid Receiver Phone Type \<value> \<value>                             \<value><br />Invalid Phone Format \<value> \<value><br />Invalid Phone Number \<value> \<value><br />Invalid Receiver Phone Number \<value> \<value><br />Invalid Area or Exchange Code \<value> \<value><br />\<value> has already been set and cannot be set multiple                             times<br />Invalid request parameter: \<value> with value \<value><br />Invalid request parameter: \<value> \<value> is invalid<br />Invalid request parameter: \<value> \<value> is                             duplicated<br />Invalid request parameter: \<value> \<value> cannot be                             negative or zero<br /> | Since 1.6.0<br />            |
| 580027       | Currently the system does not accept the currency \<value><br />Unsupported country code \<value><br />Currently the system does not accept the currency \<value><br />The parameter is not supported<br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | Since 1.6.0<br />            |
| 580028       | The URL \<value> is malformed                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |                              |
