Giter Site home page Giter Site logo

fakerestapi's Introduction

*Note Domain name changed from fakerestapi.tk to fakerestapi.com

fake online REST API https://fakerestapi.com

REST API for developers to test and prototyping of sample applications.

Download free csv data sets https://fakerestapi.com/download_csv_files Available CSV files

  1. Products - 2000 records
  2. Todo lists - 1000 records
  3. Todo items - 2000 records

visit https://fakerestapi.com to know about total records and fields in csv datasets

Api endpoint link https://fakerestapi.com/api/v1/todo_lists

Example

curl -X GET https://fakerestapi.com/api/v1/todo_lists
[
  {
	  "id" : 1,
	  "title" : todo list title,
	  "description" : todo list description,
	  "due_date":"2020-01-19T22:48:47.998Z"
	  "created_at" : 2019-08-29T19:07:55.585Z,
	  "updated_at" : 2019-08-31T03:50:58.390Z
  }
  ......
  ......
]

Fake rest api with CURL https://fakerestapi.com/fetch_data_with_curl

Fake rest api with jQuery https://fakerestapi.com/jquery_ajax

Fake rest api with ruby https://fakerestapi.com/ruby_rest_client_with_fake_rest_api

fakerestapi's People

Contributors

ganesh-raju avatar

Watchers

 avatar

fakerestapi's Issues

How to use fake online REST API in python

Requests python library is make common http requests.
install requests library with pip.

pip install requests

Get:

todo_list = requests.get('https://fakerestapi.com/api/v1/todo_lists/1')
todo_lists.status_code

200

todo_list.content

'{
       "id":1,
       "title":"Creative Arts 151",
        "due_date":"2020-06-11T11:03:41.119Z",
        "description":"Dolorem omnis consequatur. Modi voluptatem nihil. Quo quis debitis.",
         "created_at":"2019-09-07T13:41:23.170Z",
        "updated_at":"2019-09-07T13:41:23.170Z"
}'

Post

todo_list = requests.post('https://fakerestapi.com/api/v1/todo_lists', {'title': "request from pytho", 'description': "Posting from python request library"})

todo_list.content

{
     "id":1011,
     "title":"request from pytho",
     "due_date":null,
     "description":"Posting from python request library",
     "created_at":"2019-11-02T06:05:15.002Z",
     "updated_at":"2019-11-02T06:05:15.002Z"
}'

Delete

todo_list = requests.delete('https://fakerestapi.com/api/v1/todo_lists/800')
todo_list.content
200

Patch

todo_list = requests.patch('https://fakerestapi.com/api/v1/todo_lists/805', {'title': 'updated from python'})

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.