{ "openapi": "3.0.0", "info": { "title": "OrderSearchAPI", "version": "v6", "description": "Search your Ingram Micro orders. This endpoint searches by multiple parameters and supports pagination of results.\n\n*Production URL - https://api.ingrammicro.com:443/resellers/v6*" }, "paths": { "/orders/search": { "get": { "summary": "Search Your Orders", "tags": [ "Orders" ], "description": "Search your Ingram Micro orders. This endpoint searches by multiple order parameters and supports pagination of results.", "operationId": "get-resellers-v6-ordersearch", "security": [ { "application": [ "read" ] } ], "parameters": [ { "name": "ingramOrderNumber", "in": "query", "description": "The Ingram Micro order number.", "required": false, "schema": { "type": "string" } }, { "name": "orderStatus", "in": "query", "description": "Ingram Micro order status.", "required": false, "schema": { "type": "string", "enum": [ "SHIPPED", "PROCESSING", "ON HOLD", "BACKORDERED", "CANCELLED" ] } }, { "name": "orderStatus-in", "in": "query", "description": "Ingram Micro order status(can use it for multiple entries).", "required": false, "schema": { "type": "array", "items": { "type": "string", "uniqueItems": false } } }, { "name": "ingramOrderDate", "in": "query", "description": "Search by Order date(yyyy-MM-dd).", "required": false, "schema": { "type": "string", "example": "2021-04-23" } }, { "name": "ingramOrderDate-bt", "in": "query", "description": "Search with start and end date(only 2 entries allowed).", "required": false, "schema": { "type": "array", "items": { "type": "string", "uniqueItems": false } } }, { "name": "IM-CustomerNumber", "in": "header", "description": "Your unique Ingram Micro customer number.", "required": true, "schema": { "type": "string", "example": "20-222222" } }, { "name": "IM-CountryCode", "in": "header", "description": "Two-character ISO country code.", "required": true, "schema": { "type": "string", "example": "US" } }, { "name": "IM-CorrelationID", "in": "header", "description": "Unique transaction number to identify each transaction accross all the systems.", "required": true, "schema": { "type": "string", "example": "fbac82ba-cf0a-4bcf-fc03-0c508457f219-bw0a102j" } }, { "name": "IM-SenderID", "in": "header", "description": "Unique value used to identify the sender of the transaction. Example: best_buy", "required": false, "schema": { "type": "string", "example": "best_buy" } }, { "name": "customerOrderNumber", "in": "query", "description": "Search using your PO/Order number.", "required": false, "schema": { "type": "string" } }, { "name": "pageSize", "in": "query", "description": "Number of records required in the call - max records 100 per page.", "required": false, "schema": { "type": "integer", "default": "25", "format": "int32" } }, { "name": "pageNumber", "in": "query", "description": "The page number reference.", "required": false, "schema": { "type": "integer", "default": "1", "format": "int32" } } ], "responses": { "200": { "description": "OrderSearch_Response to be returned" }, "204": { "description": "No Content", "headers": { "IM-CorrelationID": { "description": "Unique transaction number to identify each transaction accross all the systems.", "schema": { "type": "string" } }, "IM-SenderID": { "description": "Unique value used to identify the sender of the transaction. Example: best_buy", "schema": { "type": "string" } } }, "content": { "application/json": { "examples": { "Success - 200": { "value": { "recordsFound": "123", "pageSize": "25", "pageNumber": "1", "orders": [ { "ingramOrderNumber": "20-RD128", "ingramOrderDate": "2020-04-03T08:54:39+05:30", "customerOrderNumber": "MyPONumber", "vendorSalesOrderNumber": "8987380", "vendorName": "Microsoft", "endUserCompanyName": "ABC TECHNOLOGIES", "orderTotal": "120.00", "orderStatus": "OPEN", "subOrders": [ { "subOrderNumber": "20-RD128-11", "subOrderTotal": "100.00", "subOrderStatus": "SHIPPED", "links": { "topic": "orders", "href": "/resellers/v6/orders/20-RD128-11", "type": "GET" } }, "links": { "topic": "orders", "href": "/resellers/v6/orders/20-RD128", "type": "GET" }, ] } ], "nextPage": "/resellers/v6/orders/[original_parameters]&pageNumber=2", "previousPage": "/resellers/v6/orders/[original_parameters]&pageNumber=1" } }, "No Data Found - 204": { "value": null } } } } }, "400": { "description": "Bad Request" }, "500": { "description": "Internal Server Error", "content": { "application/json": { "examples": { "400 - Bad Request": { "value": { "errors": [ { "id": "d27059e19119", "1ype": "/errors/validation-failed", "message": "Validation failed", "fields": [ { "field": "customerOrderNumber", "message": "Required field is missing" }, { "field": "ingramOrderDate/ingramOrderDate-bt", "message": "input date format error expected format is - yyyy-MM-dd", "value": "2020-10-21" } ] } ] } }, "500 - Internal Server Error": { "value": { "errors": [ { "id": "74681b27-b1ea-454d-9847-d27059e19119", "type": "/errors/server-error", "message": "ConnectivityIssue/ERP issue Contact Ingram Micro API Support" } ] } } } } } } } } } }, "servers": [ { "url": "https://api.ingrammicro.com:443/sandbox/resellers/v6/", "description": "Sandbox" } ], "components": { "schemas": { "OrderSearch_Response": { "type": "object", "properties": { "recordsFound": { "type": "integer", "description": "No of recourds found for the search." }, "pageSize": { "type": "integer", "description": "No of results per page.(default is 25)" }, "pageNumber": { "type": "integer", "description": "Current page number.(default is 1)" }, "orders": { "type": "array", "description": "The details for the order.", "items": { "type": "object", "properties": { "ingramOrderNumber": { "type": "string", "description": "The Ingram Micro order number." }, "ingramOrderDate": { "type": "string", "description": "The date the order was created(UTC)." }, "customerOrderNumber": { "type": "string", "description": "The reseller's order number for reference in their system." }, "vendorSalesOrderNumber": { "type": "string", "description": "The vendor's order number.(only for D-Type Orders)" }, "vendorName": { "type": "string", "description": "The name of the vendor." }, "endUserCompanyName": { "type": "string", "description": "The company name of the end user/customer." }, "orderTotal": { "type": "number", "format" : "decimal", "description": "The total of the order." }, "orderStatus": { "type": "string", "description": "The header-level status of the order.(OPEN/CLOSED/CANCELLED)" }, "subOrders": { "type": "array", "description": "Individual Ingram Micro order numbers associated with a single reseller PO.", "items": { "type": "object", "properties": { "subOrderNumber": { "type": "string", "description": "The sub order number. The two-digit prefix is the warehouse code of the warehouse nearest to the reseller. The middle number is the order number. The two-digit suffix is the sub order number." }, "subOrderTotal": { "type": "number", "format" : "decimal", "description": "The total for the suborder." }, "subOrderStatus": { "type": "string", "description": "The status of the suborder. One of:- Shipped, Canceled, Backordered, Processing, On Hold, Delivered" }, "links": { "type": "array", "description": "Link to Order Details for the sub order(s).", "items": { "type": "object", "properties": { "topic": { "type": "string", "description": "For orders or invoices. For orders the link provides details of the order. For invoices the link provides details of the invoice." }, "href": { "type": "string", "description": "The URL endpoint for accessing the relevant data." }, "type": { "type": "string", "description": "The type of call that can be made to the href link (GET, POST, Etc.)." } } } } } } }, "links": { "type": "object", "description": "Link to Order Details for the order(s).", "properties": { "topic": { "type": "string", "description": "Provides the details of the orders." }, "href": { "type": "string", "description": "The URL endpoint for accessing the relevant data." }, "type": { "type": "string", "description": "The type of call that can be made to the href link (GET, POST, Etc.)." } } } } } }, "nextPage": { "type": "string", "description": "link/URL for accessing next page." }, "previousPage": { "type": "string", "description": "link/URL for accessing previous page." } } }, "OrderSearch_Error_Response": { "type": "object", "properties": { "errors": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string", "description": "Unique Id to identify error." }, "type": { "type": "string", "description": "Describes the type of the error." }, "message": { "type": "string", "description": "Describes the error message." }, "fields": { "type": "array", "items": { "type": "object", "properties": { "field": { "type": "string", "description": "Contains the name of the field." }, "message": { "type": "string", "description": "Gives the description of the field message." }, "value": { "type": "string", "description": "Value sent in the input for the specific field." } } } } } } } } } }, "securitySchemes": { "application": { "type": "oauth2", "flows": { "clientCredentials": { "tokenUrl": "https://api.ingrammicro.com:443/oauth/oauth30/token", "scopes": { "write": "allows modifying resources", "read": "allows reading resources" } } }, "description": "" } } } }