orderItemsListPartnerAmendmentsWithHttpInfo method
List partner amendments
Lists amendments across the authenticated partner's orders. Requires the read order permission. Includes manual and automatic amendments in all statuses. Optional repeated statuses, productType, amendmentMode, orderId, orderItemId and inclusive UTC from/to timestamps filter the result. Use flat page (default 1) and limit (default 10, maximum 100) query parameters. Nested paging keys return 400 with code 10001. Amounts retain their original currency; a quote does not imply settlement. Example response: {\"items\":[{\"id\":\"b7428a30-f760-46e8-b504-a670bf9bed19\",\"orderId\":\"a46ee792-287e-44ef-a641-48de1a0f72fd\",\"orderItemId\":\"cf4a49ac-b785-43d4-912a-4be3443e48bd\",\"productType\":\"hotel\",\"amendmentMode\":\"manual\",\"status\":\"quoted\",\"createdAt\":\"2026-11-03T09:00:00Z\",\"amountToPay\":{\"amount\":25,\"currency\":\"USD\"},\"amountToRefund\":{\"amount\":0,\"currency\":\"USD\"}}],\"pagination\":{\"currentCount\":1,\"totalCount\":1,\"skip\":0,\"limit\":10,\"hasMore\":false,\"page\":1,\"totalPages\":1}}
Note: This method returns the HTTP Response.
Parameters:
-
int page: One-based page number. Default 1.
-
int limit: Page size, 1 to 100. Default 10.
-
List<String> statuses: Repeat to match any of the requested statuses.
-
String productType:
-
String amendmentMode:
-
String orderId:
-
String orderItemId:
-
DateTime from: Inclusive creation timestamp with UTC offset.
-
DateTime to: Inclusive creation timestamp with UTC offset. Send the end of a UTC day to include that whole day.
Implementation
Future<Response> orderItemsListPartnerAmendmentsWithHttpInfo({ int? page, int? limit, List<String>? statuses, String? productType, String? amendmentMode, String? orderId, String? orderItemId, DateTime? from, DateTime? to, Future<void>? abortTrigger, }) async {
// ignore: prefer_const_declarations
final path = r'/api/v1/b2b/amendments';
// ignore: prefer_final_locals
Object? postBody;
final queryParams = <QueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (page != null) {
queryParams.addAll(_queryParams('', 'page', page));
}
if (limit != null) {
queryParams.addAll(_queryParams('', 'limit', limit));
}
if (statuses != null) {
queryParams.addAll(_queryParams('multi', 'statuses', statuses));
}
if (productType != null) {
queryParams.addAll(_queryParams('', 'productType', productType));
}
if (amendmentMode != null) {
queryParams.addAll(_queryParams('', 'amendmentMode', amendmentMode));
}
if (orderId != null) {
queryParams.addAll(_queryParams('', 'orderId', orderId));
}
if (orderItemId != null) {
queryParams.addAll(_queryParams('', 'orderItemId', orderItemId));
}
if (from != null) {
queryParams.addAll(_queryParams('', 'from', from));
}
if (to != null) {
queryParams.addAll(_queryParams('', 'to', to));
}
const contentTypes = <String>[];
return apiClient.invokeAPI(
path,
'GET',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
abortTrigger: abortTrigger,
);
}