VideoAsset API

for owner and author

GET /api/v1/video_assets/:id

Parameters

Name Description
id id
file filepicker data
thumbnail_url url of a thumbnail

Request

Headers

Accept: application/json
X-Api-Token: W_C1MFivGtqBSPc8JBJiQSex26LMLc2oPg
X-Api-Email: user-130@example.com

Route

GET /api/v1/video_assets/14?file[url]=https%3A%2F%2Fwww.filepicker.io%2Fapi%2Ffile%2F4wX6usUbRYWoV0qptCZt&file[filename]=IMG_1990.MOV&file[mimetype]=video%2Fquicktime&file[size]=990637&file[id]=1&file[key]=DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV&file[container]=lecture_attachments&file[client]=computer&file[isWriteable]=true&thumbnail_url=http%3A%2F%2Fwww.example.com%2Fwhatever.jpg

Query Parameters

file: {"url"=>"https://www.filepicker.io/api/file/4wX6usUbRYWoV0qptCZt", "filename"=>"IMG_1990.MOV", "mimetype"=>"video/quicktime", "size"=>"990637", "id"=>"1", "key"=>"DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV", "container"=>"lecture_attachments", "client"=>"computer", "isWriteable"=>"true"}
thumbnail_url: http://www.example.com/whatever.jpg

cURL

curl "http://localhost:3000/api/v1/video_assets/14?file[url]=https%3A%2F%2Fwww.filepicker.io%2Fapi%2Ffile%2F4wX6usUbRYWoV0qptCZt&file[filename]=IMG_1990.MOV&file[mimetype]=video%2Fquicktime&file[size]=990637&file[id]=1&file[key]=DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV&file[container]=lecture_attachments&file[client]=computer&file[isWriteable]=true&thumbnail_url=http%3A%2F%2Fwww.example.com%2Fwhatever.jpg" -X GET \
	-H "Accept: application/json" \
	-H "X-Api-Token: W_C1MFivGtqBSPc8JBJiQSex26LMLc2oPg" \
	-H "X-Api-Email: user-130@example.com" \
	-H "Content-Type: application/json" \
	-H "Host: school.worksonmy.computer"

Response

Headers

Content-Type: application/json; charset=utf-8
Content-Length: 530

Status

200 OK

Body

{
  "id": 14,
  "school_id": 593,
  "host": "wistia",
  "host_id": null,
  "file_extension": null,
  "file": {
    "id": 1,
    "key": "DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV",
    "url": "https://www.filepicker.io/api/file/4wX6usUbRYWoV0qptCZt",
    "size": 990637,
    "client": "computer",
    "filename": "IMG_1990.MOV",
    "mimetype": "video/quicktime",
    "container": "lecture_attachments",
    "isWriteable": true
  },
  "meta": {
  },
  "url": null,
  "thumbnail_url": null,
  "file_name": null,
  "content_type": null,
  "duration": null,
  "mp4_file_size": null,
  "created_at": "2019-10-31T22:08:29Z",
  "updated_at": "2019-10-31T22:08:29Z"
}

Request

Headers

Accept: application/json
X-Api-Token: W_C1MFivGtqBSPc8JBJiQSex26LMLc2oPg
X-Api-Email: user-130@example.com

Route

GET /api/v1/video_assets/14?file[url]=https%3A%2F%2Fwww.filepicker.io%2Fapi%2Ffile%2F4wX6usUbRYWoV0qptCZt&file[filename]=IMG_1990.MOV&file[mimetype]=video%2Fquicktime&file[size]=990637&file[id]=1&file[key]=DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV&file[container]=lecture_attachments&file[client]=computer&file[isWriteable]=true&thumbnail_url=http%3A%2F%2Fwww.example.com%2Fwhatever.jpg

Query Parameters

file: {"url"=>"https://www.filepicker.io/api/file/4wX6usUbRYWoV0qptCZt", "filename"=>"IMG_1990.MOV", "mimetype"=>"video/quicktime", "size"=>"990637", "id"=>"1", "key"=>"DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV", "container"=>"lecture_attachments", "client"=>"computer", "isWriteable"=>"true"}
thumbnail_url: http://www.example.com/whatever.jpg

cURL

curl "http://localhost:3000/api/v1/video_assets/14?file[url]=https%3A%2F%2Fwww.filepicker.io%2Fapi%2Ffile%2F4wX6usUbRYWoV0qptCZt&file[filename]=IMG_1990.MOV&file[mimetype]=video%2Fquicktime&file[size]=990637&file[id]=1&file[key]=DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV&file[container]=lecture_attachments&file[client]=computer&file[isWriteable]=true&thumbnail_url=http%3A%2F%2Fwww.example.com%2Fwhatever.jpg" -X GET \
	-H "Accept: application/json" \
	-H "X-Api-Token: W_C1MFivGtqBSPc8JBJiQSex26LMLc2oPg" \
	-H "X-Api-Email: user-130@example.com" \
	-H "Content-Type: application/json" \
	-H "Host: school.worksonmy.computer"

Response

Headers

Content-Type: application/json; charset=utf-8
Content-Length: 530

Status

200 OK

Body

{
  "id": 14,
  "school_id": 593,
  "host": "wistia",
  "host_id": null,
  "file_extension": null,
  "file": {
    "id": 1,
    "key": "DKvnsx3mSaOLbcdhXo0w_IMG_1990.MOV",
    "url": "https://www.filepicker.io/api/file/4wX6usUbRYWoV0qptCZt",
    "size": 990637,
    "client": "computer",
    "filename": "IMG_1990.MOV",
    "mimetype": "video/quicktime",
    "container": "lecture_attachments",
    "isWriteable": true
  },
  "meta": {
  },
  "url": null,
  "thumbnail_url": null,
  "file_name": null,
  "content_type": null,
  "duration": null,
  "mp4_file_size": null,
  "created_at": "2019-10-31T22:08:29Z",
  "updated_at": "2019-10-31T22:08:29Z"
}