Server API - Create Watch Folder Source

Last Updated: Dec 16, 2014 03:25PM PST
Adds a source to the specified watch folder. If the watch folder has a source assigned already, this will
replace the existing source with the new source.

Base URI /api/watchfolders/{folderId}/sources/
Protocol HTTP
HTTP Method POST
Response Formats XML, JSON
Help URL /api/watchfolders/help/operations/CreateWatchFolderSource

Common Parameters
Name Required Description
folderId Yes Unique ID for the watch folder

Request Data Fields
Name Data Type Required Description
SourceMediaInfo Element Yes Element contains data describing a watch folder source location
Created DateTime Private Date and time (GMT) that the source record was created
CredentialId Guid No Optional ID of a stored credential set to use to access the source
FileName String No The file name will be treated as a folder if it ends with a slash (/) for watch folders.
FileSize Long No Not used with watch folders
FileUri String No File Uri is the fully specified URI to the source file or location. Supported sources ftp://, sftp://, s3://, azureblob://, and file://
JobId Guid Private Not used with watch folders
Modified DateTime Private Date and time the source has been modified, if any
Password String No Password to access secure source if the
CredentialId is not used S3BucketName String Obsolete Name of the S3 bucket with the source. Required if the type is S3
SourceId Guid Private Unique ID for the source record
Type Enumeration Obsolete Type of source. The source can be: 0: Undefined – Not Set 1: Uri – Source is defined by a URI 2: S3 – Source is on Amazon S3
UserName String No Username for accessing a secured source location or file and when not using CredentialId.
WatchFolderId Guid Private Watch folder ID if the source is attached to a watch folder.

Response Data Fields
Name Data Type Required Description
SourceMediaInfo Element Yes Element contains data describing a watch folder source location (XML)
Created DateTime Private Date and time (GMT) that the source record was created.
CredentialId Guid No Optional ID of a stored credential set to use to access the source.
FileName String No The file name will be treated as a folder if it ends with a slash (/) for watch folders.
FileSize Long No Not used with watch folders.
FileUri String No File Uri is the fully specified URI to the source file or location. Supported sources are ftp://, sftp://, s3://, azureblob://, and file://
JobId Guid Private Not used with watch folders
Modified DateTime Private Date and time the source has been modified, if any.
Password String No Password to access secure source if the CredentialId is not used.
S3BucketName String Obsolete Name of the S3 bucket with the source. Required if the type is S3.
SourceId Guid Private Unique ID for the source record.
Type Enumeration Obsolete Type of source. The source can be: 0: Undefined – Not Set 1: Uri – Source is defined by a URI 2: S3 – Source is on Amazon S3
UserName String No Username for accessing a secured source location or file and when not using CredentialId.
WatchFolderId Guid Private Unique ID of the watch folder to which this source belongs.

Example cURL call:
curl -H "Accept: application/xml" -H "Content-Type: application/xml" -H "x-Authorization: Basic
YWRtaW46YWRtaW4=" -X POST -d
"<SourceMediaInfo><FileUri>file://C://testFolder</FileUri></SourceMediaInfo>"
http://<host>/api/watchfolders/<WatchFolder_GUID/sources/
squeezesupport@sorensonmedia.com
https://cdn.desk.com/
false
desk
Loading
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
about
false
Invalid characters found
/customer/en/portal/articles/autocomplete