Which Bin

A super simple JSON bin day API for Eastleigh, UK. Docs

What is this?

A JSON API for Eastleigh Borough Council that tells you when your bins are due for collection. Use it to build cool things.

How does it work?

When called, the API checks Eastleigh council's website and transforms the data into JSON for easy ingestion. Results are cached for 24 hours for efficiency.

Example Request

 curl -s https://whichb.in/next/10091132558 

Example Response

			[
				{
					"name":"Household Waste Bin",
					"date":"20 Jan 2020"
				},
				{
					"name":"Food Waste Bin",
					"date":"13 Jan 2020"
				},
				{
					"name":"Recycling Bin",
					"date":"13 Jan 2020"
				},
				{
					"name":"Glass Box and Batteries",
					"date":"21 Jan 2020"
				}
			]
		
See whichb.in/docs for a more detailed overview and explanation.

How do I use it?

See whichb.in/docs

Is it free?

Yes, for non commercial use. Although I ask that if it is useful to you you consider buying me a coffee.

Why would anyone need this?

Why not‽ I wanted my bin collection dates on my home automation dashboard. Then I made a watchapp to go with it too.

But couldn't you just check the day of the week? Why do you need an API?

I could, but this wouldn't account for the other bins (glass, garden waste), and also bank holidays throw it off too. Plus overengineering these things is fun.

Do you store any of my information?

When you make a request, your UPRN is used to fetch the data from Eastleigh's website. The data is then cached in memory, but not written to disk. Your IP address will be logged by apache, but not stored for any analytics purposes. The API is designed to store as little information as required.

Add support for $county. Add $feature.

If your council have a website where you can check which bins are due, email me at mail @ willow . systems with the subject whichbin request and I'll see what I can do. Work for a council? Get in touch and let's build something cool.

For feature requests shoot me an email or get in touch via twitter

A project by Will Murphy | Donate