title: Get URL of BrightCove video for download and Stream
body: <p>I am creating an android app in which I want to play as well as download videos from BrightCove now the problem is BrightCove has its own player i.e. <code>com.brightcove.player.view.BrightcoveExoPlayerVideoView</code> Which I could not use. I have to play the video in Android Native MediaPlayer.</p>
  
  <p>I have check all the docs and there they only provide some thing like this again and again </p>
  
  <pre><code>  EventEmitter eventEmitter = brightcoveVideoView.getEventEmitter();
      Catalog catalog = new Catalog(eventEmitter, getString(R.string.account), getString(R.string.policy));
  
      catalog.findVideoByID(getString(R.string.videoId), new VideoListener() {
  
        // Add the video found to the queue with add().
        // Start playback of the video with start().
        @Override
          public void onVideo(Video video) {
            brightcoveVideoView.add(video);
            brightcoveVideoView.start(); 
          }
  
        @Override
          public void onError(String s) {
            throw new RuntimeException(s);
          }
      });
  </code></pre>
  
  <p>How could I get the exact url for playing and downloading? </p>
  
  <p>When search for a Video on BrightCove using servercalls/API_tester it returns some this </p>
  
  <blockquote>
    <p>{   "id": 1520880903001,   "name": "Space-Galaxy",   "adKeys": null,   "shortDescription": "Used as sample for Accessing Video Content with
    the Media API -- DO NOT DELETE",   "longDescription": null,<br>
    "creationDate": "1332264917716",   "publishedDate": "1332264917716",<br>
    "lastModifiedDate": "1441607273772",   "linkURL":
    "<a href="http://support.brightcove.com/en/docs/accessing-video-content-media-api" rel="nofollow">http://support.brightcove.com/en/docs/accessing-video-content-media-api</a>",
    "linkText": "Accessing Video Content with the Media API",   "tags": [
        "newtag"   ],   "videoStillURL": "<a href="http://brightcove.vo.llnwd.net/e1/pd/57838016001/57838016001_1520916808001_vs-1520911645001.jpg?pubId=57838016001" rel="nofollow">http://brightcove.vo.llnwd.net/e1/pd/57838016001/57838016001_1520916808001_vs-1520911645001.jpg?pubId=57838016001</a>",
    "thumbnailURL":
    "<a href="http://brightcove.vo.llnwd.net/e1/pd/57838016001/57838016001_1520916809001_th-1520911645001.jpg?pubId=57838016001" rel="nofollow">http://brightcove.vo.llnwd.net/e1/pd/57838016001/57838016001_1520916809001_th-1520911645001.jpg?pubId=57838016001</a>",
    "referenceId": "1520880903001",   "length": 20000,   "economics":
    "AD_SUPPORTED",   "playsTotal": 102,   "playsTrailingWeek": 0,<br>
    "FLVURL":
    "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520916807001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
    "renditions": [
        {
          "audioOnly": false,
          "controllerType": "DEFAULT",
          "displayName": "Space-Galaxy.mp4",
          "encodingRate": 800000,
          "frameHeight": 360,
          "frameWidth": 640,
          "id": 1520959065001,
          "referenceId": null,
          "remoteStreamName": null,
          "remoteUrl": null,
          "size": 1829449,
          "uploadTimestampMillis": 1332267195355,
          "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520959065001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
          "videoCodec": "H264",
          "videoContainer": "MP4",
          "videoDuration": 20000
        },
        {
          "audioOnly": false,
          "controllerType": "DEFAULT",
          "displayName": "Space-Galaxy.mp4",
          "encodingRate": 1800000,
          "frameHeight": 720,
          "frameWidth": 1280,
          "id": 1520962209001,
          "referenceId": null,
          "remoteStreamName": null,
          "remoteUrl": null,
          "size": 4265519,
          "uploadTimestampMillis": 1332267361480,
          "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520962209001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
          "videoCodec": "H264",
          "videoContainer": "MP4",
          "videoDuration": 20000
        },
        {
          "audioOnly": false,
          "controllerType": "DEFAULT",
          "displayName": "Space-Galaxy.mp4",
          "encodingRate": 1200000,
          "frameHeight": 404,
          "frameWidth": 720,
          "id": 1520962169001,
          "referenceId": null,
          "remoteStreamName": null,
          "remoteUrl": null,
          "size": 2777863,
          "uploadTimestampMillis": 1332267330633,
          "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520962169001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
          "videoCodec": "H264",
          "videoContainer": "MP4",
          "videoDuration": 20000
        },
        {
          "audioOnly": false,
          "controllerType": "DEFAULT",
          "displayName": "Space-Galaxy.mp4",
          "encodingRate": 314758,
          "frameHeight": 224,
          "frameWidth": 400,
          "id": 1520959023001,
          "referenceId": null,
          "remoteStreamName": null,
          "remoteUrl": null,
          "size": 690193,
          "uploadTimestampMillis": 1332267165343,
          "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520959023001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
          "videoCodec": "H264",
          "videoContainer": "MP4",
          "videoDuration": 20000
        },
        {
          "audioOnly": false,
          "controllerType": "DEFAULT",
          "displayName": "Space-Galaxy.mp4",
          "encodingRate": 500000,
          "frameHeight": 268,
          "frameWidth": 480,
          "id": 1520916807001,
          "referenceId": null,
          "remoteStreamName": null,
          "remoteUrl": null,
          "size": 1126642,
          "uploadTimestampMillis": 1332265138822,
          "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520916807001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
          "videoCodec": "H264",
          "videoContainer": "MP4",
          "videoDuration": 20000
        },
        {
          "audioOnly": false,
          "controllerType": "DEFAULT",
          "displayName": "Space-Galaxy.mp4",
          "encodingRate": 129761,
          "frameHeight": 224,
          "frameWidth": 400,
          "id": 1520953533001,
          "referenceId": null,
          "remoteStreamName": null,
          "remoteUrl": null,
          "size": 227983,
          "uploadTimestampMillis": 1332266955420,
          "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520953533001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
          "videoCodec": "H264",
          "videoContainer": "MP4",
          "videoDuration": 20134
        }   ],   "FLVFullLength": {
        "audioOnly": false,
        "controllerType": "DEFAULT",
        "displayName": "Space-Galaxy.mp4",
        "encodingRate": 500000,
        "frameHeight": 268,
        "frameWidth": 480,
        "id": 1520916807001,
        "referenceId": null,
        "remoteStreamName": null,
        "remoteUrl": null,
        "size": 1126642,
        "uploadTimestampMillis": 1332265138822,
        "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520916807001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
        "videoCodec": "H264",
        "videoContainer": "MP4",
        "videoDuration": 20000   },   "videoFullLength": {
        "audioOnly": false,
        "controllerType": "DEFAULT",
        "displayName": "Space-Galaxy.mp4",
        "encodingRate": 500000,
        "frameHeight": 268,
        "frameWidth": 480,
        "id": 1520916807001,
        "referenceId": null,
        "remoteStreamName": null,
        "remoteUrl": null,
        "size": 1126642,
        "uploadTimestampMillis": 1332265138822,
        "url": "rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520916807001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06",
        "videoCodec": "H264",
        "videoContainer": "MP4",
        "videoDuration": 20000   } }</p>
  </blockquote>
  
  <p>It has some links like </p>
  
  <p>rtmp://brightcove.fcod.llnwd.net/a500/e1/uds/rtmp/ondemand/&amp;mp4:57838016001/57838016001_1520959023001_Space-Galaxy.mp4&amp;1460095200000&amp;a99dcabb0f88cdf8d21b3a5778da8e06</p>
  
  <p>but there are not playing any thing on MediaPlayer. May be because of <code>rtmp</code> and for <code>rmtp</code> I may have to use Vitamio but I can't as I am restricted to use native MediaPlayer. </p>
  
  <p>On IOS I am able to get the urls using :  <code>BCOVPlaybackService</code>  But there is no such class in android .</p>
  
  <p>Thanks </p>