Ping the Semantic Web Logo
upper left corner gradient

  1. Setting up Your Ping Service Interface
  2. Setting up an XML-RPC Client
  3. Setting up a REST Client


Setting up Your Ping Service Interface


Any web service can communicate with PingtheSemanticWeb.com via two interfaces: REST and XML-RPC. You simply configure your Web service or software agent to ping PingtheSemanticWeb.com anytime you publish new RDF document on the Web.


Setting up an XML-RPC Client


The XML RPC request should be constructed based on:

RPC endpoint: http://rpc.pingthesemanticweb.com/

Method name: weblogUpdates.ping

Parameters: (should be sent in the same order as listed below) name of site (string, limited to 1024 characters [this field is not used by PingtheSemanticWeb for the moment so this string can be empty]) URL of site or RDF document (string, limited to 2048 characters)

Note: I use the "weblogUpdates.ping" method used by Weblogs.com for the only reason that this "protocol" is already implemented in a full of softwares like major blogging softwares. This way, bloggers that export RDF documents will only have to add PingtheSemanticWeb.com to the servers to ping when they publish content.


The XML RPC response will have a Struct with two members:

flerror (Boolean) which is true/1 if an error occurred
message (string) which contains "Thanks for the ping."(if successful) or an error message.


Example XML-RPC Request:


POST /ping/xmlrpc HTTP/1.0
User-Agent: Java
Host: rpc.pingthesemanticweb.com
Content-Type: text/xml
Content-length: 250


<?xml version="1.0"?>
<methodCall>
     <methodName>weblogUpdates.ping</methodName>
     <params>
         <param>
             <value>Some title page</value>
         </param>
         <param>
             <value>http://www.talkdigger.com/conversations/some_conversation.html</value>
         </param>
     </params>
</methodCall>



Example XML-RPC Response:


HTTP/1.1 200 OK
Date: Fri, 11 Aug 2006 15:48:54 GMT
Server: Apache/1.3.36 (Unix)
X-Powered-By: PHP/5.1.4
Connection: close
Content-Length: 383
Content-Type: text/xml

<?xml version="1.0"?>
     <methodResponse>
         <params>
             <param>
                 <value>
                     <struct>
                         <member>
                             <name>flerror</name>
                             <value>
                                 <boolean>0</boolean>
                             </value>
                         </member>
                         <member>
                             <name>message</name>
                             <value>Thanks for pinging PingtheSemanticWeb.com</value>
                         </member>
                     </struct>
                 </value>
             </param>
         </params>
    </methodResponse>


Possible XML-RPC errors


  • This document have already been updated by PingtheSemanticWeb.com in the last hour.
  • Ping the Semantic Web is not allowed to index this URL.
  • An unexpected error occured.



Setting up a REST Client

PingtheSemanticWeb.com accepts form-based HTTP POST and GET requests for non-extended pings. For example, the following is a valid HTTP GET ping request:

URL: http://pingthesemanticweb.com/rest/?url=[url]

Where [url] have to be replaced by the escaped URL of the FOAF or SIOC document to update.

Note: You have to escape the reserved characters: {";" | "/" | "?" | ":" | "@" | "&" | "=" | "+" | "$" | ","}

Example HTTP GET request:

http://pingthesemanticweb.com/rest/?url=http%3A//apassant.net/blog/sioc.php
upper right corner gradient