Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gumb0/cpp-instagram
C++ wrapper for Instagram REST API
https://github.com/gumb0/cpp-instagram
Last synced: 22 days ago
JSON representation
C++ wrapper for Instagram REST API
- Host: GitHub
- URL: https://github.com/gumb0/cpp-instagram
- Owner: gumb0
- License: mit
- Created: 2014-07-11T13:23:22.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-11-06T12:46:16.000Z (about 10 years ago)
- Last Synced: 2024-10-10T17:19:46.060Z (about 1 month ago)
- Language: C++
- Size: 495 KB
- Stars: 9
- Watchers: 6
- Forks: 4
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
cpp-instagram
=============C++ client library for Instagram REST API.
Only some of the APIs are supported now.
Has been built with MS Visual Studio Express 2013 (see solution and project files in msvc directory), but contains no platform dependencies and should be easily portable.
requirements
-------* boost/format http://www.boost.org/doc/libs/1_55_0/libs/format/
* libcurl http://curl.haxx.se/libcurl/
* jsoncpp https://github.com/open-source-parsers/jsoncpp
* Google Mock for tests https://code.google.com/p/googlemocksample code
----
``` cpp
#include "cpp-instagram/AuthenticatedClient.h"
#include "cpp-instagram/Exception.h"using namespace Instagram;
void downloadPopularImages()
{
try
{
AuthenticatedClientPtr client = CreateAuthenticatedClient(userToken);MediaList medias = client->getPopularMedias();
for (MediaPtr media : medias)
{
const std::string id = media->getId();
media->getImages()->getStandardResolution()->download(id + ".jpg");
}
}
catch (const Exception& e)
{
std::cerr << e.getMessage() << std::endl;
}
}
```