Can I specify my own token to protect a Vid.ly?

Quick answer: no! We take care of that for you!

You an achieve this via 2 methods:

Method A) Send a AddMedia request with just </token> to create the necessary token:

<?xml version="1.0"?>
<Query>
    <Action>AddMedia</Action>
    <userid>[userid]</userid>
    <userkey>[userkey]</userkey>
    <Source>
        <sourcefile>[sourcefile]</sourcefile>
        <Protect>
            </Token>
        </Protect>
    </Source>
</Query>

Method B) Use UpdateMedia to create a token for Vid.lys that already exist:

<?xml version="1.0"?>
<Query>
    <Action>UpdateMedia</Action>
    <userid>[userid]</userid>
    <userkey>[userkey]</userkey>
        <Source>
        <mediashortlink>[sourcefile]</mediashortlink>
        <Protect>
            </Token>
        </Protect>
    </Source>
</Query>

GetSecurityToken is used to retrieve token.  

http://api.vid.ly/?dev=1#GetSecurityToken

<?xml version="1.0"?>
<Query>
    <Action>GetSecurityToken</Action>
    <UserID>[User ID]</UserID>
    <UserKey>[User key]</UserKey>
    <MediaShortLink>[MediaShortLink]</MediaShortLink>
    <AllowedFromDate>2012-03-11 10:00:00</AllowedFromDate>
    <AllowedToDate>2012-03-12 10:00:00</AllowedToDate>
    <ExpirationTimeSeconds>86400</ExpirationTimeSeconds>
    <AllowedIP>192.168.1.1,192.168.1.50-100,192.168.2.*</AllowedIP>
</Query>

Please note that if you specify any of the following in your <protect> request, you are issuing those parameters against the token:

http://api.vid.ly/#GetSecurityToken

<?xml version="1.0"?>
<Query>
    <Action>GetSecurityToken</Action>
    <UserID>[User ID]</UserID>
    <UserKey>[User key]</UserKey>
    <MediaShortLink>[MediaShortLink]</MediaShortLink>
    <AllowedFromDate>2012-03-11 10:00:00</AllowedFromDate>
    <AllowedToDate>2012-03-12 10:00:00</AllowedToDate>
    <ExpirationTimeSeconds>86400</ExpirationTimeSeconds>
    <AllowedIP>192.168.1.1,192.168.1.50-100,192.168.2.*</AllowedIP>
</Query>
1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 2.50 out of 5)
Loading...

edchelp