openapi: 3.0.0 servers: - url: 'https://api.qa.se.com/v1/supply-chain/order-status' description: QA/test environment - url: 'https://api.se.com/v1/supply-chain/order-status' description: Production info: title: Order Status API for indirect customers version: '1.0' description: >- This API provides current order status, order shipment schedule and also list of items in the order based on parameters passed in the request. Returned information is based on registered account. contact: url: "http://www.se.com" name: "Contact Us" email: "distributorapiportal.global@se.com" paths: /orders/{country}: get: responses: '200': description: The list of orders for the requested parameters. content: application/json: schema: type: object properties: orderList: type: array items: $ref: '#/components/schemas/order' pagination: type: object properties: totalNumberOfRecords: type: integer format: int32 pageNumber: type: integer format: int32 totalNumberOfPages: type: integer format: int32 '400': $ref: '#/components/responses/Common_Oas3_400' '401': $ref: '#/components/responses/Common_Oas3_401' '403': $ref: '#/components/responses/Common_Oas3_403' '404': $ref: '#/components/responses/Common_Oas3_404' '429': $ref: '#/components/responses/Common_Oas3_429' '500': $ref: '#/components/responses/Common_Oas3_500' summary: Search for the order operationId: orderSearch tags: - orderStatus parameters: - in: query name: order-number description: >- Order number, starting from a value. Might me a full order number or just a "starting from". schema: type: string minLength: 3 - in: query name: order-status description: >- The order status is one of the pre-defined values. The full list available for your country can be obtained from your local DCX. schema: type: string - in: path name: country required: true description: The country code (US, RU, etc) schema: type: string - in: query name: page description: >- A page number. Default value = 1, if the parameter exceeds the number of pages, the last page will be returned. schema: type: integer - in: query name: page-size description: >- The size of the page. Maximum is 100, default value is 10. schema: type: integer description: The search of the order with particular paramaters /orders/{country}/{order-number}/{item-number}/shipment-schedules: get: responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/shipping-schedule' '400': $ref: '#/components/responses/Common_Oas3_400' '401': $ref: '#/components/responses/Common_Oas3_401' '403': $ref: '#/components/responses/Common_Oas3_403' '404': $ref: '#/components/responses/Common_Oas3_404' '429': $ref: '#/components/responses/Common_Oas3_429' '500': $ref: '#/components/responses/Common_Oas3_500' summary: Get the Shipping Schedule for an order description: Returns the shipment schedule of the order for each line operationId: shipmentSchedule tags: - orderStatus parameters: - in: path name: country required: true schema: type: string - in: path name: order-number required: true schema: type: string - in: path name: item-number required: true schema: type: string /orders/{country}/{order-number}: get: responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/orderDetails' '400': $ref: '#/components/responses/Common_Oas3_400' '401': $ref: '#/components/responses/Common_Oas3_401' '403': $ref: '#/components/responses/Common_Oas3_403' '404': $ref: '#/components/responses/Common_Oas3_404' '429': $ref: '#/components/responses/Common_Oas3_429' '500': $ref: '#/components/responses/Common_Oas3_500' summary: Get the order and item details operationId: details parameters: - in: path name: country required: true description: Two-letter country code (US, RU, etc) schema: type: string - in: path name: order-number required: true description: The number of your order schema: type: string - in: query name: item-number description: >- The ID of the item in the order. If not used, all items of the order will be returned. schema: type: string tags: - orderStatus description: >- This operation will return the information about the order, it's items and general shipment info. tags: - name: orderStatus description: All related to the Order Status security: - oauth2: [] components: schemas: shipping-schedule: type: object title: ShippingSchedule description: >- The order shipping report object. Contains info about the shipping status of each item in the order. properties: orderNumber: type: string description: The ID number of the order (as shown in mySE) example: AB12345 poNumber: type: string example: PO098234 description: The number of the payment order. item: type: object properties: itemNumber: type: string example: '79895' description: The ID of the line catalogNumber: type: string description: Catalog Number of the product shippingScheduleList: type: array description: >- A Shipping Schedule object. Contains all necessary info about the shipping and tracking. May contain several tracking numbers. items: type: object properties: shippingSchedule: type: object properties: shipmentNumber: type: string example: '2010093835' description: A shipping number provided by SE shipmentQuantity: type: number example: 65 description: The quantity shipped shipmentLocation: type: string example: '65484984251' description: The encoding of the shipping location carrierName: type: string example: DHL CENTRO_STD 1 DIA description: >- The name of the company delivering the shipment promiseDate: type: string description: >- The date in UTC when an order should be delivered format: date-time notBeforeDate: type: string description: >- The date in UTC before which the order won’t be delivered format: date-time shipmentDate: type: string description: The actual shipping date in UTC format: date-time routing: type: string example: Routing description: The routing details of the shipping. trackingNumbersList: type: array description: The details of the cracking items: type: object properties: tracking: type: object properties: trackingNumber: type: string example: '0857558875' description: >- The tracking number in the delivery system trackingURL: type: string description: Tracking URL, sent as CDATA trackingURLMobile: type: string description: Tracking URL for Mobile, sent as CDATA order: type: object title: Order properties: orderNumber: type: string example: '1236484' description: The number of the order listed poNumber: type: string example: PO203948 description: The number of the payment order for Schneider Electric releaseDate: type: string description: The date of releasing the order in UTC format: date-time projectName: type: string example: The very best project ever description: The name of the project to which the order is linked. expressDelivery: type: boolean example: false description: The flag of order urgency. projectManager: type: string example: John Wick description: The name of your project manager orderStatus: $ref: '#/components/schemas/orderStatus' description: The general Order object containing info about several items orderDetails: title: OrderDetails type: object description: >- The details of the order, including its item list and items' shipping data properties: orderNumber: type: string example: '12345656541' description: The 10-digit number of your order poNumber: type: string example: PO12039809 description: The number of the payment order of Schneider Electric. accountName: type: string example: The very very best account description: The text description of the account completeDelivery: type: boolean example: true description: Shows of the order is fully delivered or not releaseDate: type: string description: The date in UTC when the order was released format: date-time expressDelivery: type: boolean example: false description: >- Shows whether the order is delivered in express-mode or not. projectName: type: string example: Disney Land description: The name of the project the order is reffering to projectManager: type: string example: John Wick description: The name of your project manager orderStatus: $ref: '#/components/schemas/orderStatus' customer: $ref: '#/components/schemas/customer' itemList: type: array description: The list of order items items: type: object properties: item: type: object description: >- One item for one commercial reference in the order properties: itemNumber: type: string example: '3' description: The number of the item in the order. description: type: string example: The short description of the line description: >- Just a description of this ordered product itemHasShipped: type: boolean example: false description: >- Shows if the item has been shipped or not. catalogNumber: type: string description: >- The catalog number of the product ordered totalQtyOrdered: type: integer example: 234 description: The ordered quantity of the product. totalQtyShipped: type: integer example: 45 description: The quantity shipped. itemStatusCode: type: string example: '03' description: The code of the item status. itemStatusLabel: type: string example: In Delivery description: >- The easy-to-read description of the current status of the item status. totalBackOrdered: type: number example: 12 description: The amount of back-ordered products notBeforeQuantity: type: number example: 5 description: The "Not Before" quantity totalQtyCancelled: type: number example: 3 description: The total amount of cancelled products shipTo: type: array description: The block of shipping information items: type: object properties: shipToCountry: type: string example: France description: The target country orderStatus: type: object description: One of the predefined statuses of the order title: OrderStatus properties: orderStatusCode: type: string example: DV description: The code of the status as shown in mySE orderStatusLabel: type: string example: Delivered description: >- The label of the order status. Is dependent on the country set up in mySE orderStatusDesctiption: type: string example: The order has been delivered description: The more detailed information about the order status. customer: type: object properties: customerID: type: string example: '11584984954' description: >- The ID number of the distributor's customer (only if applicable) customerName: type: string example: Incredible Inc description: The name of the distributor title: Customer description: Basic customer info Error: type: object title: Error Response description: Error response returned to the consumer when an HTTP error status has occurred. properties: code: type: string example: MISSING_FIELD or 12345 description: |- Service-defined error code which may be numeric or a string. Errors detected by the APIM platform result in the following codes. BAD_REQUEST (for 400) UNAUTHORIZED (for 401) FORBIDDEN (for 403) NOT_FOUND (for 404) GONE (for 410) PRECONDITION_FAILED (for 412) TOO_MANY_REQUESTS (for 429) INTERNAL_SERVER_ERROR (for 500) NOT_IMPLEMENTED (for 501) Any specific service validation errors would replace BAD_REQUEST. userMessage: type: string example: 'Required field is missing: productSku' description: Human-readable general description of the error. developerMessage: type: string description: Optional human-readable description of the error details. example: 'Product master API ParseException: required tag expected' moreInfo: type: string description: 'Optional link to error documentation, which has more information about the error.' format: uri example: 'https://example.com/product-master/v1/error/12345' required: - code - userMessage securitySchemes: oauth2: type: oauth2 description: Oauth2 Application security flows: clientCredentials: tokenUrl: /token scopes: get_order_status: Retrieve the status of the order responses: Common_Oas3_400: description: 'Request is invalid and cannot be processed due one or more issues such as syntax errors, missing required fields, out of range values, conflicting query parameters, or unknown URI.' content: application/json: schema: $ref: '#/components/schemas/Error' examples: Example: value: code: BAD_REQUEST userMessage: 'Request is invalid and cannot be processed due one or more issues such as syntax errors, missing required fields, out of range values, conflicting query parameters, or unknown URI.' developerMessage: Request content is malformed or exceeded structural limits moreInfo: 'https://example.com/error/123' Common_Oas3_401: description: 'The client is not authorized to perform this request because its identity has not yet been established, or the token is invalid or has expired.' content: application/json: schema: $ref: '#/components/schemas/Error' examples: Example: value: code: UNAUTHORIZED userMessage: 'The client is not authorized to perform this request because its identity has not yet been established, or the token is invalid or has expired.' developerMessage: Invalid Access Token moreInfo: 'https://example.com/error/123' Common_Oas3_403: description: The client does not have permission to perform the requested action e.g. POST or DELETE. content: application/json: schema: $ref: '#/components/schemas/Error' examples: Example: value: code: FORBIDDEN userMessage: The client does not have permission to perform the requested action e.g. POST or DELETE. developerMessage: Http verb DELETE is not supported for path suffix /installed-products/track moreInfo: 'https://example.com/error/123' Common_Oas3_404: description: Requested resource does not exist on the server. It is assumed that the URI is valid for this type of resource. content: application/json: schema: $ref: '#/components/schemas/Error' examples: Example: value: code: NOT_FOUND userMessage: Requested resource does not exist on the server. It is assumed that the URI is valid for this type of resource. developerMessage: Records not found moreInfo: 'https://example.com/error/123' Common_Oas3_429: description: Number of requests has exceeded the client's rate limits. content: application/json: schema: $ref: '#/components/schemas/Error' examples: Example: value: code: TOO_MANY_REQUESTS userMessage: Number of requests has exceeded the client’s rate limits. developerMessage: Spike arrest violation moreInfo: 'https://example.com/error/123' Common_Oas3_500: description: Requested operation encountered an unexpected server error. content: application/json: schema: $ref: '#/components/schemas/Error' examples: Example: value: code: INTERNAL_SERVER_ERROR userMessage: Requested operation encountered an unexpected server error. developerMessage: 'Target service is unavailable, please try again later.' moreInfo: 'https://example.com/error/123'