This is quite a concept idea. I would like to create a website that can be extend by different programmer a bit "a la facebook"
Let's me explain i want to develop a very simple core application that for example would store images and i want to develop or allow external developer to develop web app that would be able to act on the image i can take this example of an OS that would store files and you can "install" different program for example to view the files or edit.
How can i reproduce the model in the Web / cloud plateform using API ?
I hope this question make sense to any body.
Thank you by advance
Web Services. Try looking up REST and SOAP.
The Semantic Web is trying to solve this by publishing structured data with common ontologies.
See this example, describing the user's photos as RDF, using the FOAF ontology:
http://www.semanticoverflow.com/questions/201/describing-in-a-foaf-file-assets-of-a-user-photo-album-video-album-etc
The Semantic Overflow website is an excelent resource to find out more about the semantic web in general, and how creating webservices that use a common set of interfaces can allow a greater reach, because tools don't have to be specific to a website.
Related
I want to write a .NET application that will interface in realtime with Dynamics NAV 2009 and 2013. The application will have to read and update entities such as customers and stock items.
Using the provided webservices seem to be the best candidate as a point for integration, and I've tried some basic tests reading, updating and creating items using webservices based on Pages and a .net client.
Unfortunately, I am very new to Dynamics, and I have some questions that probably reflect that lack of experience.
First - webservices can expose either Page or Codeunits. Is Page the correct option to use for interfacing to say - create a customer?
Secondly - My understanding is that Dynamics NAV is rarely deployed without customisation. Would a typical customisation in NAV e.g an addition of a field involve changing a standard Page, and will this change then be reflected in the webservice definition?
You are right - given your requirements, webservices are probably the best option for interfacing with NAV.
Regarding your first question: page web services know how to handle concurrency, and, thanks to the way Visual Studio encapsulates them, expose rich types that you can interact with from your .NET code. All the basic CRUD operations can be carried out using the exposed methods. For a more detailed comparison between codeunit web services and page web services, please refer to http://msdn.microsoft.com/en-us/library/dd355398.aspx.
I think most developers choose not to publish the normal pages (the ones aimed at the NAV Windows Client; previously known as the Role Tailored Client), but instead, create separate, tweaked pages for publishing as a web service. But, if you prefer, I guess you could add your custom field to the standard page and publish that as a web service.
Hope this helps! Good luck! :)
I'm currently developing a web application, that relies heavily on mobile and desktop clients consulting the web server for information. This can be accomplished nicely making a RESTful API available to handle this. So my idea is to have an application acting as the "platform" which handles all the real business logic and database information behind the curtains.
My plan is to make the platform using symfony2 and OAuth 2.0 authentication mechanisms, combined with RESTful web services.
Now my real dilema comes on the website component. Ideally I would like to think of the website as yet another client that asks this REST platform for information, and completely separate it from the platform itself.
To make it a little bit more clear, let's say we are making a blog with this architecture, so one would have a "platform/backend" that provides a rest service to list articles, for example: /articles/5. This on the backend, and with symfony2/doctrine means that the app has an Article model class, and these can be requested from the DB. A simple controller queries for the Article number 5 and returns all the information in JSON format.
Now the website on this example, could just do the easy thing and also have an Article entity and just query the database directly, but I think it would be cleaner if it could just talk to the platform through it's REST api and use that information as a "backend" for the entities.
So the real question would be, is there anyway to support this kind of design using symfony2? Have entities rely on a REST api for CRUD operations? Or I'm just better off making the platform/website a single thing and share a "CoreBundle" with all the generic entities?
There is nothing in Symfony that prevents you from doing you want.
On the client side you could use Backbone.js or Spine.js.
Have a look at FosRestBundle, it makes your life much easier to create api:
https://github.com/FriendsOfSymfony/FOSRestBundle/blob/master/Resources/doc/index.md
Can some people offer some light on the following questions? I believe that the following questions are very much debatable, but I just want to know the mere facts which will enlighten me & of course many others viewing this general question post.
Why does Magento API produces Web Service Responses in XML format & not in JSON format? There should be some advantages in producing the responses in XML format. I want to know those advantages mainly.
In Magento terminology, there are two API versions mentioned - "Normal API" (api/soap) & "API v2 (api/v2_soap)". What's the difference (mainly the advantages) between these two versions, & where does WSDL fit in?
If I'm to create a new Web Service, should I be targeting SOAP v1 format, or the SOAP v2 format, or both of these formats?
Can the Web Service create a general definition of WSDL, based on my requirements, in Magento? What I want is that I want to know whether the "wsdl.xml" file (residing in the "etc" folder of the Magento module) for any particular Magento API module can be generated dynamically? If I provide my required API method name, along with all the property names, types, and also the Response data types, then will I get the "wsdl.xml file dynamically generated with all the Complex Types & Methods & Messages properly mentioned?"
If possible, please provide some good links, from where this spider-webs of Magento Web Services can be thoroughly cleared.
Also, please consider my expertise in this field of Web Service as a novice one, so that based on any valuable input, I can re-frame the question.
Help appreciated & thanks a lot to everybody.
My Main point of asking this question is that I want to make new custom APIs which can be used by any systems, whether it be ERP / CRM / SAP / Cloud / anything in general.
P.S.
I tried posting this question in the Programmers Stack Exchange area, but due to the lack of available required tags (like magento, wsdl & soap), I had to post it here. If possible & required, please transfer this question to proper stack exchange area.
API is not for ajax(frontend), but to integrate Magento (frontend shop) with different ERP, CRM, SAP (backend tools) systems - to import data and get reports. That's why it's using XML.
This is not magento's terminology. This is done mainly for legacy support. So you have to use lates one - v2.
What means general definition of WSDL? WSDL describes published functionality - available calls/resources. If you don't need it you need to overwrite configuration files to not publish everything but only necessary ones or do this form admin area.
Could you tell more clear and more technically what do you need to do with API?
The API works great for normal PHP programming where you want to get something out of Magento. 'Normal' API works fine with PHP, furthermore, the resultant XML is very easy to work with in comparison to the XML that gets churned out by other APIs.
Some people have said that the Magento API is slow, which it is. However, if you move the same code into a Magento program then it still takes forever, the API code isn't much of a burden.
I used WCF to create a restful web service in .NET, by means of a .svc file. The web application automatically produces a WSDL file. AFAIK, the WADL is more natural for a restful web service.
How could I create a restful service in .NET (preferably with wcf) that produces a WADL description?
Note An answer like "RTFM" is accepted, as long as you indicate a suitable manual/tutorial.
This is an old question but having consumed restful services with WADLs they do offer some value. You can import them straight into SOAPUI and it will build a test suite for you automatically. Secondly they tend to contains all the required XSDs for XML based services and are useful for automatically building serialisable classes that your endpoints accept and receive.
Looks like REST Describe & Compile should do the trick.
On the WADL developer site Marc Hadley
maintains a command line tool named
WADL2Java. The ambitious goal of REST
Describe & Compile is to provide sort
of WADL2Anything. So what REST
Describe & Compile does is that it:
Generates new WADL files in a completely interactive way.
Lets you upload and edit existing WADL files.
Allows you to compile WADL files to source code in various programming
languages.
Forgive me for answering a question with a question, but do you really want to do REST? REST really has no need for things like WADL.
Update:
The "hypermedia constraint" (aka HATEOAS) dictates that the user agent discovers content based on links embedded in previously retrieved content. It really is unnecessary to have a separate document that describes all the available content.
Imagine using a web browser to go to a site and instead of going to the home page and navigating from there, you are presented with a page which is a list of all the URLs on the site. You must then looks through the list of available urls, choose the one you are interested in and copy it into the address bar.
WADL is effectively you list of site urls. You just don't need it if your main content is linked together.
Linking content instead of using a WADL "site map" has other advantages. The available links can be dynamic based on particular data values in the content. This capability can vastly reduce the complexity of clients, because the client no longer needs to host the logic to decide when it is allowed to follow a link.
Our company has a set of 3d modeling softwares written in c++ with qt based gui. We are planning to offer these applications to customers to try them from a web browser. I mean to say, we need to create web interfaces for native c++ codes. Please suggest me which technology, languages should be used. If possible please give some links to some white papers or case studies for this kind of projects. I am totally clue less :)
Ideally you would keep your c++ code on the server and use a mixture of HTML and Javascript on the browser. However since 3d modeling is so client centric you may have to run some c++ code directly in the browser.
There are a few options to look at:
Emscripten
Adobe Alchemy
Google Native Client
A Java Applet using NestedVM
Netscape plugin API
ActiveX
You could also run a few instances of your application on your server inside an XVnc session and let people use it through a VNC viewer applet. The simplest solution however is still to offer a downloadable demo of your application.
Have a look at Wt
Take a look at Native Client.
Soon you might be use WebGL to do 3D in the browser. But how long it will take for browsers to include it I do not know. But it might be good to look at it to not rule out using it in the future.
If creating everything again is too expensive, always you can create a distributed application:
One program running the main application in C++ and generating (for example) XML files.
A web application reading the XML files generated by the C++ application and translating them into the web application language (for example Adobe Flex).
Good luck!