Skip to content

DefiningRequest

DefiningRequest Properties

Property Type Required Default
AutomaticallyRetrievesStreams boolean Optional false
Name string Required
Query string Optional

AutomaticallyRetrievesStreams

Whether to automatically download the actual media associated with the Entity and store it in the offline database.

  • type: boolean
  • default: false

Name

The defining request name

  • type: string

Query

An Entity name or an Entity name with filters, e.g. Products?$filter=CategoryID eq '123'. This property is required for adding defining request.

  • type: string

Examples

There are three types of defining request:

type 1 - A defining request that identifies one or more entities where the automaticallyRetrievesStreams property is set to false. In this case, even if the defining request identifies media entities, the media streams will not be downloaded.

{
    "Name": "Customers",
    "Query": "Customers"
},

type 2 - A defining request that identifies one or more entities, some of which may be media entities, and where the automaticallyRetrievesStreams property is set to true. In this case, the media streams will be downloaded as well for media entities.

{
    "Name": "Products",
    "Query": "Products",
    "AutomaticallyRetrievesStreams": true
},

type 3 - A defining request that identifies a single media entity and the automaticallyRetrievesStreams property is set to true. The URL specified in this case MUST be the read link of the media entity, not the read link of the media stream.

{
    "Name": "Products(101)",
    "Query": "Products(101)",
    "AutomaticallyRetrievesStreams": true
},