Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This endpoint allows for management of content files (and content tags) on the network.

/content/

GET

Retrieves a list of content files on the network.

Parameters

  • marker: A value specifying which page to retrieve. This value is useful if the isTruncated entry in the response body of the previous GET call indicates that the number of Content instances exceeds the pageSize.
  • pageSize: The maximum number of Content instances that can be contained in the response body
  • filter:  An expression for filtering search results.
  • sort: An expression for sorting the search results. The sort expression specifies the entry used for sorting and the ascending/descending (ASC/DESC) sorting order (e.g. "[content].[fileName] ASC")

Response Body

  • [int] totalItemCount: The total number of Content instances relevant to the query
  • [int] pageSize: The maximum number of Content instances that can be returned in a single response
  • [bool] isTruncated: A flag indicating whether the totalItemCount exceeds the pageSize
  • [string] nextMarker: A value that can be included with a subsequent GET call to return additional results that have been truncated
  • [string] sortExpression: The sort expression specified in the URL
  • [string] filterExpression: The filter expression specified in the URL
  • [Content[]]items: An array of Content object instances. Each Content instance can have the following entries:  Anchorcontent_objectcontent_object
    • [int] id: A unique identifier for the Content instance. This value is generated by the server when the content file is uploaded.
    • [string] fileName: The name of the content file
    • [string] mediaType: The file type, which can be one of the following:
      • "Video": An MPG, MP4, TS, MOV, VOB, or WMV video file
      • "Image": A JPG, PNG, or BMP image file
      • "Audio": An MP3 or WAV audio file
      • "Text": A TXT file
      • "Other": An unknown file type
    • [string] physicalPath: The location of the file in the server directory
    • [string] virtualPath: The location of the file in the BSN virtual directory
    • [string] thumbPath: The location of the thumbnail for the video/image file in the server directory. This value is a blank string for audio, text, and unknown file types.
    • [int] fileSize: The file size (in bytes)
    • [string] fileHash: The hash algorithm and the value that results from performing the hash algorithm on the file. The string is formatted as "{algorithm}:{value}" (e.g. "SHA1:6DB465879088280AAC52DC22B07ED0AD493A99D4").
    • [string] uploadDate: A UTC timestamp indicating when the file was uploaded to BSN. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
    • [string] fileLastModifiedDate: A UTC timestamp indicating when the file was last modified on BSN. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
    • [string] probeData: The audio/video probe data. This value is a blank string for image, text, and unknown file types.
    • [Presentation[]]presentations: An array of Presentation object instances representing presentations that use the content file. Each Presentation instance can have the following values:
      • [int] id: A unique identifier for the Presentation instance
      • [string] name: The presentation name
      • [string] type: The presentation type
    • [DynamicPlaylist[]]dynamicPlaylists: An array of DynamicPlaylist object instances representing Dynamic Playlists that contain the content file. Each DynamicPlaylist instance can have the following values:
      • [int] id: A unique identifier for the DynamicPlaylist instance
      • [string] name: The Dynamic Playlist name
    • [LiveMediaFeed[]]liveMediaFeeds: An array of LiveMediaFeed object instances representing Live Media Feeds that contain the content file. Each LiveMediaFeed instance can have the following values:
      • [int] id: A unique identifier for the LiveMediaFeed instance
      • [string] name: The Live Media Feed name
    • [TaggedPlaylist[]]taggedPlaylists: An array of TaggedPlaylist object instances representing Tagged Playlists that contain the content file. Each TaggedPlaylist instance can have the following values:
      • [int] id: A unique identifier for the TaggedPlaylist instance
      • [string] name: The TaggedPlaylist name
    • [Tag{}] tags: An object that lists tags assigned to the content file. Each Tag is formatted as follows: "<value_type>::<tag_type>.<tag_key>":"<value>".
      • value_type: "string" or "number"
      • tag_type: "[Content]" (a user-defined key/value) or "[sys].[Content]" (a system-defined key/value)
      • tag_key: The tag key
      • value: The tag value
    • [Permission[]]permissions: An array of Permission object instances representing permissions rules assigned to the content file
    Panel
    borderColor#3D3D3D
    bgColor#F4F4F4
    titleColor#3D3D3D
    borderWidth0
    titleBGColor#3D3D3D
    borderStylesolid

    ON THIS PAGE

    Table of Contents
    maxLevel3
    indent20px

    /content/root/{*virtual_path)

    GET

    Retrieves a list of content files in the specified virtual-directory folder.

    Parameters

    • marker: A value specifying which page to retrieve. This value is useful if the isTruncated entry in the response body of the previous GET call indicates that the number of Content instances exceeds the pageSize.
    • pageSize: The maximum number of Content instances that can be contained in the response body
    • sort: An expression for sorting the search results. The sort expression specifies the entry used for sorting and the ascending/descending (ASC/DESC) sorting order (e.g. "[content].[fileName] ASC")

    Response Body

    • [int] totalItemCount: The total number of content files relevant to the query
    • [int] pageSize: The maximum number of Content instances that can be returned in a single response
    • [bool] isTruncated: A flag indicating whether the totalItemCount exceeds the pageSize
    • [string] nextMarker: A value that can be included with a subsequent GET call to return additional results that have been truncated
    • [string] sortExpression: The sort expression specified in the URL
    • [string] filterExpression: The filter expression, which is generated automatically from the virtual path in the URL
    • [Content[]]items: An array of Content object instances. Each Content instance can have the following entries: 
      • [int] id: A unique identifier for the Content instance. This value is generated by the server when the content file is uploaded.
      • [string] fileName: The name of the content file
      • [string] mediaType: The file type, which can be one of the following:
        • "Video": An MPG, MP4, TS, MOV, VOB, or WMV video file
        • "Image": A JPG, PNG, or BMP image file
        • "Audio": An MP3 or WAV audio file
        • "Text": A TXT file
        • "Other": An unknown file type
      • [string] physicalPath: The location of the file in the server directory
      • [string] virtualPath: The location of the file in the BSN virtual directory
      • [string] thumbPath: The location of the thumbnail for the video/image file in the server directory. This value is a blank string for audio, text, and unknown file types.
      • [int] fileSize: The file size (in bytes)
      • [string] fileHash: The hash algorithm and the value that results from performing the hash algorithm on the file. The string is formatted as "{algorithm}:{value}" (e.g. "SHA1:6DB465879088280AAC52DC22B07ED0AD493A99D4").
      • [string] uploadDate: A UTC timestamp indicating when the file was uploaded to BSN. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
      • [string] fileLastModifiedDate: A UTC timestamp indicating when the file was last modified on BSN. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
      • [string] probeData: The audio/video probe data. This value is a blank string for image, text, and unknown file types.
      • [Presentation[]]presentations: An array of Presentation object instances representing presentations that use the content file. Each Presentation instance can have the following values:
        • [int] id: A unique identifier for the Presentation instance
        • [string] name: The presentation name
        • [string] type: The presentation type
      • [DynamicPlaylist[]]dynamicPlaylists: An array of DynamicPlaylist object instances representing Dynamic Playlists that contain the content file. Each DynamicPlaylist instance can have the following values:
        • [int] id: A unique identifier for the DynamicPlaylist instance
        • [string] name: The Dynamic Playlist name
      • [LiveMediaFeed[]]liveMediaFeeds: An array of LiveMediaFeed object instances representing Live Media Feeds that contain the content file. Each LiveMediaFeed instance can have the following values:
        • [int] id: A unique identifier for the LiveMediaFeed instance
        • [string] name: The Live Media Feed name
      • [TaggedPlaylist[]]taggedPlaylists: An array of TaggedPlaylist object instances representing Tagged Playlists that contain the content file. Each TaggedPlaylist instance can have the following values:
        • [int] id: A unique identifier for the TaggedPlaylist instance
        • [string] name: The TaggedPlaylist name
      • [Tag{}] tags: An object that lists tags assigned to the content file. Each Tag is formatted as follows: "<value_type>::<tag_type>.<tag_key>":"<value>".
        • value_type: "string" or "number"
        • tag_type: "[Content]" (a user-defined key/value) or "[sys].[Content]" (a system-defined key/value)
        • tag_key: The tag key
        • value: The tag value
      • [Permission[]]permissions: An array of Permission object instances representing permissions rules assigned to the content file

    POST

    Creates a new folder in the virtual-directory location specified in the URL.

    Request Body

    • [string] name: The folder name

    Response Body

    • [int] id: A unique identifier for the folder. This value is generated by the server when the folder is created.
    • [string] name: The folder name
    • [string] creationDate: A UTC timestamp indicating when the folder is created. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
    • [string] virtualPath: The location of the folder in the BSN virtual directory
    • [string] type: The entity type, which is always "Folder"
    • [string] thumbPath: The location of the thumbnail for the folder in the server directory

    /content/count/

    GET

    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. 

    Parameters

    • filter:  An expression for filtering search results.

    Response Body

    The content-file count is returned as an integer value.

    /content/operations/

    GET

    Returns Business Operations for content.

    Response Body

    • [string] uid: A unique identifier for the Content instance.
    • [string] singularName: The name of the operation in singular form. This value is useful for displaying in entity properties dialogs.
    • [string] pluralName: The name of the operation in plural form. This value is useful for displaying in User and Role properties dialogs.
    • [string] fullName: The name of the current operation along with its parent operations (if any). Since many operation names aren't unique, this value is useful for differentiating similar business operations.
    • [string] targetEntity: The object type affected by the operation (in this case, "Content")
    • [Operation{}] parent: An Operation instance indicating the operation from which permissions are inherited. This value will be Null if there is no parent operation.
    • [Operations[]]descendants: An array of Operation instances that inherit permissions from this operation. This value is Null if there are no descendant operations.
    • [Permissions[] permissions: An array of Permission instances indicating permissions associated with this operation

    /content/{content_id}/

    GET

    Returns the Content instance with the specified ID.

    Response Body

    • [int] id: A unique identifier for the Content instance. This value is generated by the server when the content file is uploaded.
    • [string] fileName: The name of the content file
    • [string] mediaType: The file type, which can be one of the following:
      • "Video": An MPG, MP4, TS, MOV, VOB, or WMV video file
      • "Image": A JPG, PNG, or BMP image file
      • "Audio": An MP3 or WAV audio file
      • "Text": A TXT file
      • "Other": An unknown file type
    • [string] physicalPath: The location of the file in the server directory
    • [string] virtualPath: The location of the file in the BSN virtual directory
    • [string] thumbPath: The location of the thumbnail for the video/image file in the server directory. This value is a blank string for audio, text, and unknown file types.
    • [int] fileSize: The file size (in bytes)
    • [string] fileHash: The hash algorithm and the value that results from performing the hash algorithm on the file. The string is formatted as "{algorithm}:{value}" (e.g. "SHA1:6DB465879088280AAC52DC22B07ED0AD493A99D4").
    • [string] uploadDate: A UTC timestamp indicating when the file was uploaded to BSN. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
    • [string] fileLastModifiedDate: A UTC timestamp indicating when the file was last modified on BSN. The date/time is formatted as yyyy-mm-ddThh:mm:ss.sssZ.
    • [string] probeData: The audio/video probe data. This value is a blank string for image, text, and unknown file types.
    • [Presentation[]]presentations: An array of Presentation object instances representing presentations that use the content file. Each Presentation instance can have the following values:
      • [int] id: A unique identifier for the Presentation instance
      • [string] name: The presentation name
      • [string] type: The presentation type
    • [DynamicPlaylist[]]dynamicPlaylists: An array of DynamicPlaylist object instances representing Dynamic Playlists that contain the content file. Each DynamicPlaylist instance can have the following values:
      • [int] id: A unique identifier for the DynamicPlaylist instance
      • [string] name: The Dynamic Playlist name
    • [LiveMediaFeed[]]liveMediaFeeds: An array of LiveMediaFeed object instances representing Live Media Feeds that contain the content file. Each LiveMediaFeed instance can have the following values:
      • [int] id: A unique identifier for the LiveMediaFeed instance
      • [string] name: The Live Media Feed name
    • [TaggedPlaylist[]]taggedPlaylists: An array of TaggedPlaylist object instances representing Tagged Playlists that contain the content file. Each TaggedPlaylist instance can have the following values:
      • [int] id: A unique identifier for the TaggedPlaylist instance
      • [string] name: The TaggedPlaylist name
    • [Tag[]]tags: An array of key/value pairs that represent tags assigned to the content file. Each Tag is formatted as follows: "<value_type>::<tag_type>.<tag_key>":"<value>".
      • value_type: "string" or "number"
      • tag_type: "[Content]" (a user-defined key/value) or "[sys].[Content]" (a system-defined key/value)
      • tag_key: The tag key
      • value: The tag value
    • [Permission[]]permissions: An array of Permission object instances representing permissions rules assigned to the content file

    DELETE

    Removes the specified content file from the network.

    Response Body

    The server returns code 200 upon success. Upon failure, it returns code 400 with an error message.

    /content/{content_id}/tags/

    GET

    Returns tags associated with the specified content file.

    Response Body

    The response body contains an array of key/value pairs that represent tags assigned to the content file. Each Tag is formatted as follows: "<value_type>::<tag_type>.<tag_key>":"<value>".

    • value_type: "string" or "number"
    • tag_type: "[Content]" (a user-defined value) or "[sys].[Content]" (a system-defined key/value)
    • tag_key: The tag key
    • value: The tag value

    POST

    Adds one or more tags to the specified content file.

    Request Body

    The request body should contain an array of key/value pairs that specify tags to assign to the content file. Each Tag must be formatted as follows: "<value_type>::<tag_type>.<tag_key>":"<value>".

    • value_type: "string" or "number"
    • tag_type: "[Content]" (a user-defined value) or "[sys].[Content]" (a system-defined key/value)
    • tag_key: The tag key
    • value: The tag value

    DELETE

    Removes one or more tags from the specified content file.

    Request Body

    The request body should contain an array of strings specifying tags to delete. Each string must be formatted as follows: "<value_type>::<tag_type>.<tag_key>"

    • value_type: "string" or "number"
    • tag_type: "[Content]" (a user-defined value) or "[sys].[Content]" (a system-defined value)
    • tag_key: The tag key
    Anchorsystem-defined-valuesystem-defined-value Note
    titleNote
    The following are valid system-defined values for content tags: "FileName", "FileSize", "ContentType", "UploadDate",  

    This endpoint allows for management of content files (and content tags) on the network. 

    Base URL for these endpoints:  https://api.brightsignnetwork.com/2017/01/REST/Content

    GET  /

    Retrieves a list of content files on the network.

    Parameters

    filter  string

    Anexpressionfor filtering search results

    sort string

    An expression for sorting the search results. The sort expression specifies the entry used for sorting and the ascending/descending (ASC/DESC) sorting order (e.g. "[Content].[FileName] ASC")

    marker string

    A value specifying which page to retrieve. This value is useful if the isTruncated entry in the response body of the previous GET call indicates that the number of content instances exceeds the pageSize.

    pageSize int

    The maximum number of content instances that can be contained in the response body

    ______________________________________________________________

    Response Body

    Returns a paged list of every Content Entity on a network. This will return not more than 100 entities along with the information necessary to return any other remaining pages.

    DELETE  /

    Removes content files, specified by a filter, from a network. This allows multiple content files to be deleted at once.

    Parameters

    filter string 

    An expression for filtering search results

    ______________________________________________________________

    Response Body

    Returns the number of affected content files as an integer value.

    GET /Root/{*virtualPath}/ 

    Retrieves a list of content files in the specified virtual-directory folder.

    Parameters

    virtualPath string

    The location of the content instance in the BSN.cloud virtual directory

    sort string

    An expression for sorting the search results. The sort expression specifies the entry used for sorting and the ascending/descending (ASC/DESC) sorting order (e.g. "[Content].[FileName] ASC")

    marker string 

    A value specifying which page to retrieve. This value is useful if the isTruncated entry in the response body of the previous GET call indicates that the number of content instances exceeds the pageSize.

    pageSize int 

    The maximum number of content instances that can be contained in the response body

    ______________________________________________________________

    Response Body

    Returns a paged list of Content Folderentities on a network. This will return not more than 100 entities along with the information necessary to return any other remaining pages.

    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.

    Parameters

    virtualPath string

    The location of the content instance in the BSN.cloud virtual directory

    ______________________________________________________________

    Request Body

    The Content Folder Entity entity

    ______________________________________________________________

    Response Body

    Returns a 201 status code and 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.

    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. 

    Parameters

    filter string

    An expression for filtering search results

    ______________________________________________________________

    Response Body

    The content file count is returned as an integer value.

    GET /Operations/ 

    Returns the operational permissions granted to roles for specific business operations

    Response Body

    Returns the Business Operations Entity

    GET /{id:int}/ 

    Retrieves the specified content files on a network. 

    Parameters

    id int

    A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.

    maxWidth  uShort

    The maximum width of the content instance (this should equal 100)

    maxHeight uShort

    The maximum height of the content instance (this should equal 100)

    ______________________________________________________________

    Response Body

    The server returns code 200 upon success. Upon failure, it returns code 400 with an error message.

    PUT /{id:int}/ 

    Update the specified content files. 

    Parameters

    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 Body

    On success this method returns a status code 2XX, on failure it returns a status code of 5XX.

    DELETE /{id:int}/ 

    Removes the specified content file. 

    Parameters

    id int

    A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.

    ______________________________________________________________

    Response Body

    The server returns code 200 upon success. Upon failure, it returns code 400 with an error message.

    GET  /{id:int}/Tags/ 

    Returns tags associated with the specified content file.

    Parameters

    id int 

    A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.

    ______________________________________________________________

    Response Body

    Returns an array of key/value pairs that represent tags assigned to the content file. Each tag is formatted as follows: 

    "<value_type>::<tag_type>.<tag_key>":"<value>"

    POST  /{id:int}/Tags/ 

    Adds one or more tags to the specified content file.

    Parameters

    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 request body should contain an array of key/value pairs that specify tags to assign to the content file. Each tag must be formatted as follows: "<value_type>::<tag_type>.<tag_key>":"<value>"

    ______________________________________________________________

    Response Body

    On success this method returns a status code 2XX, on failure it returns a status code of 5XX.

    DELETE  /{id:int}/Tags/ 

    Removes one or more tags from the specified content file.

    Parameters

    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 request body should contain an array of strings specifying tags to delete. Each string must be formatted as follows: "<value_type>::<tag_type>.<tag_key>"

    The following are valid system-defined values for content tags: "FileName", "FileSize", "ContentType", "UploadDate",  

    ______________________________________________________________

    Response Body

    On success this method returns a status code 2XX, on failure it returns a status code of 5XX.

    GET  /{id:int}/Permissions/ 

    Includes object permissions for a given content instance.

    Parameters

    id int

    A unique identifier for the content instance. This value is generated by the server when the content file is uploaded.

    ______________________________________________________________

    Response Body

    Returns the permissions property value of the Content Entity as a paged list of content entities.

    POST  /{id:int}/Permissions/ 

    Adds permissions to the specified content instance

    Parameters

    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 Permission Entity

    ______________________________________________________________

    Response Body

    On success this method returns a status code 2XX, on failure it returns a status code of 5XX.

    DELETE  /{id:int}/Permissions/ 

    Removes permissions from the specified content instance

    Parameters

    id int

    A unique identifier for the content instance. This value is generated by the server when the content instance is uploaded.

    ______________________________________________________________

    Request Body

    The Permission Entity

    ______________________________________________________________

    Response Body

    On success this method returns a status code 2XX, on failure it returns a status code of 5XX.

    Endpoints:

    Table of Contents
    maxLevel2
    indent20px