--- title: "既存組織へのユーザー追加" url: https://docs.catalyst.zoho.com/ja/sdk/nodejs/v2/cloud-scale/authentication/add-new-user-to-existing-org/ description: "このページでは、NodeJS アプリケーションで既存の組織に新しいユーザーを追加する方法について、サンプルコードとともに説明します。" last_updated: 2026-03-30T08:10:30Z service: Cloud Scale type: general related_links: - name: "Add new user to existing org - API" url: /ja/api/code-reference/cloud-scale/authentication/add-user-to-existing-org/#AddaNewUsertoanExistingOrganization - name: "Authentication" url: /ja/cloud-scale/help/authentication/introduction --- # 既存組織への新規ユーザーの追加 エンドユーザーを既存の組織に追加でき、新しい組織を作成する必要はありません。これは、ユーザーを追加する組織の [**OrgID**](https://docs.catalyst.zoho.com/ja/cloud-scale/help/authentication/user-management/users/introduction/) を指定することで実行できます。ユーザーのアカウントに関連付けられた組織は、後から変更することはできません。 ユーザーがサインアップすると、[ZUID や User ID](https://docs.catalyst.zoho.com/ja/cloud-scale/help/authentication/user-management/users/introduction/) などの一意の識別値が作成されます。 > **** * 既存の組織にユーザーを追加するには、`OrgID`、`email_id`、`first_name` の値を必ず指定する必要があります。 * `role_id` を指定してロールに追加することもできます。role_id は Catalyst コンソールの Authentication 内の Roles セクションから取得できます。 * 新しいユーザーを招待する際、送信者のメールアドレス、件名、メールメッセージを設定できます。SDK コードで使用する前に、[Catalyst Mail Component](https://docs.catalyst.zoho.com/ja/cloud-scale/help/mail/email-configuration/) でメールアドレスを追加し、認証を完了させる必要があります。 ### JSON 設定の作成 Catalyst アプリケーションに新しいエンドユーザーを追加する前に、以下に示すように、特定のユーザーの登録情報を含む JSON オブジェクトを作成する必要があります。その後、この設定をユーザー登録メソッドに渡すことができます。 ```javascript //既存の組織に新しいユーザーを追加するJSONオブジェクトを作成する const signupConfig = { platform_type: 'web', template_details: { 'senders_mail':'dogogetu@tutuapp.bid', 'subject':'Welcome to %APP_NAME% ', 'message':'<p>Hello ,</p> <p>Follow this link to join in %APP_NAME% .</p> <p><a href=\'%LINK%\'>%LINK%</a></p> <p>If you didn't ask to join the application, you can ignore this email.</p> <p>Thanks,</p> <p>Your %APP_NAME% team</p>' }}; var userConfig = { first_name: 'Amelia', last_name: 'Burrows', email_id: 'emma@zylker.com', org_id: 10014774358 }; ``` ### 既存組織への新規ユーザーの追加 以下のコードを使用して、既存の組織に新しいエンドユーザーを追加できます。前のセクションで作成した JSON オブジェクトを `addUserToOrg()` メソッドの引数として渡す必要があります。このメソッドはユーザーのサインアッププロセスを処理し、Promise を返します。この Promise は JSON オブジェクトに解決されます。 コードで使用している `userManagement` の参照は、以前作成した[コンポーネントインスタンス](https://docs.catalyst.zoho.com/ja/sdk/nodejs/v2/cloud-scale/authentication/get-component-instance/)です。 > **** [開発環境](https://docs.catalyst.zoho.com/ja/deployment-and-billing/environments/development-environment)では、アプリケーションに追加できるユーザーは 25 名までです。アプリケーションを本番環境にデプロイした後は、任意の数のエンドユーザーを追加できます。 ```javascript let userManagement = app.userManagement(); let addUserPromise = userManagement.addUserToOrg(signupConfig, userConfig); //JSON設定をメソッドに渡す addUserPromise.then(addedUser => { //Promiseを返す console.log(addedUser); }); ``` 各バージョンで受信するサンプルレスポンスを以下に示します: **Node JS** ``` { zaid: "1005634498", user_details: { zuid: "1005643749", org_id: "10014774358", status: "ACTIVE", is_confirmed: false, email_id: "emma@zylker.com", first_name: "Amelia", last_name: "Burrows", created_time: "Aug 12, 2021 03:56 PM", modified_time: "Aug 12, 2021 03:56 PM", invited_time: "Aug 12, 2021 03:56 PM", role_details: { role_name: "App User", role_id: "2305000000006024" }, user_type: "App User", user_id: "2305000000009002", project_profiles: [] }, redirect_url: "https://aliencity-66446133.development.catalystserverless.com/app/", platform_type: "web", org_id: null } { zaid: 1005634498, user_details: { zuid: 1005643930, org_id: "10014774358", status: "ACTIVE", is_confirmed: false, email_id: "emma@zylker.com", first_name: "Amelia", last_name: "Burrows", created_time: "Aug 12, 2021 04:05 PM", modified_time: "Aug 12, 2021 04:05 PM", invited_time: "Aug 12, 2021 04:05 PM", role_details: { role_name: "App User", role_id: 2305000000006024 }, user_type: "App User", user_id: 2305000000009004, project_profiles: [] }, redirect_url: "https://aliencity-66446133.development.catalystserverless.com/app/", platform_type: "web", org_id: null } ```