Get and Process Product Uploads

You can use the Product Uploads resource to upload product data from data files to staging interface. To upload the product data, you create a product upload for processing the data files received from multiple external source systems and upload the data from the data files to staging interface.

Let's discuss scenarios, where say Green Corp. is a supplier who uses a client to connect to a partner application that uses REST API to:

  • Get product uploads

  • Post a new product upload

  • Process a product upload

Get Product Uploads

Let's say you want to get all product uploads created by Green Corp. to determine the frequency at which Green Corp.is uploading the product data. In this scenario, you get the top 200 product uploads of Green Corp. whose supplier identifier is 12496.

Example URL

Use this resource URL format.

GET

curl -u username:password "https://servername/fscmRestApi/resources/version/productUploads?limit=200 &q=SupplierId=12496" -H 'authorization: Basic c2Ntb3BlcmF0aW9uczpXZWxjb21lMQ==' -H 'cache-control: no-cache']"

This table shows the values that the partner application collects from the response payload and displays in fields in the client application.

Attribute Description

SupplierId

Value that uniquely identifies a supplier.

ProductUploadName

Name of the product upload through which products are uploaded.

CreationDate

Date and time when the application created the product upload.

Example Response

Here's an example of the response body in JSON format.

{
	"items": [
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2018-07-06T23:04:40+05:30",
		"LastUpdateDate": "2018-07-06T23:05:26.282+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100168538409,
		"ProductUploadName": "IM_SP_R9QA_EFF_NT_SR_IL_070618",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100168538409",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000278"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100168538409",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-04-01T17:16:12.579+05:30",
		"LastUpdateDate": "2019-04-01T17:27:58+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176274399,
		"ProductUploadName": "Test10017_Test-P1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176274399",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000378"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176274399",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-04-01T17:10:53+05:30",
		"LastUpdateDate": "2019-04-01T17:11:23.884+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176274390,
		"ProductUploadName": "Test10016_Test-P1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176274390",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000178"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176274390",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-04-01T17:13:10.778+05:30",
		"LastUpdateDate": "2019-04-01T17:28:18+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176274393,
		"ProductUploadName": "Test10016_Test-P1_1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176274393",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000378"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176274393",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-03-26T18:58:44+05:30",
		"LastUpdateDate": "2019-03-27T11:37:20+05:30",
		"LastUpdatedBy": "PIMQA",
		"ProductUploadId": 300100176239514,
		"ProductUploadName": "Test10015-P1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176239514",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000478"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176239514",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-03-27T16:19:01+05:30",
		"LastUpdateDate": "2019-03-27T16:23:06+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176239523,
		"ProductUploadName": "Test10016-P1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176239523",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000378"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176239523",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-04-03T11:38:49+05:30",
		"LastUpdateDate": "2019-04-03T11:55:32+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176344389,
		"ProductUploadName": "Test10017_Test-P1_@$(1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176344389",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000478"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176344389",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-04-03T13:54:29+05:30",
		"LastUpdateDate": "2019-04-03T13:54:30.282+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176346394,
		"ProductUploadName": "Test_Product_Upload",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176346394",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000178"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176346394",
			"name": "productUploads",
			"kind": "item"
		}
		]
	},
	{
		"CreatedBy": "CVSUPPA",
		"CreationDate": "2019-04-03T10:52:45+05:30",
		"LastUpdateDate": "2019-04-03T10:53:25.677+05:30",
		"LastUpdatedBy": "CVSUPPA",
		"ProductUploadId": 300100176343389,
		"ProductUploadName": "Test10017_Test-P1_@1",
		"SupplierId": 12496,
		"links": [
		{
			"rel": "self",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176343389",
			"name": "productUploads",
			"kind": "item",
			"properties": {
				"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000178"
			}
		},
		{
			"rel": "canonical",
			"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176343389",
			"name": "productUploads",
			"kind": "item"
		}
		]
	}
	],
	"count": 9,
	"hasMore": false,
	"limit": 200,
	"offset": 0,
	"links": [
	{
		"rel": "self",
		"href": "https://servername/fscmRestApi/resources/version/productUploads",
		"name": "productUploads",
		"kind": "collection"
	},
	{
		"rel": "action",
		"href": "https://servername/fscmRestApi/resources/version/productUploads/action/process",
		"name": "process",
		"kind": "other"
	}
	]
}

Create a New Product Upload

If Green Corp. wants to create a new product upload to upload the product data from a data file to the staging interface. In this scenario, Green Corp. creates a new product upload using the POST operation.

Example URL

Use this resource URL format.

POST

curl -u username:password -X POST -H "Content-Type:application/vnd.oracle.adf.resourceitem+json" -d 'request payload' 
"https://servername/fscmRestApi/resources/version/productUploads" -H 'authorization: Basic c2Ntb3BlcmF0aW9uczpXZWxjb21lMQ==' -H 'cache-control: no-cache' "

Example Request

Here's an example of the request body in JSON format.

{ 
	"ProductUploadName":"Test_Product_Upload"
}

Example Response

Here's an example of the response body in JSON format.

{
	"CreatedBy": "CVSUPPA",
	"CreationDate": "2019-04-03T13:54:29+05:30",
	"LastUpdateDate": "2019-04-03T13:54:30.282+05:30",
	"LastUpdatedBy": "CVSUPPA",
	"ProductUploadId": 300100176346394,
	"ProductUploadName": "Test_Product_Upload",
	"SupplierId": 12496,
	"links": [
	{
		"rel": "self",
		"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176346394",
		"name": "productUploads",
		"kind": "item",
		"properties": {
			"changeIndicator": "ACED0005737200136A6176612E7574696C2E41727261794C6973747881D21D99C7619D03000149000473697A65787000000001770400000001737200116A6176612E6C616E672E496E746567657212E2A0A4F781873802000149000576616C7565787200106A6176612E6C616E672E4E756D62657286AC951D0B94E08B02000078700000000178"
		}
	},
	{
		"rel": "canonical",
		"href": "https://servername/fscmRestApi/resources/version/productUploads/300100176346394",
		"name": "productUploads",
		"kind": "item"
	}
	]
}

This table shows the values that the partner application collects from the response payload and displays in the client application.

Attribute Description

ProductUploadName

Name of the product upload through which products are uploaded.

CreationDate

Date and time when the application created the product upload.

CreatedBy

User who created the product upload.

Process a Product Upload

When Green Corp. wants to upload a data file containing product data to staging interface update, Green Corp. can use the POST operation.

Example URL

Use this resource URL format.

POST

curl -u username:password -X POST -H "Content-Type:application/vnd.oracle.adf.resourceitem+json" -d 'request payload' 
"https://servername/fscmRestApi/resources/version/productUploads" -H 'authorization: Basic c2Ntb3BlcmF0aW9uczpXZWxjb21lMQ==' -H 'cache-control: o-cache'"

Example Request

Here's an example of the request body in JSON format.

{
	"name":"process", 
	"parameters":
	[
	{
		"productUploadName":"Test_Product_Upload"
	},
	{ 
		"spokeSystemCode":"SUPPLIER_1" 
	},
	{
		"dataFilePath" : "/scm/item/import/SupplierImport.csv"
	},
	{
		"template":"Supplier Map"
	} 
	]
}

Example Response

Here's an example of the response body in JSON format.

{
	"result": "The file upload is complete."
}

The partner application collects this value from the response payload and displays in the client application.

Note:

  • Oracle recommends that you create a new product upload every time you call the Process a product upload action to upload product data from a data file.
  • Before calling the Process a product upload action, you need to upload the data file and the attachments zip file to the scm$/item$/import$/ Oracle WebCenter Content account. Only the user who uploads the data file and attachments zip file to Oracle WebCenter Content can upload the product data and attachments from the data or attachment files to the staging interface.
  • If product data stewards need to upload the product data from the data file to the staging interface and add that data to a specific item batch for import, then they need to first create the item batch using the Item Batch Maintenance SOAP service to generate the batch ID. The data stewards can then call the Process a product upload action and send the batch ID as a parameter to upload the product data to the staging interface and add it to the specified item batch for import. If the schedule of the item batch is set to On Data Load, then the import process is called to import the data. If the schedule of the item batch is set to Manual, then the item batch needs to be submitted for import using the Item Batch Maintenance SOAP service.
  • You cannot change the category and item class of the product using the Product Uploads resource.