# JPMC-PDP Documentation from https://developer.payments.jpmorgan.com # Consumer profile management Create, store, update, and maintain consumer profiles, including payment card information, at J.P. Morgan. Comply with payment card industry data security standards and simplify the payment process for returning consumers and recurring transactions. When you create a consumer profile, J.P. Morgan generates a unique profile ID (`consumerProfileId`) and payment method ID (`paymentMethodId`) for future transactions. To manage a consumer profile separate from a payment request, refer to the [Consumer Profile Management API](/docs/commerce/optimization-protection/capabilities/consumer-profile-management/index). ## Create a profile during a payment You can create a consumer profile along with a payment (for example, an authorization, sale, or verification) by sending the following **required** fields in your `POST /payments` request: **Required fields for creating a consumer profile** | Field name | Description | | --- | --- | | amount | The total monetary value of the payment including all taxes and fees. | | currency | The currency for the amount fields. This is the 3 character ISO 4217 currency code. | | accountHolder.consumerProfileInfo.consumerProfileRequestType | The type of request regarding a consumer profile. Value must be set to CREATE. | | merchant.merchantSoftware.companyName | The company name of the software integrated to this API. If merchant is directly integrated, send JPMC. | | merchant.merchantSoftware.productName | The name of the product used for marketing purposes from a consumer's perspective. | | paymentMethodType.card.accountNumber | The card or token number. | | paymentMethod.Type.card.expiry.month | The month when the card expires. | | paymentMethod.Type.card.expiry.year | The year when the card expires. | | accountHolder.firstName | That part of an individual's full name considered a personal name or given name and generally positioned before the last name or family name. | | accountHolder.lastName | The last name or surname. | **HTTP method**: `POST` **Endpoint**: `/payments `**Scenario: **Creating a consumer profile while making a payment ```json { "captureMethod": "NOW", "amount": 1234, "currency": "USD", "merchant": { "merchantSoftware": { "companyName": "Payment Company", "productName": "Application Name", "version": 1.235 } }, "paymentMethodType": { "card": { "accountNumber": "4112344112344113", "expiry": { "month": 12, "year": 2027 }, "cvv": 411 }, "accountHolder": { "referenceId": "1245", "firstName": "John", "lastName": "Smith", "email": "example@example.com", "mobile": { "countryCode": 1, "phoneNumber": "1234567890" }, "consumerProfileInfo": { "consumerProfileRequestType": "CREATE" } } } } ``` **Response:** ```json { "accountHolder": { "consumerProfileInfo": { "consumerProfileRequestType": "CREATE", "consumerProfileId": "EGQSGO", "paymentMethodId": "ce8dc322-0dde-4a8e-a6ca-b2c02eb37bd6" } } } ``` When the profile create action is unsuccessful during a payment, the following fields are sent in the response: - Profile creation error code — consumerProfileInfo.consumerProfileResponseCode - Profile creation error message — consumerProfileInfo.consumerProfileResponseMessage ## Use a profile for a payment You can use payment credentials stored in a consumer profile for a payment (for example, an authorization, sale, verification, or refund) by sending the following **required** fields in your `POST /payments` request: **Required fields for using a consumer profile** | Field name | Description | | --- | --- | | amount | The total monetary value of the payment including all taxes and fees. | | currency | The currency for the amount fields. This is the 3 character ISO 4217 currency code. | | merchant.merchantSoftware.companyName | The company name of the software integrated to this API. If merchant is directly integrated, send "JPMC". | | merchant.merchantSoftware.productName | The name of the product used for marketing purposes from a consumer's perspective. | | paymentMethodType.card.accountNumber | The card or token number. | | paymentMethod.Type.card.expiry.month | The month when the card expires. | | paymentMethod.Type.card.expiry.year | The year when the card expires. | | paymentMethodType.consumerProfile.consumerProfileId | Unique identifier of a consumer maintained in the firm as requested by merchant. Consumer profile contains information relevant to processing transactions such as name, address, account, and payment methods information. | | paymentMethodType.consumerProfile.paymentMethodId | Unique identifier of the payment method in a consumer profile. | > Ensure that the consumer profile you are using is active. For more information on how to check the status of a consumer profile, refer to [Retrieving a consumer profile using the CPM API](/docs/commerce/optimization-protection/capabilities/consumer-profile-management/how-to/manage-a-consumer-profile#retrieve-a-consumer-profile). > **HTTP method**: `POST` **Endpoint**: `/payments `**Scenario: **Using a consumer profile in a payment ```json { "captureMethod": "NOW", "amount": 1234, "currency": "USD", "merchant": { "merchantSoftware": { "companyName": "Payment Company", "productName": "Application Name", "version": 1.23 } }, "paymentMethodType": { "consumerProfile": { "consumerProfileId": "EGQSGO", "paymentMethodId": "ce8dc322-0dde-4a8e-a6ca-b2c02eb37bd6" } } } ``` ## Related [Consumer Profile Management API](/docs/commerce/optimization-protection/capabilities/consumer-profile-management/index)