Legacy - ( No Longer Offered )
Keyword Discovery - FREE API manual
Click here to access the manual for the Full function API option as part of the Enterprise subscription.
The Keyword Research API (Application Programming Interface) provides a set of query functions to the Keyword Research database. The API can be integrated into custom applications or used as an alternative interface.
The API provides functions for retrieving data on single keywords, multiple keywords from a single query and account status checking. The queries return all data in XML format and the functions accept parameters as GET or POST values.
NOTE: The option between single and multiple queries has to be activated by admin, member will not be able to change the type of query results by modifying URL parameters. Contact us to change the results type for your account.
For more information on how to implement the KeywordDiscovery API in your applications using programming languages, see actual PHP, Perl and C#.Net code examples.
Contents
- Use of Free API Requirement - No Longer Offered
- Single Query - No Longer Offered
- Multiple Queries - No Longer Offered
- Authentication - No Longer Offered
Use of Free API Requirement - No Longer Offered
All applications of the free API must correctly display a link to http://www.keyworddiscovery.com/
Suggested formats:
Option 1.
Keywords provided by KeywordDiscovery.com
For more results visit KeywordDiscovery.com Keyword Research Tool
Option 2.
Keyword Results by KeywordDiscovery.com Keyword Research Tool
Single Query - No Longer Offered
This function works the same way as the search function on the Keyword Research website. A query string containing a search term is sent to the database which returns a list of search term combinations containing the original search term, along with the total number of searches, and the number of monthly searches. The query can be customized to return subsets of data via the parameters outlined below.
Parameters:
Query string/search term (required)
Parameter name: query
Aliases: q, search, queries
Description: The search term to perform the query on.
Limit
Parameter name: limit
Aliases: l, m, limited_to, maximum
Default: 10
Maximum: Account specific (default 10)
Description: The maximum number of results to return.
Compact results
Parameter name: compact
Aliases: c
Default: 1 (on)
Values: 1,0 (on,off)
Description: Returns results with abbreviated fieldname descriptions. E.g. total="1622" will be displayed as t="1622".
Results
Results are returned as XML. A simple example:
http://api.keyworddiscovery.com/top15.php?query=airport+parking
This request is for the search term "airport parking", the query will display data starting from the 10th result, and a maximum of 15 results will be returned. By default, compact result display is turned on. The XML returned from this query is shown below:
<resultset>
<results compact="true" maximum="10" offset="0" query="airport parking" sub10="false">
<r m="3619" q="airport parking" t="57907"/>
<r m="762" q="airport parking uk" t="9912"/>
<r m="1194" q="newcastle airport car parking" t="9558"/>
<r m="858" q="luton airport car parking" t="9446"/>
<r m="279" q="gatwick airport parking" t="4188"/>
<r m="251" q="newark airport parking" t="3272"/>
<r m="228" q="stansted airport parking" t="3192"/>
<r m="211" q="philadelphia airport parking" t="2963"/>
<r m="222" q="jfk airport parking" t="2889"/>
<r m="178" q="oakland airport parking" t="2495"/>
</results>
</resultset>
Each result is returned as an 'r' tag with the following attributes
- q - query string
- t - total search
- m - monthly estimate
The single query function is available at the URL http://api.keyworddiscovery.com/top15.php
Multiple Queries - No Longer Offered
The queries function can accept multiple search terms at once, limited to a maximum of 100, and returns the total number of searches and the number of monthly searches for each search term.
Parameters:
The main parameter is the list of query strings, one phrase per line.
Query string (required)
Parameter name: query
Aliases: q, search, queries, searches
Description: Search terms separated by newline characters
Limit: The number of queries you can provide at one time is limited on a per account basis
Compact results
Parameter name: compact
Aliases: c
Default: 1 (on)
Values: 1,0 (on,off)
Description: Returns results with abbreviated fieldname descriptions. E.g. total="1622" will be displayed as t="1622"
Results
Results are returned as XML. A simple example:
http://api.keyworddiscovery.com/top15.php?queries=airport+parking%0D%0Afree+web+hosting
This request is for the search terms "airport parking" and "free web hosting". By default, compact result display is turned on. The XML returned from this query is shown below:
<resultset>
<results compact="true" maximum="15" offset="0" query="airport parking" sub10="false">
<r m="3619" q="airport parking" t="57907"/>
<r m="762" q="airport parking uk" t="9912"/>
<r m="1194" q="newcastle airport car parking" t="9558"/>
<r m="858" q="luton airport car parking" t="9446"/>
<r m="279" q="gatwick airport parking" t="4188"/>
<r m="251" q="newark airport parking" t="3272"/>
<r m="228" q="stansted airport parking" t="3192"/>
<r m="211" q="philadelphia airport parking" t="2963"/>
<r m="222" q="jfk airport parking" t="2889"/>
<r m="178" q="oakland airport parking" t="2495"/>
<r m="159" q="dfw airport parking" t="2072"/>
<r m="147" q="airport car parking" t="2064"/>
<r m="1028" q="airport parking, gatwick" t="2057"/>
<r m="150" q="manchester airport parking" t="1961"/>
<r m="142" q="airport parking gatwick" t="1710"/>
</results>
<results compact="true" maximum="15" offset="0" query=" free web hosting" sub10="false">
<r m="75067" q="free web hosting" t="1201077"/>
<r m="15790" q="free web page hosting" t="252643"/>
<r m="1492" q="free web site hosting" t="23886"/>
<r m="933" q="web hosting free" t="12141"/>
<r m="237" q="list free web hosting" t="3090"/>
<r m="192" q="free web hosting php" t="3087"/>
<r m="241" q="free and web and hosting" t="2652"/>
<r m="180" q="free web hosting no ads" t="2527"/>
<r m="160" q="free adult web hosting" t="2400"/>
<r m="164" q="free web hosting service" t="2297"/>
<r m="378" q="free web hosting home business" t="2273"/>
<r m="201" q="free adult web cam hosting" t="2010"/>
<r m="105" q="free web hosting frontpage" t="1692"/>
<r m="118" q="free web hosting no adds" t="1535"/>
<r m="105" q="free web hosting ftp" t="1481"/>
</results>
</resultset>
Each result is returned as an 'r' tag with the following attributes
- q - query string
- t - total search
- m - monthly estimate
This function is available at http://api.keyworddiscovery.com/top15.php
Authentication - No Longer Offered
Authentication for the API system is performed using standard HTTP authentication. When sending a query via the API using a webbrowser a message box will appear, requiring the account holder's username and password to be entered in order to continue.
Authentication details can also be sent via the URL by inserting the username and password separated by a colon and suffixed with @, before the hostname in the query URL.
NOTE: Remember that data supplied via URL's should be correctly URL encoded.
NOTE: Microsoft Internet Explorer has disabled the ability to supply usernames and passwords via the URL in the latest versions.
This will stop you from testing this in Internet Explorer.
An example of checking the account status showing the URL authentication method:
username: user@host.com
password: secret
http://user%40host%2Ecom:secret@api.keyworddiscovery.com/top15.php
Any authentication failure will return a HTTP 401: Unauthorized.