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

# Auth

> ローカル設定ファイルを使用してアプリのログイン方法を管理します

<div className="dev-docs-banner">
  <div className="dev-docs-banner-content">
    <div className="dev-docs-banner-title">
      開発者向けドキュメントを表示しています
    </div>

    <div className="dev-docs-banner-text">
      このドキュメントは、Base44 開発者プラットフォームで作業する開発者向けです。アプリエディタでのログイン方法の管理については、<a href="/Setting-up-your-app/Managing-login-and-registration">ログインと登録の管理</a>を参照してください。
    </div>
  </div>
</div>

認証は、アプリのユーザーがどのようにサインインし、登録し、機能にアクセスするかを制御します。Auth config を使用すると、CLI を使用して Base44 と同期するローカル JSONC ファイルとしてログイン方法を管理できます。

## 設定

auth config は `base44/auth/config.jsonc` の単一の JSONC ファイルです。[プロジェクト構成](/developers/backend/overview/project-structure#config-jsonc)の `authDir` プロパティでディレクトリパスをカスタマイズできます。Base44 から現在の設定を [`auth pull`](/developers/references/cli/commands/auth-pull) でプルし、その後変更を [`auth push`](/developers/references/cli/commands/auth-push) または [`deploy`](/developers/references/cli/commands/deploy) でプッシュしてください。

[`auth password-login`](/developers/references/cli/commands/auth-password-login) と [`auth social-login`](/developers/references/cli/commands/auth-social-login) を使用してコマンドラインからもログイン方法を切り替えることができます。

## 例

```jsonc theme={null}
{
  "enableUsernamePassword": true,
  "enableGoogleLogin": false,
  "enableMicrosoftLogin": false,
  "enableFacebookLogin": false,
  "enableAppleLogin": false,
  "googleOAuthMode": "default",
  "googleOAuthClientId": null
}
```

## フィールドリファレンス

<ResponseField name="enableUsernamePassword" type="boolean">
  ユーザーがメールアドレスとパスワードでサインインできるようにします。デフォルトは `false`。
</ResponseField>

<ResponseField name="enableGoogleLogin" type="boolean">
  ユーザーが Google でサインインできるようにします。デフォルトは `false`。
</ResponseField>

<ResponseField name="enableMicrosoftLogin" type="boolean">
  ユーザーが Microsoft でサインインできるようにします。デフォルトは `false`。
</ResponseField>

<ResponseField name="enableFacebookLogin" type="boolean">
  ユーザーが Facebook でサインインできるようにします。デフォルトは `false`。
</ResponseField>

<ResponseField name="enableAppleLogin" type="boolean">
  ユーザーが Apple でサインインできるようにします。デフォルトは `false`。
</ResponseField>

<ResponseField name="googleOAuthMode" type="&#x22;default&#x22; | &#x22;custom&#x22;">
  Google OAuth 認証情報のソース方法。Base44 管理の認証情報を使用するには `default` を、独自の OAuth クライアントを使用するには `custom` を使用します。デフォルトは `default`。
</ResponseField>

<ResponseField name="googleOAuthClientId" type="string | null">
  カスタム Google OAuth クライアント ID。`googleOAuthMode` が `custom` のときのみ使用されます。これを [`auth social-login google enable --client-id`](/developers/references/cli/commands/auth-social-login) で設定してください。対応するクライアントシークレットは、このファイルではなくプロジェクトシークレットとして保存されます。デフォルトは `null`。
</ResponseField>

<Warning>
  設定にログイン方法が有効になっていない場合、プッシュ時にユーザーがロックアウトされることを CLI が警告します。少なくとも 1 つのログイン方法を有効にしてください。
</Warning>

## 関連項目

* [`auth pull`](/developers/references/cli/commands/auth-pull): Base44 から auth config をフェッチ
* [`auth push`](/developers/references/cli/commands/auth-push): auth config を Base44 にプッシュ
* [`auth password-login`](/developers/references/cli/commands/auth-password-login): パスワードログインを有効/無効化
* [`auth social-login`](/developers/references/cli/commands/auth-social-login): ソーシャルログインプロバイダーを有効/無効化
* [`deploy`](/developers/references/cli/commands/deploy): すべてのプロジェクトリソースをデプロイ
* [Managing login and registration](/Setting-up-your-app/Managing-login-and-registration): ダッシュボードでログインオプションを構成

<Note>このページは AI を使用して翻訳されました。最も正確で最新の情報については、[英語版](/) を参照してください。 </Note>
