Note: I have found that with the last three methods prefixed blogger. We basically need to implement the following methods: However, I was able to find a definition on MSDN which was very helpful. We can now create our methods, the MetaWebLog API is documented at the XML-RPC site, but again it is not very clear. The Name parameter indicates the name of our service, in this case MetaWebLogApi, there is a description and the AutoDocumentation allows us to browse to the XML-RPC service (.ashx generic handler file) and see the available methods. Public class MetaWebLogHandler : XmlRpcService Once we have done that we need to alter the class definition as follows passing some parameters to the XML-RPC service and inheriting the class from XmlRpcService as follows: [XmlRpcService(Name = "MetaWebLogApi",ĭescription = "This is XML-RPC which implement MetaWeblog API.", Within this file we first need to reference the CookComputing.XmlRpc package as follows: using CookComputing.XmlRpc I now need to create my MetaWebLogHandler.cs class file in the App_Code directory. You can now create or consume an XML-RPC service.įor this example I am going to implement the MetaWebLog API in C# to do this we need to add two files to our project, a generic handler and a class file to handler requests to the generic handler.įor this example I will create a handler named MetaWebLog.ashx and it will contain simply the following webhandler directive: Once extracted you will need to copy this. zip archive: This is the core component you will need:įor. Once you have downloaded the latest version, extract only the following file from the. Although I think the XML-RPC implementation is an excellent stable offering, the documentation is a little sketchy and hard to follow at times which is why I am posting this tutorial. Net XML-RPC implementation from CooksComputing. To start working with XML-RPC, the first thing you will need to do in download the. You can create an XML-RPC server or client easily within an existing project. Net XML-RPC framework already exists for use in ASP.Net, which has been developed by Charles Cook of CookComputing. The MetaWebLog API runs over XML-RPC an open standard for HTTP based remote procedure calls and is the standard api protocol for blog platforms. My tutorial below will show you how to easily create or consume an XML-RPC service such as the MetaWebLog API. I have recently be working on a project which needed to implement the blogging MetaWebLog API, allowing users to post blog messages from their favorite blog editor, such as Windows Live Writer or blog directly from MetaWebLog API enabled websites such as Flickr or Digg.
0 Comments
Leave a Reply. |