thoughtworks-jumpstart / api

๐Ÿ’โ€โ™€๏ธ A simple API service powered by My JSON Server

Home Page:https://my-json-server.typicode.com/thoughtworks-jumpstart/api

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

API

๐Ÿ’โ€โ™€๏ธ A simple API service powered by My JSON Server

Available resources

Fruits

GET /fruits - get all fruits

GET /fruits/:id - get a fruit by id

Posts

GET /posts - get all posts

Books and authors

GET /authors - get all authors

GET /books - get all books

GET /authors/:id/books - get all books from an author by id

Pokemon

GET /pokemon - get all Pokรฉmon

GET /pokemon/id - get a Pokรฉmon by id

Create a new resource

To create a new resource simply add a new property to db.json. See example here.

{
  "posts": [
    { "id": 1, "title": "Post 1" },
    { "id": 2, "title": "Post 2" },
    { "id": 3, "title": "Post 3" }
  ],
  "comments": [
    { "id": 1, "body": "some comment", "postId": 1 },
    { "id": 2, "body": "some comment", "postId": 1 }
  ]
}

This creates two resources posts and comments and these endpoints

  • GET /posts - gets all posts
  • GET /posts/1 - gets one post with id
  • GET /comments - gets all comments
  • GET /comments/1 - gets one comment with id
  • GET /posts/1/comments - gets all comments belonging to a post

List of public APIs

You may want to check these out for public APIs

Caveat emptor

โ˜๏ธ This API service is used for training and teaching purposes only. It is not meant to be used for production apps.

About

๐Ÿ’โ€โ™€๏ธ A simple API service powered by My JSON Server

https://my-json-server.typicode.com/thoughtworks-jumpstart/api