Interface TagUserApi

    • Method Detail

      • getTagDefinitions

        List<TagDefinition> getTagDefinitions​(TenantContext context)
        Parameters:
        context - The tenant context
        Returns:
        the list of all available tag definitions
      • addTags

        void addTags​(UUID objectId,
                     ObjectType objectType,
                     Collection<UUID> tagDefinitionIds,
                     CallContext context)
              throws TagApiException
        Parameters:
        objectId - The id for the object on which to add tags
        objectType - The object type
        tagDefinitionIds - The collection of tag definition ids
        context - The call context, for auditing purposes
        Throws:
        TagApiException
      • addTag

        void addTag​(UUID objectId,
                    ObjectType objectType,
                    UUID tagDefinitionId,
                    CallContext context)
             throws TagApiException
        Parameters:
        objectId - The id for the object on which to add tags
        objectType - The object type
        tagDefinitionId - The tag definition id
        context - The call context, for auditing purposes
        Throws:
        TagApiException
      • removeTags

        void removeTags​(UUID objectId,
                        ObjectType objectType,
                        Collection<UUID> tagDefinitions,
                        CallContext context)
                 throws TagApiException
        Parameters:
        objectId - The id for the object on which to add tags
        objectType - The object type
        tagDefinitions - The collection of tag definition ids
        context - The call context, for auditing purposes
        Throws:
        TagApiException
      • removeTag

        void removeTag​(UUID objectId,
                       ObjectType objectType,
                       UUID tagDefinitionId,
                       CallContext context)
                throws TagApiException
        Parameters:
        objectId - The id for the object on which to add tags
        objectType - The object type
        tagDefinitionId - The tage definition id
        context - The call context, for auditing purposes
        Throws:
        TagApiException
      • searchTags

        Pagination<Tag> searchTags​(String searchKey,
                                   Long offset,
                                   Long limit,
                                   TenantContext context)
        Find all tags having their object type, associated tag definition name or description matching the search key
        Parameters:
        searchKey - the search key
        offset - the offset of the first result
        limit - the maximum number of results to retrieve
        context - the user context
        Returns:
        the list of tags matching this search key for that tenant
      • getTags

        Pagination<Tag> getTags​(Long offset,
                                Long limit,
                                TenantContext context)
        Parameters:
        context - the user context
        offset - the offset of the first result
        limit - the maximum number of results to retrieve
        Returns:
        the list of tags for that tenant
      • getTagsForObject

        List<Tag> getTagsForObject​(UUID objectId,
                                   ObjectType objectType,
                                   boolean includedDeleted,
                                   TenantContext context)
        Parameters:
        objectId - UUID of the object on which to retrieve the tags
        objectType - The type of object
        includedDeleted - Whether to include deleted tags
        context - The tenant context
        Returns:
        A map of tag, key being the tagId, and value the tag
      • getTagsForAccountType

        List<Tag> getTagsForAccountType​(UUID accountId,
                                        ObjectType objectType,
                                        boolean includedDeleted,
                                        TenantContext context)
        Parameters:
        accountId - The account id
        objectType - The type of object on which to retrieve the tags
        includedDeleted - Whether to include deleted tags
        context - The tenant context
        Returns:
        A list of tags for that object type and that given account
      • getTagsForAccount

        List<Tag> getTagsForAccount​(UUID accountId,
                                    boolean includedDeleted,
                                    TenantContext context)
        Parameters:
        accountId - The account id
        includedDeleted - Whether to include deleted tags
        context - The tenant context
        Returns:
        A list of tags for that given account
      • getTagAuditLogsWithHistoryForId

        List<AuditLogWithHistory> getTagAuditLogsWithHistoryForId​(UUID tagId,
                                                                  AuditLevel auditLevel,
                                                                  TenantContext context)
        Get all the audit entries with history for a given tag.
        Parameters:
        tagId - the custom field id
        auditLevel - audit level (verbosity)
        context - the tenant context
        Returns:
        all audit entries with history for a tag
      • getTagDefinitionAuditLogsWithHistoryForId

        List<AuditLogWithHistory> getTagDefinitionAuditLogsWithHistoryForId​(UUID tagDefinitionId,
                                                                            AuditLevel auditLevel,
                                                                            TenantContext context)
        Get all the audit entries with history for a given tag definition.
        Parameters:
        tagDefinitionId - the custom field id
        auditLevel - audit level (verbosity)
        context - the tenant context
        Returns:
        all audit entries with history for a tag definition