I don't like to answer my own question but I have fixed it and just in case anyone else has the same problem I will document it here.
I modified the twitCurl code to add an extra parameter, a string to represent the 'since_id'. It was really straightforward in the end and I have submitted the changes to the twitCurl developers. Here is my diff of the changes if you can't wait:
Index: twitcurl.cpp
===================================================================
--- twitcurl.cpp (revision 25)
+++ twitcurl.cpp (working copy)
@@ -474,19 +474,28 @@
*
* @description: method to get mentions
*
-* @input: none
+* @input: sinceId - since_id in string format
*
* @output: true if GET is success, otherwise false. This does not
check http
* response by twitter. Use getLastWebResponse() for that.
*
*--*/
-bool twitCurl::mentionsGet()
+bool twitCurl::mentionsGet( std::string sinceId )
{
bool retVal = false;
if( isCurlInit() )
{
+ /* Prepare URL */
+ std::string buildUrl( "" );
+ buildUrl = twitterDefaults::TWITCURL_MENTIONS_URL;
+ if( sinceId.length() )
+ {
+
buildUrl.append( twitCurlDefaults::TWITCURL_SINCEID.c_str() );
+ buildUrl.append( sinceId.c_str() );
+ }
+
/* Perform GET */
- retVal =
performGet( twitterDefaults::TWITCURL_MENTIONS_URL );
+ retVal = performGet( buildUrl );
}
return retVal;
}
Index: twitcurl.h
===================================================================
--- twitcurl.h (revision 25)
+++ twitcurl.h (working copy)
@@ -24,6 +24,7 @@
const std::string TWITCURL_EXTENSIONFORMAT = ".xml";
const std::string TWITCURL_TARGETSCREENNAME = "?
target_screen_name=";
const std::string TWITCURL_TARGETUSERID = "?target_id=";
+ const std::string TWITCURL_SINCEID = "?since_id=";
};
/* Default twitter URLs */
@@ -123,7 +124,7 @@
bool timelineFriendsGet();
bool timelineUserGet( std::string userInfo = "" /* in */, bool
isUserId = false /* in */ );
bool featuredUsersGet();
- bool mentionsGet();
+ bool mentionsGet( std::string sinceId = "" );
/* Twitter user APIs */
bool userGet( std::string& userInfo /* in */, bool isUserId =
false /* in */ );