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

# getTokenAccountsByDelegate

> 승인된 위임자를 기준으로 모든 SPL 토큰 계정을 반환합니다.

## 요청 매개변수

<ParamField body="address" type="string" required>
  토큰 계정을 관리하도록 승인된 위임자의 Solana 주소(공개 키).
</ParamField>

<ParamField body="mint" type="string">
  특정 토큰 유형으로 위임된 계정을 필터링하기 위한 토큰 민트 주소.
</ParamField>

<ParamField body="programId" type="string">
  위임된 계정을 필터링하기 위한 특정 토큰 프로그램 ID(일반적으로 SPL 토큰 프로그램).
</ParamField>

<ParamField body="commitment" type="string">
  요청에 대한 커밋 수준.

  * `confirmed`
  * `finalized`
  * `processed`
</ParamField>

<ParamField body="minContextSlot" type="number">
  요청을 평가할 수 있는 최소 슬롯.
</ParamField>

<ParamField body="dataSlice" type="object">
  계정의 데이터 조각을 요청합니다.
</ParamField>

<ParamField body="dataSlice.length" type="number">
  반환할 바이트 수.
</ParamField>

<ParamField body="dataSlice.offset" type="number">
  읽기 시작할 바이트 오프셋.
</ParamField>

<ParamField body="encoding" type="string">
  계정 데이터에 대한 인코딩 형식.

  * `base58`
  * `base64`
  * `base64+zstd`
  * `jsonParsed`
</ParamField>


## OpenAPI

````yaml ko/openapi/rpc-http/getTokenAccountsByDelegate.yaml POST /
openapi: 3.1.0
info:
  title: Solana RPC API
  version: 1.0.0
  description: >-
    대리 토큰 권한을 쿼리하기 위한 고급 Solana API로, 애플리케이션이 특정 권한을 제3자 주소에 부여한 모든 SPL 토큰 계정을
    검색할 수 있도록 합니다.
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
servers:
  - url: https://mainnet.helius-rpc.com
    description: 메인넷 RPC 엔드포인트
  - url: https://devnet.helius-rpc.com
    description: Devnet RPC 엔드포인트
security: []
paths:
  /:
    post:
      tags:
        - RPC
      summary: getTokenAccountsByDelegate
      description: >
        특정 Solana 주소에 권한을 위임한 모든 SPL 토큰 계정을 검색합니다.

        이 강력한 API는 지출 또는 관리 권한을 제3자 애플리케이션, 지갑, 또는 다른 위임 주소에 부여 받은 모든 토큰 계정을
        식별합니다. 보안 모니터링, 위임 추적 및 애플리케이션에서 관리 또는 지출 권한을 가진 토큰 계정을 발견해야 할 때 필수적입니다.
        특정 토큰 유형과 위임 권한 수준에 따라 필터링을 지원하며, 쉽게 통합할 수 있는 파싱된 데이터를 제공합니다.
      operationId: getTokenAccountsByDelegate
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                jsonrpc:
                  type: string
                  enum:
                    - '2.0'
                  description: JSON-RPC 프로토콜 버전입니다.
                  example: '2.0'
                  default: '2.0'
                id:
                  type: string
                  description: 요청에 대한 고유 식별자입니다.
                  example: '1'
                  default: '1'
                method:
                  type: string
                  enum:
                    - getTokenAccountsByDelegate
                  description: 호출할 RPC 메서드의 이름입니다.
                  example: getTokenAccountsByDelegate
                  default: getTokenAccountsByDelegate
                params:
                  type: array
                  description: 대리로 지정된 토큰 계정을 쿼리하기 위한 매개변수입니다.
                  default:
                    - 4Nd1mBQtrMJVYVfKf2PJy9NZUZdTAsp7D4xWLs4gDB4T
                    - programId: TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA
                    - encoding: jsonParsed
                  items:
                    oneOf:
                      - type: string
                        description: 토큰 계정을 관리하도록 권한이 부여된 대리의 Solana 주소(공개 키)입니다.
                        example: 4Nd1mBQtrMJVYVfKf2PJy9NZUZdTAsp7D4xWLs4gDB4T
                      - type: object
                        description: 결과를 특정 토큰 유형 또는 프로그램으로 좁히기 위한 필터 구성입니다.
                        properties:
                          mint:
                            type: string
                            description: 특정 토큰 유형에 의해 대리 계정을 필터링하기 위한 특정 토큰 민트 주소입니다.
                            example: 3wyAj7Rt1TWVPZVteFJPLa26JmLvdb1CAKEFZm3NY75E
                          programId:
                            type: string
                            description: >-
                              대리 계정을 필터링하기 위한 특정 토큰 프로그램 ID(일반적으로 SPL 토큰
                              프로그램)입니다.
                            example: TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA
                      - type: object
                        description: 구성 객체입니다.
                        properties:
                          commitment:
                            type: string
                            description: 요청에 대한 약속 레벨입니다.
                            enum:
                              - confirmed
                              - finalized
                              - processed
                            example: finalized
                          minContextSlot:
                            type: integer
                            description: 요청을 평가할 수 있는 최소 슬롯입니다.
                            example: 1000
                          dataSlice:
                            type: object
                            description: 계정의 데이터에서 슬라이스를 요청합니다.
                            properties:
                              length:
                                type: integer
                                description: 반환할 바이트 수입니다.
                                example: 10
                              offset:
                                type: integer
                                description: 읽기를 시작할 바이트 오프셋입니다.
                                example: 0
                          encoding:
                            type: string
                            description: 계정 데이터의 인코딩 형식입니다.
                            enum:
                              - base58
                              - base64
                              - base64+zstd
                              - jsonParsed
                            example: jsonParsed
      responses:
        '200':
          description: 대리로 지정된 토큰 계정을 성공적으로 검색했습니다.
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    type: string
                    description: JSON-RPC 프로토콜 버전입니다.
                    enum:
                      - '2.0'
                    example: '2.0'
                  id:
                    type: string
                    description: 요청에 일치하는 식별자입니다.
                    example: '1'
                  result:
                    type: object
                    description: 컨텍스트 및 계정 세부 정보입니다.
                    properties:
                      context:
                        type: object
                        description: 응답의 컨텍스트입니다.
                        properties:
                          slot:
                            type: integer
                            description: 데이터가 가져온 슬롯입니다.
                            example: 1114
                      value:
                        type: array
                        description: 토큰 계정 목록입니다.
                        items:
                          type: object
                          properties:
                            pubkey:
                              type: string
                              description: 기본 58로 인코딩된 문자열로 계정 공개 키입니다.
                              example: 28YTZEwqtMHWrhWcvv34se7pjS7wctgqzCPB3gReCFKp
                            account:
                              type: object
                              description: 토큰 계정 세부 정보입니다.
                              properties:
                                lamports:
                                  type: integer
                                  description: 계정에 할당된 lamport의 수입니다.
                                  example: 1726080
                                owner:
                                  type: string
                                  description: 이 계정이 할당된 프로그램의 공개 키입니다.
                                  example: TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA
                                data:
                                  type: object
                                  description: 계정과 연관된 토큰 상태 데이터입니다.
                                  properties:
                                    program:
                                      type: string
                                      description: 프로그램 이름입니다.
                                      example: spl-token
                                    parsed:
                                      type: object
                                      description: 파싱된 토큰 데이터입니다.
                                      properties:
                                        info:
                                          type: object
                                          description: 토큰 계정 정보입니다.
                                          properties:
                                            tokenAmount:
                                              type: object
                                              description: 토큰 양 세부 정보입니다.
                                              properties:
                                                amount:
                                                  type: string
                                                  description: 소수점 없는 원시 잔액입니다.
                                                  example: '1'
                                                decimals:
                                                  type: integer
                                                  description: 소수점의 수입니다.
                                                  example: 1
                                                uiAmount:
                                                  type: number
                                                  description: 사용자 친화적인 형식의 잔액입니다.
                                                  example: 0.1
                                                uiAmountString:
                                                  type: string
                                                  description: 문자열로 된 잔액입니다.
                                                  example: '0.1'
                                            delegate:
                                              type: string
                                              description: >-
                                                토큰을 관리하거나 지출하기 위해 대리 권한이 부여된 Solana
                                                주소입니다.
                                              example: >-
                                                4Nd1mBQtrMJVYVfKf2PJy9NZUZdTAsp7D4xWLs4gDB4T
                                            delegatedAmount:
                                              type: object
                                              description: >-
                                                소유자를 대신하여 대리자가 지출할 수 있도록 권한이 부여된 토큰의
                                                양입니다.
                                              properties:
                                                amount:
                                                  type: string
                                                  description: 소수점 없는 원시 잔액입니다.
                                                  example: '1'
                                                decimals:
                                                  type: integer
                                                  description: 소수점의 수입니다.
                                                  example: 1
                                                uiAmount:
                                                  type: number
                                                  description: 사용자 친화적인 형식의 잔액입니다.
                                                  example: 0.1
                                                uiAmountString:
                                                  type: string
                                                  description: 문자열로 된 잔액입니다.
                                                  example: '0.1'
                                        state:
                                          type: string
                                          description: 토큰 계정 상태입니다.
                                          example: initialized
                                        isNative:
                                          type: boolean
                                          description: 계정이 네이티브 SOL을 보유하고 있는지 여부를 나타냅니다.
                                          example: false
                                        mint:
                                          type: string
                                          description: 토큰 민트의 공개 키입니다.
                                          example: >-
                                            3wyAj7Rt1TWVPZVteFJPLa26JmLvdb1CAKEFZm3NY75E
                                        owner:
                                          type: string
                                          description: 계정 소유자의 공개 키입니다.
                                          example: >-
                                            CnPoSPKXu7wJqxe59Fs72tkBeALovhsCxYeFwPCQH9TD
                                    space:
                                      type: integer
                                      description: 계정에 할당된 공간입니다.
                                      example: 165
                                executable:
                                  type: boolean
                                  description: 계정이 프로그램을 포함하고 있는지 여부를 나타냅니다.
                                  example: false
                                rentEpoch:
                                  type: integer
                                  description: 계정이 다음번에 임대료를 지불해야 하는 시점의 에포크입니다.
                                  example: 4
                                space:
                                  type: integer
                                  description: 계정의 데이터 크기입니다.
                                  example: 165
              examples:
                response:
                  value:
                    jsonrpc: '2.0'
                    id: '1'
                    result:
                      context:
                        slot: 1114
                      value:
                        - pubkey: 28YTZEwqtMHWrhWcvv34se7pjS7wctgqzCPB3gReCFKp
                          account:
                            lamports: 1726080
                            owner: TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA
                            data:
                              program: spl-token
                              parsed:
                                info:
                                  tokenAmount:
                                    amount: '1'
                                    decimals: 1
                                    uiAmount: 0.1
                                    uiAmountString: '0.1'
                                  delegate: 4Nd1mBQtrMJVYVfKf2PJy9NZUZdTAsp7D4xWLs4gDB4T
                                  delegatedAmount:
                                    amount: '1'
                                    decimals: 1
                                    uiAmount: 0.1
                                    uiAmountString: '0.1'
                                  state: initialized
                                  isNative: false
                                  mint: 3wyAj7Rt1TWVPZVteFJPLa26JmLvdb1CAKEFZm3NY75E
                                  owner: CnPoSPKXu7wJqxe59Fs72tkBeALovhsCxYeFwPCQH9TD
                                type: account
                              space: 165
                            executable: false
                            rentEpoch: 4
                            space: 165
        '400':
          description: 잘못된 요청 - 잘못된 요청 매개변수 또는 잘못된 요청입니다.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                jsonrpc: '2.0'
                error:
                  code: -32602
                  message: Invalid params
                id: '1'
        '401':
          description: Unauthorized - 잘못되었거나 누락된 API 키입니다.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                jsonrpc: '2.0'
                error:
                  code: -32001
                  message: Unauthorized
                id: '1'
        '429':
          description: Too Many Requests - 요청 한도를 초과했습니다.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                jsonrpc: '2.0'
                error:
                  code: -32005
                  message: Too many requests
                id: '1'
        '500':
          description: 내부 서버 오류 - 서버에서 오류가 발생했습니다.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                jsonrpc: '2.0'
                error:
                  code: -32603
                  message: Internal error
                id: '1'
        '503':
          description: Service Unavailable - 서비스가 일시적으로 사용 불가능합니다.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                jsonrpc: '2.0'
                error:
                  code: -32002
                  message: Service unavailable
                id: '1'
        '504':
          description: 게이트웨이 타임아웃 - 요청이 시간 초과되었습니다.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                jsonrpc: '2.0'
                error:
                  code: -32003
                  message: Gateway timeout
                id: '1'
      security:
        - ApiKeyQuery: []
components:
  schemas:
    ErrorResponse:
      type: object
      properties:
        jsonrpc:
          type: string
          description: JSON-RPC 프로토콜 버전입니다.
          enum:
            - '2.0'
          example: '2.0'
        error:
          type: object
          properties:
            code:
              type: integer
              description: 오류 코드입니다.
              example: -32602
            message:
              type: string
              description: 오류 메시지입니다.
            data:
              type: object
              description: 오류에 대한 추가 데이터입니다.
        id:
          type: string
          description: 요청에 일치하는 식별자입니다.
          example: '1'
  securitySchemes:
    ApiKeyQuery:
      type: apiKey
      in: query
      name: api-key
      description: >-
        Helius API 키입니다. [대시보드](https://dashboard.helius.dev/api-keys)에서 무료로 받을
        수 있습니다.

````