MENU
      SSO Userの一括作成

        SSO Userの一括作成


        記事の要約

        Classic/VPC環境で利用できます。

        外部アカウントのユーザー情報に基づいて1つ以上の SSO Userを一括作成します。SSO Userの作成に使用した外部アカウントで NAVERクラウドプラットフォームにログインできます。

        参考

        SSO Userは最大100個まで作成できます。

        リクエスト

        リクエスト形式を説明します。リクエスト形式は次の通りです。

        メソッドURI
        POST/api/v1/users/bulk

        リクエストヘッダ

        Ncloud Single Sign-On APIで共通して使用されるヘッダの詳細は、Ncloud Single Sign-Onのリクエストヘッダをご参照ください。

        リクエストボディ

        リクエストボディの説明は次の通りです。

        フィールドタイプ必須の有無説明
        paramsArrayRequiredSSO User情報

        params

        paramsの説明は次の通りです。

        フィールドタイプ必須の有無説明
        loginIdStringRequiredSSO Userログイン ID
        • 3~60文字
        • メール形式
        • 作成後は変更不可
        descriptionStringOptionalSSO Userの説明
        • 0~300文字
        userProfileObjectOptionalSSO User Profile情報
        userProfile.firstNameStringOptionalSSO Userの名(下の名前)
        • 0~200文字
        userProfile.lastNameStringOptionalSSO Userの姓(苗字)
        • 0~200文字
        userProfile.emailStringOptionalSSO Userのメールアドレス
        • 0~200文字
        userProfile.empNoStringOptionalSSO Userの社員番号
        • 0~200文字
        userProfile.phoneCountryCodeStringOptionalSSO Userの国番号
        • 0~10文字
        • 国番号形式
        userProfile.phoneNoStringOptionalSSO Userの携帯電話番号
        • 0~200文字
        • 携帯電話番号形式
        userProfile.deptNameStringOptionalSSO Userの部署名
        • 0~200文字
        accessRulesObjectRequiredアクセスルール情報
        accessRules.consoleAccessAllowedBooleanRequiredコンソールアクセスを許可するかどうか
        • true | false
          • true: 許可
          • false: 許可しない
        accessRules.apiAccessAllowedBooleanRequiredAPI Gatewayアクセスを許可するかどうか
        • true | false
          • true: 許可
          • false: 許可しない

        リクエスト例

        リクエストのサンプルコードは次の通りです。

        curl --location POST 'https://sso.apigw.ntruss.com/api/v1/users/bulk' \
        --header 'x-ncp-apigw-timestamp: {Timestamp}' \
        --header 'x-ncp-iam-access-key: {Access Key}' \
        --header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \
        --data '{
            "params": [
                {
                    "loginId": "******@ncloud.com",
                    "description": "SSO User",
                    "userProfile": {
                        "firstName": "太郎",
                        "lastName": "田中",
                        "email": "******@ncloud.com",
                        "empNo": "0012341234",
                        "phoneCountryCode": "82",
                        "phoneNo": "010-0000-0000",
                        "deptName": "部署1"
                    },
                    "accessRules": {
                        "consoleAccessAllowed": true,
                        "apiAccessAllowed": true
                    }
                },
                {
                    "loginId": "******@ncloud.com",
                    "description": "SSO User",
                    "userProfile": {
                        "firstName": "一郎",
                        "lastName": "佐藤",
                        "email": "******@ncloud.com",
                        "empNo": "00110011",
                        "phoneCountryCode": "82",
                        "phoneNo": "010-1100-0000",
                        "deptName": "部署2"
                    },
                    "accessRules": {
                        "consoleAccessAllowed": true,
                        "apiAccessAllowed": true
                    }
                }
            ]
        }'
        Shell

        レスポンス

        レスポンス形式を説明します。

        レスポンスボディ

        レスポンスボディの説明は次の通りです。

        フィールドタイプ必須の有無説明
        idString-SSO User ID
        nameString-SSO Userログイン ID
        nrnString-SSO Userに対する NAVERクラウドプラットフォームリソースの識別値
        successBoolean-API処理結果
        • true | false
          • true: 成功
          • false: 失敗
        messageString-結果メッセージ
        • successfalseの場合、表示

        レスポンスステータスコード

        Ncloud Single Sign-On APIで共通して使用されるレスポンスステータスコードの詳細は、Ncloud Single Sign-Onのレスポンスステータスコードをご参照ください。

        レスポンス例

        レスポンスのサンプルコードは次の通りです。

        [
            {
                "id": "6b0d0df7-****-****-****-1a11f29b5c34",
                "name": "******@ncloud.com",
                "nrn": "nrn:PUB:SSO::*******:User/6b0d0df7-****-****-****-1a11f29b5c34",
                "success": true
            },
            {
                "id": "ba0def04-****-****-****-ff0b962016f7",
                "name": "******@ncloud.com",
                "nrn": "nrn:PUB:SSO::*******:User/ba0def04-****-****-****-ff0b962016f7",
                "success": true
            }
        ]
        JSON

        この記事は役に立ちましたか?

        Changing your password will log you out immediately. Use the new password to log back in.
        First name must have atleast 2 characters. Numbers and special characters are not allowed.
        Last name must have atleast 1 characters. Numbers and special characters are not allowed.
        Enter a valid email
        Enter a valid password
        Your profile has been successfully updated.