UploadDocument
Upload document assets in your LinkedIn organization which can be used to create posts.
Stored Procedure-Specific Information
To use this stored procedure, exactly one of the following parameters must be specified (in addition to OwnerURN):- LocalFile
- FileStream
- FileData
If no parameter is used, or more than one parameter is used, the procedure fails.
Below are some other restrictions for document assets:
- The document's size can't exceed 100MB and 300 pages.
- The following formats are supported: PPT, PPTX, DOC, DOCX, and PDF.
To execute this procedure, enter:
EXEC UploadDocument OwnerURN='urn:li:organization:12345', LocalFile='C:/temp/my_document.pdf'
Input
| Name | Type | Required | Accepts Input Streams | Description |
| OwnerURN | String | True | False | The URN of the organization to use as the new document's owner. |
| LocalFile | String | False | False | The absolute path of the document in your system to upload to LinkedIn. |
| FileStream | String | False | True | An 'InputStream' object to use for reading the data of the document to upload to LinkedIn. Useful when accessing files in your environment ('LocalFile' parameter) is not a viable option. |
| FileData | String | False | False | A Base64-encoded string containing the data of the document to upload to LinkedIn. Useful in cases when neither the 'LocalFile' parameter nor the 'FileStream' parameter are viable options. |
Result Set Columns
| Name | Type | Description |
| DocumentURN | String | The URN of the new document asset that was created, if the upload was successful. |