Giter VIP home page Giter VIP logo

fp-api-design-challenge's Introduction

fp-api-design-challenge

Api root https://api.neightbourhoodcolab.com

Basic API info

API Endpoints

People

Houses

GET /houses

Returns all houses and their owners

Example endpoint: GET https://api.neightbourhoodcolab.com/houses?api_key=my_key

Query options:

Query Description Additional info
api_key api key for authenticating access required to access API
limit limits the number of results default: 50. If 0, will return all houses

Response

{
	"houses": [
		{
			"owner": {
        "id": number unique id,
        "name": string,
        "age": number,
        "number_of_occupants": number,
      }
			"house": {
        "id": number unique id,
        "house_number": number,
        "house_name": string,
        "address_line_1":  string,
        "address_line_2":  string or null,
        "address_line_3":  string or null,
        "county": string,
        "postcode": string,
      }
		},
    // ...
	]
}

GET /houses/search

Returns and array of houses based on search query parametres.

By default returns all houses and owners.

Example endpoint: GET https://api.neightbourhoodcolab.com/houses/search?api_key=my_key&postcode=np255py

Query options:

Query Description Additional info
api_key Api key for authenticating access Required to access API
limit Limits the number of results Default: 50. If 0, will return all houses
postcode Query based on postcode
house_name Query based on house name
house_number Query based on house number

Database

our data is stored in a relational database and the structure is outlined below.

People Database

id name age number_of_occupants
number string number number or null

Owners Database

owner_id house_id
number number

Address Database

id house_number house_name address_line_1 address_line_2 address_line_3 county postcode
number number or null string or null string string or null string or null string string

fp-api-design-challenge's People

Contributors

velocima avatar iamdanielcooper 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.