> Documentation index: [Saleor](/llms.txt) · [This section](/api-reference/payments/llms.txt)
> Source: https://docs.saleor.io/api-reference/payments/inputs/payment-input

# PaymentInput Input Type

Fields required to create a payment.

The legacy Payments API is deprecated and will be removed. Use the Transactions API instead.

```graphql
input PaymentInput {
  gateway: String!
  token: String
  amount: PositiveDecimal
  returnUrl: String
  storePaymentMethod: StorePaymentMethodEnum
  metadata: [MetadataInput!]
}
```

<a id="fields"></a>

### Fields

<a id="gateway"></a>

#### [`gateway`](#gateway) ● [`String!`](/api-reference/miscellaneous/scalars/string.md)

A gateway to use with that payment.

<a id="token"></a>

#### [`token`](#token) ● [`String`](/api-reference/miscellaneous/scalars/string.md)

Client-side generated payment token, representing customer's billing data in a secure manner.

<a id="amount"></a>

#### [`amount`](#amount) ● [`PositiveDecimal`](/api-reference/miscellaneous/scalars/positive-decimal.md)

Total amount of the transaction, including all taxes and discounts. If no amount is provided, the checkout total will be used.

<a id="return-url"></a>

#### [`returnUrl`](#return-url) ● [`String`](/api-reference/miscellaneous/scalars/string.md)

URL of a storefront view where user should be redirected after requiring additional actions. Payment with additional actions will not be finished if this field is not provided.

<a id="store-payment-method"></a>

#### [`storePaymentMethod`](#store-payment-method) ● [`StorePaymentMethodEnum`](/api-reference/payments/enums/store-payment-method-enum.md)

Payment store type.

<a id="metadata"></a>

#### [`metadata`](#metadata) ● [`[MetadataInput!]`](/api-reference/miscellaneous/inputs/metadata-input.md)

User public metadata. Can be read by any API client authorized to read the object it's attached to.

Warning: never store sensitive information, including financial data such as credit card details.

<a id="member-of"></a>

### Member Of

[`checkoutPaymentCreate`](/api-reference/deprecated/checkout/mutations/checkout-payment-create.md) mutation
