> ## 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.

# getUserRecords

> Solana ウォレット所有者が登録した公開シールドアドレスレコードを検索します。

## レジストリレコード

Solana 所有者の公開鍵を 1～100 個指定します。レスポンスには、リクエスト順に所有者ごとのエントリが `result.records` に 1 件ずつ含まれます。レコードを読み取ったスロットで所有者のレジストリレコードが存在しない場合、エントリは `null` になります。

レコードには、所有者の base58 ヌリファイア公開鍵と base64 閲覧公開鍵が含まれます。閲覧公開鍵は、33 バイトのタグ付き X25519 鍵です。`0x04` の後に、正規形式の 32 バイト u 座標が続きます。マージが無効な場合、`mergeEncryption` は `0` になり、PoseidonCtrV1 の場合は `1` になります。

レコードは、`context.slot` 以降のスロットで Solana から取得されます。これらは公開登録鍵です。ウォレットの鍵の取り扱いについては、[シールド鍵ペアと暗号化](https://www.helius.dev/docs/ja/privacy/concepts/encryption.md)を参照してください。

## リクエストパラメータ

**owners** `array` *required*

ユーザーレジストリで検索する Solana 公開鍵です。最大 100 個です。


## OpenAPI

````yaml ja/openapi/privacy/getUserRecords.yaml POST /v1/spr/getUserRecords
openapi: 3.0.3
info:
  title: Solana プライバシーリング API
  version: 0.51.2
  description: 暗号化された状態、履歴、証明、公開レジストリレコードに対応するプライバシーインデクサー JSON-RPC API です。
servers:
  - url: https://devnet.helius-rpc.com
    description: Devnet Solana プライバシーリング API
security: []
paths:
  /v1/spr/getUserRecords:
    post:
      summary: getUserRecords
      description: Solana ウォレットの所有者が登録した公開シールドアドレスレコードを検索します。
      operationId: getUserRecords
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - jsonrpc
                - id
                - method
                - params
              properties:
                id:
                  type: string
                  description: リクエストを識別するための ID です。
                  default: '1'
                jsonrpc:
                  type: string
                  description: JSON-RPC プロトコルのバージョンです。
                  enum:
                    - '2.0'
                  default: '2.0'
                method:
                  type: string
                  description: 呼び出すメソッドです。URL パスの最後のセグメントと一致する必要があります。
                  enum:
                    - getUserRecords
                  default: getUserRecords
                params:
                  type: object
                  required:
                    - owners
                  properties:
                    owners:
                      type: array
                      items:
                        $ref: '#/components/schemas/SerializablePubkey'
                      description: ユーザーレジストリで検索する Solana 公開鍵です。最大 100 件です。
                      maxItems: 100
                      minItems: 1
                  additionalProperties: false
                  example:
                    owners:
                      - '11111111111111111111111111111111'
            example:
              jsonrpc: '2.0'
              id: '1'
              method: getUserRecords
              params:
                owners:
                  - '11111111111111111111111111111111'
        required: true
      responses:
        '200':
          description: JSON-RPC レスポンスです。result を読み取る前に error を確認してください。
          content:
            application/json:
              schema:
                type: object
                required:
                  - jsonrpc
                  - id
                properties:
                  error:
                    type: object
                    required:
                      - code
                      - message
                    properties:
                      code:
                        type: integer
                      message:
                        type: string
                      data:
                        type: object
                        additionalProperties: true
                  id:
                    type: string
                    description: リクエスト ID です。
                  jsonrpc:
                    type: string
                    description: JSON-RPC プロトコルのバージョンです。
                    enum:
                      - '2.0'
                  result:
                    type: object
                    required:
                      - context
                      - records
                    properties:
                      context:
                        $ref: '#/components/schemas/Context'
                      records:
                        type: array
                        items:
                          type: object
                          description: ユーザーレジストリレコードです。Solana 公開鍵が公開するシールドアドレスを表します。
                          required:
                            - owner
                            - nullifierPubkey
                            - viewingPubkey
                            - mergeEncryption
                          properties:
                            mergeEncryption:
                              type: integer
                              format: uint8
                              description: >-
                                所有者が `merge_transact` で受け入れるマージ出力暗号化方式です。0
                                はマージを無効にし、1 は PoseidonCtrV1
                                を選択します。方式が選択されている間は、任意の呼び出し元がその方式でこの所有者の UTXO
                                をマージできます。
                              minimum: 0
                            nullifierPubkey:
                              allOf:
                                - $ref: '#/components/schemas/Hash'
                              description: ウォレット全体で使用する nullifier 公開鍵です。ローテーションされることはありません。
                            owner:
                              $ref: '#/components/schemas/SerializablePubkey'
                            viewingPubkey:
                              allOf:
                                - $ref: '#/components/schemas/Base64String'
                              description: >-
                                タグ付き X25519 閲覧公開鍵です（0x04 の後に正規形式の 32 バイトの u
                                座標が続きます）。
                          additionalProperties: false
                          nullable: true
                        description: >-
                          リクエストされた所有者ごとに、リクエスト順で 1
                          つのエントリが返されます。レコードの読み取り時点のスロットで所有者にレジストリレコードがない場合は
                          `null` です。このスロットは `context.slot` より前にはなりません。
                    additionalProperties: false
              example:
                jsonrpc: '2.0'
                id: '1'
                result:
                  context:
                    slot: 4242
                    blockTime: 1730000000
                  records:
                    - null
        '400':
          description: >-
            実行前に拒否されました。メソッドとパスの不一致、メソッドフィールドの重複、またはバッチリクエストの場合は -32601
            が返されます。読み取れない、またはサイズ超過の本文の場合は -32600 が返されます。
          content:
            application/json:
              schema:
                type: object
                required:
                  - jsonrpc
                  - id
                  - error
                properties:
                  jsonrpc:
                    type: string
                    enum:
                      - '2.0'
                  id:
                    type: string
                    nullable: true
                    description: リクエスト ID です。本文が単一の JSON-RPC 呼び出しでない場合は null です。
                  error:
                    type: object
                    required:
                      - code
                      - message
                    properties:
                      code:
                        type: integer
                      message:
                        type: string
                      data:
                        type: object
                        additionalProperties: true
        '429':
          description: レート制限を超過しました。
          content:
            application/json:
              schema:
                type: object
                required:
                  - jsonrpc
                  - id
                  - error
                properties:
                  jsonrpc:
                    type: string
                    enum:
                      - '2.0'
                  id:
                    type: string
                    nullable: true
                    description: リクエスト ID です。本文が単一の JSON-RPC 呼び出しでない場合は null です。
                  error:
                    type: object
                    required:
                      - code
                      - message
                    properties:
                      code:
                        type: integer
                      message:
                        type: string
                      data:
                        type: object
                        additionalProperties: true
        '500':
          description: 内部サーバーエラーです。
          content:
            application/json:
              schema:
                type: object
                required:
                  - jsonrpc
                  - id
                  - error
                properties:
                  jsonrpc:
                    type: string
                    enum:
                      - '2.0'
                  id:
                    type: string
                    nullable: true
                    description: リクエスト ID です。本文が単一の JSON-RPC 呼び出しでない場合は null です。
                  error:
                    type: object
                    required:
                      - code
                      - message
                    properties:
                      code:
                        type: integer
                      message:
                        type: string
                      data:
                        type: object
                        additionalProperties: true
      security:
        - ApiKeyQuery: []
components:
  schemas:
    SerializablePubkey:
      type: string
      description: base58 でエンコードされた Solana 公開鍵です。
    Context:
      type: object
      required:
        - blockTime
        - slot
      properties:
        blockTime:
          type: integer
          format: int64
        slot:
          type: integer
          format: uint64
          description: スロットに基づいて鮮度を確認するために、インデクサーが永続化した最も高いスロットです。
          minimum: 0
    Hash:
      type: string
      description: base58 でエンコードされた 32 バイトのハッシュです。
    Base64String:
      type: string
      description: base64 でエンコードされたバイト文字列です。
  securitySchemes:
    ApiKeyQuery:
      type: apiKey
      in: query
      name: api-key
      description: Helius API キーです。

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.