Import Company Users
post
/rest/v16/companies/{companyName}/users/actions/import
This endpoint is used to import users of specified company stored in a zip file. If administration groups are enabled, then only users with User Administrator permission and Access to the Bulk Upload segment are allowed to import users.
Request
Supported Media Types
- multipart/form-data
Path Parameters
-
companyName(required): string
Company login name. For Host Company users, use _host. For Partner Organization users, use partner organization company login name.
Form Parameters
-
file(required): file
Zip file to be imported
Response
Supported Media Types
- application/json
Default Response
Upload File Task details
Root Schema : Task details
Type:
object
Title:
Task details
Task details
Show Source
-
links:
array Links
Title:
Links
Links to the related objects. -
taskId:
integer
Title:
Task Id
The status log task Id.
Nested Schema : Links
Type:
array
Title:
Links
Links to the related objects.
Show Source
-
Array of:
object Reference Links
Title:
Reference Links
Reference links for the Parent, Self, Children and Related as applicable
Nested Schema : Reference Links
Type:
object
Title:
Reference Links
Reference links for the Parent, Self, Children and Related as applicable
Show Source
-
href:
string
Title:
href
URL to the related object -
rel:
string
Title:
Link
Link relationship to the current object
Examples
The following example shows how to import data tables by submitting a POST request to the REST resource using cURL. For more information about cURL, see Use cURL.
curl "https://cpq-123.us.oracle.com/rest/v16/adminMeta/actions/import" \ -X POST \ -H "Accept: application/zip" \ -H "Authorization: Basic c3VwZXJ1c2VyOnFhcGFzcw==" \ -H "cookie: JSESSIONID=fc628c0043c1411b8cc00359b5131ffe4ba4b30680f9d8fb6c91!-1829082220" \ -H "Content-Type: multipart/form-data"
Response Body Sample
{ "taskId": 3022163950, "links": [{ "rel": "related", "href": "https://sitename.oracle.com/rest/v16/tasks/3022163950" } ] }
A task is initiated when you import users and the status log file will be associated with the task. After importing the users, you can view the status of the import and cancel the import.
Get Task Example
To view the status of the users import, initiate the Get Task REST API using the task id from the Import Company Users REST API response.
URI Endpoint Sample
https://sitename.oracle.com/rest/v16/tasks/3022163950
Response Body Sample
{ "id": 3022163950, "dateModified": "11/16/2020 3:44 AM", "links": [{ "rel": "self", "href": "https://sitename.oracle.com/rest/v16/tasks/3022163950" }, { "rel": "parent", "href": "https://sitename.oracle.com/rest/v16/tasks" }, { "rel": "child", "href": "https://sitename.oracle.com/rest/v16/tasks/3022163950/files" } ], "name": "BulkUpload", "category": { "lookupCode": "4", "displayValue": "Bulk Upload" }, "status": "Completed", "executionTime": "11/16/2020 3:44 AM", "dateAdded": "11/16/2020 3:44 AM" }