Class ReportsImpl

java.lang.Object
com.eqixiac.equinix.customerportal.client.implementation.ReportsImpl
All Implemented Interfaces:
Reports

public class ReportsImpl extends Object implements Reports
  • Constructor Details

    • ReportsImpl

      public ReportsImpl()
  • Method Details

    • getReports

      public PaginatedList<Report> getReports()
      Description copied from interface: Reports
      Lists generated reports.

      Maps to GET /v1/reportCenter/reports (getReports).

      Specified by:
      getReports in interface Reports
      Returns:
      a paginated list of reports
    • getReports

      public PaginatedList<Report> getReports(Integer durationDays, List<ReportStatus> statuses, List<ReportSort> sorts)
      Description copied from interface: Reports
      Lists generated reports with the spec's optional filters.

      Maps to GET /v1/reportCenter/reports (getReports) with duration, statuses and sorts. Lists are sent comma-separated (collectionFormat: csv); a null or empty argument is not sent and the service default applies (7 days, all statuses, -GENERATED_DATE).

      Specified by:
      getReports in interface Reports
      Parameters:
      durationDays - number of days back to search, 1 to 365, or null
      statuses - report statuses to include (IN_PROGRESS, SUCCESS, ERROR in the spec), or null
      sorts - sort order, or null
      Returns:
      a paginated list of reports
    • getReportById

      public Report getReportById(String reportId)
      Description copied from interface: Reports
      Retrieves a generated report by id.

      Maps to GET /v1/reportCenter/reports/{reportId} (getReportById).

      Specified by:
      getReportById in interface Reports
      Parameters:
      reportId - the report id
      Returns:
      the matching report
    • deleteReports

      public List<? extends Report> deleteReports(List<String> reportIds)
      Description copied from interface: Reports
      Deletes generated reports in bulk.

      Maps to DELETE /v1/reportCenter/reports (deleteReports). This is a best-effort bulk delete: the response carries one result per requested report id, each with a reportId and a per-report status (SUCCESS or ERROR), so callers can detect partial failures.

      Specified by:
      deleteReports in interface Reports
      Parameters:
      reportIds - the report ids to delete
      Returns:
      the per-report delete results
    • downloadReports

      public byte[] downloadReports(List<String> reportIds)
      Description copied from interface: Reports
      Downloads one or more generated reports as a combined file (zip).

      Maps to GET /v1/reportCenter/reports/files (downloadReports).

      Specified by:
      downloadReports in interface Reports
      Parameters:
      reportIds - the report ids to download
      Returns:
      the downloaded file bytes
    • downloadReport

      public byte[] downloadReport(String reportId)
      Description copied from interface: Reports
      Downloads a single generated report's file.

      Maps to GET /v1/reportCenter/reports/{reportId}/file (downloadReport).

      Specified by:
      downloadReport in interface Reports
      Parameters:
      reportId - the report id
      Returns:
      the report file bytes
    • getScheduledReports

      public List<? extends ScheduledReport> getScheduledReports()
      Description copied from interface: Reports
      Lists scheduled report definitions.

      Maps to GET /v1/reportCenter/reports/scheduler (getScheduledReports).

      Specified by:
      getScheduledReports in interface Reports
      Returns:
      the list of scheduled reports
    • getScheduledReport

      public ScheduledReport getScheduledReport(String scheduledId)
      Description copied from interface: Reports
      Retrieves a scheduled report by id.

      Maps to GET /v1/reportCenter/reports/scheduler/{scheduledId} (getScheduledReport).

      Specified by:
      getScheduledReport in interface Reports
      Parameters:
      scheduledId - the scheduled report id
      Returns:
      the matching scheduled report
    • scheduleReport

      public ScheduledReport scheduleReport(ScheduleReportRequest request)
      Description copied from interface: Reports
      Creates a scheduled report definition.

      Maps to POST /v1/reportCenter/reports/scheduler (scheduleReport).

      Specified by:
      scheduleReport in interface Reports
      Parameters:
      request - the schedule request body
      Returns:
      the created scheduled report
    • updateScheduledReport

      public ScheduledReport updateScheduledReport(String scheduledId, ScheduleReportRequest request)
      Description copied from interface: Reports
      Updates an existing scheduled report definition.

      Maps to PUT /v1/reportCenter/reports/scheduler/{scheduledId} (updateScheduledReport).

      Specified by:
      updateScheduledReport in interface Reports
      Parameters:
      scheduledId - the scheduled report id
      request - the updated schedule request body
      Returns:
      the updated scheduled report
    • deleteScheduledReports

      public boolean deleteScheduledReports(List<String> scheduledIds)
      Description copied from interface: Reports
      Deletes scheduled report definitions in bulk.

      Maps to DELETE /v1/reportCenter/reports/scheduler (deleteScheduledReports).

      Specified by:
      deleteScheduledReports in interface Reports
      Parameters:
      scheduledIds - the scheduled report ids to delete
      Returns:
      true if the request succeeded
    • generateReport

      public Report generateReport(String scheduledId)
      Description copied from interface: Reports
      Generates a report from a scheduled report definition.

      Maps to POST /v1/reportCenter/reports/scheduler/{scheduledId}/report (generateReport).

      Specified by:
      generateReport in interface Reports
      Parameters:
      scheduledId - the scheduled report id
      Returns:
      the generated report
    • getReportDefinitions

      public List<ReportDefinitionJson> getReportDefinitions()
      Description copied from interface: Reports
      Lists the available report definitions.

      Maps to GET /v1/reportCenter/reports/definitions (getReportDefinitions).

      Specified by:
      getReportDefinitions in interface Reports
      Returns:
      the list of report definitions
    • getReportDefinition

      public ReportDefinitionJson getReportDefinition(String reportName)
      Description copied from interface: Reports
      Retrieves a single report definition by name.

      Maps to GET /v1/reportCenter/reports/definitions/{reportName} (getReportDefinition).

      Specified by:
      getReportDefinition in interface Reports
      Parameters:
      reportName - the report definition name
      Returns:
      the matching report definition