createMedia
Add media to your account
Post media you wish to add to your account for transcription.
/media
Usage and SDK Samples
curl -X post "https://app.watchingwords.com/api/v1/media?url=&apiKey="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.MediaApi;
import java.io.File;
import java.util.*;
public class MediaApiExample {
public static void main(String[] args) {
MediaApi apiInstance = new MediaApi();
String url = url_example; // String | The url of the media you wish transcribed.
String apiKey = apiKey_example; // String | Required for authentication, on your settings page.
try {
Media result = apiInstance.createMedia(url, apiKey);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling MediaApi#createMedia");
e.printStackTrace();
}
}
}
import io.swagger.client.api.MediaApi;
public class MediaApiExample {
public static void main(String[] args) {
MediaApi apiInstance = new MediaApi();
String url = url_example; // String | The url of the media you wish transcribed.
String apiKey = apiKey_example; // String | Required for authentication, on your settings page.
try {
Media result = apiInstance.createMedia(url, apiKey);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling MediaApi#createMedia");
e.printStackTrace();
}
}
}
String *url = url_example; // The url of the media you wish transcribed.
String *apiKey = apiKey_example; // Required for authentication, on your settings page.
MediaApi *apiInstance = [[MediaApi alloc] init];
// Add media to your account
[apiInstance createMediaWith:url
apiKey:apiKey
completionHandler: ^(Media output, NSError* error) {
if (output) {
NSLog(@"%@", output);
}
if (error) {
NSLog(@"Error: %@", error);
}
}];
var WatchingWordsApi = require('watching_words_api');
var api = new WatchingWordsApi.MediaApi()
var url = url_example; // {String} The url of the media you wish transcribed.
var apiKey = apiKey_example; // {String} Required for authentication, on your settings page.
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.createMedia(url, apiKey, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class createMediaExample
{
public void main()
{
var apiInstance = new MediaApi();
var url = url_example; // String | The url of the media you wish transcribed.
var apiKey = apiKey_example; // String | Required for authentication, on your settings page.
try
{
// Add media to your account
Media result = apiInstance.createMedia(url, apiKey);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling MediaApi.createMedia: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\Api\MediaApi();
$url = url_example; // String | The url of the media you wish transcribed.
$apiKey = apiKey_example; // String | Required for authentication, on your settings page.
try {
$result = $api_instance->createMedia($url, $apiKey);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling MediaApi->createMedia: ', $e->getMessage(), PHP_EOL;
}
?>
Parameters
Query parameters
Name | Description |
---|---|
url* | |
apiKey* |