Web CEO Online API Reference

Transcription

Web CEO Online API Reference
SEO API Reference
The Web CEO’s SEO API uses json requests:
{
"method": "method name",
"key": "your API key",
"id": request id (optional)
<…>
}
The "method" parameter is used to specify one of the supported commands listed down below.
The "key" parameter is an API key that is generated on the "API Access" page (My account > API).
The "id" parameter, which is optional, is used to bind the response to its request when the requests are
processed asynchronously.
Requests are sent via the HTTPS POST command to https://online.webceo.com/api/ - a json request should be
included in the json parameter.
*See examples in PHP, Python, Java.
Server response is an array of the following type:
[
{
"method": "method name",
"id": request id (if supplied),
"result": response code (can be omitted, if response is "0"), see the table below
"errormsg": "error message" (if error occurs),
"data": "the requested data"
}
]
Page 1 of 72
Web CEO – SEO API Reference
If necessary, queries can be grouped into one package:
[
{
"method": "method1",
...
},
{
"method": "method2",
...
}
]
Response Codes
0
Request successfully processed
1
Bad request
4
Not found
5
Bad arguments
6
Access denied
10
Unknown command (method)
11
Scanning
12
Not configured
100
Site not available
403
Forbidden
500
Server Error (contact support if you get this response code)
Page 2 of 72
Web CEO – SEO API Reference
Supported commands
Project management:
get_projects
Get the list of projects.
get_project
Get project’s details.
add_project
Add a new project.
set_project
Modify the parameters of an existing project.
del_project
Remove a project.
share_projects
Share projects to a user of the white label domain.
remove_share_projects
Remove projects from the user's project list.
rescan_project
Start scanning a project.
add_limit
Add a new project scan limit profile.
set_limit
Modify the parameters of an existing scan limit profile.
get_limit
Get the details of a scan limit profile.
get_limits
Get the list of scan limit profiles.
del_limit
Remove a scan limit profile.
get_billing_details
Get the billing details for the last 20 payments.
User management (applied only to the White Label Domain feature):
add_user
Add a new user to your white label domain.
set_user
Modify the parameters of an existing user.
del_user
Remove a user from your white label domain.
share_project_group
Grant a user access to a group of projects.
get_user_info
Get user’s details.
Sitemap Generator
submit_sitemap
Submit the sitemap to Google, Bing, and Yahoo.
Backlink Quality Check Tool:
get_competitor_metrics
Get the summarized backlink data for a site and its competitors.
get_linking_pages
Get the detailed data on external pages linking to your site.
get_competitor_backlinks
Get the list of pages linking to your competition and your site.
get_competitors
set_competitors
Get the list of competitors configured in the Backlink Quality Check or the Competitor
Backlink Spy tool.
Add, check or uncheck the competitors in the settings of the Backlink quality Check or
the Competitor Backlink Spy tool.
*See Appendix A for the status messages and texts of the SEO Analysis Tool.
Page 3 of 72
Web CEO – SEO API Reference
Rank Tracking Tool:
get_rankings
Get the ranking data for X last scans.
get_rankings_cached_results
Get the cached ranking results for a keyword.
get_rankings_keywords
Get the list of keywords configured to check the site rankings for.
add_rankings_keywords
Add keywords to the Rank Tracking settings of a project.
del_rankings_keywords
Remove keywords from the Rank Tracking settings of a project.
get_rankings_ses
Get the list of search engines configured in the Rank Tracking settings of a project.
add_rankings_ses
Add a search engine to the Rank Tracking settings of a project.
del_rankings_ses
Remove search engines from the Rank Tracking settings of a project.
get_rankings_competitors
Get the list of competitors configured in the Rank Tracking settings of a project.
add_rankings_competitors
Add a competitor to the Rank Tracking settings of a project.
del_rankings_competitors
Remove a competitor from the Rank Tracking settings of a project.
get_keywords_tags
Get the list of keywords with tags assigned to them in a project.
update_keywords_tags
Add, modify or delete specific tags of keywords in a project.
delete_keywords_all_tags
Remove all tags of all keywords in a project.
Technical Audit & SEO Analysis Tools:
get_site_audit_data
Get the scanning results for broken links & content optimization issues.
get_site_audit_keywords
Get the list of keywords configured for the Landing Page SEO analysis.
add_site_audit_keywords
Add keywords to the list configured for the Landing Page SEO analysis.
del_site_audit_keywords
Remove keywords from list configured for the Landing Page SEO analysis.
Page 4 of 72
Web CEO – SEO API Reference
Internal Links Optimization Tool:
get_interlinks_link_text
Get the list of link texts of your site’s internal links.
Web Buzz Tool:
get_buzz_counts
Get the number of posts found by the Web Buzz.
get_buzz_keywords
Get the list of keywords configured in the Web Buzz.
add_buzz_keywords
Add keywords to the list of keywords configured in the Web Buzz.
del_buzz_keywords
Remove keywords from the list of keywords configured in the Web Buzz.
SEO Checklist:
get_todo_stages
Get the details about completing the stages of the SEO Checklist.
Social Engagement
get_social_metrics
Page 5 of 72
Use this command to get social metrics found by the Social Engagement Tool.
Web CEO – SEO API Reference
Project management:
get_projects
Use this command to get the list of projects.
Request:
{
"method": "get_projects",
"key": "your API key",
"id": request id (optional)
}
Response:
{
"method": "get_projects",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": [
{
"project": "project id",
"domain": "project domain without http://",
"user": "user email" (only if you have White Label Domain configured)
},
]
…,
}
Page 6 of 72
Web CEO – SEO API Reference
get_project
Use this command to get the details of a project.
Note:
1. The "user" parameter can be set only by a white label domain owner.
2. You can specify either a "domain" or a "project" parameter. The "project" parameter is preferred.
Request:
{
"method": "get_project",
"key": "your API key",
"id": request id (optional),
"data": {
"user": "user email",
"domain": "project domain without http://",
"project": "project id"
}
}
Response:
{
"method": "get_project",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"last_scan_date": "YYYY-MM-DD",
"link": "URL of the Site Dashboard",
"groups": ["group_name1", …],
"notes": "project notes",
"limit": "project scan limit profile"
"marker": "unique identifier of a project"
}
}
Page 7 of 72
Web CEO – SEO API Reference
add_project
Use this command to add a new project.
Note:
1. The "user" parameter can be set only by a white label domain owner.
Request:
{
"method": "add_project",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email",
"domain": "project domain without http://",
"notes": "project notes", (optional)
"groups": ["group_name1", …], (optional)
"limit": "project scan limit profile", (optional)
"marker": "unique identifier of a project" (optional)
}
}
Response:
{
"method": "add_project",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Page 8 of 72
Web CEO – SEO API Reference
set_project
Use this command to modify the parameters of an existing project.
Note:
1. The "user" parameter can be set only by a white label domain owner.
2. You can specify either a "domain" or a "project" parameter. The "project" parameter is preferred.
Request:
{
"method": "set_project",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email",
"domain": "project domain without http://",
"project": "project id",
"notes": "project notes", (optional)
"groups": ["group_name1", …], (optional)
"limit": "project scan limit profile", (optional)
"marker": "unique identifier of a project" (optional)
}
}
Response:
{
"method": "set_project",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": project id
}
}
Page 9 of 72
Web CEO – SEO API Reference
del_project
Use this command to remove a project.
Note:
1. The “user” parameter can be set only by a white label domain owner.
2. You can specify either a "domain" or a "project" parameter. The "project" parameter is preferred.
Request:
{
"method": "del_project",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email",
"domain": "project domain without http://",
"project": "project id"
}
}
Response:
{
"method": "del_project",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Page 10 of 72
Web CEO – SEO API Reference
share_projects
Use this command to share the certain projects to a user of the White Label domain.
Request:
{
"method": "share_projects",
"key": "API key",
"data": {
"user": "user email",
"projects": ["project_hash1", "project_hash2" …] (use e4c8c83b for sharing demo project)
}
}
Response:
{
"method": "share_projects",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"data":{
"projects": ["project_hash1", "project_hash2", ...],
"user": "user_email"
}
}
Page 11 of 72
Web CEO – SEO API Reference
remove_shared_projects
Use this command to remove certain projects from the list of the projects available to the user of the White Label
domain.
Request:
{
"method": "remove_shared_projects",
"key": "API key",
"data": {
"user": "user email",
"projects": ["project_hash1", "project_hash2" …] (use e4c8c83b for removing demo project)
}
}
Response:
{
"method": "remove_shared_projects",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"data":{
"projects": ["project_hash1", "project_hash2", ...],
"user": "user_email"
}
}
Page 12 of 72
Web CEO – SEO API Reference
rescan_project
Use this command to start scanning of a project.
If you include the "tools" parameter, you will launch scanning in the tools specified in this parameter ("ranker" –
Rank Tracking, "auditor" – Technical Audit and SEO Analysis, "backlinks_count" – Competitor Link Profile report
of the Backlink Quality Check, "backlinks_pages" – Linking Pages report of the Backlink Quality Check,
"competitor_backlinks" – Competitor Backlink Spy, "interlinks" – Internal Links Optimization, "partners" – Backlink
Integrity Tracking, “sitemap” – Sitemap Generator, “social” - Social Engagement). If you don’t include the "tools"
parameter, scanning will be launched in the following tools: (i) Rank Tracking, (ii) Technical Audit, (iii) SEO
Analysis, (iv) Backlink Quality Check (Competitor Link Profile report) and (v) Backlink Integrity Tracking, given
that the profiles of the above tools are configured.
If you include the "update_settings" parameter, you will scan a sitemap, pull the first N pages from the sitemap
(to be specified in the parameter "page_count"), then pull the first N keywords from the META Keywords tag of
every pulled page (to be specified in the "keyword_count" parameter) and add the pulled pages and keywords to
the settings of Rank Tracking and SEO Analysis tools.
Request:
{
"method": "rescan_project",
"key": "your API key",
"id": request id (optional),
"data": {
"project": "project id",
"tools": ["ranker", "auditor", "backlinks_count", "backlinks_pages", " competitor_backlinks",
"interlinks", "partners", “sitemap”,”social”], (optional)
“callback_url”:”URL of the page requested after the scanning is finished” (optional),
"update_settings": {
"page_count": 20, (optional)
"keyword_count": 5
} (optional)
}
}
Response:
{
"method": "rescan_project",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Page 13 of 72
Web CEO – SEO API Reference
add_limit
Use this command to add a new scan limit profile.
Request:
{
"method": "add_limit",
"key": "your API key",
"id": request id, (optional)
"data": {
"name": "name of a scan limit profile", (required)
"ranker_max_kw": max number of keywords, (optional) (if not specified, default value is 5)
"ranker_max_se": max number of search engines, (optional) (value should be from 1 to 5; if not
specified, default value is 3)
"ranker_max_pages": max number of SERPs to check rankings, (optional) (value should be from
1 to 10; if not specified, default value is 3)
"ranker_max_competitors": max number of competitors in the Rank Tracking tool, (optional) (value
should be from 1 to 20; if not specified, default value is 5)
"ranker_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional) (if not specified, default value is "monthly")
"ranker_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional) (if not specified, default value is "never")
"linker_max_backlinks": max number of backlinks to be analyzed by the Backlink Quality Check
tool, (optional) (value should be from 100 to 50,000; if not specified, default value is 100)
"linker_max_competitors": max number of competitors in the Backlink Quality Check tool,
(optional) (value should be from 1 to 4; if not specified, default value is 2)
"backlinkslist_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (optional) (if not specified, default value is "monthly")
"backlinkslist_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (if not specified, default value is "never")
"spy_max_competitors_backlinks": max number of competitor backlinks to be analyzed by the
Competitor Backlink Spy tool, (optional) (value should be from 100 to 50,000; if not specified, default value is 100)
"spy_max_competitors": max number of competitor domains to be checked by the Competitor
Backlink Spy tool (optional) (value should be from 1 to 4; if not specified, default value is 2)
"backlinksspy_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (optional) (if not specified, default value is "monthly")
"backlinksspy_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (if not specified, default value is "never")
"auditor_max_pages": max number of site pages scanned for broken links, (optional) (value
should be from 1 to 50,000; if not specified, default value is 1,000)
"auditor_max_landing_pages": max number of landing pages scanned for content optimization
issues, (optional) (value should be from 1 to 50,000; if not specified, default value is 30)
"auditor_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional) (if not specified, default value is "monthly")
"auditor_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (if not specified, default value is "never")
"submission_max_se": max number of search engines for automatic submission 5 | 10 | 15 | … |
"all", (optional) (value should be multiple of 5, if value is not specified, default value is 5)
"buzz_kw_limit": max number of keywords tracked by the Web Buzz tool, (optional) (value should
be from 1 to 20; if not specified, default value is 2)
"partners_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional) (if not specified, default value is "monthly")
"partners_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice
a month" | "quarterly" | "never" (if not specified, default value is "never")
}
}
Page 14 of 72
Web CEO – SEO API Reference
Response:
{
"method": "add_limit",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"limit_id": "limit id"
}
}
Page 15 of 72
Web CEO – SEO API Reference
set_limit
Use this command to modify the parameters of an existing scan limit profile.
Request:
{
"method": "set_limit",
"key": "your API key",
"id": request id, (optional)
"data": {
"limit_id": "limit id",
"name": "name of a scan limit profile", (optional)
"ranker_max_kw": max number of keywords, (optional) (if not specified, default value is 5)
"ranker_max_se": max number of search engines, (optional) (value should be from 1 to 5; if not
specified, default value is 3)
"ranker_max_pages": max number of SERPs to check rankings, (optional) (value should be from
1 to 10; if not specified, default value is 3)
"ranker_max_competitors": max number of competitors in the Rank Tracking tool, (optional) (value
should be from 1 to 20; if not specified, default value is 5)
"ranker_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional)
"ranker_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional)
"linker_max_backlinks": max number of backlinks to be analyzed by the Backlink Quality Check
tool, (optional) (value should be from 100 to 50,000; if not specified, default value is 100)
"linker_max_competitors": max number of competitors in the Backlink Quality Check tool,
(optional) (value should be from 1 to 4; if not specified, default value is 2)
"backlinkslist_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (optional)
"backlinkslist_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (optional)
"spy_max_competitors_backlinks": max number of competitor backlinks to be analyzed by the
Competitor Backlink Spy tool, (optional) (value should be from 100 to 50,000; if not specified, default value is 100)
"spy_max_competitors": max number of competitor domains to be checked by the Competitor
Backlink Spy tool (optional) (value should be from 1 to 4; if not specified, default value is 2)
"backlinksspy_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (optional)
"backlinksspy_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never" (optional)
"auditor_max_pages": max number of site pages scanned for broken links, (optional) (value
should be from 1 to 50,000; if not specified, default value is 1,000)
"auditor_max_landing_pages": max number of landing pages scanned for content optimization
issues, (optional) (value should be from 1 to 50,000; if not specified, default value is 30)
"auditor_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional)
"auditor_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional)
"submission_max_se": max number of search engines for automatic submission 5 | 10 | 15 | … |
"all", (optional) (value should be multiple of 5, if value is not specified, default value is 5)
"buzz_kw_limit": max number of keywords tracked by the Web Buzz tool, (optional) (value should
be from 1 to 20; if not specified, default value is 2)
"partners_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never" (optional)
"partners_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice
a month" | "quarterly" | "never" (optional)
}
}
Page 16 of 72
Web CEO – SEO API Reference
Response:
{
"method": "set_limit",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"limit_id": "limit id"
}
}
Page 17 of 72
Web CEO – SEO API Reference
get_limit
Use this command to get the properties of a scan limit profile.
Request:
{
"method": "get_limit",
"key": "your API key",
"id": request id, (optional)
"data": {
"limit_id": "limit id"
}
}
Response:
{
"method": "get_limit",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"name": "name of a scan limit profile",
"ranker_max_kw": max number of keywords,
"ranker_max_se": max number of search engines,
"ranker_max_pages": max number of SERPs to check rankings,
"ranker_max_competitors": max number of competitors in Rank Tracking tool,
"ranker_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never"
"ranker_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never"
"linker_max_backlinks": max number of backlinks to be analyzed by the Backlink Quality Check
tool,
"linker_max_competitors": max number of competitors in the Backlink Quality Check tool,
"backlinkslist_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never"
"backlinkslist_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never"
"spy_max_competitors_backlinks": max number of competitor backlinks to be analyzed by the
Competitor Backlink Spy tool,
"spy_max_competitors": max number of competitor domains to be checked by the Competitor
Backlink Spy tool,
"backlinksspy_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never"
"backlinksspy_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" |
"twice a month" | "quarterly" | "never"
"auditor_max_pages": max number of site pages scanned for broken links,
"auditor_max_landing_pages": max number of landing pages scanned for content optimization
issues,
"auditor_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never"
"auditor_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never"
"submission_max_se": max number of search engines for automatic submission,
"buzz_kw_limit": max number of keywords tracked by the Web Buzz tool,
"partners_auto_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice a
month" | "quarterly" | "never"
"partners_manual_scan_period": "once a day" | "once a week" | "twice a week" | "monthly" | "twice
a month" | "quarterly" | "never"
}
}
Page 18 of 72
Web CEO – SEO API Reference
get_limits
Use this command to get the list of scan limit profiles created in your Web CEO account.
Request:
{
"method": "get_limits",
"key": "your API key",
"id": request id (optional)
}
Response:
{
"method": "get_limits",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"limits": [["limit_id1", "limit_name1"], ["limit_id2", "limit_name2"] … ]
}
}
Page 19 of 72
Web CEO – SEO API Reference
del_limit
Use this command to remove a scan limit profile.
Request:
{
"method": "del_limit",
"key": "your API key",
"id": request id, (optional)
"data": {
"limit_id": "id of the limit that you are going to remove", (required)
"replace_with_id": "id of the limit that will replace the limit to be deleted in projects where it was
assigned; if this parameter is not specified, the projects where this limit was assigned will be assigned a scan limit
"no limits" (optional)
}
}
Response:
{
"method": "del_limit",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"limit_id": "limit id"
}
}
Page 20 of 72
Web CEO – SEO API Reference
get_billing_details
Use this command to get the billing details for the last 20 payments.
Request:
{
"method": "get_billing_details",
"key": "your API key",
"id": request id, (optional)
"data": {
"payments_count": number of payments (optional)
}
}
Response:
{
"method": " get_billing_details",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"created": "YYYY-MM-DD HH:MM:SS" (date of request),
"account": "email address of account owner",
"currency": "USD",
"payments": [
{
"date": "YYYY-MM-DD HH:MM:SS" (date of payment),
"id": payment id in the Web CEO system,
"amount": amount of payment,
"description": "payment details",
"details": {
"total": amount of payment,
"tariff": subscription paid,
"projects": [
{
"id": "project id",
"domain": "project domain without http://",
"manager": "email address", (optional)
"active_tools": [list of active tools],
"amount": total amount of project cost,
"specification": {
"fee": site monthly fee,
"backlink_checker": scanning cost,
"rank_checker": scanning cost,
"site_auditor": scanning cost
}
} …other projects
]
}
} …other payments
]
}
}
Page 21 of 72
Web CEO – SEO API Reference
User management:
(applied only to accounts with the White Label Domain feature enabled.)
add_user
Use this command to add a new user to your white label domain.
Note:
- if you want to include the user into the certain groups, add their names to the “groups” parameter. To remove
user from all the groups, leave it empty (“groups”:[ ]).
Request:
{
"method": "add_user",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email",
"password": "password", (optional) (value should be string, not integer)
"role": "ROLE_MANAGER" | "ROLE_CLIENT" | "ROLE_CLIENT_EXTENDED" |
"ROLE_READONLY"|ROLE_SPECIALIST| ROLE_TRIAL (optional),
"manager": "manager email address" (optional),
"groups": ["group1", "group2"] (optional)
}
}
Response:
{
"method": "add_user",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id (optional)
}
Predefined user roles are:
- ROLE_MANAGER – Project Manager;
- ROLE_CLIENT - Client (CANNOT add projects);
- ROLE_CLIENT_EXTENDED - Client (CAN add projects);
- ROLE_READONLY – Client (read-only reports);
- ROLE_SPECIALIST – SEO Specialist;
- ROLE_TRIAL - Trial
You can also specify non-predefined roles created for the domain. If no value is specified for the "role"
parameter, the default value is ROLE_CLIENT.
Page 22 of 72
Web CEO – SEO API Reference
set_user
Use this command to modify the parameters of an existing user.
Note:
- if you want to include the user into the certain groups, add their names to the “groups” parameter. To remove
user from all the groups, leave it empty (“groups”:[ ]).
Request:
{
"method": "set_user",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email",
"password": "password", (optional) (value should be string, not integer)
"suspended": 1 | 0, (optional),
"role": "ROLE_MANAGER" | "ROLE_CLIENT" | "ROLE_CLIENT_EXTENDED" |
"ROLE_READONLY" |ROLE_SPECIALIST| ROLE_TRIAL (optional)
"manager": "manager email address" (optional),
"groups": ["group1", "group2"] (optional)
}
}
Response:
{
"method": "set_user",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id (optional)
}
Page 23 of 72
Web CEO – SEO API Reference
del_user
Use this command to remove a user from your white label domain.
Request:
{
"method": "del_user",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email"
}
}
Response:
{
"method": "del_user",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id (optional)
}
Page 24 of 72
Web CEO – SEO API Reference
share_project_group
Use this command to grant a user access to a group of projects. A user will get access to the current projects in
a group and all projects that will be added to this group in the future.
Request:
{
"method": "share_project_group",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email",
"project_group": ["project_group_name1", …] (value should be string, not integer)
}
}
Response:
{
"method": "share_project_group",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"user": "user email",
"project_group": ["project_group_name1", …]
}
}
Page 25 of 72
Web CEO – SEO API Reference
get_user_info
Use this command to get the details of a user.
Request:
{
"method": "get_user_info",
"key": "your API key",
"id": request id, (optional)
"data": {
"user": "user email"
}
}
Response:
{
"method": "get_user_info",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"user": "user email",
"date_joined": "YYYY-MM-DD HH:MM:SS", (GMT)
"last_login": "YYYY-MM-DD HH:MM:SS" (GMT)
"project_group": ["project_group_name1", …]
}
}
Page 26 of 72
Web CEO – SEO API Reference
Rank Tracking Tool:
get_rankings
Use this command to get the ranking data for the X last scans of a project.
Note: Values of the "history_depth" parameter are interpreted as follows:
 1 – current site rankings;
 2 – current and 1 previous scan (default value, if "history_depth" is not specified);
 3 or more – current and 2 or more scans
Request:
{
"method": "get_rankings",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"grouped": 0|1, (0 – not grouped, 1 – grouped by page) (optional)
"pages_filter": ['/', '/help.html'], (page filters, active only when "grouped" parameter
has value "1") (optional)
"competitors": 0|1, (0 – without competitors, 1 – with competitors, active only when
"grouped" parameter has value "0") (optional)
"history_depth": any integer equal to or more than 2 (number of scans) (optional)
}
}
Response (when parameter "grouped" is 0):
{
"method": "get_rankings",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain",
"ranking_data": [
{
"kw": "keyword",
"positions": [
{
"se": "search engine",
"language": ISO 639-1 language code,
"country": ISO 3166 country code or 00 for global search,
"location": "Miami, FL", (optional)
"scan_history":[
{
"date": "YYYY-MM-DD", (scan date)
"url": "url of an organic result",
"pos": position of an organic result,
"video": { (marker of result, may be "ad", "news", "image", "video", "shop",
"place")
Page 27 of 72
Web CEO – SEO API Reference
"url": "url of an organic result",
"type": "ad" | "news" | "image" | "video" | "shop" | "place",
"pos": position of an extended result
}
},...
]
},...
]
},...
],
"competitors": [
{
"domain": "competitor's domain",
"competitor_data": [
{
"kw": "keyword",
"positions": [
{
"se": "search engine",
"language": ISO 639-1 language code,
"country": ISO 3166 country code or 00 for global search,
"location": "Miami, FL", (optional)
"scan_history":[
{
"url": "url",
"pos": position,
"date": "YYYY-MM-DD" (scan date)
},...
]
},...
]
},...
]
},...
]
}
}
Response (when parameter "grouped" is 1):
{
"method": "get_rankings",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"ranking_data": [
{
"url": "url",
"keywords": [
{
Page 28 of 72
Web CEO – SEO API Reference
"kw": "keyword",
"positions": [
{
"se": "search engine",
"language": ISO 639-1 language code,
"country": ISO 3166 country code or 00 for global search,
"location": "Miami, FL", (optional)
"scan_history": [
{
"url": "url",
"date": "YYYY-MM-DD", (scan date)
"type": "ad" | "news" | "image" | "video" | "shop" | "place",
"pos": position of an extended result
}
{
"url": "url",
"date": "YYYY-MM-DD", (scan date)
"type": "organic",
"pos": position of an organic result
},...
]
},...
]
},…
]
},...
]
}
}
Page 29 of 72
Web CEO – SEO API Reference
get_rankings_cached_results
Use this command to get the cached ranking results for a keyword.
Note:
-
the “location” parameter should be setup to “country” if you want to get cached results with the “Pages
from” specification (make sure to setup a proper language, too), or to custom Google location, if it was
specified in the Rank Tracking settings. In all other cases, just don’t specify this parameter;
-
the “mobile” parameter can be used for Google, Bing or Yahoo only.
Request:
{
"method": "get_rankings_cached_results",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"keyword": "keyword",
"se_data": {
"se": "search engine",
“mobile”:0|1 (1 – the mobile version of SE, 0 – the regular SE) (optional),
"country": country ISO code,
"language": language ISO code,
"location": "Google location" or “country”,
"youtube_channel":”URL of the Youtube channel” (optional, for Youtube only)
}
}
}
Response:
{
"method": " get_rankings_cached_results",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain",
"keyword": "keyword",
"se": "se_country_language",
"cache_data": [
{
#result_type: [list_of_urls]
"organic": ["url_1", …, "url_x"],
},
{
#result_type: [list_of_urls]
"ad": ["url_1", …, "url_x"],
},
…,
]
}
}
Page 30 of 72
Web CEO – SEO API Reference
get_rankings_keywords
Use this command to get the list of keywords configured in the Rank Tracking settings of a project.
Request:
{
"method": "get_rankings_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_rankings_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"keywords": ["keyword_1", "keyword_2", ...]
}
}
Page 31 of 72
Web CEO – SEO API Reference
add_rankings_keywords
Use this command to add keywords to the Rank Tracking settings of a project.
Request:
{
"method": "add_rankings_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"keywords": ["keyword_1", "keyword_2", ...]
}
}
Response:
{
"method": "add_rankings_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 32 of 72
Web CEO – SEO API Reference
del_rankings_keywords
Use this command to remove keywords from the Rank Tracking settings of a project.
Request:
{
"method": "del_rankings_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"keywords": ["keyword_1", "keyword_2", ...]
}
}
Response:
{
"method": "del_rankings_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 33 of 72
Web CEO – SEO API Reference
get_rankings_ses
Use this command to get the list of search engines configured in the Rank Tracking settings of a project.
Request:
{
"method": "get_rankings_ses",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_rankings_ses",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"ses": [
{
"se": "search engine name",
"country": ISO 3166 country code or 00 for global search,
"language": ISO 639-1 language code,
"description": "search engine description",
"location": "location for Google's location-based results" (optional),
"youtube_channel":”URL of the Youtube channel” (optional, for Youtube only)
}
]
}
}
Page 34 of 72
Web CEO – SEO API Reference
add_rankings_ses
Use this command to add search engine(-s) to the Rank Tracking settings of a project.
Note:
-
the “location” parameter should be setup to “country” if you want to get cached results with the “Pages
from” specification (make sure to setup a proper language, too), or to custom Google location, if it was
specified in the Rank Tracking settings. In all other cases, just don’t specify this parameter;
-
the “mobile” parameter can be used for Google, Bing or Yahoo only;
-
add the Youtube channel, such as https://youtube.com/user/CHANNEL_NAME or
https://youtube.com/channel/CHANNEL_NAME, as a “youtube_channel” parameter if you are adding
Youtube.
Request:
{
"method": "add_rankings_ses",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"ses": [
{
"se": "search engine name",
“mobile”:0|1 (1 – the mobile version of SE, 0 – the regular SE) (optional),
"country": ISO 3166 country code or 00 for global search,
"language": ISO 639-1 language code,
"description": "search engine description", (optional)
"location": "location for Google's location-based results" or “country”,
"youtube_channel":”URL of the Youtube channel” (optional, for Youtube only)
}
]
}
}
Response:
{
"method": "add_rankings_ses",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
*For the list of supported search engines and countries, see this document.
Page 35 of 72
Web CEO – SEO API Reference
del_rankings_ses
Use this command to remove the specified search engine(-s) configured in the Rank Tracking settings of a
project.
Note:
-
the “location” parameter should be setup to “country” if you want to get cached results with the “Pages
from” specification (make sure to setup a proper language, too), or to custom Google location, if it was
specified in the Rank Tracking settings. In all other cases, just don’t specify this parameter;
-
the “mobile” parameter can be used for Google, Bing or Yahoo only;
-
add the Youtube channel, such as https://youtube.com/user/CHANNEL_NAME or
https://youtube.com/channel/CHANNEL_NAME, as a “youtube_channel” parameter if you are adding
Youtube.
Request:
{
"method": "del_rankings_ses",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"ses": [
{
"se": "search engine name",
“mobile”:0|1 (1 – the mobile version of SE, 0 – the regular SE) (optional),
"country": ISO 3166 country code or 00 for global search,
"language": ISO 639-1 language code,
"description": "search engine description", (optional)
"location": "location for Google's location-based results" or “country”
}
]
….
"new_ses": [ optional, required when you delete the last search engine
{
"se": "search engine name",
"country": ISO 3166 country code or 00 for global search,
"language": ISO 639-1 language code,
"description": "search engine description", (optional)
"location": "location for Google's location-based results", (optional)
"youtube_channel":”URL of the Youtube channel” (optional, for Youtube only)
}
]
…
}
}
Response:
{
"method": "del_rankings_ses",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 36 of 72
Web CEO – SEO API Reference
get_rankings_competitors
Use this command to get the list of competitors configured in the Rank Tracking settings of a project.
Request:
{
"method": "get_rankings_competitors",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_rankings_competitors",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"competitors": ["competitor_1", "competitor_2", ...]
}
}
Page 37 of 72
Web CEO – SEO API Reference
add_rankings_competitors
Use this command to add competitor(-s) to the Rank Tracking settings of a project.
Request:
{
"method": "add_rankings_competitors",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"competitors": ["competitor_1", "competitor_2", ...]
}
}
Response:
{
"method": "add_rankings_competitors",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 38 of 72
Web CEO – SEO API Reference
del_rankings_competitors
Use this command to remove competitor(-s) configured in the Rank Tracking settings of a project.
Request:
{
"method": "del_rankings_competitors",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"competitors": ["competitor_1", "competitor_2", ...]
}
}
Response:
{
"method": "del_rankings_competitors",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 39 of 72
Web CEO – SEO API Reference
get_keywords_tags
Use this command to get the list of keywords with tags assigned to them in a project in the Rank Tracking tool.
Request:
{
"method": "get_keywords_tags",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": " get_keywords_tags",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"keyword_tags": {
"keyword": ["tag_1", "tag_2", …]
…,
}
}
}
Page 40 of 72
Web CEO – SEO API Reference
update_keywords_tags
Use this command to add, modify or delete specific tags of keywords in a project in the Rank Tracking tool.
Request:
{
"method": "update_keywords_tags",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"keywords_tags": {
"keywords": ["current_tag_1", "current_tag_2", “new_tag”, ...]
…,
}
}
}
Response:
{
"method": "update_keywords_tags",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 41 of 72
Web CEO – SEO API Reference
delete_keywords_all_tags
Use this command to delete all tags of all keywords in a project in the Rank Tracking tool.
Request:
{
"method": "delete_keywords_all_tags",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "delete_keywords_all_tags",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 42 of 72
Web CEO – SEO API Reference
Internal Links Optimization Tool:
get_interlinks_link_text
Use this command to get the list of link texts of your site’s internal links.
Request:
{
"method": "get_interlinks_link_text",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"order": "text" | "links" | "pw" | "blinks" | "nflinks" | "swlinks", (optional)* (if not
specified, default value is "pw")
"order_direction": "asc" | "desc", (optional) (if not specified, default value is "desc")
"page_number": number of page of a report (300 link texts per page) (if not specified,
default value is 1)
}
}
Response:
{
"method": "get_interlinks_link_text",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain",
"scanned_date": "YYYY-MM-DD",
"page_number": number of page of a report (300 link texts per page),
"data": [
{
"link_text": "link text",
"links_total": total number of links,
"text_juice": text juice,
"links_to_blocked_pages": number of links to pages that are blocked with
robots.txt or NoIndex tag,
"links_nofollow": number of links with nofollow attribute,
"links_sitewide": number of sitewide links,
"links": [ {
"link_from": "link with the given link text",
"page_authority": authority of a page where the link is published
}]
},...
]
}
}
Page 43 of 72
Web CEO – SEO API Reference
Backlink Quality Check Tool:
get_competitor_metrics
Use this command to get the summarized backlink data for a site and its competitors.
Request:
{
"method": "get_competitor_metrics",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
"history_depth": number of scans (optional) (value should be integer, ≥2)
}
}
Response:
{
"method": "get_competitor_metrics",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"scanned_date": "YYYY-MM-DD",
"data": [
{
"domain": "domain name",
"pagerank": Google PageRank of a home page,
"total": total number of backlinks found,
"total_history": the list of values of the total number of backlinks found during
previous scans, (only when the "history_depth" value is valid)
"domains": number of linking domains found,
"domains_history": the list of values of the number of linking domains found during
previous cans, (only when the "history_depth" value is valid)
"pages": number of linking pages found,
"pages_history": the list of values of the number of linking pages found during
previous cans, (only when the "history_depth" value is valid)
".gov": number of backlinks from .gov domains,
".gov_history": the list of values of the number of backlinks from .gov domains
found during previous cans, (only when the "history_depth" value is valid)
".edu": number of backlinks from .edu domains,
".edu_history": the list of values of the number of backlinks from .edu domains
found during previous cans, (only when the "history_depth" value is valid)
"nofollow": number of backlinks with ‘nofollow’ attribute,
"sitewide": number of sitewide backlinks
},…
]
}
}
Page 44 of 72
Web CEO – SEO API Reference
get_linking_pages
Use this command to get the detailed data on external pages linking to your site.
Request:
{
"method": "get_linking_pages",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_linking_pages",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"scanned_date": "YYYY-MM-DD",
"data": [
{
"page_url": "linking page URL",
"link_target_page": "target page URL",
"link_text": "link text",
"link_type": "text | redirect | frame | form",
"link_nofollow": false | true,
"link_sitewide": false | true,
"link_status": "Lost | Nofollow | Toxic (manually assigned) | Toxic | OK | OK
(manually assigned) | Suspected toxic", (status of link toxicity)
"is_new": false | true,
"page_title": "title of a linking page",
"page_size": size of a linking page in bytes,
"page_ilinks": number of internal links on a linking page,
"page_elinks": number of external links on a linking page,
"page_pagerank": Google PageRank of a linking page,
"home_page_pagerank": Google PR of linking domain’s home page,
"alexa_rank": Alexa Traffic Rank of a linking domain,
"dmoz_categories": "category1/subcategory1\ncategory2/subcategory2",
"from_domain": number of backlinks from the same domain,
"from_subnet": number of backlinks from the same subnet,
"ip": IP address of a linking page,
"last_crawled": "YYYY-MM-DD" (date of last crawl)
},…
]
}
}
Page 45 of 72
Web CEO – SEO API Reference
get_competitor_backlinks
Use this command to get the list of pages linking to your competition and your site.
Request:
{
"method": "get_competitor_backlinks",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_competitor_backlinks",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"scanned_date": "YYYY-MM-DD", (date of scan)
"data": [
{
"url_from": "linking page URL",
"pagerank": Google PageRank,
"domains_to": ["domain1", "domain2", …] (competitor domains, including your domain,
to which the page is linking to),
},…
]
}
}
Page 46 of 72
Web CEO – SEO API Reference
get_competitors
Use this command to get the list of competitors configured in the Backlink Quality Check or the Competitor
Backlink Spy tool.
Request:
{
"method": "get_competitors",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"tool": "backlink_quality_check" | "competitor_backlink_spy"
}
}
Response:
{
"method": "get_competitors",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"tool": "backlink_quality_check" | "competitor_backlink_spy",
"competitors": {
"checked": ["competitor_domain_1", "competitor_domain_1", …],
"unchecked": ["competitor_domain_a", "competitor_domain_b", …]
}
}
}
Page 47 of 72
Web CEO – SEO API Reference
set_competitors
Use this command to add, check or uncheck the competitors in the settings of the Backlink Quality Check or the
Competitor Backlink Spy tool.
Request:
{
"method": "set_competitors",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"tool": "backlink_quality_check" | "competitor_backlink_spy",
"competitors": {
"checked": ["competitor_domain_1", "competitor_domain_1", …], (all competitors
specified in this parameter will be checked in the settings window of the tools)
"unchecked": ["competitor_domain_a", "competitor_domain_b", …] (all competitors
specified in this parameter will be unchecked if they are available in the settings window of the tools or will be
added as unchecked if they are not found)
}
}
}
Response:
{
"method": "set_competitors",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"tool": "backlink_quality_check" | "competitor_backlink_spy",
"competitors": {
"checked": ["competitor_domain_1", "competitor_domain_1", …],
"unchecked": ["competitor_domain_a", "competitor_domain_b", …]
}
}
}
Page 48 of 72
Web CEO – SEO API Reference
Site Map Generator:
submit_sitemap
Use this command to submit your sitemap to Google, Bing, and Yahoo.
Request:
{
"method": "submit_sitemap",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"sitemap_url": "URL of sitemap location"
}
}
Response:
{
"method": "submit_sitemap",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain",
"sitemap_url": "URL of sitemap location"
}
}
Page 49 of 72
Web CEO – SEO API Reference
Technical Audit and SEO Analysis:
get_site_audit_data
Use this command to get the scanning results for technical and SEO issues.
Request:
{
"method": "get_site_audit_data",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"pages_filter": ['/', '/help.html'] (page filters) (optional)
}
}
Response:
{
"method": "get_site_audit_data",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"broken_anchors": total number of broken anchors,
"broken_links": total number of broken links,
"d_scan": "YYYY-MM-DD", (date of scanning)
"scanned_pages": number of scanned pages,
"general_errors": total number of detected general optimization issues,
"optimizer_errors": total number of detected keyword optimization issues,
"summary": {
#scanning results for factors related to the whole site#
"factor1": {"status": "OK|Problem"},
"factor2": {"status": "OK|Problem"},
…
},
"pages": [
{
"url": "complete page URL",
"page_unavailable": empty or 1 (page that was added for keyword optimization
scanning is not available),
"keywords": {
#if present, scanning results of checking for keyword optimization#
"keyword1”: {
If present, scanning results for factors:
"kw_body",
"kw_body_persent",
"kw_description",
"kw_h",
"kw_img_alt",
"kw_title",
"kw_url",
"kw_url_one"
#
"factor1": {"status": "OK|Problem"},
Page 50 of 72
Web CEO – SEO API Reference
"factor2": {"status": "OK|Problem"},
…
}, ...
},
"general": {
#if present, scanning results for factors related to a page#
"description",
"description_length",
"description_uniq",
"h1",
"h1_presence",
"links_count",
"redirect",
"title",
"title_length",
"title_uniq",
"url_ansi",
"url_query"
#
"factor1": {"status": "OK|Problem"},
"factor2": {"status": "OK|Problem"},
…
},
"elinks": [
#if present, external broken links#
{
"line": line number where a broken link was found,
"status": HTTP error code,
"url": "complete URL"
}, ...
],
"ilinks": [
#if present, internal broken links#
{
"line": line number where a broken link was found,
"status": HTTP error code,
"url": "complete URL"
},...
],
"pictures": [
#if present, broken image links#
{
"line": line number where a broken link was found,
"status": HTTP error code,
"url": "complete URL"
},...
],
"anchors": [
#if present, broken anchors#
{
"line": line number where a broken link was found,
"status": HTTP error code,
"url": "complete URL"
},...
]
}
]
}
}
*For the status messages and texts of the SEO Analysis Tool Appendix A.
Page 51 of 72
Web CEO – SEO API Reference
get_site_audit_keywords
Use this command to get the list of keywords configured for the Landing Page SEO analysis in the SEO Analysis
tool.
Request:
{
"method": "get_site_audit_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_site_audit_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://",
"urls": [
{
"url": "url",
"title": "title",
"keywords": ["keyword1", "keyword2", …]
}
]
}
}
Page 52 of 72
Web CEO – SEO API Reference
add_site_audit_keywords
Use this command to add keywords to the list of keywords configured for the Landing Page SEO analysis in the
SEO Analysis tool.
Request:
{
"method": "add_site_audit_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"urls": [
{
"url": "url",
"title": "title", (optional)
"keywords": ["keyword1", "keyword2", …]
}
]
}
}
Response:
{
"method": "add_site_audit_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 53 of 72
Web CEO – SEO API Reference
del_site_audit_keywords
Use this command to remove keywords from the list of keywords configured for the Landing Page SEO analysis
in the SEO Analysis tool.
Request:
{
"method": "del_site_audit_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"urls": [
{
"url": "url",
"keywords": ["keyword1", "keyword2", …]
}
]
}
}
Response:
{
"method": "del_site_audit_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"domain": "project domain without http://"
}
}
Page 54 of 72
Web CEO – SEO API Reference
Social Engagement
get_social_metrics
Use this command to get social metrics found by the Social Engagement Tool.
Request:
{
"method": "get_social_metrics",
"key": "your API key",
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_social_metrics",
"result": absent | 0 | error code,
"errormsg": absent | "error message"
"data": {
"project": project id,
"domain": "project domain",
"metrics": [{
"page": url,
"changes": number of changes,
"fb_likes": number of Facebook likes,
"fb_shares": number of Facebook shares,
"fb_comments": number of Facebook comments,
"g_plus_ones": number of Google+ “plus ones”,
"tweets": number of tweets
},
...
]
}
}
Page 55 of 72
Web CEO – SEO API Reference
Web Buzz Tool:
get_buzz_counts
Use this command to get the number of posts found by the Web Buzz tool.
Request:
{
"method": "get_buzz_counts",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_buzz_counts",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"total": total number of posts,
"unread": number of unread posts,
"favorites": number of favorite posts
}
}
Page 56 of 72
Web CEO – SEO API Reference
get_buzz_keywords
Use this command to get the list of keywords configured in the Web Buzz tool.
Request:
{
"method": "get_buzz_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_buzz_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"keywords": ["keyword_1", "keyword_2", ...]
}
}
Page 57 of 72
Web CEO – SEO API Reference
add_buzz_keywords
Use this command to add keywords to the list of keywords configured in the Web Buzz tool.
Request:
{
"method": "add_buzz_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"keywords": ["keyword_1", "keyword_2", ...]
}
}
Response:
{
"method": "add_buzz_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Page 58 of 72
Web CEO – SEO API Reference
del_buzz_keywords
Use this command to remove keywords from the list of keywords configured in the Web Buzz tool.
Request:
{
"method": "del_buzz_keywords",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id",
"keywords": ["keyword_1", "keyword_2", ...]
}
}
Response:
{
"method": "del_buzz_keywords",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Page 59 of 72
Web CEO – SEO API Reference
SEO Checklist:
get_todo_stages
Use this command to get the details on the status of the SEO Checklist stages.
Request:
{
"method": "get_todo_stages",
"key": "your API key",
"id": request id, (optional)
"data": {
"project": "project id"
}
}
Response:
{
"method": "get_todo_stages",
"result": absent | 0 | error code,
"errormsg": absent | "error message",
"id": request id, (optional)
"data": {
"project": "project id",
"todolist": [
{
"name": "name of the To Do List stage",
"tasks_all": total number of tasks in the stage,
"tasks_done": number of completed tasks,
"percent_done": 0-100,
"date_completed": -|"YYYY-MM-DD"
}
]
}
}
Page 60 of 72
Web CEO – SEO API Reference
Appendix A.
Technical Audit status messages, texts of warnings and recommendations
Factor ID
Factor name
broken_links
Broken Links
ilinks
Internal links
Status
Status “OK”
Texts
No broken internal links were found on the
scanned pages.
Status “Problem”:
elinks
External links
Warning, sg.
%(count)s broken internal link was found on
your site.
Warning, pl.
%(count)s broken internal links were found
on your site.
Recommendation
Replace the broken internal links with valid
ones, because broken links reduce your site
quality and may negatively impact your site
visitors' experience.
Warning (second level), sg.
This broken internal link was found %
(count)s time:
Warning (second level), pl.
This broken internal link was found %
(count)s times:
Status “OK”
No broken external links were found on the
scanned pages.
Status “Problem”:
pictures
Image links
Warning, sg.
%(count)s broken external link was found on
your site.
Warning, pl.
%(count)s broken external links were found
on your site.
Recommendation
Replace the broken external links with valid
ones, because broken links reduce your site
quality and may negatively impact your site
visitors' experience.
Warning (second level), sg.
This broken external link was found %
(count)s time:
Warning (second level), pl.
This broken external link was found %
(count)s times:
Status “OK”
No broken image links were found on the
scanned pages.
Status “Problem”:
Page 61 of 72
Warning, sg.
%(count)s broken image link was found on
your site.
Warning, pl.
%(count)s broken image links were found on
your site.
Recommendation
Replace the broken image links with valid
ones, because broken images reduce your
site quality and may negatively impact your
site visitors' experience.
Warning (second level), sg.
This broken image link was found %(count)s
time:
Warning (second level), pl.
This broken image link was found %(count)s
times:
Web CEO – SEO API Reference
Factor ID
Factor name
broken_links
Broken Links
anchors
Anchors
Status
Status “OK”
Texts
No broken anchors were found on the
scanned pages.
Status “Problem”:
general
General optimization
title
TITLE tag
presence
Warning, sg.
%(count)s broken anchor was found on your
site.
Warning, pl.
%(count)s broken anchors were found on
your site.
Recommendation
Replace the broken anchors with valid ones,
because broken anchors negatively impact
your site visitors' experience.
Warning (second level), sg.
This broken anchor was found %(count)s
time:
Warning (second level), pl.
This broken anchor was found %(count)s
times:
Status “OK”
The TITLE tag was found on all scanned
pages of your site.
Status “Problem”:
title_uniq
Duplicate TITLE
tags
Warning, sg.
%(count)s page of your site has no TITLE
tag.
Warning, pl.
%(count)s pages of your site have no TITLE
tag.
Recommendation
Make sure that the TITLE tag is present on
all pages of your site, because it increases
the overall relevancy of your site for SEs and
results in more click throughs.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
No duplicate TITLE tags were found on the
scanned pages of your site.
Status “Problem”:
Page 62 of 72
Warning, sg.
%(count)s page of your site has duplicate
TITLE tag.
Warning, pl.
%(count)s pages of your site have duplicate
TITLE tags.
Recommendation
Use unique and descriptive TITLE tags
across all pages of your site, because
duplicate Titles may cause problems with
site indexing and rankings. As an option, you
may leave the duplicate TITLE tags intact
but use a "canonical" attribute on the noncanonical pages to let the search engines
know which one is the preferred page.
Warning (second level), sg.
%(count)s page with duplicate TITLE tag: %
(tag_text)s
Warning (second level), pl.
%(count)s pages with duplicate TITLE tag:
%(tag_text)s
Web CEO – SEO API Reference
Factor ID
Factor name
general
General optimization
title_length
TITLE tag length
Status
Status “OK”
Texts
The TITLE tag length on the scanned pages
is OK.
Status “Problem”:
description
Description tag
presence
Warning, sg.
%(count)s TITLE tag exceeds the
recommended length (70 characters).
Warning, pl.
%(count)s TITLE tags exceed the
recommended length (70 characters).
Recommendation
Shorten your TITLE tag to 70 characters,
because longer titles will be cut off on the
search results pages.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
The Description tag was found on all
scanned pages.
Status “Problem”:
description_uniq
Duplicate
Description tags
Warning, sg.
%(count)s page of your site has no
Description tag.
Warning, pl.
%(count)s pages of your site have no
Description tag.
Recommendation
Make sure that the Description tag is present
across all pages of your site, because SEs
use them as snippets on the search results
pages.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
No duplicate Description tags were found on
the scanned pages.
Status “Problem”:
Page 63 of 72
Warning, sg.
%(count)s page of your site has duplicate
Description tag.
Warning, pl.
%(count)s pages of your site have duplicate
Description tags.
Recommendation
Use unique and descriptive Description tags
across all pages of your site, because SEs
use them as snippets on the search results
pages. As an option, you may leave the
duplicate Description tags intact but use a
"canonical" attribute on the non-canonical
pages to let the search engines know which
one is the preferred page.
Warning (second level), sg.
%(count)s page with duplicate Description
tag: %(tag_text)s
Warning (second level), pl.
%(count)s pages with duplicate Description
tag: %(tag_text)s
Web CEO – SEO API Reference
Factor ID
Factor name
Status
general
General optimization
description_lengt
h
Description tag
length
Status “OK”
Texts
The Description tag length on the scanned
pages is OK.
Status “Problem”:
sitemap
XML sitemap
presence
Warning, sg.
%(count)s Description tag exceeds the
recommended length (160 characters).
Warning, pl.
%(count)s Description tags exceed the
recommended length (160 characters).
Recommendation
Shorten your Description tag to 160
characters, because longer Descriptions will
be cut off on the search results pages.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
The XML Sitemap file was found on your
site.
Status “Problem”:
robots
Page 64 of 72
Robots.txt
presence
Warning, sg.
The XML Sitemap file was not found on your
site.
Warning, pl.
The XML Sitemap file was not found on your
site.
Recommendation
Create the XML Sitemap and upload it to the
root directory of your web server, because it
helps SEs to crawl the site more intelligently.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
The Robots.txt file was found on your site.
Status “Problem”:
Warning, sg.
The Robots.txt file was not found on your
site.
Warning, pl.
The Robots.txt file was not found on your
site.
Recommendation
Create the Robots.txt file and upload it to
the root directory of your web server, with its
help you can exclude content from the
crawling process of search engine bots.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Web CEO – SEO API Reference
Factor ID
Factor name
general
General optimization
links_count
Number of
outgoing links
on a page
url_query
Page URL
structure
Status
Status “OK”
Texts
The number of outgoing links on your site
pages is OK.
Status “Problem”:
Warning, sg.
%(count)s page of your site contains an
excessive number of outgoing links (more
than 50).
Warning, pl.
%(count)s pages of your site contain an
excessive number of outgoing links (more
than 50).
Recommendation
Reduce the number of outgoing links,
because excessive use of outgoing links
may negatively impact your page's PR and
rankings.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
The page URL structure of the scanned
pages is OK.
Status “Problem”:
url_ansi
Valid characters
in a page URL
Warning, sg.
%(count)s page URL contains an excessive
number of dynamic parameters.
Warning, pl.
%(count)s page URLs contain an excessive
number of dynamic parameters.
Recommendation
Rewrite the page's URL to avoid excessive
number of dynamic parameters (more than
3) and make your URLs crawlable and SEfriendly.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
All URLs of your site pages contain valid
characters.
Status “Problem”:
Page 65 of 72
Warning, sg.
%(count)s page URL contains invalid
characters.
Warning, pl.
%(count)s page URLs contain invalid
characters.
Recommendation
Rewrite the page's URL to make it crawlable
and SE-friendly. Use the following
characters: a-z A-Z 0-9 . _ ~ : \ / ? # [ ] @ ! $
&'()*+,;=
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Web CEO – SEO API Reference
Factor ID
Factor name
general
General optimization
h1_presence
H1 heading
presence
Status
Status “OK”
Texts
The H1 heading was found on all scanned
pages of your site.
Status “Problem”:
h1
redirect
Page 66 of 72
Number of H1
headings on a
page
302 Redirect and
META Refresh
presence
Warning, sg.
%(count)s page of your site has no H1
heading.
Warning, pl.
%(count)s pages of your site have no H1
heading.
Recommendation
Add a keyword-rich H1 heading, because
some search engines still consider the
contents of this heading to be important.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
The number of H1 headings on the scanned
pages is OK.
Status “Problem”:
Warning, sg.
%(count)s page contains an excessive
number of H1 headings.
Warning, pl.
%(count)s pages contain an excessive
number of H1 headings.
Recommendation
Leave only one H1 that you consider the
most important and change the rest to H2,
H3, etc., because SEs may penalize
excessive H1 headings as a spam
technique.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
Neither 302 Redirects nor META Refresh
was found on your site pages.
Status “Problem”:
Warning, sg.
%(count)s page contains 302 Redirect /
META Refresh.
Warning, pl.
%(count)s pages contain 302 Redirects /
META Refresh tags.
Recommendation
Change 302 Redirect / META Refresh to 301
Redirects, because 302 Redirects and META
Refresh are not SEO-friendly and pass no
link juice.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Web CEO – SEO API Reference
Factor ID
Factor name
Status
on_page
Keyword optimization
page_unavailabl
e
Availability of
site pages
Status “OK”
Texts
All pages specified in the settings were
found and analyzed.
Status “Problem”:
kw_title
kw_h
Page 67 of 72
Keyword
presence in the
TITLE tag
Keyword
presence in
headings (H1-H6)
Warning, sg.
%(count)s page unavailable (Not found,
Forbidden, etc.)
Warning, pl.
%(count)s pages unavailable (Not found,
Forbidden, etc.)
Recommendation
It is critical that your site pages are
available 24/7, otherwise you will lose
visitors and opportunities.
Warning (second level), sg.
n/a
Warning (second level), pl.
n/a
Status “OK”
All targeted keywords were found in the
TITLE tag on all analyzed pages.
Status “Problem”:
Warning, sg.
%(count)s page is missing keywords in the
TITLE tag.
Warning, pl.
%(count)s pages are missing keywords in
the TITLE tags.
Recommendation
Add targeted keywords to the TITLE tags of
your pages to make your pages more
relevant to SEs.
Warning (second level), sg.
%(count)s keyword was not found in the
TITLE tag
Warning (second level), pl.
%(count)s keywords were not found in the
TITLE tag
Status “OK”
All targeted keywords were found in the H1H6 headings of all analyzed pages.
Status “Problem”:
Warning, sg.
%(count)s page is missing keywords in the
H1-H6 headings.
Warning, pl.
%(count)s pages are missing keywords in
the H1-H6 headings.
Recommendation
Add targeted keywords to the H1-H6
headings to make your pages more
relevant to SEs.
Warning (second level), sg.
%(count)s keyword was not found in the
H1-H6 headings
Warning (second level), pl.
%(count)s keywords were not found in the
H1-H6 headings
Web CEO – SEO API Reference
Factor ID
Factor name
Status
on_page
Keyword optimization
kw_body
Keyword
presence
in Body
kw_body_persen
t
Keyword stuffing
on a page
Status “OK”
Texts
All targeted keywords were found in the
Body area of the analyzed pages.
Status “Problem”:
Warning, sg.
%(count)s page is missing keywords in the
Body area.
Warning, pl.
%(count)s pages are missing keywords in
the Body area.
Recommendation
Add targeted keywords to the Body area to
make your pages more relevant to SEs.
Warning (second level), sg.
%(count)s keyword was not found in the
Body area
Warning (second level), pl.
%(count)s keywords were not found in the
Body area
Status “OK”
No keyword stuffing was detected in the
Body area of the analyzed pages.
Status “Problem”:
kw_url
Page 68 of 72
Keyword
presence in
the page URL
Warning, sg.
%(count)s page with keyword stuffing in the
Body area was detected.
Warning, pl.
%(count)s pages with keyword stuffing in
the Body area were detected.
Recommendation
Remove frequently used keywords from
your pages' Body to avoid SEs spam
penalties.
Warning (second level), sg.
%(count)s keyword is excessively used in
the Body area
Warning (second level), pl.
%(count)s keywords are excessively used
in the Body area
Status “OK”
All targeted keywords were found in the
URLs of the analyzed pages.
Status “Problem”:
Warning, sg.
%(count)s page is missing keywords in the
page URL.
Warning, pl.
%(count)s pages are missing keywords in
the page URLs.
Recommendation
Change the page's URL to one with
targeted keywords, because this is one of
the most important SEO parameters.
Warning (second level), sg.
%(count)s keyword was not found in the
URL
Warning (second level), pl.
%(count)s keywords were not found in the
URL
Web CEO – SEO API Reference
Factor ID
Factor name
on_page
Keyword optimization
kw_url_one
Keyword stuffing
in the page URL
Status
Status “OK”
Texts
No keyword stuffing was detected in the
URLs of the analyzed pages.
Status “Problem”:
kw_description
kw_img_alt
Page 69 of 72
Keyword
presence in the
Description tag
Keyword
presence in
ALT attributes
of images
Warning, sg.
%(count)s page with keyword stuffing in the
page URL was detected.
Warning, pl.
%(count)s pages with keyword stuffing in the
page URL were detected.
Recommendation
Remove excessively used keywords from
the page URL to avoid SEs spam penalties.
Warning (second level), sg.
%(count)s keyword is excessively used in
the page URL
Warning (second level), pl.
%(count)s keywords are excessively used in
the page URL
Status “OK”
All targeted keywords were found in the
Description tag of the analyzed pages.
Status “Problem”:
Warning, sg.
%(count)s page is missing keywords in the
Description tag.
Warning, pl.
%(count)s pages are missing keywords in
the Description tags.
Recommendation
Add targeted keywords to the Description
tag to make it more relevant to SEs.
Warning (second level), sg.
%(count)s keyword was not found in the
Description tag
Warning (second level), pl.
%(count)s keywords were not found in the
Description tag
Status “OK”
All targeted keywords were found in the ALT
attributes of images of the targeted pages.
Status “Problem”:
Warning, sg.
%(count)s page is missing keywords in the
ALT attributes of the images.
Warning, pl.
%(count)s pages are missing keywords in
the ALT attributes of the images.
Recommendation
Add targeted keywords to the ALT attributes
of the images to make them relevant for
image search.
Warning (second level), sg.
%(count)s keyword was not found in the
image ALT attributes
Warning (second level), pl.
%(count)s keywords were not found in the
image ALT attributes
Web CEO – SEO API Reference
Examples of a JSON request to Web CEO’s API.
A sample piece of source code in several programming languages to make a call to Web CEO’s API that returns
a list of projects of a Web CEO’s account.
PHP
<?php
$command = array("key" => "YOUR_API_KEY", "method" => "get_projects");
$ch = curl_init("https://online.webceo.com/api/");
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
curl_setopt($ch, CURLOPT_POSTFIELDS, "json=".urlencode(json_encode($command)));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$result = curl_exec($ch);
$json_result = json_decode($result, True)[0];
var_dump($json_result);
?>
Page 70 of 72
Web CEO – SEO API Reference
Python
# Example in Python 2.7 that prints a list of projects added to a Web CEO's account:
import urllib
import urllib2
import json
# API command to get the list of projects added to a user's account in Web CEO
command = {"key": "YOUR_API_KEY", "method": "get_projects"}
# generate body of a POST request
opener = urllib2.build_opener(urllib2.HTTPHandler)
request = urllib2.Request("https://online.webceo.com/api/", data=urllib.urlencode({'json':
json.dumps(command)}))
# request data
response = opener.open(request)
# parse JSON response
projects = json.loads(response.read())[0]['data']
# print list of projects
for project in projects:
print project['domain']
Page 71 of 72
Web CEO – SEO API Reference
Java
import org.json.JSONObject;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.net.URL;
import java.net.URLConnection;
public class WebCEOCOnlineApiTest {
public static void main(String[] args) throws IOException {
JSONObject json = new JSONObject();
json.put("method", "get_projects");
json.put("key", "YOUR_API_KEY");
URL url = new URL("https://online.webceo.com/api/");
URLConnection connection = url.openConnection();
connection.setDoOutput(true);
// send data
OutputStreamWriter out = new OutputStreamWriter(connection.getOutputStream());
out.write("json=" + json.toString());
out.close();
// read response
StringBuilder responseSB = new StringBuilder();
BufferedReader br = new BufferedReader(new InputStreamReader(connection.getInputStream()));
String line;
while ( (line = br.readLine()) != null) {
responseSB.append(line);
}
br.close();
// responseSB now contains response
System.out.println(responseSB.toString());
}
}
Page 72 of 72
Web CEO – SEO API Reference