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

# ユーザー一覧を取得

> 会社のユーザーを、無効なユーザーも含めて一覧表示します。`auth.view_user` が必要です。通常の一覧と検索では、会社の管理者、staff権限を持つユーザー、サービスアカウントを除外します。大文字と小文字を区別しないメールアドレスの完全一致検索では、会社の管理者も対象です。



## OpenAPI

````yaml /ja/api-reference/openapi.json get /users
openapi: 3.0.0
info:
  title: Corgea API
  version: 1.0.0
  description: Corgeaのスキャン機能および脆弱性管理機能を操作するためのAPI
servers:
  - url: https://www.corgea.app/api/v1
    description: 本番サーバー
  - url: https://eu.corgea.app/api/v1
    description: EU本番サーバー
security:
  - CorgeaToken: []
  - BearerAuth: []
paths:
  /users:
    get:
      tags:
        - Users
      summary: ユーザー一覧を取得
      description: >-
        会社のユーザーを、無効なユーザーも含めて一覧表示します。`auth.view_user`
        が必要です。通常の一覧と検索では、会社の管理者、staff権限を持つユーザー、サービスアカウントを除外します。大文字と小文字を区別しないメールアドレスの完全一致検索では、会社の管理者も対象です。
      operationId: listUsers
      parameters:
        - name: page
          in: query
          schema:
            type: integer
            minimum: 1
            default: 1
        - name: page_size
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 50
            default: 20
        - name: search
          in: query
          schema:
            type: string
          description: メールアドレス、名、姓で絞り込みます。
        - name: email
          in: query
          schema:
            type: string
          description: 大文字と小文字を区別しないメールアドレスの完全一致検索。
      responses:
        '200':
          description: リクエストが成功しました
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: ok
                  users:
                    type: array
                    items:
                      $ref: '#/components/schemas/CompanyUser'
                  page:
                    type: integer
                  total_pages:
                    type: integer
                  total_users:
                    type: integer
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
components:
  schemas:
    CompanyUser:
      type: object
      properties:
        id:
          type: integer
        email:
          type: string
          format: email
        first_name:
          type: string
        last_name:
          type: string
        active:
          type: boolean
        roles:
          type: array
          items:
            $ref: '#/components/schemas/UserRole'
        created_at:
          type: string
          format: date-time
    UserRole:
      type: object
      properties:
        id:
          type: integer
        name:
          type: string
  responses:
    Unauthorized:
      description: トークンが無効か、指定されていません
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Missing or invalid authorization header
    Forbidden:
      description: 権限がないか、機能を利用できません
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Permission denied
  securitySchemes:
    CorgeaToken:
      type: apiKey
      in: header
      name: CORGEA-TOKEN
      description: 認証用のAPIキー 無効なユーザーのAPIトークンは拒否されます。
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Authorizationヘッダーで使用するOAuth2アクセストークン（JWT）

````

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