Part 3 - Set up Drupal 7 REST web server and create a .NET client to perform CRUD operations

While migrating contents from SharePoint 2010 content library to Drupal 7 content node repository (I am not sure the official name) , I have noticed that the way Drupal identifies the node is different than the way SharePoint identifies each SPListItem. SharePoint uses globally/universally unique identifier (GUID or UUID) to identify contents contrast to Drupal which uses node id which consists of sequential integer value.

Fortunately, I was wrong. In fact, there is a field in Drupal node that stores UUID value. Since I was trying to push contents from SharePoint to Drupal via REST call, I was thrilled to find this field, but immediately, I found another roadblock. If you look at my previous post (Part 2), I was targeting each node via node id. To get a node, I had to do something like this:  http://serverip/rest/node/101. But, I was not able to target a node by UUID, for an example, http://serverip/rest/node/343d0210-cdd7-19c4-85b5-da467712fs43.

While investigating the problem, I found a solution. In fact, I could use a querystring to target a node. I guess Apache (or something) was handling a clean URL.

Here is the syntax:

http://serverip/rest/node?parameters[uuid]=343d0210-cdd7-19c4-85b5-da467712fs43

I hope this helps.







Comments

Popular Posts