/api/space/tag-management/tags

The following operations are supported on this resource:

  • GET - Return the tags based on a context
  • POST - Create a new tag
GET /tags Version 3

Return the tags based on a context.

Sample Usage

GET /tags


  • Sample Output XML:
    <tags total="1" uri="/api/space/tag-management/tags">
         <tag href="/api/space/tag-management/tags/6094870" uri="/api/space/tag-management/tags/6094870" >
               <id>6094870</id>
               <name>test</name>
               <access-type>private</access-type>
         </tag>
    </tags>

  • Sample Output JSON:
    {
       "tags" : {
         "@total" : "1" ,
         "@uri" : "/api/space/tag-management/tags" ,
           "tag" : {
             "@href" : "/api/space/tag-management/tags/6094870" ,
             "@uri" : "/api/space/tag-management/tags/6094870" ,
             "id" : 6094870 ,
             "name" : "test" ,
             "access-type" : "private"
          }
      }
    }

  • Access Control

    The following capabilities are required to access this API: DefaultRead

      For the deprecated versions of this API, refer to :
    • version 1

    POST /tags Version 1

    This API is used to create a tag object.

    Note: The tag name cannot start with a space. It cannot contain a special character, such as a comma, double quote, or parentheses. The name cannot exceed 255 characters.

    .

    Sample Usage

    POST /tags


  • Sample Input XML:

    <tag>
       <name>test-tag</name>
       <type>private</type>
       <targets>
          <target href="/api/space/user-management/users/30244913"/>
       </targets>
    </tag>

  • Sample Output XML:

    <tag uri="/api/space/tag-management/tags">
       <id>458766</id>
       <name>test-tag</name>
       <type>private</type>
       <targets uri="/api/space/tag-management/tags/targets" href="/api/space/tag-management/tags/458766/targets">
          <target type="vnd.net.juniper.space.user-management.user" href="/api/space/user-management/users/30244913" uri="/api/space/tag-management/tags/458766/targets/458767"/>
       </targets>
    </tag>

  • Sample Input JSON:

    {
      "tag": {
          "name":"test-tag",
          "type":"private",
          "targets": {
              "target":{
                  "@href":"/api/space/user-management/users/30244913"
              }
          }
       }
    }

  • Sample Output JSON:

    {
    "tag":
       {
    "@uri" : "/api/space/tag-management/tags",
       "id":458766,
       "name":"test-tag",
       "type":"private",
       "targets":
       {
    "@uri" : "/api/space/tag-management/tags/targets",
    "@href" : "/api/space/tag-management/tags/458766/targets",
          "target":
          {
          "@type": "vnd.net.juniper.space.user-management.user",
          "@href":"/api/space/user-management/users/30244913" ,
          "@uri": "/api/space/tag-management/tags/458766/targets/458767"
          }
       }
       }
    }

  • Access Control

    The following capabilities are required to access this API: CreateTags

    Data Notification

    This API supports data notification.