Interface UserResource


@Path("/users") @Consumes("application/json") @Produces("application/vnd.ilandcloud.api.v1.0+json") public interface UserResource
User Resource Interface v1.
Author:
Cory Snyder
  • Method Details

    • getUser

      @GET @Path("/{username}") UserResponse getUser(@PathParam("username") String username)
      Returns the user specified by their username.
      Parameters:
      username - the user's username
      Returns:
      user
    • updateUser

      @PUT @Path("/{username}") @Consumes("application/json") UserResponse updateUser(@PathParam("username") String username, UserUpdateRequest request)
      Updates a user's information.
      Parameters:
      username - the user's username
      Returns:
      updated user
    • getActiveSessions

      @GET @Path("/{username}/sessions") UserSessionListResponse getActiveSessions(@PathParam("username") String username)
      Gets a user's current sessions.
      Parameters:
      username - unique username as seen by iland AD
      Returns:
      user
    • endAllActiveSessions

      @DELETE @Path("/{username}/sessions") void endAllActiveSessions(@PathParam("username") String username)
      Ends all active sessions for the user.
      Parameters:
      username - the username to get sessions for
    • endSession

      @DELETE @Path("/{username}/sessions/{sessionId}") void endSession(@PathParam("username") String username, @PathParam("sessionId") String sessionId)
      Ends a session for a user.
      Parameters:
      username - the username of the user
      sessionId - the session ID to end
    • getAccountEvents

      @GET @Path("/{username}/account-events") AccountEventListResponse getAccountEvents(@PathParam("username") String username, @QueryParam("offset") Integer offset, @QueryParam("limit") Integer limit, @QueryParam("dateFrom") Long dateFrom, @QueryParam("dateTo") Long dateTo)
      Gets account event logs.
      Parameters:
      username - the username of the user
    • subscribeToEntityHistory

      @POST @Path("/{username}/actions/subscribe-to-entity-history") @Consumes("application/json") UserEntityHistorySubscriptionResponse subscribeToEntityHistory(@PathParam("username") String username, UserEntityHistorySubscriptionCreateRequest sub)
      Add an entity history subscription.
      Parameters:
      username - username
      sub - subscription details
      Returns:
      new subscription
    • removeEntityHistorySubscription

      @POST @Path("/{username}/actions/unsubscribe-from-entity-history") @Consumes("application/json") void removeEntityHistorySubscription(@PathParam("username") String username, UserEntityHistorySubscriptionDeleteRequest sub)
      Remove an entity history subscription.
      Parameters:
      username - username
      sub - subscription details
    • getEntityHistorySubscriptions

      @GET @Path("/{username}/entity-history-subscriptions") UserEntityHistorySubscriptionListResponse getEntityHistorySubscriptions(@PathParam("username") String username)
      Get entity history subscriptions for a given user.
      Parameters:
      username - username
      Returns:
      list of entity history subscriptions
    • getPreferences

      @GET @Path("/{username}/preferences") UserPreferencesResponse getPreferences(@PathParam("username") String username)
      Retrieve user preferences section.
      Parameters:
      username - username to retrieve preferences for
      Returns:
      user preferences
    • updatePreferences

      @PUT @Path("/{username}/preferences") @Consumes("application/json") UserPreferencesResponse updatePreferences(@PathParam("username") String username, UserPreferencesCreateRequest request)
      Store / update user preferences section.
      Parameters:
      username - username to store preferences for
      Returns:
      user preferences
    • delete

      @DELETE @Path("/{username}") void delete(@PathParam("username") String username)
      Deletes a user.
      Parameters:
      username - username of the user to delete
    • getLoginEvents

      @GET @Path("/{username}/login-events") LoginEventListResponse getLoginEvents(@PathParam("username") String username, @QueryParam("offset") Integer offset, @QueryParam("limit") Integer limit)
      Get login events for a user. Login events include both successfull and unsuccessful login attempts. The type field of the returned login events will either be 'LOGIN' (meaning success) or 'LOGIN_ERROR' (meaning login failure. You may request at most 100 events at a time.
      Parameters:
      username - the user's username
      offset - the offset of the first event to retrieve
      limit - the limit of the number of login events to retrieve
      Returns:
      list of login events
    • getUserAlertEmails

      @GET @Path("/{username}/alert-emails") UserAlertEmailsResponse getUserAlertEmails(@PathParam("username") String username)
      Get the set of user alerting emails for a given username.

      This set of emails is used for all alerts (resource and billing, etc) whenever an alert is triggered.

      Parameters:
      username - the user's username
      Returns:
      set of alerting emails
    • updateAlertEmails

      @POST @Path("/{username}/actions/update-alert-emails") @Consumes("application/json") UserAlertEmailsResponse updateAlertEmails(@PathParam("username") String username, UserAlertEmailsCreateRequest userAlertEmails)
      Store the set of user alerting emails for a given username.
      Parameters:
      username - the user's username
      userAlertEmails - set of alerting emails for the user
      Returns:
      set of alerting emails
    • getInventory

      @GET @Path("/{username}/inventory") UserInventoryResponse getInventory(@PathParam("username") String username, @QueryParam("company") String companyId)
      Gets the inventory hierarchy for a user.
      Parameters:
      username - the username of the user
      companyId - optional company ID parameter that may be used to restrict the results to just those within a specific company
      Returns:
      list of org hierarchies for the specified user
    • getCompanyRole

      @GET @Path("/{username}/roles/{companyId}") RoleResponse getCompanyRole(@PathParam("username") String username, @PathParam("companyId") String companyId)
      Get the company role for a specified user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      Returns:
      the user's role within the specified company.
    • updateCompanyRole

      @PUT @Path("/{username}/roles/{companyId}") @Consumes("application/json") void updateCompanyRole(@PathParam("username") String username, @PathParam("companyId") String companyId, UserRoleUpdateRequest userRoleUpdateRequest)
      Update the company role for a specified user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      userRoleUpdateRequest - the data object specifying role update parameters
    • getAvailableBillingPermissions

      @GET @Path("/{companyId}/permissions/billing") UserBillingPermissionListResponse getAvailableBillingPermissions(@PathParam("companyId") String companyId)
      Gets user billing permissions for a company and the current user. With each permission, a list of user inventory entities usable with the permission is included as well.
      Parameters:
      companyId - the company id
      Returns:
      list of billing permissions
    • deleteCompanyRole

      @DELETE @Path("/{username}/roles/{companyId}") void deleteCompanyRole(@PathParam("username") String username, @PathParam("companyId") String companyId)
      Deletes a user's role within a specified company.
      Parameters:
      username - the username of the user
      companyId - the company ID
    • getCompanies

      @GET @Path("/{username}/companies") CompanyListResponse getCompanies(@PathParam("username") String username)
      Gets the list of companies that the user has access to.
      Parameters:
      username - the username of the user
    • getAllUserOrgs

      @GET @Path("/{username}/orgs") OrgListResponse getAllUserOrgs(@PathParam("username") String username)
      Gets the list of orgs that the user has access to.
      Parameters:
      username - the username of the user
    • getOrgsForUser

      @GET @Path("/{username}/companies/{companyId}/orgs") OrgListResponse getOrgsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the orgs for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of orgs
    • getVdcsForUser

      @GET @Path("/{username}/companies/{companyId}/vdcs") VdcListResponse getVdcsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the vDCs for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of vDCs
    • getVappsForUser

      @GET @Path("/{username}/companies/{companyId}/vapps") VappListResponse getVappsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the vApps for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of vApps
    • getVmsForUser

      @GET @Path("/{username}/companies/{companyId}/vms") VmListResponse getVmsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the VMs for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of VMs
    • getMediaForUser

      @GET @Path("/{username}/companies/{companyId}/media") MediaListResponse getMediaForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the media for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of media
    • getVappTemplatesForUser

      @GET @Path("/{username}/companies/{companyId}/vapp-templates") VappTemplateListResponse getVappTemplatesForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the vApp templates for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of vApp templates
    • getEdgesForUser

      @GET @Path("/{username}/companies/{companyId}/edges") EdgeListResponse getEdgesForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the edges for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of edges
    • getVpgsForUser

      @GET @Path("/{username}/companies/{companyId}/vpgs") ExpandedVpgListResponse getVpgsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId, @QueryParam("expand") List<VpgSubEntityRequest> expand)
      Get the VPGs for company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of VPGs
    • getVccFailoverPlansForUser

      @GET @Path("/{username}/companies/{companyId}/vcc-failover-plans") VccFailoverPlanListResponse getVccFailoverPlansForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get all VCC-R failover plans for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of VCC-R failover plan
    • getBaCompaniesForUser

      @GET @Path("/{username}/companies/{companyId}/vac-companies") BaCompanySetResponse getBaCompaniesForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the vac companies for company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      set of vac companies
    • getBaJobsForUser

      @GET @Path("/{username}/companies/{companyId}/vac-jobs") BaJobListResponse getBaJobsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the vac jobs for company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      list of vac jobs
    • getOrgVdcNetworksForUser

      @GET @Path("/{username}/companies/{companyId}/org-vdc-networks") OrgVdcNetworkListResponse getOrgVdcNetworksForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the org vdc networks for the company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      a list of org vdc networks
    • getVappNetworksForUser

      @GET @Path("/{username}/companies/{companyId}/vapp-networks") VappNetworkListResponse getVappNetworksForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the vapp networks for the company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      a list of org vdc networks
    • getCatalogsForUser

      @GET @Path("/{username}/companies/{companyId}/catalogs") CatalogListResponse getCatalogsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the catalogs for the given company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      Returns:
      a list of catalogs
    • getO365OrganizationsForUser

      @GET @Path("/{username}/companies/{companyId}/o365-organizations") O365OrganizationSetResponse getO365OrganizationsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the Office 365 VBO companies for a company and user.
      Parameters:
      username - the user name
      companyId - the company identifier (aka CRM # id)
      locationId - the location identifier
      Returns:
      a O365OrganizationSetResponse instance.
    • getO365JobsForUser

      @GET @Path("/{username}/companies/{companyId}/o365-jobs") O365JobSetResponse getO365JobsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the Office 365 VBO jobs for a company and user.
      Parameters:
      username - the user name
      companyId - the company identifier (aka CRM # id)
      locationId - the location identifier
      Returns:
      a O365JobSetResponse instance.
    • getO365CopyJobsForUser

      @GET @Path("/{username}/companies/{companyId}/o365-copy-jobs") O365CopyJobSetResponse getO365CopyJobsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the Office 365 VBO copy jobs for a company and user.
      Parameters:
      username - the user name
      companyId - the company identifier (aka CRM # id)
      locationId - the location identifier
      Returns:
      a O365CopyJobSetResponse instance.
    • getO365ActiveRestoreSessionsForUser

      @GET @Path("/{username}/companies/{companyId}/o365-restore-sessions") O365RestoreSessionSetResponse getO365ActiveRestoreSessionsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId)
      Get the Office 365 VBO active restore sessions for a company and user.
      Parameters:
      username - the user name
      companyId - the company identifier (aka CRM # id)
      locationId - the location identifier
      Returns:
      a O365RestoreSessionSetResponse instance.
    • getBackupGroupsForUser

      @GET @Path("/{username}/companies/{companyId}/backup-groups") BackupGroupListResponse getBackupGroupsForUser(@PathParam("username") String username, @PathParam("companyId") String companyId, @QueryParam("location") String locationId, @QueryParam("includeSummaryStats") boolean includeSummaryStats, @QueryParam("includeLastRun") boolean includeLastRun, @QueryParam("includeBackupPolicy") boolean includeBackupPolicy)
      Get the backup groups for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      includeLastRun - whether to include last run info
      includeSummaryStats - whether to include summary stats in the response
      includeBackupPolicy - whether to include backup policy details
      Returns:
      list of backup groups
    • getV2BackupGroups

      @GET @Path("/{username}/companies/{companyId}/backup-groups-x") com.iland.cohesity.iaas.backups.common.model.ListResponse<com.iland.cohesity.iaas.backups.backupgroups.api.modelx.BackupGroupV2> getV2BackupGroups(@PathParam("username") String username, @PathParam("companyId") com.iland.cohesity.iaas.backups.common.model.CompanyId companyId, @QueryParam("location") com.iland.cohesity.iaas.backups.common.model.LocationId locationId, @QueryParam("includeSummaryStats") boolean includeSummaryStats, @QueryParam("includeLastRun") boolean includeLastRun, @QueryParam("includeBackupPolicy") boolean includeBackupPolicy, @QueryParam("includeLegacyVMware") boolean includeLegacyVMware)
      Get the backup groups for a company and user.
      Parameters:
      username - the username of the user
      companyId - the company ID
      locationId - the location ID
      includeLastRun - whether to include last run info
      includeSummaryStats - whether to include summary stats in the response
      includeBackupPolicy - whether to include backup policy details
      includeLegacyVMware - weather to include legacy VMware backup groups
      Returns:
      list of backup groups
    • getIdentityProviderLink

      @GET @Path("/{username}/identity-provider-link") UserIdentityProviderLinkResponse getIdentityProviderLink(@PathParam("username") String username)
      Get the identity provider link for a user if they have any.
      Parameters:
      username - name of user to get identity provider link for
      Returns:
      user identity provider link