POST /Root/{*virtualPath}/
Creates a content folder in the specified virtual directory folder and returns the URL link to the folder location. This resource maps to the virtual folder in the content library, accordingly the virtual path is either complete or a partial path to a destination content folder or file.
Required Scope Token
bsn.api.main.content.create
______________________________________________________________
Segment
virtualPath
string
The location of the content instance in the BSN.cloud virtual directory
______________________________________________________________
Request Body
______________________________________________________________
Response
Success Response Body
201: Returns the new resource created and referenced by the Uri (given by the Location header field) in the response. The response includes the Content Folder Entity.
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request or request body is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
415: The server cannot accept the data representation that you sent (as specified in the "Content-Type" header)
5XX: Any 500 code is an internal server error
GET /Count/
Retrieves the number of content files on the network matching the specified filter criteria. If no filter is included, this call returns the total number of content files on the network.
Required Scope Token
bsn.api.main.content.retrieve
______________________________________________________________
Query String Parameter
filter
string optional
An expression for filtering search results.
______________________________________________________________
Response
Success Response Body
200: The content file count is returned as an integer value.
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
5XX: Any 500 code is an internal server error
GET /{id:int}/
Retrieves the specified content file
Required Scope Token
bsn.api.main.content.retrieve
______________________________________________________________
Segment
id
int
A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Query String Parameters
These parameters should only be used when requesting an image (they depend on the representation type):
maxWidth
uShort optional
The maximum width of the content instance (this should equal 100).
maxHeight
uShort optional
The maximum height of the content instance (this should equal 100).
______________________________________________________________
Response
Success Response with Body
200: Returns either the Content Entity or the file associated with the requested content, depending on what is specified in the request.
Success Response
304: The resource was not modified since the time specified in the “If-Modified-Since” header
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
5XX: Any 500 code is an internal server error
PUT /{id:int}/
Update the specified content files.
Required Scope Token
bsn.api.main.content.update
______________________________________________________________
Segment
id
int
A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Request Body
The Content Entity
______________________________________________________________
Response
Success
204: The specified content file has been updated on the network
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: Either the request or request body is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
412: Precondition failed (the resource changed since the time specified in the “If-Unmodified-Since” header value)
415: The server cannot accept the data representation that you sent (as specified in the "Content-Type" header)
5XX: Any 500 code is an internal server error
DELETE /{id:int}/
Removes the specified content file.
Required Scope Token
bsn.api.main.content.delete
______________________________________________________________
Segment
id
int
A unique identifier for the content instance to delete.
______________________________________________________________
Response
Success
204: The specified content file has been removed
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
412: Precondition failed (the resource changed since the time specified in the “If-Unmodified-Since” header value)
5XX: Any 500 code is an internal server error
GET /{id:int}/Tags/
Returns tags associated with the specified content file.
Required Scope Token
bsn.api.main.content.retrieve
______________________________________________________________
Segment
id
int
A unique identifier for the content file. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Response
Success Response Body
200: Returns a list of properties and their values. For example:
"string::[sys].[Content].<MediaType>": "Image", "int::[Content].<Category>": 42
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
5XX: Any 500 code is an internal server error
POST /{id:int}/Tags/
Adds one or more tags to the specified content file. The following are valid system-defined values for content tags: "FileName", "FileSize", "ContentType", and "UploadDate".
Required Scope Token
bsn.api.main.content.update
______________________________________________________________
Segment
id
int
A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Request Body
tags
DynamicObject
A collection of key value pairs where the key is tag name, and the value is tag value. See the Tags
entry in Player Entity for more information.
______________________________________________________________
Response
Success
204: A new tag has been successfully added to the specified content file
Failure
400: Either a tag with the specified key was already defined, the request is malformed and therefore invalid, or there is a conflict
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
415: The server cannot accept the data representation that you sent (as specified in the "Content-Type" header)
5XX: Any 500 code is an internal server error
DELETE /{id:int}/Tags/
Removes one or more tags from the specified content file
Required Scope Token
bsn.api.main.content.update
______________________________________________________________
Segment
id
int
A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Request Body
list
List<string>
A list of key/value pairs that specify the tags to delete from the content file
______________________________________________________________
Response
Success
204: The specified tags have been removed from the specified content file
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request or request body is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
412: Precondition failed (the resource changed since the time specified in the “If-Unmodified-Since” header value)
5XX: Any 500 code is an internal server error
GET /Operations/
Returns the operational permissions granted to roles for specific business operations
Required Scope Token
bsn.api.main.operations.retrieve
______________________________________________________________
Response
Success Response Body
200: Returns the Business Operations Entity
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
5XX: Any 500 code is an internal server error
GET /{id:int}/Permissions/
Returns object permissions for a given content instance.
Required Scope Token
bsn.api.main.content.retrieve
______________________________________________________________
Segment
id
int
A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Response
Success Response Body
200: Returns an array of Permission entities
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
5XX: Any 500 code is an internal server error
POST /{id:int}/Permissions/
Adds permissions to the specified content instance
Required Scope Token
bsn.api.main.content.update
______________________________________________________________
Segment
id
int
A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Request Body
An array of Permission entities
______________________________________________________________
Response
Success
204: The permissions were successfully added to the specified content instance
Failure
400: The request is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
415: The server cannot accept the data representation that you sent (as specified in the "Content-Type" header)
5XX: Any 500 code is an internal server error
DELETE /{id:int}/Permissions/
Removes permissions from the specified content file
Required Scope Token
bsn.api.main.content.update
______________________________________________________________
Segment
id
int
A unique identifier for the content file. This value is generated by the server when the content file is uploaded.
______________________________________________________________
Request Body
An array of Permission entities
______________________________________________________________
Response
Success
204: The specified permissions have been removed from the specified content file
Failure
300: The requested representation could not be returned because it is ambiguous (there are multiple requested representations)
400: The request or request body is malformed and therefore invalid
401: The access token is invalid or not specified
403: The supplied access token, though valid, doesn't provide access to this method
404: The server cannot find the requested resource (the path does not exist)
406: The server cannot return the data representation that you requested (as specified in the "Accept" header)
5XX: Any 500 code is an internal server error