User operations

This section describes the adapter requests and responses for the User operations.

Tip

Use the <items> element when you call an adapter from an out-of-the-box process in TrueSight Orchestration Development Studio. Use the adapter request XML when you create a custom process by using the Call Adapter activity in TrueSight Orchestration Development Studio.

Get Users

The Get Users operation retrieves the list of users in the TrueSight Network Automation database. 

The following table describes the input elements for the Get Users operation.

Input elements for the adapter request for the Get Users operation

Input parameter nameDescriptionTypeRequired
<operation-name>

Specifies the name of the operation that retrieves all users.

Process path: RBA-AD-BMC_Configuration_Automation_Networks:v8.9:User:Get Users

Valid value: get-users

--
adapter name

Specifies the name of the adapter to use to run the request.

Default value: BCANActor

StringNo
connection parameters

Contains the additional connection parameters required for the adapter to connect to TrueSight Network Automation.

Sample:

<connection-parameters>
	<soap-url>hostname:443</soap-url>
 	<user-name>sysadmin</user-name>
 	<password>password</password>
	<soap-version>1.1</soap-version>
</connection-parameters> 

Contains the following child elements:

  • <soap-url>: Specifies the URL for the remote SOAP service for TrueSight Network Automation.

  • <user-name>: Specifies the username required to connect to the target.
  • <password>: Specifies the password that matches the username.
  • <soap-version>: Specifies the SOAP version to use. Valid values: 1.1 (default), 1.2
XMLNo


The following figure shows a sample adapter request for the Get Users operation.

Sample adapter request for the Get Users operation 

<bmc-configuration-automation-networks-request>
    <entity>user</entity>
    <request>
      <operation-name>get-users</operation-name>
      <parameters />
    </request>
  </bmc-configuration-automation-networks-request>

The following figure illustrates the response for the sample Get Users operation.

Adapter response for the sample Get Users operation 


Get User by Key

The Get User by Key operation retrieves the user details from the TrueSight Network Automation database by using a specific user key. 

The following table describes the elements for the <items> XML element and adapter request for the Get Users by Key operation.

Elements for the <items> XML element and adapter request for the Get Users by Key operation

ElementDefinitionRequired
<user-key>Specifies the user key required to retrieve the user details.Yes

The following figure shows a sample <items> XML element for the Get Users by Key operation.

<items> XML element for the Get Users by Key operation 

<items>
    <item>
    <parameters>
    <user-key>9861234527-11</user-key>
    </parameters>
     </item>
</items>

The following table describes the input elements for the Get Users by Key operation.

Input elements for the Get Users by Key operation

Input nameDescriptionTypeRequired
adapter name

Specifies the name of the adapter to use to run the request.

Default value: BCANActor

StringNo
items

Specifies the <items>XML that contains the user key.

XMLYes
connection parameters

Contains the additional connection parameters required for the adapter to connect to TrueSight Network Automation.

Example
<connection-parameters>
	<soap-url>hostname:443</soap-url>
 	<user-name>sysadmin</user-name>
 	<password>password</password>
	<soap-version>1.1</soap-version>
</connection-parameters> 


Contains the following child elements:

  • <soap-url>: Specifies the URL for the remote SOAP service for TrueSight Network Automation.

  • <user-name>: Specifies the username required to connect to the target.
  • <password>: Specifies the password that matches the username.
  • <soap-version>: Specifies the SOAP version to use. Valid values: 1.1 (default), 1.2
XMLNo


The following figure shows a sample adapter request for the Get Users by Key operation.

Sample adapter request for the Get Users by Key operation 

<bmc-configuration-automation-networks-request>
    <entity>user</entity>
    <request>
      <operation-name>get-user-by-key</operation-name>
      <parameters>
        <user-key>9861234527-11</user-key>
      </parameters>
    </request>
  </bmc-configuration-automation-networks-request>

The following figure illustrates the response for the sample Get Users by Key operation.

Adapter response for the sample Get Users by Key operation 

Get User by Name

The Get Users by Name operation retrieves the details for a user TrueSight Network Automation database by using the specified user name. 

The following table describes the elements for the <items> XML element and adapter request for the Get Users by Name operation.

Elements for the <items> XML element and adapter request for the Get Users by Name operation

ElementDefinitionRequired
<name>Specifies the name of the userYes

The following figure shows a sample <items> XML element for the Get Users by Name operation.

<items> XML element for the Get Users by Name operation 

<items>
    <item>
    <parameters>
    <name>Allen</name>
    </parameters>
     </item>
</items>

The following table describes the input elements for the Get Users by Name operation.

Input elements for the Get Users by Name operation

Input nameDescriptionTypeRequired
adapter name

Specifies the name of the adapter to use to run the request.

Default value: BCANActor

StringNo
items

Specifies the <items>XML that contains the user name.

XMLYes
connection parameters

Contains the additional connection parameters required for the adapter to connect to TrueSight Network Automation.

Example
<connection-parameters>
	<soap-url>hostname:443</soap-url>
 	<user-name>sysadmin</user-name>
 	<password>password</password>
	<soap-version>1.1</soap-version>
</connection-parameters> 


Contains the following child elements:

  • <soap-url>: Specifies the URL for the remote SOAP service for TrueSight Network Automation.

  • <user-name>: Specifies the username required to connect to the target.
  • <password>: Specifies the password that matches the username.
  • <soap-version>: Specifies the SOAP version to use. Valid values: 1.1 (default), 1.2
XMLNo

The following figure shows a sample adapter request for the Get Users by Name operation.

Sample adapter request for the Get Users by Name operation 

<bmc-configuration-automation-networks-request>
    <entity>user</entity>
    <request>
      <operation-name>get-user-by-name</operation-name>
      <parameters>
        <name>Allen</name>
      </parameters>
    </request>
  </bmc-configuration-automation-networks-request>

The following figure illustrates the response for the sample Get Users by Name operation.

Adapter response for the sample Get Users by Name operation 

<bmc-configuration-automation-networks-response>
  <metadata>
    <status>success</status>
  </metadata>
  <parameters>
    <output>
      <account-created-on>1556628155569</account-created-on>
      <dynamic-fields>
        <element>
          <name>Full Name</name>
          <values>
            <element>Allen Albrook</element>
          </values>
        </element>
      </dynamic-fields>
      <email-address>ab@bmc.com</email-address>
      <enabled>true</enabled>
      <encrypted-password>****MASKED****</encrypted-password>
      <force-password-change>****MASKED****</force-password-change>
      <key>98699527-29</key>
      <last-password-change>****MASKED****</last-password-change>
      <last-successful-login>1556628275403</last-successful-login>
      <password-never-expires>****MASKED****</password-never-expires>
      <realm-role-name>com.bmc.bcan.engine.user.security.User.DEFAULT_REALM_ROLE_NAME</realm-role-name>
      <roles>
        <element>Administrator</element>
      </roles>
      <root-account>false</root-account>
      <user-name>Allen</user-name>
    </output>
  </parameters>
</bmc-configuration-automation-networks-response>

Add User

The Add User operation add a new user in TrueSight Network Automation. 

The following table describes the elements for the <items> XML element and adapter request for the Add User operation.

Elements for the <items> XML element and adapter request for the Add User operation

ElementDefinitionTypeRequired
<user-dto>

Contains the following child elements for providing additional information
for adding a user (except <cleartext-password>):

  • <dynamic-fields>
  • <email-address>
  • <enabled>
  • <force-password-change>
  • <password-never-expires>
  • <realm-role-name>
  • <roles>
  • <root-account>
  • <user-name>
XMLYes
<dynamic-fields>

Specifies the XML to provide the full name of a new user in a key-value pair.

Example
<dynamic-fields>
    <element>
       <name>Full Name</name>
       <values>
	<element>Abhi Kumar</element>
       </values>
    </element>
</dynamic-fields>
XMLYes
<email-address>Specifies the email address of the new userStringYes
<enabled>

Specifies whether to enable the user after creation.

Valid values: true (default), false.

BooleanNo
<force-password-change>

Specifies whether to make the user change the password after creation.

Valid values: true (default), false.

BooleanNo
<password-never-expires>

Specifies whether to create a user with a password that never expires.

Valid values: true, false (default).

BooleanNo
<realm-role-name>Specifies the name of the realm to be used.StringNo
<roles>

Specifies the role name, in XML. You can assign more than one role to a user.

Example
<roles>
 <!--zero or more array elements follow-->
 <element>Administrator</element>
</roles>
XMLYes
<root-account>

Specifies whether the user should have a root account.

Valid values: true, false (default).

BooleanNo
<user-name>Specifies the username for the new user.StringYes
<cleartext-password>Specifies the password for the new user.StringYes

The following figure shows a sample <items> XML element for the Add User operation.

<items> XML element for the Add User operation 

<items>
   <item>
      <parameters>
          <user-dto>
              <dynamic-fields>                    
                    <element>
                      <name>Full Name</name>
                      <values>
                        <element>Abhi Kumar</element>
                      </values>
                    </element>
              </dynamic-fields>
              <email-address>ag@bmc.com</email-address>
              <enabled>true</enabled>
              <force-password-change>false</force-password-change>
              <password-never-expires>true</password-never-expires>
              <realm-role-name>a</realm-role-name>
              <roles>
               <!--zero or more array elements follow-->
               <element>Administrator</element>
              </roles>
              <root-account>false</root-account>
              <user-name>aguser</user-name>           
          </user-dto>
          <cleartext-password>adminpassword</cleartext-password>
     </parameters>
   </item>
</items>

The following table describes the input elements for the Add User operation.

Input elements for the Add User operation

Input nameDescriptionTypeRequired
adapter name

Specifies the name of the adapter to use to run the request.

Default value: BCANActor

StringNo
items

Specifies the <items>XML that contains the user name and other details to create a new user.

XMLYes
connection parameters

Contains the additional connection parameters required for the adapter to connect to TrueSight Network Automation.

Example
<connection-parameters>
	<soap-url>hostname:443</soap-url>
 	<user-name>sysadmin</user-name>
 	<password>password</password>
	<soap-version>1.1</soap-version>
</connection-parameters> 


Contains the following child elements:

  • <soap-url>: Specifies the URL for the remote SOAP service for TrueSight Network Automation.

  • <user-name>: Specifies the username required to connect to the target.
  • <password>: Specifies the password that matches the username.
  • <soap-version>: Specifies the SOAP version to use. Valid values: 1.1 (default), 1.2
XMLNo

The following figure shows a sample adapter request for the Add User operation.

Sample adapter request for the Add User operation 

<bmc-configuration-automation-networks-request>
      <entity>user</entity>
      <request>
        <operation-name>add-user</operation-name>
        <parameters>
          <user-dto>
            <dynamic-fields>
              <!--zero or more array elements follow-->
              <element>
                <name>Full Name</name>
                <values>
                  <!--zero or more array elements follow-->
                  <element>Abhi</element>
                </values>
              </element>
            </dynamic-fields>
            <email-address>ag@bmc.com</email-address>
            <enabled>true</enabled>
            <force-password-change>false</force-password-change>
            <password-never-expires>true</password-never-expires>
            <roles>
              <!--zero or more array elements follow-->
              <element>Administrator</element>
            </roles>
            <root-account>false</root-account>
            <user-name>aggupta</user-name>
          </user-dto>
          <cleartext-password>admin123</cleartext-password>
        </parameters>
      </request>
    </bmc-configuration-automation-networks-request>

The following figure illustrates the response for the sample Add User operation.

Adapter response for the sample Add User operation 

<bmc-configuration-automation-networks-response>
  <metadata>
    <status>success</status>
  </metadata>
  <parameters>
    <output>98699527-22</output>
  </parameters>
</bmc-configuration-automation-networks-response>

Modify User

The Modify User edits a user details and permissions in TrueSight Network Automation. 

The following table describes the elements for the <items> XML element and adapter request for the Modify User operation.

Elements for the <items> XML element and adapter request for the Modify User operation

ElementDefinitionTypeRequired
<user-dto>

Contains the following child elements for modifying additional information
for a user (except <cleartext-password>):

  • <dynamic-fields>
  • <email-address>
  • <enabled>
  • <force-password-change>
  • <password-never-expires>
  • <realm-role-name>
  • <roles>
  • <root-account>
  • <user-name>
XMLYes
<dynamic-fields>

Specifies the XML to provide the full name of a new user in a key-value pair.

Example
<dynamic-fields>
    <element>
       <name>Full Name</name>
       <values>
	<element>Abhi Kumar</element>
       </values>
    </element>
</dynamic-fields>
XMLNo
<email-address>Specifies the email address of the new userStringYes
<enabled>

Specifies whether to enable the user after creation.

Valid values: true, false.

BooleanNo
<force-password-change>

Specifies whether to make the user change the password after creation.

Valid values: true, false.

BooleanNo
<password-never-expires>

Specifies whether to create a user with a password that never expires.

Valid values: true, false.

BooleanNo
<key>Specifies the user key for the user that you want to modify the details for.StringYes
<roles>

Specifies the role name, in XML. You can assign more than one role to a user.

Example
<roles>
 <!--zero or more array elements follow-->
 <element>Administrator</element>
 <element>Manager</element>
</roles>
XMLYes
<root-account>

Specifies whether the user should have a root account.

Valid values: true, false.

BooleanNo
<user-name>Specifies the username for the new user.StringYes
<cleartext-password>Specifies the password for the new user.StringNo

The following figure shows a sample <items> XML element for the Modify User operation.

Sample <items> XML element for the Modify User operation 

<items>
    <item>
        <parameters>
            <user-dto>
                <dynamic-fields>
                    <element>
                    <name>Full Name</name>
                    <values>
                        <element>Allen B.</element>
                    </values>
                    </element>
                </dynamic-fields>
            <email-address>allb@bmc.com</email-address>
            <enabled>true</enabled>
            <key>98699523-11</key>
            <password-never-expires>false</password-never-expires>
            <roles>
              <element>Administrator</element>
              <element>Manager</element>
            </roles>
            <root-account>false</root-account>
            <user-name>allb</user-name>      
            </user-dto>
            <cleartext-password>password</cleartext-password>
        </parameters>
     </item>
</items>

The following table describes the input elements for the Modify User operation.

Input elements for the Modify User operation

Input nameDescriptionTypeRequired
adapter name

Specifies the name of the adapter to use to run the request.

Default value: BCANActor

StringNo
items

Specifies the <items>XML that contains the user name and other details to modify a user.

XMLYes
connection parameters

Contains the additional connection parameters required for the adapter to connect to TrueSight Network Automation.

Example
<connection-parameters>
	<soap-url>hostname:443</soap-url>
 	<user-name>sysadmin</user-name>
 	<password>password</password>
	<soap-version>1.1</soap-version>
</connection-parameters> 


Contains the following child elements:

  • <soap-url>: Specifies the URL for the remote SOAP service for TrueSight Network Automation.

  • <user-name>: Specifies the username required to connect to the target.
  • <password>: Specifies the password that matches the username.
  • <soap-version>: Specifies the SOAP version to use. Valid values: 1.1 (default), 1.2
XMLNo

The following figure shows a sample adapter request for the Modify User operation.

Sample adapter request for the Modify User operation 

<bmc-configuration-automation-networks-request>
   <entity>user</entity>
   <request>
     <operation-name>modify-user</operation-name>
     <parameters>
           <user-dto>
               <dynamic-fields>
                   <element>
                   <name>Full Name</name>
                   <values>
                       <element>Allen B.</element>
                   </values>
                   </element>
               </dynamic-fields>
           <email-address>allb@bmc.com</email-address>
           <enabled>true</enabled>
           <key>98699523-11</key>
           <password-never-expires>false</password-never-expires>
           <roles>
             <element>Administrator</element>
             <element>Manager</element>
           </roles>
           <root-account>false</root-account>
           <user-name>allb</user-name>  
           </user-dto>
           <cleartext-password>password</cleartext-password>
       </parameters>
   </request>
 </bmc-configuration-automation-networks-request>

The following figure illustrates the response for the sample adapter request.

Adapter response for the sample adapter request

<bmc-configuration-automation-networks-response>
  <metadata>
    <status>success</status>
  </metadata>
  <parameters>
    <output>true</output>
  </parameters>
</bmc-configuration-automation-networks-response>

The following figure illustrates the response in case of an error. 

Adapter error response for a sample request

<bmc-configuration-automation-networks-response>
  <metadata>
    <status>success</status>
  </metadata>
  <parameters>
    <output>
      <metadata>
        <status>error</status>
        <error>Error occurred processing request data   Summary: Failed to call a web service.
 
 Caused by:
   Summary: Cannot change the username.
</error>
      </metadata>
    </output>
  </parameters>


Delete User

The Delete User removes a user (that matches a specified user key) in TrueSight Network Automation. 

The following table describes the elements for the <items> XML element and adapter request for the Delete User operation.

Elements for the <items> XML element and adapter request for the Delete User operation

ElementDefinitionTypeRequired
<user-key>Specifies the user key required to remove the user.StringYes

The following figure shows a sample <items> XML element for the Delete User operation.

<items> XML element for the Delete User operation 

<items>
    <item>
    <parameters>
    <user-key>9861234527-11</user-key>
    </parameters>
     </item>
</items>

The following table describes the input elements for the Delete User operation.

Input elements for the Delete User operation

InputDescriptionTypeRequired
items

Specifies the <items>XML that contains the user name and other details to create a new user.

XMLYes
connection parameters

Contains the additional connection parameters required for the adapter to connect to TrueSight Network Automation.

Example
<connection-parameters>
	<soap-url>hostname:443</soap-url>
 	<user-name>sysadmin</user-name>
 	<password>password</password>
	<soap-version>1.1</soap-version>
</connection-parameters> 

Contains the following child elements:

  • <soap-url>: Specifies the URL for the remote SOAP service for TrueSight Network Automation.

  • <user-name>: Specifies the username required to connect to the target.
  • <password>: Specifies the password that matches the username.
  • <soap-version>: Specifies the SOAP version to use. Valid values: 1.1 (default), 1.2
XMLNo

The following figure shows a sample adapter request for the Delete User operation.

Sample adapter request for the Delete User operation 

<bmc-configuration-automation-networks-request>
    <entity>user</entity>
    <request>
      <operation-name>delete-user</operation-name>
      <parameters>
        <user-key>9861234527-11</user-key>
      </parameters>
    </request>
  </bmc-configuration-automation-networks-request>

The following figure illustrates the response for the sample adapter request.

Adapter response for the sample adapter request

<bmc-configuration-automation-networks-response>
  <metadata>
    <status>success</status>
  </metadata>
  <parameters />
</bmc-configuration-automation-networks-response>

The following figure shows the response when an invalid key is specified.

Adapter error response in case of invalid key

<bmc-configuration-automation-networks-response>
  <metadata>
    <status>success</status>
  </metadata>
  <parameters>
    <output>
      <metadata>
        <status>error</status>
        <error>Error occurred processing request data   Summary: Failed to call a web service.
 Caused by:
   Summary: Errors occurred while deleting user.
</error>
      </metadata>
    </output>
  </parameters>
</bmc-configuration-automation-networks-response>

Back to top

Was this page helpful? Yes No Submitting... Thank you

Comments