Selling Partner API for Reports (2021-06-30)

Download OpenAPI specification:Download

The Selling Partner API for Reports lets you retrieve and manage a variety of reports that can help selling partners manage their businesses.

reports

getReports

Returns report details for the reports that match the filters that you specify.

Usage Plan:

Rate (requests per second) Burst
0.0222 10

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

query Parameters
reportTypes
Array of strings [ 1 .. 10 ] items

A list of report types used to filter reports. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required.

processingStatuses
Array of strings non-empty
Items Enum: "CANCELLED" "DONE" "FATAL" "IN_PROGRESS" "IN_QUEUE"

A list of processing statuses used to filter reports.

marketplaceIds
Array of strings [ 1 .. 10 ] items

A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify.

pageSize
integer [ 1 .. 100 ]
Default: 10

The maximum number of reports to return in a single call.

createdSince
string <date-time>

The earliest report creation date and time for reports to include in the response, in ISO 8601 date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days.

createdUntil
string <date-time>

The latest report creation date and time for reports to include in the response, in ISO 8601 date time format. The default is now.

nextToken
string

A string token returned in the response to your previous request. nextToken is returned when the number of results exceeds the specified pageSize value. To get the next page of results, call the getReports operation and include this token as the only parameter. Specifying nextToken with any other parameters will cause the request to fail.

Responses

Response samples

Content type
application/json
{
  • "reports": [
    ],
  • "nextToken": "string"
}

createReport

Creates a report.

Usage Plan:

Rate (requests per second) Burst
0.0167 15

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

Request Body schema: application/json
object (ReportOptions)

Additional information passed to reports. This varies by report type.

reportType
required
string

The report type.

dataStartTime
string <date-time>

The start of a date and time range, in ISO 8601 date time format, used for selecting the data to report. The default is now. The value must be prior to or equal to the current date and time. Not all report types make use of this.

dataEndTime
string <date-time>

The end of a date and time range, in ISO 8601 date time format, used for selecting the data to report. The default is now. The value must be prior to or equal to the current date and time. Not all report types make use of this.

marketplaceIds
required
Array of strings [ 1 .. 25 ] items

A list of marketplace identifiers. The report document's contents will contain data for all of the specified marketplaces, unless the report type indicates otherwise.

Responses

Request samples

Content type
application/json
{
  • "reportOptions": {
    },
  • "reportType": "string",
  • "dataStartTime": "2019-08-24T14:15:22Z",
  • "dataEndTime": "2019-08-24T14:15:22Z",
  • "marketplaceIds": [
    ]
}

Response samples

Content type
application/json
{
  • "reportId": "string"
}

cancelReport

Cancels the report that you specify. Only reports with processingStatus=IN_QUEUE can be cancelled. Cancelled reports are returned in subsequent calls to the getReport and getReports operations.

Usage Plan:

Rate (requests per second) Burst
0.0222 10

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

path Parameters
reportId
required
string

The identifier for the report. This identifier is unique only in combination with a seller ID.

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

getReport

Returns report details (including the reportDocumentId, if available) for the report that you specify.

Usage Plan:

Rate (requests per second) Burst
2.0 15

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

path Parameters
reportId
required
string

The identifier for the report. This identifier is unique only in combination with a seller ID.

Responses

Response samples

Content type
application/json
{
  • "marketplaceIds": [
    ],
  • "reportId": "string",
  • "reportType": "string",
  • "dataStartTime": "2019-08-24T14:15:22Z",
  • "dataEndTime": "2019-08-24T14:15:22Z",
  • "reportScheduleId": "string",
  • "createdTime": "2019-08-24T14:15:22Z",
  • "processingStatus": "CANCELLED",
  • "processingStartTime": "2019-08-24T14:15:22Z",
  • "processingEndTime": "2019-08-24T14:15:22Z",
  • "reportDocumentId": "string"
}

getReportSchedules

Returns report schedule details that match the filters that you specify.

Usage Plan:

Rate (requests per second) Burst
0.0222 10

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

query Parameters
reportTypes
required
Array of strings [ 1 .. 10 ] items

A list of report types used to filter report schedules.

Responses

Response samples

Content type
application/json
{
  • "reportSchedules": [
    ]
}

createReportSchedule

Creates a report schedule. If a report schedule with the same report type and marketplace IDs already exists, it will be cancelled and replaced with this one.

Usage Plan:

Rate (requests per second) Burst
0.0222 10

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

Request Body schema: application/json
reportType
required
string

The report type.

marketplaceIds
required
Array of strings [ 1 .. 25 ] items

A list of marketplace identifiers for the report schedule.

object (ReportOptions)

Additional information passed to reports. This varies by report type.

period
required
string
Enum: "PT5M" "PT15M" "PT30M" "PT1H" "PT2H" "PT4H" "PT8H" "PT12H" "P1D" "P2D" "P3D" "PT84H" "P7D" "P14D" "P15D" "P18D" "P30D" "P1M"

One of a set of predefined ISO 8601 periods that specifies how often a report should be created.

nextReportCreationTime
string <date-time>

The date and time when the schedule will create its next report, in ISO 8601 date time format.

Responses

Request samples

Content type
application/json
{
  • "reportType": "string",
  • "marketplaceIds": [
    ],
  • "reportOptions": {
    },
  • "period": "PT5M",
  • "nextReportCreationTime": "2019-08-24T14:15:22Z"
}

Response samples

Content type
application/json
{
  • "reportScheduleId": "string"
}

cancelReportSchedule

Cancels the report schedule that you specify.

Usage Plan:

Rate (requests per second) Burst
0.0222 10

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

path Parameters
reportScheduleId
required
string

The identifier for the report schedule. This identifier is unique only in combination with a seller ID.

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

getReportSchedule

Returns report schedule details for the report schedule that you specify.

Usage Plan:

Rate (requests per second) Burst
0.0222 10

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

path Parameters
reportScheduleId
required
string

The identifier for the report schedule. This identifier is unique only in combination with a seller ID.

Responses

Response samples

Content type
application/json
{
  • "reportScheduleId": "string",
  • "reportType": "string",
  • "marketplaceIds": [
    ],
  • "reportOptions": {
    },
  • "period": "string",
  • "nextReportCreationTime": "2019-08-24T14:15:22Z"
}

getReportDocument

Returns the information required for retrieving a report document's contents.

Usage Plan:

Rate (requests per second) Burst
0.0167 15

For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.

path Parameters
reportDocumentId
required
string

The identifier for the report document.

Responses

Response samples

Content type
application/json
{
  • "reportDocumentId": "string",
  • "url": "string",
  • "compressionAlgorithm": "GZIP"
}