# My Payments My Payments represents [Payments](https://docs.commercetools.com/api/projects/payments.md) associated with a specific [Customer](https://docs.commercetools.com/api/projects/customers.md). The My Payments endpoints require an access token from the [password flow](https://docs.commercetools.com/api/authorization.md#password-flow) or [anonymous session flow](https://docs.commercetools.com/api/authorization.md#tokens-for-anonymous-sessions). The endpoints intentionally provide access to a limited subset of the fields on a [Payment](https://docs.commercetools.com/urn?urn=ctp%3Aapi%3Atype%3APayment). This provides extra security in scenarios when the client application must communicate directly with the API on behalf of a customer. The My Payments API can help in synchronous or asynchronous communication with a payment service provider (PSP). For example, if a client application receives a token for a credit card from a payment service, it can create a [MyPaymentDraft](https://docs.commercetools.com/api/projects/me-payments.md#mypaymentdraft) with the token, and optionally add a Transaction to authorize a certain amount. The Payment can then be passed to another service that uses the general [Payment](https://docs.commercetools.com/api/projects/payments.md) endpoint and can communicate with the PSP to charge the credit cart. This service can be triggered by a [Subscription](https://docs.commercetools.com/api/projects/subscriptions.md), or be implemented as an [API Extension](https://docs.commercetools.com/api/projects/api-extensions.md). After a [Transaction](https://docs.commercetools.com/urn?urn=ctp%3Aapi%3Atype%3ATransaction) is added to a Payment, it can no longer be updated or deleted using My Payments. ## Representations #### MyPayment See API type definition [MyPayment](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPayment). #### MyPaymentDraft See API type definition [MyPaymentDraft](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentDraft). #### MyPaymentPagedQueryResponse See API type definition [MyPaymentPagedQueryResponse](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentPagedQueryResponse). #### MyTransactionDraft See API type definition [MyTransactionDraft](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyTransactionDraft). ## Get MyPayment See API endpoint definition [GET /\{projectKey}/me/payments/\{id}](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%2F%7Bid%7D%3AGET). ## Query MyPayments See API endpoint definition [GET /\{projectKey}/me/payments](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%3AGET). ## Check if MyPayment exists ### Check if MyPayment exists by ID See API endpoint definition [HEAD /\{projectKey}/me/payments/\{id}](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%2F%7Bid%7D%3AHEAD). ### Check if MyPayment exists by Query Predicate See API endpoint definition [HEAD /\{projectKey}/me/payments](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%3AHEAD). ## Create MyPayment See API endpoint definition [POST /\{projectKey}/me/payments](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%3APOST). ## Update MyPayment See API endpoint definition [POST /\{projectKey}/me/payments/\{id}](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%2F%7Bid%7D%3APOST). ## Update actions #### Set MethodInfo Interface See API type definition [MyPaymentSetMethodInfoInterfaceAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetMethodInfoInterfaceAction). #### Set MethodInfo Method See API type definition [MyPaymentSetMethodInfoMethodAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetMethodInfoMethodAction). #### Set MethodInfo Name See API type definition [MyPaymentSetMethodInfoNameAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetMethodInfoNameAction). #### Set MethodInfo InterfaceAccount See API type definition [MyPaymentSetMethodInfoInterfaceAccountAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetMethodInfoInterfaceAccountAction). #### Set MethodInfo Custom Type See API type definition [MyPaymentSetMethodInfoCustomTypeAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetMethodInfoCustomTypeAction). #### Set MethodInfo CustomField See API type definition [MyPaymentSetMethodInfoCustomFieldAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetMethodInfoCustomFieldAction). #### Add Transaction See API type definition [MyPaymentAddTransactionAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentAddTransactionAction). #### Set CustomField See API type definition [MyPaymentSetCustomFieldAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetCustomFieldAction). #### Set Transaction CustomField See API type definition [MyPaymentSetTransactionCustomFieldAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentSetTransactionCustomFieldAction). #### Change AmountPlanned See API type definition [MyPaymentChangeAmountPlannedAction](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Atype%3AMyPaymentChangeAmountPlannedAction). ## Delete MyPayment See API endpoint definition [DELETE /\{projectKey}/me/payments/\{id}](https://docs.commercetools.com/api/projects/me-payments.md?urn=ctp%3Aapi%3Aendpoint%3A%2F%7BprojectKey%7D%2Fme%2Fpayments%2F%7Bid%7D%3ADELETE). ## Related pages - [Section overview page](https://docs.commercetools.com/api.md) - [Previous page: My Orders](https://docs.commercetools.com/api/projects/me-orders.md) - [Next page: My Shopping Lists](https://docs.commercetools.com/api/projects/me-shoppingLists.md)