Giter Site home page Giter Site logo

feedbin-api's Introduction

Feedbin API V2

This is the official documentation for the Feedbin REST-style API.

API Objects

Tech Notes

Changes

Making Requests

The base URL for all requests is https://api.feedbin.com/v2/ Only https is supported.

The Feedbin API uses HTTP Basic authentication

Using cURL you would make a request like:

curl -u '[email protected]:password' https://api.feedbin.com/v2/subscriptions.json

When creating or updating a record you must set application/json; charset=utf-8 as the Content-Type header.

curl -u '[email protected]:password' \
-H "Content-Type: application/json; charset=utf-8" \
-X POST -d '{"feed_url":"http://daringfireball.net"}' \
https://api.feedbin.com/v2/subscriptions.json

Without this header you'll wind up with a 415 Unsupported Media Type response.

HTTP Caching, Use It

For extra speed, please use HTTP Caching. GET request set ETag and a Last-Modified headers.

curl -v -u '[email protected]:password'  https://api.feedbin.com/v2/subscriptions/3.json
< ETag: "c7d001e87bda1f0d3745b6bd2811b055"
< Last-Modified: Sat, 02 Feb 2013 15:20:46 GMT

You can use these headers in subsequent requests like:

curl -v -u '[email protected]:password' --header 'If-Modified-Since:Sat, 02 Feb 2013 15:20:46 GMT' --header 'If-None-Match:"c7d001e87bda1f0d3745b6bd2811b055"' https://api.feedbin.com/v2/subscriptions/3.json
< HTTP/1.1 304 Not Modified

Pagination

Entries use pagination. Each page has a limit of 100 items. Paginated request will include a link header like:

Links: <https://api.feedbin.com/v2/feeds/1/entries.json?page=2>; rel="next", <https://api.feedbin.com/v2/feeds/1/entries.json?page=5>; rel="last"

The possible rel values are:

  • first The URL of the first page of results.
  • prev The URL of the previous page of results.
  • next The URL of the next page of results.
  • last The URL of the last page of results.

On paginated resources there is a header in the response called: X-Feedbin-Record-Count. This header reports the total number of records for a resource.

Dates

The Feedbin API uses the ISO 8601 date format. All responses will include dates formatted to this spec and all requests should stick to it as well. The dates are as high resolution as possible to allow for rapid state changes. When using the since parameter it is best to include the date exactly as it was returned by the server when the last request was made. Rounding down to the nearest second will most likely cause duplicates.

The date should include complete date plus hours, minutes, seconds and timezone YYYY-MM-DDThh:mm:ss.ssssssTZD (eg 2013-02-19T07:33:38.449047-08:00 or in UTC 2013-02-19T15:33:38.449047Z). All dates will be converted to UTC, so the timezone is very important.

Note

In Objective-C it's important to force a locale for the date because different regions can cause unexpected output. For example you can properly format a date for the Feedbin API like:

NSDateFormatter *feedbinDateFormatter = [[NSDateFormatter alloc] init];
feedbinDateFormatter.timeZone = [NSTimeZone timeZoneWithAbbreviation:@"GMT"];
[feedbinDateFormatter setDateFormat:@"yyyy-MM-dd'T'HH:mm:ss.SSSSSS'Z'"];
[feedbinDateFormatter setLocale:[[NSLocale alloc] initWithLocaleIdentifier:@"en_US"]];

Thanks to Stefan Pauwels for sharing this tip.

Domain

Until 2014-03-14 the API hostname was api.feedbin.me. api.feedbin.me will remain available but api.feedbin.com is recommended because it is the new primary domain.

feedbin-api's People

Contributors

benubois avatar brendanlong avatar gbouerat avatar paulombcosta avatar robzolkos avatar zegnat avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.