> ## 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 Portfolio Counterparty ID

> Retrieve the counterparty ID for a given portfolio.



## OpenAPI

````yaml get /v1/portfolios/{portfolio_id}/counterparty
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/portfolios/{portfolio_id}/counterparty:
    get:
      tags:
        - Advanced Transfer
      summary: Get Portfolio Counterparty ID
      description: Retrieve the counterparty ID for a given portfolio.
      operationId: PrimeRESTAPI_GetPortfolioCounterpartyID
      parameters:
        - name: portfolio_id
          in: path
          description: The portfolio ID
          required: true
          schema:
            type: string
      responses:
        '200':
          description: A successful response.
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/coinbase.public_rest_api.GetPortfolioCounterpartyIDResponse
components:
  schemas:
    coinbase.public_rest_api.GetPortfolioCounterpartyIDResponse:
      type: object
      properties:
        counterparty:
          $ref: '#/components/schemas/coinbase.public_rest_api.Counterparty'
    coinbase.public_rest_api.Counterparty:
      type: object
      properties:
        counterparty_id:
          type: string
          description: The unique counterparty ID for the portfolio
          example: CB12345678

````