@@ -42,6 +42,13 @@ func ResourceTencentCloudCamUserSamlConfig() *schema.Resource {
4242 },
4343 },
4444
45+ "auxiliary_domain" : {
46+ Optional : true ,
47+ Computed : true ,
48+ Type : schema .TypeString ,
49+ Description : "auxiliary domain, like: `xxx.com`." ,
50+ },
51+
4552 "status" : {
4653 Computed : true ,
4754 Type : schema .TypeInt ,
@@ -51,7 +58,7 @@ func ResourceTencentCloudCamUserSamlConfig() *schema.Resource {
5158 "metadata_document_file" : {
5259 Type : schema .TypeString ,
5360 Optional : true ,
54- Description : "The path used to save the samlMetadat file." ,
61+ Description : "The path used to save the saml Metadata file." ,
5562 },
5663 },
5764 }
@@ -80,6 +87,10 @@ func resourceTencentCloudCamUserSamlConfigCreate(d *schema.ResourceData, meta in
8087 request .SAMLMetadataDocument = helper .String (tccommon .StringToBase64 (saml ))
8188 }
8289
90+ if v , ok := d .GetOk ("auxiliary_domain" ); ok {
91+ request .AuxiliaryDomain = helper .String (v .(string ))
92+ }
93+
8394 err := resource .Retry (tccommon .WriteRetryTimeout , func () * resource.RetryError {
8495 result , e := meta .(tccommon.ProviderMeta ).GetAPIV3Conn ().UseCamClient ().CreateUserSAMLConfig (request )
8596 if e != nil {
@@ -128,6 +139,10 @@ func resourceTencentCloudCamUserSamlConfigRead(d *schema.ResourceData, meta inte
128139 _ = d .Set ("saml_metadata_document" , metadata )
129140 }
130141
142+ if userSamlConfig .AuxiliaryDomain != nil {
143+ _ = d .Set ("auxiliary_domain" , userSamlConfig .AuxiliaryDomain )
144+ }
145+
131146 if userSamlConfig .Status != nil {
132147 _ = d .Set ("status" , userSamlConfig .Status )
133148 }
@@ -166,6 +181,12 @@ func resourceTencentCloudCamUserSamlConfigUpdate(d *schema.ResourceData, meta in
166181 }
167182 }
168183
184+ if d .HasChange ("auxiliary_domain" ) {
185+ if v , ok := d .GetOk ("auxiliary_domain" ); ok {
186+ request .AuxiliaryDomain = helper .String (v .(string ))
187+ }
188+ }
189+
169190 service := CamService {client : meta .(tccommon.ProviderMeta ).GetAPIV3Conn ()}
170191 samlConfig , describeErr := service .DescribeCamUserSamlConfigById (ctx )
171192 if describeErr != nil {
0 commit comments