> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cdp.coinbase.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Entity Payment Method

> Get payment method details by id for a given entity.

<Info>
  **Entity ID**

  To retrieve your entity\_id, use [List Portfolios](/api-reference/prime-api/rest-api/portfolios/list-portfolios).
</Info>

Use the Prime SDK or CLI to test this endpoint by following the [quickstart](/prime/introduction/quickstart) guide and running with the following examples

<Tabs>
  <Tab title="Java">
    ```java theme={null}
    PaymentMethodsService paymentMethodsService = PrimeServiceFactory.createPaymentMethodsService(client);

    GetEntityPaymentMethodRequest request = new GetEntityPaymentMethodRequest.Builder()
        .entityId("ENTITY_ID_HERE")
        .paymentMethodId("PAYMENT_METHOD_ID_HERE")
        .build();

    GetEntityPaymentMethodResponse response = paymentMethodsService.getEntityPaymentMethod(request);
    ```

    For more information, please visit the [Prime Java SDK](https://github.com/coinbase-samples/prime-sdk-java).
  </Tab>

  <Tab title=".NET">
    ```csharp wrap theme={null}
    var paymentMethodsService = new PaymentMethodsService(client);

    var request = new GetEntityPaymentMethodRequest("ENTITY_ID_HERE", "PAYMENT_METHOD_ID_HERE");

    var response = paymentMethodsService.GetEntityPaymentMethod(request);
    ```

    For more information, please visit the [Prime .NET SDK](https://github.com/coinbase-samples/prime-sdk-dotnet).
  </Tab>

  <Tab title="Go">
    ```go wrap theme={null}
    paymentMethodsService := paymentmethods.NewPaymentMethodsService(client)

    request := &paymentmethods.GetEntityPaymentMethodRequest{
        Id: "ENTITY_ID_HERE",
        PaymentMethodId: "PAYMENT_METHOD_ID_HERE",
    }

    response, err := paymentMethodsService.GetEntityPaymentMethod(context.Background(), request)
    ```

    For more information, please visit the [Prime Go SDK](https://github.com/coinbase-samples/prime-sdk-go).
  </Tab>

  <Tab title="Python">
    ```python wrap theme={null}
    prime_client = PrimeClient(credentials)

    request = GetEntityPaymentMethodRequest(
        entity_id="ENTITY_ID_HERE",
        payment_method_id="PAYMENT_METHOD_ID_HERE",
    )

    response = prime_client.get_entity_payment_method(request)
    ```

    For more information, please visit the [Prime Python SDK](https://github.com/coinbase-samples/prime-sdk-py).
  </Tab>

  <Tab title="CLI">
    ```bash wrap theme={null}
    primectl get-entity-payment-method --help
    ```

    For more information, please visit the [Prime CLI](https://github.com/coinbase-samples/prime-cli).
  </Tab>

  <Tab title="TS/JS">
    ```typescript wrap theme={null}
    const paymentMethodsService = new PaymentMethodsService(client);

    paymentMethodsService.getPaymentMethod({
        entityId: 'ENTITY_ID_HERE',
        paymentMethodId: 'PAYMENT_METHOD_ID_HERE'
    }).then(async (response) => {
        console.log('Payment Methods: ', response);
    })
    ```

    For more information, please visit the [Prime TS SDK](https://github.com/coinbase-samples/prime-sdk-ts).
  </Tab>
</Tabs>


## OpenAPI

````yaml GET /v1/entities/{entity_id}/payment-methods/{payment_method_id}
openapi: 3.0.1
info:
  title: REST API
  description: >-
    The Coinbase Prime REST API provides programmatic access to trading,
    custody, staking, market data, and account management functionality.
  version: '0.1'
servers:
  - url: https://api.prime.coinbase.com/
security: []
tags:
  - name: PrimeRESTAPI
paths:
  /v1/entities/{entity_id}/payment-methods/{payment_method_id}:
    get:
      tags:
        - Payment Methods
      summary: Get Entity Payment Method
      description: Get payment method details by id for a given entity.
      operationId: PrimeRESTAPI_GetEntityPaymentMethodDetails
      parameters:
        - name: entity_id
          in: path
          required: true
          schema:
            type: string
        - name: payment_method_id
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: A successful response.
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/coinbase.public_rest_api.GetEntityPaymentMethodDetailsResponse
components:
  schemas:
    coinbase.public_rest_api.GetEntityPaymentMethodDetailsResponse:
      type: object
      properties:
        details:
          $ref: '#/components/schemas/coinbase.public_rest_api.PaymentMethodDetails'
    coinbase.public_rest_api.PaymentMethodDetails:
      type: object
      properties:
        id:
          type: string
        symbol:
          type: string
        payment_method_type:
          $ref: '#/components/schemas/coinbase.public_rest_api.PaymentMethodType'
        name:
          type: string
        account_number:
          type: string
        bank_code:
          type: string
    coinbase.public_rest_api.PaymentMethodType:
      title: Indicates the payment method type
      type: string
      description: |-
        - UNKNOWN_PAYMENT_METHOD_TYPE: nil value
         - METHOD_WIRE: Wire transfer
         - METHOD_SEN: Silvergate exchange network
         - METHOD_SWIFT: Swift
      enum:
        - METHOD_WIRE
        - METHOD_SEN
        - METHOD_SWIFT

````