12 lines
4.2 KiB
Plaintext
12 lines
4.2 KiB
Plaintext
---
|
|
displayed_sidebar: paymentReference
|
|
---
|
|
|
|
import { TypeList } from "docs-ui"
|
|
|
|
# CreatePaymentSessionDTO
|
|
|
|
The payment session to be created.
|
|
|
|
<TypeList types={[{"name":"provider_id","type":"`string`","description":"The provider's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`string`","description":"The ISO 3 character currency code of the payment session.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"amount","type":"[BigNumberInput](../../types/payment.BigNumberInput/page.mdx)","description":"The amount to be authorized.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"numeric","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"raw","type":"[BigNumberRawValue](../../types/payment.BigNumberRawValue/page.mdx)","description":"","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"value","type":"`string` \\| `number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"bigNumber","type":"`BigNumber`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"data","type":"`Record<string, unknown>`","description":"Necessary data for the associated payment provider to process the payment.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"context","type":"[PaymentProviderContext](../payment.PaymentProviderContext/page.mdx)","description":"Necessary context data for the associated payment provider.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"account_holder","type":"[PaymentAccountHolderDTO](../../types/payment.PaymentAccountHolderDTO/page.mdx)","description":"The account holder information, if available for the payment provider.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"data","type":"`Record<string, unknown>`","description":"Account holder's details as stored in the third-party payment provider.","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"name":"customer","type":"[PaymentCustomerDTO](../../types/payment.PaymentCustomerDTO/page.mdx)","description":"The customer information from Medusa.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"id","type":"`string`","description":"The ID of the customer in Medusa.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"email","type":"`string`","description":"The email of the customer.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"company_name","type":"`string` \\| `null`","description":"The customer's company name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"first_name","type":"`string` \\| `null`","description":"The customer's first name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"last_name","type":"`string` \\| `null`","description":"The customer's last name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"phone","type":"`string` \\| `null`","description":"The customer's phone number.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"billing_address","type":"[PaymentAddressDTO](../../types/payment.PaymentAddressDTO/page.mdx) \\| `null`","description":"The customer's billing address.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"idempotency_key","type":"`string`","description":"Idempotency key for the request, if the payment provider supports it. It will be ignored otherwise.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"metadata","type":"`Record<string, unknown>`","description":"Holds custom data in key-value pairs.","optional":true,"defaultValue":"","expandable":false,"children":[]}]} expandUrl="https://docs.medusajs.com/learn/fundamentals/data-models/manage-relationships#retrieve-records-of-relation" sectionTitle="CreatePaymentSessionDTO"/>
|