The basic use of the Sell Feed API includes creating tasks, getting task status and information, uploading files, and getting files or reports. The following outlines the basic General Sell API Tasks to use these methods.
Note: The order_task and task endpoints are ready for use. Coming Soon! The customer_service_metric_task resources are not ready for use but will be available soon.
Note: The location response header for the create task contains the URL to the task. Use this URL to call methods associated with the applicable create task call.
Use a POST call to create a task using the method associated with the resource. Some create tasks require you to specify filter criteria (like createCustomerServiceMetricTask and createOrderTask), and some do not (like createTask).
The location response header contains the getTask call URI to retrieve the created task. Use this call URI to retrieve the task status through a getTask call. The eBay-assigned task ID is passed in as a path parameter to identify the task to retrieve. Depending on the type of feed/report that will be uploaded/downloaded, you can also provide filter criteria in the request payload of the method to customize the report.
Use a GET call to check the status of a created task. For example, call the getTask method to return the status of a tasks created with the createTask method. When a status of
COMPLETED_WITH_ERROR is returned, the file has been processed and you can proceed with the next task (the file can be uploaded or downloaded). Send the created eBay-assigned task ID when calling the method.
To check the status of multiple tasks, use a getTasks method with date filters and/or tasks associated with a specific feed type. You can limit the tasks returned by using or adjusting URI filters such as date_range or look_back_days.
In similar fashions, retrieve the status of createCustomerServiceMetricTask/s or createOrderTask/s calls using their associated get methods. For example, to check the status of a created Order Task, call the getOrderTasks method with the task ID returned from the createOrderTask method passed in as a path parameter.
To download a report, use a GET call. Download a report by calling the getResultFile method with the task ID passed in as a path parameter.
You can acknowledge the orders that you have already fulfilled by uploading a file. To upload a file, use POST calls. First, create an upload task using the createTask method for the feedType
LMS_ORDER_ACK. After this task has been created (when the returned status is
CREATED), you can upload the acknowledgment file. Upload the acknowledgment file by calling the uploadFile method with the task ID passed in as a path parameter.
Use a GET call to retrieve a file that has been uploaded using uploadFile. Download the file by calling the getResultFile method with the task ID passed in as a path parameter.