/api/space/user-management/users

The following operations are supported on this resource:

  • GET - Get All Users
  • POST - Create a new user
  • PATCH - Multiple deletes to the users collection
GET /users Version 3

Get All Users.

Sample Usage

GET /users


  • Sample Output XML:
    <users total="Integer" uri="/api/space/user-management/users">
         <user href="/api/space/user-management/users/{id}" uri="/api/space/user-management/users/{id}">
               <id>Integer</id>
               <name>String</name>
               <first-name>String</first-name>
               <last-name>String</last-name>
               <primary-email>String</primary-email>
               <domains total="Integer">
                   <domain href="/api/space/domain-management/domains/{id}" uri="/api/space/user-management/users/{id}">
                         <id>Integer</id>
                         <name>String</name>
                   </domain>
               </domains>
               <auth-mode>String</auth-mode>
               <status>String</status>
               <password-status>ACTIVE</password-status>
               <role-type>GUI_ROLE_ACCESS</role-type>
               <lock-out-status>String</lock-out-status>
               <read-only>Boolean</read-only>
         </user>
    </users>

  • Sample Output JSON:
    {
       "users" : {
         "@total" : "Integer" ,
         "@uri" : "/api/space/user-management/users" ,
         "user" : {
           "@href" : "/api/space/user-management/users/{id}" ,
           "@uri" : "/api/space/user-management/users/{id}" ,
           "id" : "Integer" ,
           "name" : "String" ,
           "first-name" : "String" ,
           "last-name" : "String" ,
           "primary-email" : "String" ,
           "domains" : {
             "@total" : "Integer" ,
             "domain" : {
               "@href" : "/api/space/domain-management/domains/{id}" ,
               "@uri" : "/api/space/user-management/users/{id}" ,
               "id" : "Integer" ,
               "name" : "String"
             }
           } ,
           "auth-mode" : "String" ,
           "status" : "String" ,
           "password-status" : "ACTIVE" ,
           "role-type" : "GUI_ROLE_ACCESS" ,
           "lock-out-status" : "String" ,
           "read-only" : "Boolean"
         }
       }
    }

  • Access Control

    The following capabilities are required to access this API: ReadUser, CreateDomain, ModifyDomain

      For other non-deprecated versions of this API, refer to :
    • version 1


    POST /users Version 1

    Create a new user in Junos Space.

    Sample Usage

    POST /users?email-password=<email-password>&generate-password=<generate-password>


    • Parameters:
      Name Type URI Type Description Required
      email-password Boolean Query Should the password be mailed to the user? This works only for temporary password. N
      generate-password Boolean Query Generate a temporary password N
  • Sample Input XML:
    <user>
       <name>test</name>
       <firstName>Test</firstName>
       <middleName>Test</middleName>
       <lastName>Test</lastName>
       <password>0Nf72o7CPMCYNY6Ks213EQ==</password>
       <primaryPhone>0013010000001</primaryPhone>
       <primaryEmail>super@juniper.net</primaryEmail>
       <api-access-profile href="/api/space/user-management/api-access-profiles/12345" />
       <roles>
         <role href="/api/space/user-management/roles/65601" />
         <role href="/api/space/user-management/roles/65603" />
       </roles>
         <x509-authentication-parameters>
               <x509-authentication-parameter>
                   <parameter-value>String</parameter-value>
                   <x509-certificate-parameter>
                         <x509-parameter-name>String</x509-parameter-name>
                   </x509-certificate-parameter>
               </x509-authentication-parameter>
         </x509-authentication-parameters>
    </user>

  • Sample Output XML:
    <user uri="/api/space/user-management/users/3506194">
      <id>3506194</id>
      <name>test12</name>
      <firstName>Test1</firstName>
      <middleName>Test</middleName>
    <lastName>Test</lastName>
      <password>ofQT2y3J5L5ujweGtHMuXg==</password>
      <primaryPhone>0013010000001</primaryPhone>
      <primaryEmail>super@juniper.net</primaryEmail>
       <api-access-profile href="/api/space/user-management/api-access-profiles/12345" >
              <id>12345</id>
            <name>apiaccessprofile</name>
       </api-access-profile>
      <roles uri="/api/space/user-management/users/3506194/roles">
        <role uri="/api/space/user-management/users/3506194/roles/65658" href="/api/space/user-management/roles/65658">
          <id>65658</id>
          <name>jobsAdmin</name>

        </role>
      </roles>
         <x509-authentication-parameters>
               <x509-authentication-parameter>
                   <parameter-value>String</parameter-value>
                   <x509-certificate-parameter>
                         <x509-parameter-name>String</x509-parameter-name>
                   </x509-certificate-parameter>
               </x509-authentication-parameter>
         </x509-authentication-parameters>
      <method href="/api/space/user-management/users/196637/change-password" rel="change-password" />
    </user>

  • Sample Input JSON:

    {
      "user":{
         "name":"testUser",
         "firstName":"testFirstName",
         "middleName":"testMiddleName",
         "lastName":"testLastName",
         "password":"test@123",
         "primaryPhone":"0013010000001",
         "viewAllObjects":"true",
         "primaryEmail":"test@juniper.net",
        "api-access-profile": {
            "@href":"/api/space/user-management/api-access-profiles/12345"
              },
         "roles": {
            "role":[
               {
                  "@href":"/api/space/user-management/roles/65601"
               },
               {
                  "@href":"/api/space/user-management/roles/65603"
               }
            ]
         },
         "x509-authentication-parameters" : {
           "x509-authentication-parameter" : {
             "parameter-value" : "String" ,
             "x509-certificate-parameter" : {
               "x509-parameter-name" : "String"
             }
           }
         }
      }

  • Sample Output JSON:

    {
      "user":{
            "@uri": "/api/space/user-management/users/196651",
            "id":196651,
            "name":"testuser",
            "firstName":"testFirstName",
            "middleName":"testMiddleName",
            "lastName":"testLastName",
            "password": "zrbJcGWPMVBKkBuJ3NPkYQ==",
             "primaryPhone": "0013010000001",
            "primaryEmail":"test@juniper.net",
        "api-access-profile": {
            "@href":"/api/space/user-management/api-access-profiles/12345",
                 "id": 12345,
                  "name":"apiaccessprofile"
              }
            "roles": {
                  "@uri":"/api/space/user-management/users/196651/roles",
                  "role": [
                   ;  {
                   ;    "@uri": "/api/space/user-management/users/196651/roles/65655",
                   ;    "@href":"/api/space/user-management/roles/65655",
                   ;    "id":65655,
                   ;    "name":"userAdmin"
                   ;  },
                   ;  {
                   ;    "@uri": "/api/space/user-management/users/196651/roles/65656",
                   ;    "@href":"/api/space/user-management/roles/65656",
                   ;    "id":65656,
                   ;    "name":"tagsAdmin"
                   ;  }
                 ]
            },
         "x509-authentication-parameters" : {
           "x509-authentication-parameter" : {
             "parameter-value" : "String" ,
             "x509-certificate-parameter" : {
               "x509-parameter-name" : "String"
             }
           }
         } ,
            "method":{
                  "@href":"/api/space/user-management/users/196651/change-password",
                  "@rel":"change-password"
            }
      }

  • Access Control

    The following capabilities are required to access this API: CreateUser

    Data Notification

    This API supports data notification.

    PATCH /users Version 1

    Multiple deletes to the users collection.

    Sample Usage

    PATCH /users


    • Content-Type Headers:
      application/vnd.net.juniper.space.user-management.users_patch+xml;version=1

  • Sample Patch XML:
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <diff>
       <!--What you see below are just samples of patch operations that may be performed on this DTO.-->
       <!--For more information about patch document format please look at http://http://www.rfc-editor.org/rfc/rfc5261.txt-->
       <remove sel="users/user[@some attribute='some value']"/>
       <!-- or using element selection-->
       <remove sel="users/user[some element='some value']"/>
    </diff>

  • Access Control

    The following capabilities are required to access this API: DeleteUser